On Wed, Oct 21, 2015 at 11:11:05PM -0400, Ricardo Signes wrote: > I think this patch should be applied unless there are specific technical > problems with it. I have hit the difficulty Ivan describes, and I agree with > his reasoning in general. I think we have hit some specific technical problems. (Sorry for not looking carefully at this quite some time ago!) The relatively recent Configure change commit 41d73075f0801c26794dadb1ff690f305d7e53a7 Author: Ivan Pozdeev <vano@mail.mipt.ru> Date: Wed Aug 12 20:33:12 2015 +0300 Make -O behaviour the default has unintentionally broken a few things. Configure's -O option was (somewhat sloppily) defined as let -D and -U override definitions from loaded configuration file. What was perhaps unclearly specified is that the "loaded configuration file" could be an old config.sh or could be a hints file (or Policy.sh file). It used to be that you could do something like the following sh Configure -Dccflags=-DSOME_RANDOM_FLAG and the hints/ files would *append* to that value. As just one example, in hints/solaris_2.sh, there are lines like the following: ccflags="$ccflags -DPTR_IS_LONG" ccflags="$ccflags -DPERL_USE_SAFE_PUTENV" Many other hints do something similar. This appending behavior is documented in hints/README.hints. If you wanted to override those hints file setting, you would use the -O flag. Most of the time you didn't want to override them, so -O was not the default. Now it is true that the examples in the INSTALL file all use -Accflags instead of -Dccflags, but the hints files were generally written to allow either, and some third-party build scripts do so. Some examples: Apple system /usr/bin/perl: config_args='-ds -e -Dprefix=/usr -Dccflags=-g -pipe -Dldflags= -Dman3ext=3pm -Duseithreads -Duseshrplib -Dinc_version_list=none -Dcc=cc'; Darwin MacPorts: [perl #128093] Broken build of perl5.24.0-RC5 on Mac OS X (10.7) Debian: config_args='-Dusethreads -Duselargefiles -Dccflags=-DDEBIAN -D_FORTIFY_SOURCE=2 -g -O2 -fstack-protector-strong -Wformat -Werror=format-security -Dldflags= -Wl,-z,relro -Dlddlflags=-shared -Wl,-z,relro -Dcccdlflags=-fPIC -Darchname=x86_64-linux-gnu -Dprefix=/usr -Dprivlib=/usr/share/perl/5.20 -Darchlib=/usr/lib/x86_64-linux-gnu/perl/5.20 -Dvendorprefix=/usr -Dvendorlib=/usr/share/perl5 -Dvendorarch=/usr/lib/x86_64-linux-gnu/perl5/5.20 -Dsiteprefix=/usr/local -Dsitelib=/usr/local/share/perl/5.20.2 -Dsitearch=/usr/local/lib/x86_64-linux-gnu/perl/5.20.2 -Dman1dir=/usr/share/man/man1 -Dman3dir=/usr/share/man/man3 -Dsiteman1dir=/usr/local/man/man1 -Dsiteman3dir=/usr/local/man/man3 -Duse64bitint -Dman1ext=1 -Dman3ext=3perl -Dpager=/usr/bin/sensible-pager -Uafs -Ud_csh -Ud_ualarm -Uusesfio -Uusenm -Ui_libutil -Uversiononly -DDEBUGGING=-g -Doptimize=-O2 -Duseshrplib -Dlibperl=libperl.so.5.20.2 -des'; OpenBSD: config_args='-dsE -Dopenbsd_distribution=defined -Dccflags=-DNO_LOCALE_NUMERIC -DNO_LOCALE_COLLATE -Dmksymlinks' A quick look through perlbug reports for -Dccflags in config_args shows similar things for systems from cpanel, centos, and redhat as well. There are probably others; I didn't search very hard. So my question is: Was making -O the default really worthwhile? I gather it helped in a case where someone re-ran Configure with new ccflags but with an existing config.sh present. If that was the use case, then I think a tweak to the 're-use config.sh?' logic might be a better solution. Thanks for reading this far, -- Andy Dougherty doughera@lafayette.eduThread Previous | Thread Next