Skip Menu |
Report information
Id: 131337
Status: resolved
Priority: 0/
Queue: perl5

Owner: jkeenan <jkeenan [at] cpan.org>
Requestors: jkeenan [at] pobox.com
Cc:
AdminCc:

Operating System: freebsd
PatchStatus: (no value)
Severity: medium
Type: (no value)
Perl Version:
  • 5.25.9
  • 5.25.10
  • 5.25.11
  • 5.25.12
  • 5.25.13
Fixed In: (no value)



Subject: 24e16d7 broke g++ build on FreeBSD-11.0
From: James E Keenan <jkeenan [...] pobox.com>
To: perlbug [...] perl.org
Date: Sat, 20 May 2017 23:54:11 -0400
Download (untitled) / with headers
text/plain 4.8k
Summary: A commit to Perl 5 blead in December 2016 made it impossible to build perl on FreeBSD-11.0 when using g++ as the C-compiler. Preliminary remarks: 1. The default C-compiler on FreeBSD-11.0 is clang, not g++. When I smoke-test blead on FreeBSD-11.0, I configure with clang and certain options selected to try to get as close as possible to those used by the FreeBSD project to port perl to that version of the OS. 2. Hence, what I report below is an edge case that we should explore mostly in the hope that it will lead to more accurate and flexible source code in the Perl 5 core distribution. In particular, we should not consider what follows as a blocker for the release of 5.26.0. Instead, we should study the problem during the 5.27 development cycle. Bug report: At the point when perl-5.24.0 was released, perl could have been built with g++ on FreeBSD-11.0. (We weren't smoke-testing perl on FreeBSD-11.0 at all at that time, so our knowledge of its buildability is strictly retrospective.) At tag v5.24.0 all tests would PASS XXXXXXX. However, at a certain point in the 5.25-5.26 development cycle, changes were made which meant that thereafter any attempt to build perl with g++ on FreeBSD-11.0 would fail without ever getting as far as 'make test'. Bisection indicates that the following is the first bad commit: ##### commit 24e16d7b405f10168aae144d4a2c37d9c6443b9e Author: Karl Williamson <khw@cpan.org> AuthorDate: Sun Dec 11 20:35:09 2016 -0700 Commit: Karl Williamson <khw@cpan.org> CommitDate: Fri Dec 23 16:48:36 2016 -0700 regexec.c: Make isFOO_lc() non-static ##### The immediately preceding commit would be: ##### commit ddb659335ba5267366f1c691fb334983fd1b2023 Author: Karl Williamson <khw@cpan.org> AuthorDate: Thu Dec 8 22:01:58 2016 -0700 Commit: Karl Williamson <khw@cpan.org> CommitDate: Fri Dec 23 16:48:36 2016 -0700 utf8.c: White space, comments only ##### If I were to configure at ddb65933 as follows: ##### sh ./Configure -des -Dusedevel \ -Duseithreads \ -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \ -Dcc="g++" ##### ... and then call 'make -j${TEST_JOBS} test_harness'. Perl would build successfully, although it would FAIL t/re/regexp_nonull.t. (I am attaching the output of './perl -Ilib -V' for this build.) If I now were to advance to commit 24e16d7b405f10168aae144d4a2c37d9c6443b9e and configure as above, 'make' would fail. The full build log, gzipped, is attached; here is the tail: ##### g++ -o perl -pthread -Wl,-E -fstack-protector-strong -L/usr/local/lib perlmain.o lib/auto/B/B.a lib/auto/Compress/Raw/Bzip2/Bzip2.a lib/auto/Compress/Raw/Zlib/Zlib.a lib/auto/Cwd/Cwd.a lib/auto/DB_File/DB_File.a lib/auto/Data/Dumper/Dumper.a lib/auto/Devel/PPPort/PPPort.a lib/auto/Devel/Peek/Peek.a lib/auto/Digest/MD5/MD5.a lib/auto/Digest/SHA/SHA.a lib/auto/Encode/Encode.a lib/auto/Fcntl/Fcntl.a lib/auto/File/DosGlob/DosGlob.a lib/auto/File/Glob/Glob.a lib/auto/Filter/Util/Call/Call.a lib/auto/GDBM_File/GDBM_File.a lib/auto/Hash/Util/Util.a lib/auto/Hash/Util/FieldHash/FieldHash.a lib/auto/I18N/Langinfo/Langinfo.a lib/auto/IO/IO.a lib/auto/IPC/SysV/SysV.a lib/auto/List/Util/Util.a lib/auto/MIME/Base64/Base64.a lib/auto/Math/BigInt/FastCalc/FastCalc.a lib/auto/NDBM_File/NDBM_File.a lib/auto/Opcode/Opcode.a lib/auto/POSIX/POSIX.a lib/auto/PerlIO/encoding/encoding.a lib/auto/PerlIO/mmap/mmap.a lib/auto/PerlIO/scalar/scalar.a lib/auto/PerlIO/via/via.a lib/auto/SDBM_File/SDBM_File.a lib/auto/Socket/Socket.a lib/auto/Storable/Storable.a lib/auto/Sys/Hostname/Hostname.a lib/auto/Sys/Syslog/Syslog.a lib/auto/Tie/Hash/NamedCapture/NamedCapture.a lib/auto/Time/HiRes/HiRes.a lib/auto/Time/Piece/Piece.a lib/auto/Unicode/Collate/Collate.a lib/auto/Unicode/Normalize/Normalize.a lib/auto/arybase/arybase.a lib/auto/attributes/attributes.a lib/auto/mro/mro.a lib/auto/re/re.a lib/auto/threads/threads.a lib/auto/threads/shared/shared.a lib/auto/Encode/Byte/Byte.a lib/auto/Encode/CN/CN.a lib/auto/Encode/EBCDIC/EBCDIC.a lib/auto/Encode/JP/JP.a lib/auto/Encode/KR/KR.a lib/auto/Encode/Symbol/Symbol.a lib/auto/Encode/TW/TW.a lib/auto/Encode/Unicode/Unicode.a libperl.a `cat ext.libs` -lpthread -lgdbm -lm -lcrypt -lutil libperl.a(regexec.o): In function `Perl_isFOO_lc': regexec.c:(.text+0x2d30): multiple definition of `Perl_isFOO_lc' lib/auto/re/re.a(re_exec.o):re_exec.c:(.text+0x47a0): first defined here collect2: error: ld returned 1 exit status *** [perl] Error code 1 make: stopped in /usr/home/jkeenan/gitwork/perl2 1 error make: stopped in /usr/home/jkeenan/gitwork/perl2 ##### So this is a regression between 5.24 and 5.26. However, since it is a case we have not previously tested and which is not likely to be used in production code, it will probably suffice to investigate it during the 5.27-5.28 development cycle. Thank you very much. Jim Keenan

Message body is not shown because sender requested not to inline it.

Message body not shown because it is not plain text.

Message body is not shown because sender requested not to inline it.

From: "Craig A. Berry" <craig.a.berry [...] gmail.com>
To: "Perl5 Porters (E-mail)" <perl5-porters [...] perl.org>
Date: Sun, 21 May 2017 08:11:31 -0500
CC: bugs-bitbucket [...] rt.perl.org
Subject: Re: [perl #131337] 24e16d7 broke g++ build on FreeBSD-11.0
Download (untitled) / with headers
text/plain 1.2k
On Sat, May 20, 2017 at 10:54 PM, James E Keenan <perlbug-followup@perl.org> wrote: Show quoted text
> > Bisection indicates that the following is the first bad commit: > > ##### > commit 24e16d7b405f10168aae144d4a2c37d9c6443b9e > Author: Karl Williamson <khw@cpan.org> > AuthorDate: Sun Dec 11 20:35:09 2016 -0700 > Commit: Karl Williamson <khw@cpan.org> > CommitDate: Fri Dec 23 16:48:36 2016 -0700 > > regexec.c: Make isFOO_lc() non-static > #####
Show quoted text
> ext.libs` -lpthread -lgdbm -lm -lcrypt -lutil > libperl.a(regexec.o): In function `Perl_isFOO_lc': > regexec.c:(.text+0x2d30): multiple definition of `Perl_isFOO_lc' > lib/auto/re/re.a(re_exec.o):re_exec.c:(.text+0x47a0): first defined here > collect2: error: ld returned 1 exit status > *** [perl] Error code 1
Surely this was fixed by: commit 9637d2a524bfab39fd1e4cbf27b8f632a8265e9e Author: Craig A. Berry <craigberry@mac.com> Date: Thu Dec 29 14:03:43 2016 -0600 Don't define Perl_isFOO_lc in the regex extension. Otherwise it ends up multiply defined, which annoys the VMS linker (and probably the AIX linker too). Can you you either do another bisect that starts from there or at least post the error that makes the build fail in blead (assuming it still does)?
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 1.5k
On Sun, 21 May 2017 13:11:38 GMT, craig.a.berry@gmail.com wrote: Show quoted text
> On Sat, May 20, 2017 at 10:54 PM, James E Keenan > <perlbug-followup@perl.org> wrote: >
> > > > Bisection indicates that the following is the first bad commit: > > > > ##### > > commit 24e16d7b405f10168aae144d4a2c37d9c6443b9e > > Author: Karl Williamson <khw@cpan.org> > > AuthorDate: Sun Dec 11 20:35:09 2016 -0700 > > Commit: Karl Williamson <khw@cpan.org> > > CommitDate: Fri Dec 23 16:48:36 2016 -0700 > > > > regexec.c: Make isFOO_lc() non-static > > #####
>
> > ext.libs` -lpthread -lgdbm -lm -lcrypt -lutil > > libperl.a(regexec.o): In function `Perl_isFOO_lc': > > regexec.c:(.text+0x2d30): multiple definition of `Perl_isFOO_lc' > > lib/auto/re/re.a(re_exec.o):re_exec.c:(.text+0x47a0): first defined here > > collect2: error: ld returned 1 exit status > > *** [perl] Error code 1
> > Surely this was fixed by: > > commit 9637d2a524bfab39fd1e4cbf27b8f632a8265e9e > Author: Craig A. Berry <craigberry@mac.com> > Date: Thu Dec 29 14:03:43 2016 -0600 > > Don't define Perl_isFOO_lc in the regex extension. > > Otherwise it ends up multiply defined, which annoys the VMS linker > (and probably the AIX linker too). > > > Can you you either do another bisect that starts from there or at > least post the error that makes the build fail in blead (assuming it > still does)?
I am attaching the log of 'make' (gzipped) that I got when compiling blead with g++ yesterday. Blead was probably at 2c4393cceb72ac358b1127131a605f20eb3e7588 at that point. Thank you very much. -- James E Keenan (jkeenan@cpan.org)
Subject: make.g++.log.gz
Download make.g++.log.gz
application/gzip 11.9k

Message body not shown because it is not plain text.

RT-Send-CC: perl5-porters [...] perl.org
On Sun, 21 May 2017 13:11:38 GMT, craig.a.berry@gmail.com wrote: Show quoted text
> [snip]
Show quoted text
> Surely this was fixed by: > > commit 9637d2a524bfab39fd1e4cbf27b8f632a8265e9e > Author: Craig A. Berry <craigberry@mac.com> > Date: Thu Dec 29 14:03:43 2016 -0600 > > Don't define Perl_isFOO_lc in the regex extension. > > Otherwise it ends up multiply defined, which annoys the VMS linker > (and probably the AIX linker too). > > > Can you you either do another bisect that starts from there or at > least post the error that makes the build fail in blead (assuming it > still does)?
Using this function to configure: ##### gpp_configure () { sh ./Configure -des -Dusedevel \ -Duseithreads \ -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \ -Dcc="g++" } ##### ... I tried to build perl at commit 9637d2a and got the same, "multiple definition of `Perl__is_grapheme'" build failure as previous posted. See attachment for gzipped output of 'make' at this revision. Thank you very much. -- James E Keenan (jkeenan@cpan.org)
Subject: 9637d2a.g++.freebsd.11.0.make.log.gz

Message body not shown because it is not plain text.

Date: Sun, 21 May 2017 20:31:39 -0500
From: "Craig A. Berry" <craig.a.berry [...] gmail.com>
To: Craig Berry via RT <perlbug-followup [...] perl.org>
CC: "Perl5 Porters (E-mail)" <perl5-porters [...] perl.org>
Subject: Re: [perl #131337] 24e16d7 broke g++ build on FreeBSD-11.0
Download (untitled) / with headers
text/plain 1.8k
On Sun, May 21, 2017 at 11:24 AM, James E Keenan via RT <perlbug-followup@perl.org> wrote: Show quoted text
> On Sun, 21 May 2017 13:11:38 GMT, craig.a.berry@gmail.com wrote:
>> [snip]
>
>> Surely this was fixed by: >> >> commit 9637d2a524bfab39fd1e4cbf27b8f632a8265e9e >> Author: Craig A. Berry <craigberry@mac.com> >> Date: Thu Dec 29 14:03:43 2016 -0600 >> >> Don't define Perl_isFOO_lc in the regex extension. >> >> Otherwise it ends up multiply defined, which annoys the VMS linker >> (and probably the AIX linker too). >> >> >> Can you you either do another bisect that starts from there or at >> least post the error that makes the build fail in blead (assuming it >> still does)?
> > Using this function to configure: > > ##### > gpp_configure () > { > sh ./Configure -des -Dusedevel \ > -Duseithreads \ > -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \ > -Dcc="g++" > } > ##### > > ... I tried to build perl at commit 9637d2a and got the same, "multiple definition of `Perl__is_grapheme'" build failure as previous posted. See attachment for gzipped output of 'make' at this revision.
How do you mean "the same"? Previously it was Perl_isFOO_lc that was multiply defined. Now it is Perl__is_grapheme, which looks like an entirely different problem (albeit following a similar pattern). Does that exact same error still happen in blead? If so, does the following fix it? diff --git a/regexec.c b/regexec.c index 0b5c847f1c..ea52477781 100644 --- a/regexec.c +++ b/regexec.c @@ -9708,6 +9708,8 @@ S_to_byte_substr(pTHX_ regexp *prog) return TRUE; } +#ifndef PERL_IN_XSUB_RE + bool Perl__is_grapheme(pTHX_ const U8 * strbeg, const U8 * s, const U8 * strend, const UV cp) { @@ -9763,7 +9765,7 @@ Perl__is_grapheme(pTHX_ const U8 * strbeg, const U8 * s, const U8 * strend, cons return isGCB(cp_gcb_val, next_cp_gcb_val, strbeg, s, TRUE); } - +#endif /*
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 2.8k
On Mon, 22 May 2017 01:32:07 GMT, craig.a.berry@gmail.com wrote: Show quoted text
> On Sun, May 21, 2017 at 11:24 AM, James E Keenan via RT > <perlbug-followup@perl.org> wrote:
> > On Sun, 21 May 2017 13:11:38 GMT, craig.a.berry@gmail.com wrote:
> >> [snip]
> >
> >> Surely this was fixed by: > >> > >> commit 9637d2a524bfab39fd1e4cbf27b8f632a8265e9e > >> Author: Craig A. Berry <craigberry@mac.com> > >> Date: Thu Dec 29 14:03:43 2016 -0600 > >> > >> Don't define Perl_isFOO_lc in the regex extension. > >> > >> Otherwise it ends up multiply defined, which annoys the VMS linker > >> (and probably the AIX linker too). > >> > >> > >> Can you you either do another bisect that starts from there or at > >> least post the error that makes the build fail in blead (assuming it > >> still does)?
> > > > Using this function to configure: > > > > ##### > > gpp_configure () > > { > > sh ./Configure -des -Dusedevel \ > > -Duseithreads \ > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" > > \ > > -Dcc="g++" > > } > > ##### > > > > ... I tried to build perl at commit 9637d2a and got the same, > > "multiple definition of `Perl__is_grapheme'" build failure as > > previous posted. See attachment for gzipped output of 'make' at this > > revision.
> > How do you mean "the same"? Previously it was Perl_isFOO_lc that was > multiply defined. Now it is Perl__is_grapheme, which looks like an > entirely different problem (albeit following a similar pattern). Does > that exact same error still happen in blead? If so, does the > following fix it? > > diff --git a/regexec.c b/regexec.c > index 0b5c847f1c..ea52477781 100644 > --- a/regexec.c > +++ b/regexec.c > @@ -9708,6 +9708,8 @@ S_to_byte_substr(pTHX_ regexp *prog) > return TRUE; > } > > +#ifndef PERL_IN_XSUB_RE > + > bool > Perl__is_grapheme(pTHX_ const U8 * strbeg, const U8 * s, const U8 * > strend, const UV cp) > { > @@ -9763,7 +9765,7 @@ Perl__is_grapheme(pTHX_ const U8 * strbeg, const > U8 * s, const U8 * strend, cons > return isGCB(cp_gcb_val, next_cp_gcb_val, strbeg, s, TRUE); > } > > - > +#endif > > > /*
Your patch -- which I've pushed in the smoke-me/jkeenan/131337-craig branch -- does enable 'make' to complete when g++ is the C-compiler on FreeBSD-11.0. However, there is a persistent test failure in t/re/regexp_nonull.t (http://perl5.test-smoke.org/report/55820) -- a failure which that branch does not get when compiling with g++ on Linux (http://perl5.test-smoke.org/report/55823). I am attaching: * the gzipped log of 'make' for that build; * the ./perl -Ilib -V output for that build; * the output for "cd t; ./perl harness -v re/regexp_nonull.t; cd -" for that build * and by way of contrast, the output for "cd t; ./perl harness -v re/regexp_nonull.t; cd -" on FreeBSD-11.0 but using the regular configuration style with 'clang'. Thank you very much. -- James E Keenan (jkeenan@cpan.org)
Subject: 131337.gpp_configure.make.output.txt.gz

