File: ltmain_as-needed.patch

package info (click to toggle)
cairo 1.12.2-3
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 100,404 kB
  • sloc: ansic: 226,667; xml: 16,073; sh: 12,046; cpp: 3,725; cs: 1,763; makefile: 1,070; python: 155; awk: 86
file content (32 lines) | stat: -rw-r--r-- 910 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
Index: cairo/build/ltmain.sh
===================================================================
--- cairo.orig/build/ltmain.sh	2010-06-26 16:12:17.428175248 +0200
+++ cairo/build/ltmain.sh	2010-06-26 16:13:17.044176141 +0200
@@ -5800,6 +5800,11 @@
 	arg=$func_stripname_result
 	;;
 
+      -Wl,--as-needed)
+	deplibs="$deplibs $arg"
+	continue
+	;;
+
       -Wl,*)
 	func_stripname '-Wl,' '' "$arg"
 	args=$func_stripname_result
@@ -6163,6 +6168,15 @@
 	lib=
 	found=no
 	case $deplib in
+	-Wl,--as-needed)
+	  if test "$linkmode,$pass" = "prog,link"; then
+	    compile_deplibs="$deplib $compile_deplibs"
+	    finalize_deplibs="$deplib $finalize_deplibs"
+	  else
+	    deplibs="$deplib $deplibs"
+	  fi
+	  continue
+	  ;;
 	-mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe \
         |-threads|-fopenmp|-openmp|-mp|-xopenmp|-omp|-qsmp=*)
 	  if test "$linkmode,$pass" = "prog,link"; then