author | Jiri Sasek <Jiri.Sasek@Oracle.COM> |
Wed, 26 Mar 2014 13:35:48 -0700 | |
branch | s11-update |
changeset 3036 | 19bbecc872de |
parent 2824 | ed80ca124641 |
permissions | -rw-r--r-- |
2824
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
1 |
The various curl NTLM tests try to LD_PRELOAD a test library |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
2 |
called .../tests/libtest/.libs/libhostname.so that's been |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
3 |
created as a pre-requisite to running the numerous Perl tests. |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
4 |
|
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
5 |
This patch adjusts LD_PRELOAD to be LD_PRELOAD_32 or LD_PRELOAD_64 |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
6 |
depending upon whether we are running the 32 or 64 bit tests. |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
7 |
|
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
8 |
As this is Solaris specific, this patch will not be pushed upstream. |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
9 |
|
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
10 |
--- tests/runtests.pl.orig 2013-11-18 07:12:48.748872794 -0800 |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
11 |
+++ tests/runtests.pl 2013-11-18 07:15:32.604982653 -0800 |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
12 |
@@ -2405,10 +2405,21 @@ |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
13 |
delete $ENV{$var} if($ENV{$var}); |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
14 |
} |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
15 |
else { |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
16 |
- if(($var =~ /^LD_PRELOAD/) && |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
17 |
- ($debug_build || ($has_shared ne "yes"))) { |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
18 |
- # print "Skipping LD_PRELOAD due to no release shared build\n"; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
19 |
- next; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
20 |
+ if($var =~ /^LD_PRELOAD/) { |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
21 |
+ if(exe_ext() && (exe_ext() eq '.exe')) { |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
22 |
+ # print "Skipping LD_PRELOAD due to lack of OS support\n"; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
23 |
+ next; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
24 |
+ } |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
25 |
+ if($debug_build || ($has_shared ne "yes")) { |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
26 |
+ # print "Skipping LD_PRELOAD due to no release shared build\n"; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
27 |
+ next; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
28 |
+ } |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
29 |
+ # make this LD_PRELOAD_{bits} |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
30 |
+ open(FP, "/bin/file $content |"); |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
31 |
+ my $bits = <FP>; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
32 |
+ if ($bits =~ /^.+ELF\s(\d\d)-bit.+$/) { |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
33 |
+ $var .= '_'.$1; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
34 |
+ } |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
35 |
} |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
36 |
$ENV{$var} = "$content"; |
ed80ca124641
15941200 curl "gmake test" failures
Rich Burridge <rich.burridge@oracle.com>
parents:
diff
changeset
|
37 |
} |