Message body not shown because it is not plain text.

Subject: 131337.gpp_configure.regexp_nonull.output.txt
Can't locate XS/APItest.pm in @INC (you may need to install the XS::APItest module) (@INC contains: ../lib) at re/regexp_nonull.t line 10. re/regexp_nonull.t .. Dubious, test returned 2 (wstat 512, 0x200) No subtests run Test Summary Report ------------------- re/regexp_nonull.t (Wstat: 512 Tests: 0 Failed: 0) Non-zero exit status: 2 Parse errors: No plan found in TAP output Files=1, Tests=0, 0 wallclock secs ( 0.01 usr + 0.01 sys = 0.02 CPU) Result: FAIL
Subject: 131337.perl.V.txt
Summary of my perl5 (revision 5 version 26 subversion 0) configuration: Commit id: 52ad33ec8fe7f11aee1e5a6c729b5c8e213daeb1 Platform: osname=freebsd osvers=11.0-release-p1 archname=amd64-freebsd-thread-multi uname='freebsd kid51.freebsd11.2 11.0-release-p1 freebsd 11.0-release-p1 #0 r306420: thu sep 29 01:43:23 utc 2016 root@releng2.nyi.freebsd.org:usrobjusrsrcsysgeneric amd64 ' config_args='-des -Dusedevel -Duseithreads -Doptimize=-O2 -pipe -fstack-protector -fno-strict-aliasing -Dcc=g++' hint=recommended useposix=true d_sigaction=define useithreads=define usemultiplicity=define use64bitint=define use64bitall=define uselongdouble=undef usemymalloc=n default_inc_excludes_dot=define bincompat5005=undef Compiler: cc='g++' ccflags ='-DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_FORTIFY_SOURCE=2' optimize='-O2 -pipe -fstack-protector -fno-strict-aliasing' cppflags='-DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include' ccversion='' gccversion='5.4.0' 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='ld' ldflags ='-pthread -Wl,-E -fstack-protector-strong -L/usr/local/lib' libpth=/usr/lib /usr/local/lib /usr/local/lib/gcc5/include/c++/ /usr/local/lib/gcc5/include/c++//x86_64-portbld-freebsd11.0 /usr/local/lib/gcc5/include/c++//backward /usr/local/lib /usr/local/lib/gcc5/gcc/x86_64-portbld-freebsd11.0/5.4.0/include-fixed /usr/lib libs=-lpthread -lgdbm -lm -lcrypt -lutil perllibs=-lpthread -lgdbm -lm -lcrypt -lutil libc= so=so useshrplib=false libperl=libperl.a gnulibc_version='' Dynamic Linking: dlsrc=dl_none.xs dlext=none d_dlsymun=undef ccdlflags='' cccdlflags='-DPIC -fPIC' lddlflags='' Characteristics of this binary (from libperl): Compile-time options: HAS_TIMES MULTIPLICITY PERLIO_LAYERS PERL_COPY_ON_WRITE PERL_DONT_CREATE_GVSV PERL_IMPLICIT_CONTEXT PERL_MALLOC_WRAP PERL_OP_PARENT PERL_PRESERVE_IVUV PERL_USE_DEVEL USE_64_BIT_ALL USE_64_BIT_INT USE_ITHREADS USE_LARGE_FILES USE_LOCALE USE_LOCALE_COLLATE USE_LOCALE_CTYPE USE_LOCALE_NUMERIC USE_LOCALE_TIME USE_PERLIO USE_PERL_ATOF USE_REENTRANT_API Built under freebsd Compiled at May 21 2017 22:41:48 %ENV: PERL_WORKDIR="/home/jkeenan/gitwork/perl" @INC: lib /usr/local/lib/perl5/site_perl/5.26.0/amd64-freebsd-thread-multi /usr/local/lib/perl5/site_perl/5.26.0 /usr/local/lib/perl5/5.26.0/amd64-freebsd-thread-multi /usr/local/lib/perl5/5.26.0
Subject: 131337.regular_configure.regexp_nonull.output.txt

