Source: juce Version: 4.1.0+repack-2 Severity: normal Tags: patch Dear Maintainer,
The package juce fails to build from source on ppc64el with the following: > <command-line>:0:7: error: expected identifier before numeric constant > ../../Source/Application/../Application/jucer_CommonHeaders.h:35:9: note: in > expansion of macro 'linux' > linux, > ^ > <command-line>:0:7: error: expected '}' before numeric constant > ../../Source/Application/../Application/jucer_CommonHeaders.h:35:9: note: in > expansion of macro 'linux' > linux, > ^ > <command-line>:0:7: error: expected unqualified-id before numeric constant > ../../Source/Application/../Application/jucer_CommonHeaders.h:35:9: note: in > expansion of macro 'linux' > linux, > ^ And some more errors related to the same. That is due to the preprocessor macro 'linux' being defined on ppc64el, with the usage of 2 -std flags: -std=gnu++0x and -std=c++11. When not using -std=gnu++0x, the package builds on ppc64el. I know the Makefile is not supposed to be editted, but since we do not regenerate it in the debian build, my patch edits it anyway. The patch is attached. Let me know if you have comments or suggestions. Regards. Fernando
diff -Nru juce-4.1.0+repack/debian/changelog juce-4.1.0+repack/debian/changelog --- juce-4.1.0+repack/debian/changelog 2016-02-16 10:45:30.000000000 -0500 +++ juce-4.1.0+repack/debian/changelog 2016-02-26 09:11:39.000000000 -0500 @@ -1,3 +1,11 @@ +juce (4.1.0+repack-2.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Removing usage of flag -std=gnu++0x for ppc64el, since it redefines + preprocessor macro "linux 1", which causes ftbfs on ppc64el. + + -- Fernando Seiti Furusato <ferse...@br.ibm.com> Fri, 26 Feb 2016 09:06:33 -0500 + juce (4.1.0+repack-2) unstable; urgency=medium * Use numeric build-date diff -Nru juce-4.1.0+repack/debian/patches/series juce-4.1.0+repack/debian/patches/series --- juce-4.1.0+repack/debian/patches/series 2016-02-11 06:42:47.000000000 -0500 +++ juce-4.1.0+repack/debian/patches/series 2016-02-26 09:05:41.000000000 -0500 @@ -6,3 +6,4 @@ debian_introjucer-modulepath.patch debian_make-introjucer.patch debian_do-not-track.patch +standard-definition.patch diff -Nru juce-4.1.0+repack/debian/patches/standard-definition.patch juce-4.1.0+repack/debian/patches/standard-definition.patch --- juce-4.1.0+repack/debian/patches/standard-definition.patch 1969-12-31 19:00:00.000000000 -0500 +++ juce-4.1.0+repack/debian/patches/standard-definition.patch 2016-02-26 09:05:41.000000000 -0500 @@ -0,0 +1,32 @@ +Index: juce-4.1.0+repack/extras/Introjucer/Builds/Linux/Makefile +=================================================================== +--- juce-4.1.0+repack.orig/extras/Introjucer/Builds/Linux/Makefile ++++ juce-4.1.0+repack/extras/Introjucer/Builds/Linux/Makefile +@@ -20,8 +20,12 @@ ifeq ($(CONFIG),Debug) + TARGET_ARCH := + endif + ++ ifneq ($(shell uname -m), ppc64le) ++ JUCE_CFLAGS += -std=gnu++0x ++ endif ++ + JUCE_CPPFLAGS := $(DEPFLAGS) -D "LINUX=1" -D "DEBUG=1" -D "_DEBUG=1" -D "JUCER_LINUX_MAKE_7346DA2A=1" -D "JUCE_APP_VERSION=4.1.0" -D "JUCE_APP_VERSION_HEX=0x40100" -I /usr/include -I /usr/include/freetype2 -I ../../JuceLibraryCode -I ../../../../modules $(CPPFLAGS) +- JUCE_CFLAGS += $(JUCE_CPPFLAGS) $(TARGET_ARCH) -g -ggdb -O0 -std=gnu++0x -Wreorder -Wuninitialized -Wunused-parameter -Wstrict-aliasing -Wshadow -Wsign-compare $(CFLAGS) ++ JUCE_CFLAGS += $(JUCE_CPPFLAGS) $(TARGET_ARCH) -g -ggdb -O0 -Wreorder -Wuninitialized -Wunused-parameter -Wstrict-aliasing -Wshadow -Wsign-compare $(CFLAGS) + JUCE_CXXFLAGS += $(JUCE_CFLAGS) -std=c++11 $(CXXFLAGS) + JUCE_LDFLAGS += $(TARGET_ARCH) -L$(BINDIR) -L$(LIBDIR) -L$(LIBJUCE_PATH) -ljuce_d $(LDFLAGS) + +@@ -40,8 +44,12 @@ ifeq ($(CONFIG),Release) + TARGET_ARCH := + endif + ++ ifneq ($(shell uname -m), ppc64le) ++ JUCE_CFLAGS += -std=gnu++0x ++ endif ++ + JUCE_CPPFLAGS := $(DEPFLAGS) -D "LINUX=1" -D "NDEBUG=1" -D "JUCER_LINUX_MAKE_7346DA2A=1" -D "JUCE_APP_VERSION=4.1.0" -D "JUCE_APP_VERSION_HEX=0x40100" -I /usr/include -I /usr/include/freetype2 -I ../../JuceLibraryCode -I ../../../../modules $(CPPFLAGS) +- JUCE_CFLAGS += $(JUCE_CPPFLAGS) $(TARGET_ARCH) -O3 -std=gnu++0x -Wreorder -Wuninitialized -Wunused-parameter -Wstrict-aliasing -Wshadow -Wsign-compare $(CFLAGS) ++ JUCE_CFLAGS += $(JUCE_CPPFLAGS) $(TARGET_ARCH) -O3 -Wreorder -Wuninitialized -Wunused-parameter -Wstrict-aliasing -Wshadow -Wsign-compare $(CFLAGS) + JUCE_CXXFLAGS += $(JUCE_CFLAGS) -std=c++11 $(CXXFLAGS) + JUCE_LDFLAGS += $(TARGET_ARCH) -L$(BINDIR) -L$(LIBDIR) -fvisibility=hidden -L$(LIBJUCE_PATH) -ljuce $(LDFLAGS) +