Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PATCH 11/11] XSLoader 0.21: use dl_find_symbol 3rd optional argument #14588

Closed
p5pRT opened this issue Mar 14, 2015 · 6 comments
Closed

[PATCH 11/11] XSLoader 0.21: use dl_find_symbol 3rd optional argument #14588

p5pRT opened this issue Mar 14, 2015 · 6 comments

Comments

@p5pRT
Copy link

p5pRT commented Mar 14, 2015

Migrated from rt.perl.org#124069 (status was 'resolved')

Searchable as RT124069$

@p5pRT
Copy link
Author

p5pRT commented Mar 14, 2015

From @rurban

generated with the help of perlbug 1.40 running under perl 5.21.9.


XSLoader 0.21​: use dl_find_symbol 3rd optional argument
to skip the worthless dl_last_error message on darwin

CPAN is upstream, but for completeness I post it here also.
CPAN has to wait on p5p for DynaLoader-1.33.



Flags​:
  category=library
  severity=medium
  Type=Patch
  PatchStatus=HasPatch
  module=XSLoader


Site configuration information for perl 5.21.9​:

Configured by rurban at Sun Feb 22 17​:14​:55 CET 2015.

Summary of my perl5 (revision 5 version 21 subversion 9) configuration​:
 
  Platform​:
  osname=linux, osvers=3.16.0-4-amd64, archname=x86_64-linux-debug
  uname='linux reini 3.16.0-4-amd64 #1 smp debian 3.16.7-ckt2-1 (2014-12-08) x86_64 gnulinux '
  config_args='-de -Dusedevel -Uversiononly -Dinstallman1dir=none -Dinstallman3dir=none -Dinstallsiteman1dir=none -Dinstallsiteman3dir=none -DEBUGGING -Doptimize='-g3' -Uuseithreads -D'cc=gcc-5.0' -Accflags=''-msse4.2'' -Accflags=''-march=corei7'' -Dcf_email=''rurban@​cpanel.net'' -Dperladmin=''rurban@​cpanel.net'''
  hint=recommended, useposix=true, d_sigaction=define
  useithreads=undef, usemultiplicity=undef
  use64bitint=define, use64bitall=define, uselongdouble=undef
  usemymalloc=n, bincompat5005=undef
  Compiler​:
  cc='gcc-5.0', ccflags ='-msse4.2 -march=corei7 -fwrapv -DDEBUGGING -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64',
  optimize='-g3',
  cppflags='-msse4.2 -march=corei7 -fwrapv -DDEBUGGING -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include'
  ccversion='', gccversion='5.0.0 20150103 (experimental)', gccosandvers=''
  intsize=4, longsize=8, ptrsize=8, doublesize=8, byteorder=12345678, doublekind=3
  d_longlong=define, longlongsize=8, d_longdbl=define, longdblsize=16, longdblkind=3
  ivtype='long', ivsize=8, nvtype='double', nvsize=8, Off_t='off_t', lseeksize=8
  alignbytes=8, prototype=define
  Linker and Libraries​:
  ld='gcc-5.0', ldflags =' -fstack-protector-strong -L/usr/local/lib'
  libpth=/usr/local/lib /usr/local/lib/gcc/x86_64-unknown-linux-gnu/5.0.0/include-fixed /usr/include/x86_64-linux-gnu /usr/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib /lib64 /usr/lib64 /usr/local/lib64
  libs=-lpthread -lnsl -lgdbm -ldb -ldl -lm -lcrypt -lutil -lc -lgdbm_compat
  perllibs=-lpthread -lnsl -ldl -lm -lcrypt -lutil -lc
  libc=libc-2.19.so, so=so, useshrplib=false, libperl=libperl.a
  gnulibc_version='2.19'
  Dynamic Linking​:
  dlsrc=dl_dlopen.xs, dlext=so, d_dlsymun=undef, ccdlflags='-Wl,-E'
  cccdlflags='-fPIC', lddlflags='-shared -g3 -L/usr/local/lib -fstack-protector-strong'

Locally applied patches​:
  Devel​::PatchPerl 1.30