Message body is not shown because it is too large.

RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 1.7k
On Mon, 22 May 2017 13:08:13 GMT, jkeenan wrote: [snip] Show quoted text
> > Your patch -- which I've pushed in the smoke-me/jkeenan/131337-craig > branch -- does enable 'make' to complete when g++ is the C-compiler on > FreeBSD-11.0. However, there is a persistent test failure in > t/re/regexp_nonull.t (http://perl5.test-smoke.org/report/55820) -- a > failure which that branch does not get when compiling with g++ on > Linux (http://perl5.test-smoke.org/report/55823). > > I am attaching: > > * the gzipped log of 'make' for that build; > > * the ./perl -Ilib -V output for that build; > > * the output for "cd t; ./perl harness -v re/regexp_nonull.t; cd -" > for that build > > * and by way of contrast, the output for "cd t; ./perl harness -v > re/regexp_nonull.t; cd -" on FreeBSD-11.0 but using the regular > configuration style with 'clang'. > > Thank you very much.
It appears that when, on FreeBSD-11.0, I configure with g++ in the smoke-me/jkeenan/131337-craig branch, the perl that gets built does not have XS::APItest. If, in a "regular_configure" of perl on this platform -- i.e., building with the default C-compiler clang -- at the end of 'make test_prep' I issue this command: ##### find . -type f -name '*APItest*' ##### ... I get these results: ##### ./ext/XS-APItest/APItest.pm ./ext/XS-APItest/APItest.xs ./ext/XS-APItest/APItest_BS ./ext/XS-APItest/APItest.c ./ext/XS-APItest/APItest.bs ./ext/XS-APItest/APItest.o ./lib/auto/XS/APItest/APItest.bs ./lib/auto/XS/APItest/APItest.so ./lib/XS/APItest.pm ##### However, if I build with g++ instead, I only get these results: ##### ./ext/XS-APItest/APItest.pm ./ext/XS-APItest/APItest.xs ./ext/XS-APItest/APItest_BS ##### I don't know why this is happening. Perhaps it is a different bug. Thank you very much. -- James E Keenan (jkeenan@cpan.org)
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 3.2k
On Mon, 22 May 2017 14:11:58 GMT, jkeenan wrote: Show quoted text
> On Mon, 22 May 2017 13:08:13 GMT, jkeenan wrote: > [snip]
> > > > Your patch -- which I've pushed in the smoke-me/jkeenan/131337-craig > > branch -- does enable 'make' to complete when g++ is the C-compiler > > on > > FreeBSD-11.0. However, there is a persistent test failure in > > t/re/regexp_nonull.t (http://perl5.test-smoke.org/report/55820) -- a > > failure which that branch does not get when compiling with g++ on > > Linux (http://perl5.test-smoke.org/report/55823). > > > > I am attaching: > > > > * the gzipped log of 'make' for that build; > > > > * the ./perl -Ilib -V output for that build; > > > > * the output for "cd t; ./perl harness -v re/regexp_nonull.t; cd -" > > for that build > > > > * and by way of contrast, the output for "cd t; ./perl harness -v > > re/regexp_nonull.t; cd -" on FreeBSD-11.0 but using the regular > > configuration style with 'clang'. > > > > Thank you very much.
> > It appears that when, on FreeBSD-11.0, I configure with g++ in the > smoke-me/jkeenan/131337-craig branch, the perl that gets built does > not have XS::APItest. > > If, in a "regular_configure" of perl on this platform -- i.e., > building with the default C-compiler clang -- at the end of 'make > test_prep' I issue this command: > > ##### > find . -type f -name '*APItest*' > ##### > > ... I get these results: > > ##### > ./ext/XS-APItest/APItest.pm > ./ext/XS-APItest/APItest.xs > ./ext/XS-APItest/APItest_BS > ./ext/XS-APItest/APItest.c > ./ext/XS-APItest/APItest.bs > ./ext/XS-APItest/APItest.o > ./lib/auto/XS/APItest/APItest.bs > ./lib/auto/XS/APItest/APItest.so > ./lib/XS/APItest.pm > ##### > > However, if I build with g++ instead, I only get these results: > > ##### > ./ext/XS-APItest/APItest.pm > ./ext/XS-APItest/APItest.xs > ./ext/XS-APItest/APItest_BS > ##### > > I don't know why this is happening. Perhaps it is a different bug. >
If there is an additional bug, it probably occurs much earlier -- in the configure stage. I am attaching the config.sh for blead built with my regular configuration command ... ##### regular_configure () { OS=`uname` if [ $OS = 'FreeBSD' ] then sh ./Configure -des -Dusedevel \ -Duseithreads \ -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" else sh ./Configure -des -Dusedevel fi } ##### ... and for the smoke-me/jkeenan/131337-craig branch built as follows: ##### gpp_configure () { sh ./Configure -des -Dusedevel \ -Duseithreads \ -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \ -Dcc="g++" } ##### If you grep for '_ext=', the differences are startling. regular_configure has a long list of libraries, including XS/APItest, as the value for 'dynamic_ext'. gpp_configure has an empty string for 'dynamic_ext'. In regular_configure, 'static_ext' has a value of a single whitespace. In gpp_configure, 'static_ext' has a long list of libraries which does not include XS/APItest. In regular_configure, 'XS/APItest' can be found in the values for 'dynamic_ext', 'extensions' and 'known_extensions'. In gpp_configure, 'XS/APItest' is found only in 'known_extensions'. Can anyone offer some insight into this? Thank you very much. -- James E Keenan (jkeenan@cpan.org)
Subject: gpp_configure.131337-craig.config.sh
Download gpp_configure.131337-craig.config.sh
application/x-shellscript 33.1k

