File: 00_fix_as-needed.diff

package info (click to toggle)
quesoglc 0.7.2-8
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 4,192 kB
  • sloc: ansic: 14,620; sh: 9,718; makefile: 283; python: 50
file content (32 lines) | stat: -rw-r--r-- 819 bytes parent folder | download | duplicates (6)
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
Description: Fix ltmain.sh --as-needed issue.
Author: Bradley Smith <bradsmith@debian.org>
--- a/build/ltmain.sh
+++ b/build/ltmain.sh
@@ -4189,6 +4189,11 @@
 	arg=$func_stripname_result
 	;;
 
+      -Wl,--as-needed)
+	deplibs="$deplibs $arg"
+	continue
+	;;
+      
       -Wl,*)
 	func_stripname '-Wl,' '' "$arg"
 	args=$func_stripname_result
@@ -4543,6 +4548,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)
 	  if test "$linkmode,$pass" = "prog,link"; then
 	    compile_deplibs="$deplib $compile_deplibs"