Description: Some CCOPTIONS are not valid LDOPTIONS (e.g., -mminimal-toc), so filter-out NOTLDOPTIONS Author: Mauricio Faria de Oliveira Origin: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=765370;msg=5;att=1;filename=xutils-dev-ppc64el.debdiff Last-Update: 2016-01-07 diff --git a/Imake.tmpl b/Imake.tmpl index 9d02cb6..3e5c28e 100644 --- a/Imake.tmpl +++ b/Imake.tmpl @@ -2064,6 +2064,7 @@ MODLDCOMBINEFLAGS = ModuleLdCombineFlags CDEBUGFLAGS = DefaultCDebugFlags CCOPTIONS = DefaultCCOptions /* to distinguish from param flags */ + NOTLDOPTIONS = DefaultNotLDOptions /* not to be used as linker options */ /* * STD_INCLUDES contains system-specific includes * TOP_INCLUDES specifies how to get to /usr/include or its build substitute @@ -2078,6 +2079,7 @@ MODLDCOMBINEFLAGS = ModuleLdCombineFlags LDPRELIB = LdPreLib $(INSTALLED_LIBS) LDPOSTLIB = LdPostLib LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) $(EXTRA_LDOPTIONS) $(THREADS_LDFLAGS) $(LOCAL_LDFLAGS) $(LDPRELIBS) + LDOPTIONS := $(filter-out $(NOTLDOPTIONS),$(LDOPTIONS)) CXXLDOPTIONS = $(CXXDEBUGFLAGS) $(CXXOPTIONS) $(EXTRA_LDOPTIONS) $(THREADS_CXXLDFLAGS) $(LOCAL_LDFLAGS) $(LDPRELIBS) LDLIBS = $(LDPOSTLIBS) $(THREADS_LIBS) $(SYS_LIBRARIES) $(EXTRA_LIBRARIES) diff --git a/linux.cf b/linux.cf index 7845325..e2f28fa 100644 --- a/linux.cf +++ b/linux.cf @@ -898,6 +898,7 @@ InstallNamedTargetNoClobber(install,file.ad,$(INSTAPPFLAGS),$(XAPPLOADDIR),class #ifdef Ppc64Architecture # define DefaultCCOptions -mminimal-toc +# define DefaultNotLDOptions -mminimal-toc # ifndef OptimizedCDebugFlags # define OptimizedCDebugFlags DefaultGcc2Ppc64Opt # endif