@​INC for perl 5.21.9​:
  /usr/local/lib/perl5/site_perl/5.21.9/x86_64-linux-debug
  /usr/local/lib/perl5/site_perl/5.21.9
  /usr/local/lib/perl5/5.21.9/x86_64-linux-debug
  /usr/local/lib/perl5/5.21.9
  /usr/local/lib/perl5/site_perl/5.21.8
  /usr/local/lib/perl5/site_perl/5.21.7
  /usr/local/lib/perl5/site_perl/5.21.4
  /usr/local/lib/perl5/site_perl/5.21.3
  /usr/local/lib/perl5/site_perl/5.21.2
  /usr/local/lib/perl5/site_perl/5.21.1
  /usr/local/lib/perl5/site_perl/5.21.0
  /usr/local/lib/perl5/site_perl/5.20.1
  /usr/local/lib/perl5/site_perl/5.20.0
  /usr/local/lib/perl5/site_perl/5.19.11
  /usr/local/lib/perl5/site_perl/5.19.10
  /usr/local/lib/perl5/site_perl/5.19.9
  /usr/local/lib/perl5/site_perl/5.19.8
  /usr/local/lib/perl5/site_perl/5.19.7
  /usr/local/lib/perl5/site_perl/5.19.6
  /usr/local/lib/perl5/site_perl/5.19.5
  /usr/local/lib/perl5/site_perl/5.19.4
  /usr/local/lib/perl5/site_perl/5.19.3
  /usr/local/lib/perl5/site_perl/5.19.2
  /usr/local/lib/perl5/site_perl/5.19.1
  /usr/local/lib/perl5/site_perl/5.19.0
  /usr/local/lib/perl5/site_perl/5.18.4
  /usr/local/lib/perl5/site_perl/5.18.2
  /usr/local/lib/perl5/site_perl/5.18.1
  /usr/local/lib/perl5/site_perl/5.18.0
  /usr/local/lib/perl5/site_perl/5.17.11
  /usr/local/lib/perl5/site_perl/5.17.10
  /usr/local/lib/perl5/site_perl/5.17.8
  /usr/local/lib/perl5/site_perl/5.17.7
  /usr/local/lib/perl5/site_perl/5.17.6
  /usr/local/lib/perl5/site_perl/5.17.5
  /usr/local/lib/perl5/site_perl/5.17.4
  /usr/local/lib/perl5/site_perl/5.17.3
  /usr/local/lib/perl5/site_perl/5.17.2
  /usr/local/lib/perl5/site_perl/5.17.1
  /usr/local/lib/perl5/site_perl/5.17.0
  /usr/local/lib/perl5/site_perl/5.17
  /usr/local/lib/perl5/site_perl/5.16.3
  /usr/local/lib/perl5/site_perl/5.16.2
  /usr/local/lib/perl5/site_perl/5.16.1
  /usr/local/lib/perl5/site_perl/5.16.0
  /usr/local/lib/perl5/site_perl/5.15.9
  /usr/local/lib/perl5/site_perl/5.15.8
  /usr/local/lib/perl5/site_perl/5.15.7
  /usr/local/lib/perl5/site_perl/5.15.6
  /usr/local/lib/perl5/site_perl/5.15.5
  /usr/local/lib/perl5/site_perl/5.15.4
  /usr/local/lib/perl5/site_perl/5.15.3
  /usr/local/lib/perl5/site_perl/5.15.2
  /usr/local/lib/perl5/site_perl/5.14.4
  /usr/local/lib/perl5/site_perl/5.14.3
  /usr/local/lib/perl5/site_perl/5.14.2
  /usr/local/lib/perl5/site_perl/5.14.1
  /usr/local/lib/perl5/site_perl/5.12.5
  /usr/local/lib/perl5/site_perl/5.12.4
  /usr/local/lib/perl5/site_perl/5.10.1
  /usr/local/lib/perl5/site_perl/5.8.9
  /usr/local/lib/perl5/site_perl/5.8.8
  /usr/local/lib/perl5/site_perl/5.8.7
  /usr/local/lib/perl5/site_perl/5.8.6
  /usr/local/lib/perl5/site_perl/5.8.5
  /usr/local/lib/perl5/site_perl/5.8.4
  /usr/local/lib/perl5/site_perl/5.8.3
  /usr/local/lib/perl5/site_perl/5.8.2
  /usr/local/lib/perl5/site_perl/5.8.1
  /usr/local/lib/perl5/site_perl/5.6.2
  /usr/local/lib/perl5/site_perl
  .