Message body not shown because it is not plain text.

Subject: regular_configure.blead.config.sh
Download regular_configure.blead.config.sh
application/x-shellscript 32.4k

Message body not shown because it is not plain text.

From: Leon Timmermans <fawaka [...] gmail.com>
To: perlbug <perlbug-followup [...] perl.org>
Subject: Re: [perl #131337] 24e16d7 broke g++ build on FreeBSD-11.0
CC: Perl5 Porters <perl5-porters [...] perl.org>
Date: Mon, 22 May 2017 19:02:48 +0200
Download (untitled) / with headers
text/plain 1.6k
On Mon, May 22, 2017 at 5:09 PM, James E Keenan via RT <perlbug-followup@perl.org> wrote:
Show quoted text
If there is an additional bug, it probably occurs much earlier -- in the configure stage.

I am attaching the config.sh for blead built with my regular configuration command ...

#####
regular_configure ()
{
    OS=`uname`
    if [ $OS = 'FreeBSD' ]
    then
        sh ./Configure -des -Dusedevel \
            -Duseithreads \
            -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing"
    else
        sh ./Configure -des -Dusedevel
    fi
}
#####

... and for the smoke-me/jkeenan/131337-craig branch built as follows:

#####
gpp_configure ()
{
    sh ./Configure -des -Dusedevel \
        -Duseithreads \
        -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \
        -Dcc="g++"
}
#####

If you grep for '_ext=', the differences are startling.  regular_configure has a long list of libraries, including XS/APItest, as the value for 'dynamic_ext'.  gpp_configure has an empty string for 'dynamic_ext'.

In regular_configure, 'static_ext' has a value of a single whitespace.  In gpp_configure, 'static_ext' has a long list of libraries which does not include XS/APItest.

In regular_configure, 'XS/APItest' can be found in the values for 'dynamic_ext', 'extensions' and 'known_extensions'.  In gpp_configure, 'XS/APItest' is found only in 'known_extensions'.

Can anyone offer some insight into this?

Thank you very much.


Yeah, the long list of .a files in the original post looked strange to me. What is the value of the usedl config variable?

Leon
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 1.9k
On Mon, 22 May 2017 17:03:43 GMT, LeonT wrote: Show quoted text
> On Mon, May 22, 2017 at 5:09 PM, James E Keenan via RT < > perlbug-followup@perl.org> wrote: >
> > If there is an additional bug, it probably occurs much earlier -- in the > > configure stage. > > > > I am attaching the config.sh for blead built with my regular configuration > > command ... > > > > ##### > > regular_configure () > > { > > OS=`uname` > > if [ $OS = 'FreeBSD' ] > > then > > sh ./Configure -des -Dusedevel \ > > -Duseithreads \ > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" > > else > > sh ./Configure -des -Dusedevel > > fi > > } > > ##### > > > > ... and for the smoke-me/jkeenan/131337-craig branch built as follows: > > > > ##### > > gpp_configure () > > { > > sh ./Configure -des -Dusedevel \ > > -Duseithreads \ > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \ > > -Dcc="g++" > > } > > ##### > > > > If you grep for '_ext=', the differences are startling. regular_configure > > has a long list of libraries, including XS/APItest, as the value for > > 'dynamic_ext'. gpp_configure has an empty string for 'dynamic_ext'. > > > > In regular_configure, 'static_ext' has a value of a single whitespace. In > > gpp_configure, 'static_ext' has a long list of libraries which does not > > include XS/APItest. > > > > In regular_configure, 'XS/APItest' can be found in the values for > > 'dynamic_ext', 'extensions' and 'known_extensions'. In gpp_configure, > > 'XS/APItest' is found only in 'known_extensions'. > > > > Can anyone offer some insight into this? > > > > Thank you very much. > > > >
> Yeah, the long list of .a files in the original post looked strange to me. > What is the value of the usedl config variable? > > Leon
$ grep -n usedl *.config.sh gpp_configure.131337-craig.config.sh:1161:usedl='undef' regular_configure.blead.config.sh:1160:usedl='define' So, 'undef' in the g++ case. -- James E Keenan (jkeenan@cpan.org)
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 3.4k
On Mon, 22 May 2017 17:26:44 GMT, jkeenan wrote: Show quoted text
> On Mon, 22 May 2017 17:03:43 GMT, LeonT wrote:
> > On Mon, May 22, 2017 at 5:09 PM, James E Keenan via RT < > > perlbug-followup@perl.org> wrote: > >
> > > If there is an additional bug, it probably occurs much earlier -- > > > in the > > > configure stage. > > > > > > I am attaching the config.sh for blead built with my regular > > > configuration > > > command ... > > > > > > ##### > > > regular_configure () > > > { > > > OS=`uname` > > > if [ $OS = 'FreeBSD' ] > > > then > > > sh ./Configure -des -Dusedevel \ > > > -Duseithreads \ > > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict- > > > aliasing" > > > else > > > sh ./Configure -des -Dusedevel > > > fi > > > } > > > ##### > > > > > > ... and for the smoke-me/jkeenan/131337-craig branch built as > > > follows: > > > > > > ##### > > > gpp_configure () > > > { > > > sh ./Configure -des -Dusedevel \ > > > -Duseithreads \ > > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict- > > > aliasing" \ > > > -Dcc="g++" > > > } > > > ##### > > > > > > If you grep for '_ext=', the differences are startling. > > > regular_configure > > > has a long list of libraries, including XS/APItest, as the value > > > for > > > 'dynamic_ext'. gpp_configure has an empty string for > > > 'dynamic_ext'. > > > > > > In regular_configure, 'static_ext' has a value of a single > > > whitespace. In > > > gpp_configure, 'static_ext' has a long list of libraries which does > > > not > > > include XS/APItest. > > > > > > In regular_configure, 'XS/APItest' can be found in the values for > > > 'dynamic_ext', 'extensions' and 'known_extensions'. In > > > gpp_configure, > > > 'XS/APItest' is found only in 'known_extensions'. > > > > > > Can anyone offer some insight into this? > > > > > > Thank you very much. > > > > > >
> > Yeah, the long list of .a files in the original post looked strange > > to me. > > What is the value of the usedl config variable? > > > > Leon
> > $ grep -n usedl *.config.sh > gpp_configure.131337-craig.config.sh:1161:usedl='undef' > regular_configure.blead.config.sh:1160:usedl='define' > > So, 'undef' in the g++ case.
This is starting to look like a "Linux vs FreeBSD" case. If in my FreeBSD-10.3 VM (which is having its own problems with a g++ build; see RT #131336) I do a regular_configure in blead and then a gpp_configure in the smoke-me/jkeenan/131337-craig branch, I observe the same differences as I do in my FreeBSD-11.0 VM. In 10.3 in the branch, 'usedl' is 'undef', 'dynamic_ext' is '', 'static_ext' has many libraries but not XS/APItest. However, when on Linux I configure like this: ##### sh ./Configure -des -Dusedevel -Dcc="g++" ##### ... I get a "more plausible" config.sh: ##### $ grep -n -E 'usedl|dynamic_ext|static_ext' config.sh 667:dynamic_ext='arybase attributes B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd Data/Dumper DB_File Devel/Peek Devel/PPPort Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util Math/BigInt/FastCalc MIME/Base64 mro Opcode PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via POSIX re SDBM_File Socket Storable Sys/Hostname Sys/Syslog threads threads/shared Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap' 1103:static_ext=' ' 1159:usedl='define' ##### Thank you very much. -- James E Keenan (jkeenan@cpan.org)
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 4.4k
On Mon, 22 May 2017 17:49:51 GMT, jkeenan wrote: Show quoted text
> On Mon, 22 May 2017 17:26:44 GMT, jkeenan wrote:
> > On Mon, 22 May 2017 17:03:43 GMT, LeonT wrote:
> > > On Mon, May 22, 2017 at 5:09 PM, James E Keenan via RT < > > > perlbug-followup@perl.org> wrote: > > >
> > > > If there is an additional bug, it probably occurs much earlier -- > > > > in the > > > > configure stage. > > > > > > > > I am attaching the config.sh for blead built with my regular > > > > configuration > > > > command ... > > > > > > > > ##### > > > > regular_configure () > > > > { > > > > OS=`uname` > > > > if [ $OS = 'FreeBSD' ] > > > > then > > > > sh ./Configure -des -Dusedevel \ > > > > -Duseithreads \ > > > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict- > > > > aliasing" > > > > else > > > > sh ./Configure -des -Dusedevel > > > > fi > > > > } > > > > ##### > > > > > > > > ... and for the smoke-me/jkeenan/131337-craig branch built as > > > > follows: > > > > > > > > ##### > > > > gpp_configure () > > > > { > > > > sh ./Configure -des -Dusedevel \ > > > > -Duseithreads \ > > > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict- > > > > aliasing" \ > > > > -Dcc="g++" > > > > } > > > > ##### > > > > > > > > If you grep for '_ext=', the differences are startling. > > > > regular_configure > > > > has a long list of libraries, including XS/APItest, as the value > > > > for > > > > 'dynamic_ext'. gpp_configure has an empty string for > > > > 'dynamic_ext'. > > > > > > > > In regular_configure, 'static_ext' has a value of a single > > > > whitespace. In > > > > gpp_configure, 'static_ext' has a long list of libraries which > > > > does > > > > not > > > > include XS/APItest. > > > > > > > > In regular_configure, 'XS/APItest' can be found in the values for > > > > 'dynamic_ext', 'extensions' and 'known_extensions'. In > > > > gpp_configure, > > > > 'XS/APItest' is found only in 'known_extensions'. > > > > > > > > Can anyone offer some insight into this? > > > > > > > > Thank you very much. > > > > > > > >
> > > Yeah, the long list of .a files in the original post looked strange > > > to me. > > > What is the value of the usedl config variable? > > > > > > Leon
> > > > $ grep -n usedl *.config.sh > > gpp_configure.131337-craig.config.sh:1161:usedl='undef' > > regular_configure.blead.config.sh:1160:usedl='define' > > > > So, 'undef' in the g++ case.
> > This is starting to look like a "Linux vs FreeBSD" case. > > If in my FreeBSD-10.3 VM (which is having its own problems with a g++ > build; see RT #131336) I do a regular_configure in blead and then a > gpp_configure in the smoke-me/jkeenan/131337-craig branch, I observe > the same differences as I do in my FreeBSD-11.0 VM. In 10.3 in the > branch, 'usedl' is 'undef', 'dynamic_ext' is '', 'static_ext' has many > libraries but not XS/APItest. > > However, when on Linux I configure like this: > > ##### > sh ./Configure -des -Dusedevel -Dcc="g++" > ##### > > ... I get a "more plausible" config.sh: > > ##### > $ grep -n -E 'usedl|dynamic_ext|static_ext' config.sh > 667:dynamic_ext='arybase attributes B Compress/Raw/Bzip2 > Compress/Raw/Zlib Cwd Data/Dumper DB_File Devel/Peek Devel/PPPort > Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob > Filter/Util/Call Hash/Util Hash/Util/FieldHash I18N/Langinfo IO > IPC/SysV List/Util Math/BigInt/FastCalc MIME/Base64 mro Opcode > PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via POSIX re > SDBM_File Socket Storable Sys/Hostname Sys/Syslog threads > threads/shared Tie/Hash/NamedCapture Time/HiRes Time/Piece > Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap' > 1103:static_ext=' ' > 1159:usedl='define' > ##### > > Thank you very much.
After much experimentation, this is what I have got somewhat working. On FreeBSD-11.0, in the smoke-me/jkeenan/131337-craig branch, I configure as follows: ##### sh ./Configure -des -Dusedevel \ -Duseithreads \ -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \ -Dcc="g++" \ -Dusedl \ -Ddlsrc='dl_dlopen.xs' ##### That populates config.sh as in attachment 131337.better.config.sh.txt. 'make' and 'make test_harness' complete successfully. But this begs the question: Why on FreeBSD --but not on Linux -- does a request to build with g++ require command-line switches 'usedl' and 'dlsrc' to be populated? I have stared at the relevant code in ./Configure but cannot figure out the answer. Thank you very much. -- James E Keenan (jkeenan@cpan.org)
Subject: 131337.better.config.sh.txt
17:config_args='-des -Dusedevel -Duseithreads -Doptimize=-O2 -pipe -fstack-protector -fno-strict-aliasing -Dcc=g++ -Dusedl -Ddlsrc=dl_dlopen.xs' 25:config_arg7='-Ddlsrc=dl_dlopen.xs' 660:dlsrc='dl_dlopen.xs' 686:extensions='B Compress/Raw/Bzip2 Compress/Raw/Zlib Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Digest/MD5 Digest/SHA Encode Fcntl File/DosGlob File/Glob Filter/Util/Call GDBM_File Hash/Util Hash/Util/FieldHash I18N/Langinfo IO IPC/SysV List/Util MIME/Base64 Math/BigInt/FastCalc NDBM_File Opcode POSIX PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via SDBM_File Socket Storable Sys/Hostname Sys/Syslog Tie/Hash/NamedCapture Time/HiRes Time/Piece Unicode/Collate Unicode/Normalize XS/APItest XS/Typemap arybase attributes mro re threads threads/shared Archive/Tar Attribute/Handlers AutoLoader B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Config/Perl/V Devel/SelfStubber Digest Dumpvalue Env Errno Exporter ExtUtils/CBuilder ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS File/Fetch File/Find File/Path File/Temp FileCache Filter/Simple Getopt/Long HTTP/Tiny I18N/Collate I18N/LangTags IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 JSON/PP Locale/Codes Locale/Maketext Locale/Maketext/Simple Math/BigInt Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NEXT Net/Ping Params/Check Perl/OSType PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage Safe Search/Dict SelfLoader Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Memoize Tie/RefHash Time/Local XSLoader autodie autouse base bignum constant encoding/warnings experimental if lib libnet parent perlfaq podlators version' 887:known_extensions='Amiga/ARexx Amiga/Exec Archive/Tar Attribute/Handlers AutoLoader B B/Debug CPAN CPAN/Meta CPAN/Meta/Requirements CPAN/Meta/YAML Carp Compress/Raw/Bzip2 Compress/Raw/Zlib Config/Perl/V Cwd DB_File Data/Dumper Devel/PPPort Devel/Peek Devel/SelfStubber Digest Digest/MD5 Digest/SHA Dumpvalue Encode Env Errno Exporter ExtUtils/CBuilder ExtUtils/Constant ExtUtils/Install ExtUtils/MakeMaker ExtUtils/Manifest ExtUtils/Miniperl ExtUtils/ParseXS Fcntl File/DosGlob File/Fetch File/Find File/Glob File/Path File/Temp FileCache Filter/Simple Filter/Util/Call GDBM_File Getopt/Long HTTP/Tiny Hash/Util Hash/Util/FieldHash I18N/Collate I18N/LangTags I18N/Langinfo IO IO/Compress IO/Socket/IP IO/Zlib IPC/Cmd IPC/Open3 IPC/SysV JSON/PP List/Util Locale/Codes Locale/Maketext Locale/Maketext/Simple MIME/Base64 Math/BigInt Math/BigInt/FastCalc Math/BigRat Math/Complex Memoize Module/CoreList Module/Load Module/Load/Conditional Module/Loaded Module/Metadata NDBM_File NEXT Net/Ping ODBM_File Opcode POSIX Params/Check Perl/OSType PerlIO/encoding PerlIO/mmap PerlIO/scalar PerlIO/via PerlIO/via/QuotedPrint Pod/Checker Pod/Escapes Pod/Functions Pod/Html Pod/Parser Pod/Perldoc Pod/Simple Pod/Usage SDBM_File Safe Search/Dict SelfLoader Socket Storable Sys/Hostname Sys/Syslog Term/ANSIColor Term/Cap Term/Complete Term/ReadLine Test Test/Harness Test/Simple Text/Abbrev Text/Balanced Text/ParseWords Text/Tabs Thread/Queue Thread/Semaphore Tie/File Tie/Hash/NamedCapture Tie/Memoize Tie/RefHash Time/HiRes Time/Local Time/Piece Unicode/Collate Unicode/Normalize VMS/DCLsym VMS/Filespec VMS/Stdio Win32 Win32API/File Win32CORE XS/APItest XS/Typemap XSLoader arybase attributes autodie autouse base bignum constant encoding/warnings experimental if lib libnet mro parent perlfaq podlators re threads threads/shared version ' 1163:usedl='define'
Date: Mon, 22 May 2017 23:06:38 +0200
Subject: Re: [perl #131337] 24e16d7 broke g++ build on FreeBSD-11.0
CC: Perl5 Porters <perl5-porters [...] perl.org>
From: Leon Timmermans <fawaka [...] gmail.com>
To: perlbug <perlbug-followup [...] perl.org>
On Mon, May 22, 2017 at 9:59 PM, James E Keenan via RT <perlbug-followup@perl.org> wrote:
Show quoted text
After much experimentation, this is what I have got somewhat working.

On FreeBSD-11.0, in the smoke-me/jkeenan/131337-craig branch, I configure as follows:

#####
sh ./Configure -des -Dusedevel \
        -Duseithreads \
        -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" \
        -Dcc="g++" \
        -Dusedl \
        -Ddlsrc='dl_dlopen.xs'
#####

That populates config.sh as in attachment 131337.better.config.sh.txt.

'make' and 'make test_harness' complete successfully.

But this begs the question:  Why on FreeBSD --but not on Linux -- does a request to build with g++ require command-line switches 'usedl' and 'dlsrc' to be populated?

I have stared at the relevant code in ./Configure but cannot figure out the answer.


The hints for linux mention that "If using g++, the Configure scan for dlopen() and (especially) dlerror() might fail, easier just to forcibly hint them in." and adds a workaround. Possibly the freebsd hints need something similar.

Leon
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 1.3k
On Mon, 22 May 2017 21:07:39 GMT, LeonT wrote: Show quoted text
> On Mon, May 22, 2017 at 9:59 PM, James E Keenan via RT < > perlbug-followup@perl.org> wrote: >
> > After much experimentation, this is what I have got somewhat working. > > > > On FreeBSD-11.0, in the smoke-me/jkeenan/131337-craig branch, I > > configure > > as follows: > > > > ##### > > sh ./Configure -des -Dusedevel \ > > -Duseithreads \ > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict-aliasing" > > \ > > -Dcc="g++" \ > > -Dusedl \ > > -Ddlsrc='dl_dlopen.xs' > > ##### > > > > That populates config.sh as in attachment > > 131337.better.config.sh.txt. > > > > 'make' and 'make test_harness' complete successfully. > > > > But this begs the question: Why on FreeBSD --but not on Linux -- > > does a > > request to build with g++ require command-line switches 'usedl' and > > 'dlsrc' > > to be populated? > > > > I have stared at the relevant code in ./Configure but cannot figure > > out > > the answer. > > > >
> The hints for linux mention that "If using g++, the Configure scan for > dlopen() and (especially) dlerror() might fail, easier just to > forcibly > hint them in." and adds a workaround. Possibly the freebsd hints need > something similar. > > Leon
That looks promising. See https://perl5.git.perl.org/perl.git/commitdiff/48e836997 -- James E Keenan (jkeenan@cpan.org)
RT-Send-CC: perl5-porters [...] perl.org
Download (untitled) / with headers
text/plain 2.2k
On Tue, 23 May 2017 02:15:19 GMT, jkeenan wrote: Show quoted text
> On Mon, 22 May 2017 21:07:39 GMT, LeonT wrote:
> > On Mon, May 22, 2017 at 9:59 PM, James E Keenan via RT < > > perlbug-followup@perl.org> wrote: > >
> > > After much experimentation, this is what I have got somewhat > > > working. > > > > > > On FreeBSD-11.0, in the smoke-me/jkeenan/131337-craig branch, I > > > configure > > > as follows: > > > > > > ##### > > > sh ./Configure -des -Dusedevel \ > > > -Duseithreads \ > > > -Doptimize="-O2 -pipe -fstack-protector -fno-strict- > > > aliasing" > > > \ > > > -Dcc="g++" \ > > > -Dusedl \ > > > -Ddlsrc='dl_dlopen.xs' > > > ##### > > > > > > That populates config.sh as in attachment > > > 131337.better.config.sh.txt. > > > > > > 'make' and 'make test_harness' complete successfully. > > > > > > But this begs the question: Why on FreeBSD --but not on Linux -- > > > does a > > > request to build with g++ require command-line switches 'usedl' and > > > 'dlsrc' > > > to be populated? > > > > > > I have stared at the relevant code in ./Configure but cannot figure > > > out > > > the answer. > > > > > >
> > The hints for linux mention that "If using g++, the Configure scan > > for > > dlopen() and (especially) dlerror() might fail, easier just to > > forcibly > > hint them in." and adds a workaround. Possibly the freebsd hints need > > something similar. > > > > Leon
> > That looks promising. See > https://perl5.git.perl.org/perl.git/commitdiff/48e836997
Applied to blead in these commits: ##### commit 21a33adc37856aaedd4bf756d5dca47bdc4f7b50 Author: James E Keenan <jkeenan@cpan.org> AuthorDate: Mon May 22 21:25:18 2017 Commit: James E Keenan <jkeenan@cpan.org> CommitDate: Sat Jun 3 18:22:46 2017 When building with g++ on FreeBSD, explicitly set 'usedl' and 'dlsrc'. For: https://rt.perl.org/Ticket/Display.html?id=131337 Signed-off-by: James E Keenan <jkeenan@cpan.org> commit 66c5e3f2ab554a89dfc00689602414ac21ea66f6 Author: James E Keenan <jkeenan@cpan.org> AuthorDate: Sun May 21 22:16:23 2017 Commit: James E Keenan <jkeenan@cpan.org> CommitDate: Sat Jun 3 18:22:46 2017 Patch suggested by Craig Berry for RT 131337. ##### See http://perl5.test-smoke.org/report/56009 Marking ticket Resolved. -- James E Keenan (jkeenan@cpan.org)
Date: Mon, 12 Jun 2017 16:08:30 -0400
From: Andy Dougherty <doughera [...] lafayette.edu>
To: James E Keenan via RT <perlbug-followup [...] perl.org>
Subject: Re: [perl #131337] 24e16d7 broke g++ build on FreeBSD-11.0
Download (untitled) / with headers
text/plain 1.5k
On Mon, Jun 05, 2017 at 06:05:07AM -0700, James E Keenan via RT wrote: Show quoted text
> Applied to blead in these commits: > > ##### > commit 21a33adc37856aaedd4bf756d5dca47bdc4f7b50 > Author: James E Keenan <jkeenan@cpan.org> > AuthorDate: Mon May 22 21:25:18 2017 > Commit: James E Keenan <jkeenan@cpan.org> > CommitDate: Sat Jun 3 18:22:46 2017 > > When building with g++ on FreeBSD, explicitly set 'usedl' and 'dlsrc'. > > For: https://rt.perl.org/Ticket/Display.html?id=131337 > Signed-off-by: James E Keenan <jkeenan@cpan.org> > > commit 66c5e3f2ab554a89dfc00689602414ac21ea66f6 > Author: James E Keenan <jkeenan@cpan.org> > AuthorDate: Sun May 21 22:16:23 2017 > Commit: James E Keenan <jkeenan@cpan.org> > CommitDate: Sat Jun 3 18:22:46 2017 > > Patch suggested by Craig Berry for RT 131337. > ##### > > See http://perl5.test-smoke.org/report/56009 > > Marking ticket Resolved.
I pushed a slightly simpler version that forces Configure to find dlopen() as commit 2c8efe4079b75c61cf34425054539a9c24913e9f Author: Andy Dougherty <doughera@lafayette.edu> Date: Mon Jun 12 08:02:10 2017 -0400 Simpler hints fix for [perl #131337]. Having found dlopen(), the values of usedl=define and dlsrc=dl_dlopen.xs then follow naturally, but the user can still override and choose static linking, if desired, with -Uusedl. (I've also attached the patch here to record it in RT -- I meant to do so earlier, but failed to include RT in the appropriate CC: line.) The ticket should still stay Resolved. -- Andy Dougherty doughera@lafayette.edu

Message body is not shown because sender requested not to inline it.



This service is sponsored and maintained by Best Practical Solutions and runs on Perl.org infrastructure.

For issues related to this RT instance (aka "perlbug"), please contact perlbug-admin at perl.org