File: 01_fix_as-needed.diff

package info (click to toggle)
libview 0.6.6-2.1
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, jessie, jessie-kfreebsd, stretch, wheezy
  • size: 2,432 kB
  • ctags: 806
  • sloc: sh: 9,942; cpp: 3,098; ansic: 1,011; makefile: 169; perl: 67
file content (32 lines) | stat: -rw-r--r-- 916 bytes parent folder | download | duplicates (2)
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: libview-0.6.6/ltmain.sh
===================================================================
--- libview-0.6.6.orig/ltmain.sh	2010-04-22 00:39:58.000000000 +0100
+++ libview-0.6.6/ltmain.sh	2010-06-05 11:57:46.000000000 +0100
@@ -4716,6 +4716,11 @@
 	arg=$func_stripname_result
 	;;
 
+      -Wl,--as-needed)
+	deplibs="$deplibs $arg"
+	continue
+	;;
+      
       -Wl,*)
 	func_stripname '-Wl,' '' "$arg"
 	args=$func_stripname_result
@@ -5070,6 +5075,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"