1 |
vapier 14/01/31 08:01:14 |
2 |
|
3 |
Added: apr-1.5.0-sysroot.patch |
4 |
Log: |
5 |
Utilize SYSROOT to locate build-time paths when cross-compiling, and drop redundent -L/-R libdir flags to simplify linking. #385775 by Bertrand Jacquin. |
6 |
|
7 |
(Portage version: 2.2.8-r1/cvs/Linux x86_64, signed Manifest commit with key D2E96200) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 dev-libs/apr/files/apr-1.5.0-sysroot.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/apr/files/apr-1.5.0-sysroot.patch?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/apr/files/apr-1.5.0-sysroot.patch?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: apr-1.5.0-sysroot.patch |
16 |
=================================================================== |
17 |
https://bugs.gentoo.org/385775 |
18 |
|
19 |
utilize $SYSROOT to find the right includedir tree |
20 |
|
21 |
drop the -L/-R paths since we know our libdir is the standard path which |
22 |
the compiler already knows how to locate |
23 |
|
24 |
--- a/apr-config.in |
25 |
+++ b/apr-config.in |
26 |
@@ -28,7 +28,7 @@ libdir="@libdir@" |
27 |
datarootdir="@datadir@" |
28 |
datadir="@datadir@" |
29 |
-installbuilddir="@installbuilddir@" |
30 |
-includedir="@includedir@" |
31 |
+installbuilddir="${SYSROOT}@installbuilddir@" |
32 |
+includedir="${SYSROOT}@includedir@" |
33 |
|
34 |
CC="@CC@" |
35 |
CPP="@CPP@" |
36 |
@@ -183,7 +183,7 @@ while test $# -gt 0; do |
37 |
--link-ld) |
38 |
if test "$location" = "installed"; then |
39 |
### avoid using -L if libdir is a "standard" location like /usr/lib |
40 |
- flags="$flags -L$libdir -l${APR_LIBNAME}" |
41 |
+ flags="$flags -l${APR_LIBNAME}" |
42 |
else |
43 |
### this surely can't work since the library is in .libs? |
44 |
flags="$flags -L$APR_BUILD_DIR -l${APR_LIBNAME}" |
45 |
@@ -200,7 +200,7 @@ while test $# -gt 0; do |
46 |
### avoid using -L if libdir is a "standard" location like /usr/lib |
47 |
# Since the user is specifying they are linking with libtool, we |
48 |
# *know* that -R will be recognized by libtool. |
49 |
- flags="$flags -L$libdir -R$libdir -l${APR_LIBNAME}" |
50 |
+ flags="$flags -l${APR_LIBNAME}" |
51 |
else |
52 |
flags="$flags $LA_FILE" |
53 |
fi |