Environment for perl 5.21.9​:
  HOME=/home/rurban
  LANG=en_US.utf8
  LANGUAGE (unset)
  LD_LIBRARY_PATH (unset)
  LOGDIR (unset)
  PATH=/home/rurban/bin​:/usr/local/bin​:/usr/bin​:/bin​:/usr/local/games​:/usr/games
  PERL_BADLANG (unset)
  SHELL=/bin/bash

@p5pRT
Copy link
Author

p5pRT commented Mar 14, 2015

From @rurban

0004-XSLoader-0.21-use-dl_find_symbol-3rd-optional-argume.patch
From 046d5f370efd4eed4702f9cdd75cac2b5a7bcb82 Mon Sep 17 00:00:00 2001
From: Reini Urban <rurban@cpanel.net>
Date: Sat, 14 Mar 2015 00:31:41 +0100
Subject: [PATCH 4/4] XSLoader 0.21: use dl_find_symbol 3rd optional argument

to skip the worthless dl_last_error message
---
 dist/XSLoader/XSLoader_pm.PL | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git dist/XSLoader/XSLoader_pm.PL dist/XSLoader/XSLoader_pm.PL
index 414eaf2..d518d10 100644
--- dist/XSLoader/XSLoader_pm.PL
+++ dist/XSLoader/XSLoader_pm.PL
@@ -10,7 +10,7 @@ print OUT <<'EOT';
 
 package XSLoader;
 
-$VERSION = "0.20";
+$VERSION = "0.21";
 
 #use strict;
 
@@ -123,10 +123,11 @@ print OUT <<'EOT';
 EOT
 
     if ($^O eq 'darwin') {
-print OUT <<'EOT';
-        if ($boot_symbol_ref = dl_find_symbol(0, $bootname)) {
-            goto boot; #extension library has already been loaded, e.g. darwin
-        }
+      my $extra_arg = ', 1 ' if $DynaLoader::VERSION ge '1.33';
+print OUT <<"EOT";
+    if (\$boot_symbol_ref = dl_find_symbol( 0, \$bootname $extra_arg)) {
+        goto boot; #extension library has already been loaded, e.g. darwin
+    }
 EOT
     }
 
-- 
2.1.4

@p5pRT
Copy link
Author

p5pRT commented Mar 29, 2015

From @tonycoz

On Sat Mar 14 03​:58​:57 2015, rurban@​cpanel.net wrote​:

XSLoader 0.21​: use dl_find_symbol 3rd optional argument
to skip the worthless dl_last_error message on darwin

CPAN is upstream, but for completeness I post it here also.
CPAN has to wait on p5p for DynaLoader-1.33.

XSLoader is blead-upstream.

Tony

@p5pRT
Copy link
Author

p5pRT commented Mar 29, 2015

The RT System itself - Status changed from 'new' to 'open'

@p5pRT
Copy link
Author

p5pRT commented Nov 10, 2015

From @tonycoz

On Sat Mar 14 03​:58​:57 2015, rurban@​cpanel.net wrote​:

XSLoader 0.21​: use dl_find_symbol 3rd optional argument
to skip the worthless dl_last_error message on darwin

CPAN is upstream, but for completeness I post it here also.
CPAN has to wait on p5p for DynaLoader-1.33.

Applied as c35721e, which a modified version check.

Tony

@p5pRT p5pRT closed this as completed Nov 10, 2015
@p5pRT
Copy link
Author

p5pRT commented Nov 10, 2015

@tonycoz - Status changed from 'open' to 'resolved'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant