diff -Nru juce-5.4.4~repack0/debian/changelog juce-5.4.4~repack0/debian/changelog --- juce-5.4.4~repack0/debian/changelog 2019-08-21 11:56:30.000000000 +0000 +++ juce-5.4.4~repack0/debian/changelog 2019-08-22 08:01:56.000000000 +0000 @@ -1,3 +1,14 @@ +juce (5.4.4~repack0-3) unstable; urgency=medium + + * Make Makefiles created by Debian's Projucer compile without further ado + * Add patch to link against (required) system-libraries + * Add patch to inject LIBS into Projucer's Makefile-exporter from the + from the cmdline + * Make armel/mipsel/... Projucer add "-latomic" to LIBS + * Document the Projucer fixes in README.Debian + + -- IOhannes m zmölnig (Debian/GNU) Thu, 22 Aug 2019 10:01:56 +0200 + juce (5.4.4~repack0-2) unstable; urgency=medium * Link against "libatomic" on armel/mipsel/... to fix FTBFS diff -Nru juce-5.4.4~repack0/debian/patches/debian_link_systemlibs.patch juce-5.4.4~repack0/debian/patches/debian_link_systemlibs.patch --- juce-5.4.4~repack0/debian/patches/debian_link_systemlibs.patch 1970-01-01 00:00:00.000000000 +0000 +++ juce-5.4.4~repack0/debian/patches/debian_link_systemlibs.patch 2019-08-22 08:01:56.000000000 +0000 @@ -0,0 +1,61 @@ +Description: have Projucer link against the system libraries + since the Debian package has removed 3rd-party libraries (jpeg, png, flag, + ogg/vorbis), we must use against the system libraries. +Author: IOhannes m zmölnig +Origin: Debian +Forwarded: no +Last-Update: 2019-08-21 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +--- juce.orig/extras/Projucer/Source/ProjectSaving/jucer_ProjectExport_Make.h ++++ juce/extras/Projucer/Source/ProjectSaving/jucer_ProjectExport_Make.h +@@ -464,6 +464,39 @@ + if (isCurlEnabled() && ! isLoadCurlSymbolsLazilyEnabled()) + packages.add ("libcurl"); + ++ // on Debian, a number of 3rd-party libs have been stripped away, ++ // so we need to link to the system libraries ++ if (project.getEnabledModules().isModuleEnabled ("juce_core")) ++ { ++ packages.add ("zlib"); ++ } ++ if (project.getEnabledModules().isModuleEnabled ("juce_graphics")) ++ { ++ packages.add ("libjpeg"); ++ packages.add ("libpng"); ++ } ++ if (project.getEnabledModules().isModuleEnabled ("juce_audio_formats")) ++ { ++ if(project.isConfigFlagEnabled ("JUCE_USE_FLAC", true)) ++ { ++ packages.add ("flac"); ++ } ++ ++ if(project.isConfigFlagEnabled ("JUCE_USE_OGGVORBIS", true)) ++ { ++ packages.add ("vorbis"); ++ packages.add ("vorbisfile"); ++ packages.add ("vorbisenc"); ++ packages.add ("ogg"); ++ } ++ } ++ if (project.getEnabledModules().isModuleEnabled ("juce_audio_devices")) ++ { ++ if(project.isConfigFlagEnabled ("JUCE_JACK", true)) ++ { ++ packages.add ("jack"); ++ } ++ } + packages.removeDuplicates (false); + + return packages; +@@ -563,6 +596,9 @@ + StringArray result (linuxLibs); + + auto libraries = StringArray::fromTokens (getExternalLibrariesString(), ";", "\"'"); ++#ifdef DEBIAN_JUCERPROJECT_LIBS ++ libraries.addArray(StringArray::fromTokens (DEBIAN_JUCERPROJECT_LIBS, ";", "\"'")); ++#endif + libraries.removeEmptyStrings(); + + for (auto& lib : libraries) diff -Nru juce-5.4.4~repack0/debian/patches/series juce-5.4.4~repack0/debian/patches/series --- juce-5.4.4~repack0/debian/patches/series 2019-08-21 11:56:30.000000000 +0000 +++ juce-5.4.4~repack0/debian/patches/series 2019-08-22 08:01:56.000000000 +0000 @@ -8,4 +8,5 @@ debian_python3.patch debian_unittests_globalpaths.patch debian_vst.patch +debian_link_systemlibs.patch spelling.patch diff -Nru juce-5.4.4~repack0/debian/README.Debian juce-5.4.4~repack0/debian/README.Debian --- juce-5.4.4~repack0/debian/README.Debian 2019-08-21 11:56:30.000000000 +0000 +++ juce-5.4.4~repack0/debian/README.Debian 2019-08-22 08:01:56.000000000 +0000 @@ -53,6 +53,25 @@ make LDFLAGS="$(pkg-config --libs libpng libjpeg flac vorbis vorbisfile vorbisenc ogg zlib)" + *Alternatively*, resave the JUCE-project with the Debian-packaged 'Projucer' + (>=5.4.4~repack0-3) which will take care of adding these libraries (if + required) to the LinuxMakefile build. + +- When compiling for some embedded architectures (notably 'armel', 'mipsel' and + the like), you might need to link against '-latomic'. + The following snippet for d/rules can help inject the library on the required + architectures: + + # link with libatomic on architectures without built-in atomic + noatomicarch = $(shell dpkg-architecture -qDEB_HOST_ARCH | egrep -x "(armel|powerpc|powerpcspe|m68k|mips|mipsel|sh4|riscv64)") + ifeq ($(if $(noatomicarch),atomic), atomic) + LDFLAGS += -latomic + endif + + *Alternatively*, resave the JUCE-project with the Debian-packaged 'Projucer' + (>=5.4.4~repack0-3) which will take care of adding the relevant flags to the + LinuxMakefile build. + - Also be aware, that Projucer generated makefiles usually include "-march=native", which is mostly not what you want for a generic baseline CPU build. diff -Nru juce-5.4.4~repack0/debian/rules juce-5.4.4~repack0/debian/rules --- juce-5.4.4~repack0/debian/rules 2019-08-21 11:56:30.000000000 +0000 +++ juce-5.4.4~repack0/debian/rules 2019-08-22 08:01:56.000000000 +0000 @@ -30,6 +30,7 @@ # link with libatomic on architectures without built-in atomic ifeq ($(if $(noatomicarch),atomic), atomic) LDFLAGS += -latomic + CPPFLAGS += -DDEBIAN_JUCERPROJECT_LIBS='\"atomic\"' endif %: @@ -41,6 +42,7 @@ dh_auto_build -D $(DEB_SRCDIR) -- \ V=1 \ LDFLAGS="$(LDFLAGS)" \ + CPPFLAGS="$(CPPFLAGS)" \ $(empty) make -C debian/extra/lv2-ttl-generator/ help2man -N \