diff --git a/tools/plotting/fastnnlo_scaledep.py b/tools/plotting/fastnnlo_scaledep.py index 3e0965d249cee9673a2eed46cc30f9c361a017b6..30b7c86d5e06599d8db54de56112250307d4a761 100755 --- a/tools/plotting/fastnnlo_scaledep.py +++ b/tools/plotting/fastnnlo_scaledep.py @@ -91,7 +91,8 @@ from fastnlo import SetGlobalVerbosity # Redefine ScalarFormatter class ScalarFormatterForceFormat(ScalarFormatter): # Override function that finds format to use. - def _set_format(self, vmin, vmax): + # def _set_format(self, vmin, vmax): + def _set_format(self): self.format = "%1.2f" # Give format here @@ -142,7 +143,7 @@ def plotting(x_axis, xmin, xmax, iobs, xs_cn, xs_fl, xs_fu, dxsr_cn, xind, title fig = plt.figure(figsize=(7, 5)) ax1 = plt.subplot(gs[:, :]) ax1.set_xlim([xmin, xmax]) - ax1.set_xscale('log', nonposx='clip') + ax1.set_xscale('log', nonpositive='clip') ax1.set_yscale('linear') # Texify labels # tlabels = [] @@ -252,7 +253,7 @@ def plotting(x_axis, xmin, xmax, iobs, xs_cn, xs_fl, xs_fu, dxsr_cn, xind, title ax2 = plt.subplot(gs[2, :]) # ax2 = plt.subplot(gs[2, :], sharex=ax1) ax2.set_xlim([xmin, xmax]) - ax2.set_xscale('log', nonposx='clip') + ax2.set_xscale('log', nonpositive='clip') ax2.set_yscale('linear') ax2.set_xlabel(r'%s' % xlabel, horizontalalignment='right', x=1.0, verticalalignment='top', y=1.0) diff --git a/v2.5/generators/nlojet++/ChangeLog b/v2.5/generators/nlojet++/ChangeLog index aa3146f3c023e4cf828c3e281724fa36d42528c6..36be2e03fac71975160e5c407e33a20289ea50a8 100644 --- a/v2.5/generators/nlojet++/ChangeLog +++ b/v2.5/generators/nlojet++/ChangeLog @@ -1,6 +1,906 @@ +2023-07-12 Release of fastNLO interface to NLOJet++ package version 2.5.1, tag 2888 + ======================================================================== + +2023-07-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/configure.ac, + v2.5/generators/nlojet++/interface/check/Makefile.am: For makefile + portability remove commands from Makefile.am and use AC_SUBST + variables from configure.ac instead + +2023-07-12 JohannesGaessler <johannesg@5d6.de> + + * v2.5/generators/nlojet++/interface/check/Makefile.am, + v2.5/generators/nlojet++/interface/check/fnlo-compare-tables.py, + v2.5/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in, + v2.5/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in, + v2.5/generators/nlojet++/interface/{check/input => + data/check}/InclusiveNJets_InclusiveJets_fix.wrm, + v2.5/generators/nlojet++/interface/{check/input => + data/check}/InclusiveNJets_InclusiveJets_flex.wrm, + v2.5/generators/nlojet++/interface/data/check/Makefile.am, + v2.5/generators/nlojet++/interface/{ => + data}/check/compare-table-helper.py, + v2.5/generators/nlojet++/interface/{check/input => + data/check}/fix_NodeDensity.str, + v2.5/generators/nlojet++/interface/{check/input => + data/check}/fix_NodesPerBin.str, + v2.5/generators/nlojet++/interface/{check/input => + data/check}/flex_NodeDensity.str, + v2.5/generators/nlojet++/interface/{check/input => + data/check}/flex_NodesPerBin.str: Fixed NLOJet++ distcheck paths + +2023-07-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/README + inconsistency; drop all LHAPDF5 stuff; by default no doxygen use + +2023-07-11 JohannesGaessler <johannesg@5d6.de> + + * v2.5/generators/nlojet++/interface/check/compare-table-helper.py, + v2.5/generators/nlojet++/interface/check/fnlo-compare-tables.py, + v2.5/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in, + v2.5/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in: Skip + nlojet++ checks if no Python extension + +2023-07-11 JohannesGaessler <johannesg@5d6.de> + + * v2.5/generators/nlojet++/interface/check/Makefile.am, + v2.5/generators/nlojet++/interface/check/fnlo-compare-tables.py, + v2.5/generators/nlojet++/interface/check/{ => + input}/InclusiveNJets_InclusiveJets_fix.wrm, + v2.5/generators/nlojet++/interface/check/{ => + input}/InclusiveNJets_InclusiveJets_flex.wrm, + v2.5/generators/nlojet++/interface/check/{ => + input}/fix_NodeDensity.str, + v2.5/generators/nlojet++/interface/check/{ => + input}/fix_NodesPerBin.str, + v2.5/generators/nlojet++/interface/check/{ => + input}/flex_NodeDensity.str, + v2.5/generators/nlojet++/interface/check/{ => + input}/flex_NodesPerBin.str: Fixed nlojet++ make check PYTHONPATH, + make clean + +2023-07-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * : Merge bin_density into master + +2023-07-02 JohannesGaessler <johannesg@5d6.de> + + * test/.gitignore, test/InclusiveNJets_InclusiveJets_fix.wrm, + test/InclusiveNJets_InclusiveJets_flex.wrm, test/compare_tables.py, + test/fix_NodeDensity.str, test/fix_NodesPerBin.str, + test/flex_NodeDensity.str, test/flex_NodesPerBin.str: Added + NodesPerBin <-> BinDensity test files + +2023-02-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/ChangeLog, v2.5/generators/nlojet++/NEWS: + Updated ChangeLog and NEWS + +2023-02-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/mygitcl: Add command for updating + ChangeLog + +2023-02-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/mygitcl: Add command for updating + ChangeLog + +2023-02-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/interface/hadron/Makefile.am: Comment out + work-in-progress version (new) + +2023-02-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc, + v2.5/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc, + v2.5/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc, + v2.5/generators/nlojet++/interface/hadron/InclusiveNJets.cc, + v2.5/generators/nlojet++/interface/hadron/InclusiveNJets_new.cc: + Implementation of HT_parton as scale + +2023-02-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/configure.ac, + v2.5/generators/nlojet++/m4/ax_check_zlib.m4, + v2.5/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4, + v2.5/generators/nlojet++/m4/libtool.m4, + v2.5/generators/nlojet++/m4/ltoptions.m4, + v2.5/generators/nlojet++/m4/ltversion.m4: autotools update + +2022-07-21 Release of fastNLO interface to NLOJet++, package version 2.5.0, revision 2845 + ============================================================================== + +2022-07-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/generators/nlojet++/Makefile.am, + v2.5/generators/nlojet++/configure.ac, + v2.5/generators/nlojet++/m4/libtool.m4, + v2.5/generators/nlojet++/m4/ltoptions.m4, + v2.5/generators/nlojet++/m4/ltsugar.m4, + v2.5/generators/nlojet++/m4/ltversion.m4, + v2.5/generators/nlojet++/m4/lt~obsolete.m4, + +2021-05-26 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + Version cleanup ... + +2021-05-26 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + Version cleanup ... + +2021-05-26 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.3/generators/nlojet++/configure.ac + +2021-05-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * : Merge in development from master + +2020-09-07 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2771 + ==================================================================================== + +2020-09-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.3/generators/nlojet++/interface/include/fnlo_int_nlojet/fnlo_int + _hhc_nlojet.h, + v2.3/generators/nlojet++/interface/tools/fnlo_int_hhc_nlojet.cc + +2019-03-08 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/InclusiveNJetDiffs/fnl2342e + -2332e_I1298810_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveNJetDiffs/fnl2342e + -2332e_y0_I1298810_v23_fix.str, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc: Add + choice of min,ave,max to x sect difference scenario; impact very + small + +2019-02-03 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2657 + ==================================================================================== + +2019-02-03 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/configure.ac: Fix some autotools issues + +2019-02-01 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/check/InclusiveNJets.str, + v2.0/generators/nlojet++/interface/check/InclusiveNJets_fnr0001midp + HT_I723509_v23_fix_warmup.txt, + v2.0/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in, + v2.0/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in, + v2.0/generators/nlojet++/interface/check/fnr0001midpHT_I723509_v23_ + fix.str, v2.0/generators/nlojet++/interface/{ => + data}/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fix.wrm, + v2.0/generators/nlojet++/interface/data/check/InclusiveNJets_fnr000 + 1midpHT_I723509_v23_fix_warmup.txt, + v2.0/generators/nlojet++/interface/data/check/warmup.txt: Check + cleanup in nlojet++ interface + +2019-02-01 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/m4/ax_check_zlib.m4, + v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4, + v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx_11.m4, + v2.0/generators/nlojet++/m4/ax_require_defined.m4: Add new CRunDec3; add fscheme; + some more adaptations to as evolution interface + +2019-01-31 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc, + v2.0/generators/nlojet++/interface/jetalgos/fastjet-jets.cc, + v2.0/generators/nlojet++/interface/jetalgos/fj-jets.cc: Bugfix in + delta sigma scenarion + + 2019-01-31 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/InclusiveNJetDiffs/fnl2342e + -2332e_y0_I1298810_v23_fix.str: Reduced steering file + +2019-01-30 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc: + Propagate weight for x section diffs; TODO decide which version + +2019-01-30 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/InclusiveNJetDiffs/Makefile + .am: Fixes to NLOJet++ cross section diff scenario for Suman + +2019-01-30 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/configure.ac, + v2.0/generators/nlojet++/interface/data/InclusiveNJetDiffs/fnl2342e + -2332e_I1298810_v23_fix.str, + v2.0/generators/nlojet++/interface/data/Makefile.am, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc: + Fixes to NLOJet++ cross section diff scenario for Suman + +2019-01-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/check/InclusiveNJets.str, + v2.0/generators/nlojet++/interface/check/InclusiveNJets_fnr0001midp + HT_I723509_v23_fix.wrm, + v2.0/generators/nlojet++/interface/check/InclusiveNJets_fnr0001midp + HT_I723509_v23_fix_warmup.txt, + v2.0/generators/nlojet++/interface/check/fnr0001midpHT_I723509_v23_ + fix.str, v2.0/generators/nlojet++/interface/data/Makefile.am: + Additions to NLOJet++ interface + +2019-01-16 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc: + Add lunique switch for jet pairs loop of Panos + +2018-11-26 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/InclusiveNJetDiffs/fnl2342e + -2332e_I1298810_v23_fix.str, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc: Add + test scenario to calculate x section differences as needed for + radius ratio etc.; only for fix-scale tables for now + +2018-11-26 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/check/Makefile.am, + v2.0/generators/nlojet++/interface/check/fnlo-nj-wrmtest.pl.in, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJets.cc: Update + NLOJet++ interface for some changes in toolkit + +2018-03-24 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/configure.ac: SVNREV --> GITREV + +2018-03-24 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/fastNLOjetpp.cc: SVNREV --> GITREV + +2018-03-24 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/.gitignore: More + gitignores + +2018-03-23 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/check/.gitignore: Updated + gitignore settings + +2018-03-23 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/.gitignore, v2.0/generators/nlojet++/.gitignore: Updated gitignore settings + +2018-01-30 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/Makefile.am, + v2.0/generators/nlojet++/configure.ac, v2.0/toolkit/Makefile.am: + Same git adaptations for NLOJet++ interface + +2017-11-14 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * tools/fnlo-run-nlojet.pl, + v2.0/generators/nlojet++/interface/data/dev/fnl5332h_v23_fix.str, + v2.0/generators/nlojet++/interface/data/dev/fnl5362h_v23_fix.str: + Prepare NLOJet++ calcs for Nemo git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2426 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-11-07 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2424 + ==================================================================================== + +2017-11-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in, + v2.0/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in, + v2.0/generators/nlojet++/interface/check/fnlo-nj-wrmtest.pl.in, + v2.0/generators/nlojet++/interface/data/check/{fnr0001midpHT_I72350 + 9_v23_fix_InclusiveNJets_warmup.txt => + InclusiveNJets_fnr0001midpHT_I723509_v23_fix_warmup.txt}: Fix make + check for NLOJet++ interface git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2424 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-11-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/check/warmup.txt: Fix link git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2423 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-11-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/check/warmup.txt: Fix link git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2422 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-11-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl5332g_v23_ + I1459051_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl5362g_v23_ + I1459051_fix.str, + v2.0/generators/nlojet++/interface/data/dev/fnl5332h_v23_fix.str, + v2.0/generators/nlojet++/interface/data/dev/fnl5362h_v23_fix.str, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc: + Scenario update for nlojet++ git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2419 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-08-17 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2016_I14 + 59051.info, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2016_I14 + 59051.plot, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2016_I14 + 59051.yoda: Remove Rivet files now in standard release git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2412 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-08-15 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2411 + ======================================================================================== + +2017-08-15 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in, + v2.0/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in, + v2.0/generators/nlojet++/interface/data/check/fnr0001midpHT_I723509 + _v23_fix_InclusiveNJets_warmup.txt: Update checks for newer toolkit + version git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2411 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-08-15 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/Makefile.am: Deal with m4 macro issues git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2410 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-08-15 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/m4/ax_check_zlib.m4, + v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4, + v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx_11.m4, + v2.0/generators/nlojet++/m4/ax_prog_doxygen.m4, + v2.0/generators/nlojet++/m4/ax_python_devel.m4, + v2.0/generators/nlojet++/m4/ax_require_defined.m4, + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2409 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-06-27 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/configure.ac, + v2.0/generators/nlojet++/interface/data/dev/fnl5932numa_v23_fix.str + , v2.0/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc, + v2.0/generators/nlojet++/interface/hadron/Makefile.am: Add new test + calc git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2405 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2017-03-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2015_I14 + 10826.info, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2015_I14 + 10826.plot, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2015_I14 + 10826.yoda, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2016_I14 + 59051.info, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2016_I14 + 59051.plot, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2016_I14 + 59051.yoda, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2017_I14 + 87277.info, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2017_I14 + 87277.plot, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2017_I14 + 87277.yoda: Add my prel. Rivet files for data-table comparisons git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2384 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2016-12-23 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJets.cc: Add + OutputCompression to InclusiveNJets.cc; todo for events git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2349 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2016-12-23 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/README: Don't forget to do + some steering updates for NLOJet++ git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2348 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2016-10-24 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/Makefile.am, + v2.0/generators/nlojet++/configure.ac, + v2.0/generators/nlojet++/interface/check/Makefile.am, + v2.0/generators/nlojet++/interface/check/{fnlo-nj-lotest.pl => + fnlo-nj-lotest.pl.in}, + v2.0/generators/nlojet++/interface/check/{fnlo-nj-nlotest.pl => + fnlo-nj-nlotest.pl.in}, + v2.0/generators/nlojet++/interface/check/{fnlo-nj-wrmtest.pl => + fnlo-nj-wrmtest.pl.in}, + v2.0/generators/nlojet++/interface/data/check/Makefile.am, + v2.0/generators/nlojet++/interface/data/check/born.tab.gz, + v2.0/generators/nlojet++/interface/data/check/nlo.tab.gz, + v2.0/generators/nlojet++/interface/data/check/{fnr0001midpHT_I72350 + 9_v23_fix.str => steer.str}, + v2.0/generators/nlojet++/interface/data/check/warmup.txt: Finished + check setup for NLOJet++ interface; supports VPATH builds, i.e. also + make distcheck git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2296 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2016-10-23 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/check/Makefile.am, + v2.0/generators/nlojet++/interface/check/fnlo-nj-lotest.pl, + v2.0/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl: Fixes + in perl scripts git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2295 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2016-10-23 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/configure.ac, + v2.0/generators/nlojet++/interface/Makefile.am, + v2.0/generators/nlojet++/interface/check/Makefile.am, + v2.0/generators/nlojet++/interface/check/fnlo-nj-lotest.pl, + v2.0/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl, + v2.0/generators/nlojet++/interface/check/fnlo-nj-wrmtest.pl, + v2.0/generators/nlojet++/interface/data/Makefile.am, + v2.0/generators/nlojet++/interface/data/check/Makefile.am, + v2.0/generators/nlojet++/interface/data/check/fnr0001midpHT_I723509 + _v23_fix.str, + v2.0/generators/nlojet++/interface/data/check/fnr0001midpHT_I723509 + _v23_fix_InclusiveNJets_warmup.txt: Add table production checks to + NLOJet++ interface git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2294 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2016-10-13 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2272 + ==================================================================================== + +2016-10-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJets.cc, + v2.0/generators/nlojet++/interface/tools/fnlo_int_hhc_nlojet.cc: Fix + issue with steering and Gen/ProcConsts changes in Nlojet++ interface git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2271 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2016-09-20 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/dev/fnl5662ia_v23_fix.str: + Add test scenario for later concatenation git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2246 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-10-21 Georg Sieber <georg.sieber@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/dev/fnl_triplediffjets.str: + steering for 3d jet measurement. git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2196 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-10-06 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/sherpa/ATLAS_2012_I1082936/MCgrid_ATLAS_2012_I10829 + 36.str, v2.0/generators/sherpa/ATLAS_2012_I1082936/Makefile, + v2.0/generators/sherpa/ATLAS_2012_I1082936/Run_prod.dat, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/MCgrid_ATLAS_20 + 12_I1082936.cc, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/MCgrid_ATLAS_20 + 12_I1082936.cc.orig, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/MCgrid_ATLAS_20 + 12_I1082936.info, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/MCgrid_ATLAS_20 + 12_I1082936.plot, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/MCgrid_ATLAS_20 + 12_I1082936.yoda, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/templates/MCgri + d_ATLAS_2012_I1082936.cc, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/templates/MCgri + d_ATLAS_2012_I1082936.info, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/templates/MCgri + d_ATLAS_2012_I1082936.plot, + v2.0/generators/sherpa/ATLAS_2012_I1082936/analysis/templates/MCgri + d_ATLAS_2012_I1082936.yoda, + v2.0/generators/sherpa/ATLAS_2012_I1082936/basic.str, + v2.0/generators/sherpa/ATLAS_2012_I1082936/mcgrid/MCgrid_ATLAS_2012 + _I1082936/phasespace/d04-x01-y01.txt, + v2.0/generators/sherpa/ATLAS_2012_I1082936/mcgrid/basic.str.evtcoun + t, v2.0/generators/sherpa/ATLAS_2012_I1082936/run_steps.csh: Add + working example with mcgrid + sherpa git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2189 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-09-18 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/fastNLOjetpp.cc: Fix + some missing std:: in nlojet++ interface git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2177 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-08-20 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/dev/fnl3732denhta_v23_fix.s + tr, + v2.0/generators/nlojet++/interface/data/dev/fnl3732numhta_v23_fix.s + tr: Updated devel scenarios git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2138 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-07-14 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/dev/fnl5332g_v23_fix.str, + v2.0/generators/nlojet++/interface/data/dev/fnl5362g_v23_fix.str: + Remove empty bins git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2131 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-07-14 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/dev/fnl5332g_v23_fix.str, + v2.0/generators/nlojet++/interface/data/dev/fnl5362g_v23_fix.str: + new dev scenarios git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2130 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-07-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/Examples/InclusiveJets_Upda + tedDescription_v23_fix.str, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_mu2_v23_fix.s + tr: Respect min. number git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2129 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-07-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_2mu_v23_fix.s + tr, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_2x_v23_fix.st + r, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_mu2_v23_fix.s + tr, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_x2_v23_fix.st + r, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_xcm_v23_fix.s + tr, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_xl10_v23_fix. + str, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_xlin_v23_fix. + str, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_xll25_v23_fix + .str, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_xln_v23_fix.s + tr, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_xon_v23_fix.s + tr, + v2.0/generators/nlojet++/interface/data/Test/fnl2342b_xsl10_v23_fix + .str: Add series of tests for fnlo paper git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2128 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-07-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/dev/fnl3732denht_v23_fix.st + r, + v2.0/generators/nlojet++/interface/data/dev/fnl3732numht_v23_fix.st + r: Dev scenarios git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2127 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-06-03 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2125 + ==================================================================================== + +2015-06-03 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/tools/fnlo_int_hhc_nlojet.cc: + Some comment lines added where nan and inf from NLOjet++ passed + through. git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2123 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-06-01 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/dev/fnl5332f_v23_fix.str: + Devel scen git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2119 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-06-01 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/dev/fnl5332f_v23_fix.str: + Devel scenario git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2118 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-31 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/dev/fnl5662i_v23_fix.str, + v2.0/generators/nlojet++/interface/data/dev/fnl5672i_v23_fix.str: + devel scenario git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2117 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-31 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/dev/fnl2522adiff_v23_fix.st + r, v2.0/generators/nlojet++/interface/data/dev/fnl5622i_v23_fix.str: + devel scenario git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2116 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-31 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/dev/fnl3232e_v23_fix.str: + devel scenario git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2115 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-30 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/dev/fnl3732dena_v23_fix.str + , + v2.0/generators/nlojet++/interface/data/dev/fnl3732numa_v23_fix.str: + Devel scenarios git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2114 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-22 Georg Sieber <georg.sieber@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc: + additional observables for triple diff tables. git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2112 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-12 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2111 + ==================================================================================== + +2015-05-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/data/Makefile.am: Fix subdir + vars in Makefile.am git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2111 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc: + Work on info/debug output; fix bug with central jet pT3 cut + affecting new dijet angular git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2110 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJets.cc: Work + on info/debug output git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2109 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-12 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc: + Work on info/debug output git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2108 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc: + Add more observables & scales; add debug|info output git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2098 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/AzimuthalDecorrelation/Make + file.am, + v2.0/generators/nlojet++/interface/data/AzimuthalDecorrelation/fnl2 + 522diffb_I885663_v23_fix.str, + v2.0/generators/nlojet++/interface/data/AzimuthalDecorrelation/fnl2 + 522normb_I885663_v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetAngular/fnl2622f_I1090 + 423_v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetAngular/fnl2622f_I1090 + 423_v23_flex.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2412c_I895742_ + v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2412c_I895742_ + v23_flex.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2412e_I1208923 + _v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2412e_I1208923 + _v23_flex.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452_I1082936_ + v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452_I1082936_ + v23_fix_ptmax.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452_I1082936_ + v23_fix_ptmaxexpystar.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452_I1082936_ + v23_flex_ptmaxexpystar.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452b_I1268975 + _v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452b_I1268975 + _v23_fix_ptmax.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452b_I1268975 + _v23_fix_ptmaxexpystar.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2452b_I1268975 + _v23_flex_ptmaxexpystar.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2462_I1082936_ + v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2462_I1082936_ + v23_flex_ptmaxexpystar.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2462b_I1268975 + _v23_fix.str, + v2.0/generators/nlojet++/interface/data/DijetMass/fnl2462b_I1268975 + _v23_flex_ptmaxexpystar.str, + v2.0/generators/nlojet++/interface/data/Examples/DijetMass_Example_ + v23_fix.str, + v2.0/generators/nlojet++/interface/data/Examples/InclusiveJets_Exam + ple_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2332e_I129 + 8810_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2342b_I902 + 309_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2342b_I902 + 309_v23_flex.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2342e_I129 + 8810_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2352_I1082 + 936_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2352b_I132 + 5553_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2362_I1082 + 936_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl2362b_I132 + 5553_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl4352_I1228 + 693_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnl4362_I1228 + 693_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnr0001midpHT + _I723509_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnr0001midpMB + _I723509_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnt2004_I7433 + 42_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnt2007midp_I + 790693_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveJets/fnt2009midp_I + 779574_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveNJetEvents/fnl2732 + dena_I1230937_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveNJetEvents/fnl2732 + numa_I1230937_v23_fix.str, + v2.0/generators/nlojet++/interface/data/Makefile.am: Add option to + avoid warmup binning check; useful for bin borders in pi etc; add + test setups for azim.dec, dijet angular git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2097 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-06 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/configure.ac, + v2.0/generators/nlojet++/interface/data/Makefile.am: Add R3/2 + scenarios to distribution git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2093 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-06 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/dev/fnl5732dena_v23_fix.str + , + v2.0/generators/nlojet++/interface/data/dev/fnl5732numa_v23_fix.str: + Devel only git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2092 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-05-06 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/InclusiveNJetEvents/fnl2732 + dena_I1230937_v23_fix.str, + v2.0/generators/nlojet++/interface/data/InclusiveNJetEvents/fnl2732 + numa_I1230937_v23_fix.str: Update/finalize CMS R3/2 scenarios git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2091 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + 2015-04-23 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 2067 ==================================================================================== +2015-04-23 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/ChangeLog, + v2.0/generators/nlojet++/NEWS, + v2.0/generators/nlojet++/configure.ac, v2.0/toolkit/ChangeLog, + v2.0/toolkit/NEWS, v2.0/toolkit/{ToDo_Toolkit.txt => TODO}: Prepare + toolkit prerelease git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2067 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-04-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJets.cc: + Implement prapidity for incl. jets git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2057 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-04-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/Examples/DijetMass_Example_ + v23_fix.str: Finalize dijet mass example str git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2056 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-04-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJets.cc, + v2.0/generators/nlojet++/interface/hadron/InclusiveNJets_new.cc: + Adaptations to modified toolkit methods git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2055 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-04-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/Examples/{InclusiveDijetEve + nts_Example_v23_fix.str => DijetMass_Example_v23_fix.str}, + v2.0/generators/nlojet++/interface/data/Examples/InclusiveJets_Exam + ple_v23_fix.str, + v2.0/generators/nlojet++/interface/data/Makefile.am: Update example + steers; delimit tarball content git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2054 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + +2015-04-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2011_I89 + 5742.info, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2011_I89 + 5742.plot, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2013_I12 + 08923.info, + v2.0/generators/nlojet++/interface/data/RivetAdditions/CMS_2013_I12 + 08923.plot: Adaptations in my Rivet files git-svn-id: + https://ekptrac.physik.uni-karlsruhe.de/svn/fastNLO/trunk@2053 + aa5437bd-d6fa-0310-9a40-cbaab9bf9339 + 2015-04-21 rabbertz * InclusiveNJets.cc: Implement prapidity for incl. jets @@ -299,6 +1199,9 @@ * fj-jets.cc: fix memory leak in fastjet helper +2014-11-11 Prerelease of fastNLO interface to NLOJet++, package version 2.3.1pre, revision 1903 + ==================================================================================== + 2014-11-11 rabbertz * Makefile.am, configure.ac: Use new fnlo-tk-config in NLOJet++ interface @@ -393,6 +1296,9 @@ nlojet++, reader, toolkit, userkr, v2.0: Set selective svnignore patterns for autogenerated files; documented in .svnignore files +2014-05-28 Prerelease of the fastNLO interface to NLOJet++, package version 2.3.1pre, revision 1804 + ======================================================================================== + 2014-05-28 rabbertz * InclusiveJets.str, Makefile.am, fnl2342b_v22_fix.str, diff --git a/v2.5/generators/nlojet++/NEWS b/v2.5/generators/nlojet++/NEWS index 5874d2e1912dd2fee8f4ccd9b76f7ddf46a47248..9d3391e2a25ef83a5a14d36e1527950b66cb75e9 100644 --- a/v2.5/generators/nlojet++/NEWS +++ b/v2.5/generators/nlojet++/NEWS @@ -1,3 +1,21 @@ +Release Notes for fastnlo_interface_nlojet version 2.5.1 revision 2888 +======================================================================= +Major improvement (Johannes Gäßler): +- optional on-the-fly x-binning extension with given bin density +Other: +- LHAPDF5 support removed +- By default NO Doxygen documentation anymore; must be switched on explicitly + + +Release Notes for fastnlo_interface_nlojet version 2.5.0 revision 2858: +======================================================================= +- Implementation of HT_parton as scale +- autotools update + + +TODO: inbetween release notes + + Release Notes for fastnlo_interface_nlojet version 2.3.1pre revision 2067: ========================================================================== Updated to work with new toolkit prerelease. diff --git a/v2.5/generators/nlojet++/README b/v2.5/generators/nlojet++/README index bb80bec0876d6dfcfa41e8fe770c76ceeb9524d7..e67891fef9beef469d0c5e2e5f88c3dbcb29725f 100644 --- a/v2.5/generators/nlojet++/README +++ b/v2.5/generators/nlojet++/README @@ -16,7 +16,7 @@ # For installation of interface package: Patched version of NLOJet++-4.1.3: nlojet++-4.1.3-patched.tar.gz # FastJet-3.0.6 for the example scenario: fastjet-3.0.6.tar.gz # The fastNLO Toolkit 2.3.0pre: fastnlo_toolkit-2.3.1pre-1854.tar.gz -# The fastNLO toolkit requires: LHAPDF version 5 or 6, e.g.: lhapdf-5.9.1.tar.gz +# The fastNLO toolkit requires: LHAPDF version 6 # # All these packages are also downloadable from http://fastnlo.hepforge.org/code/v23/code-v23.html diff --git a/v2.5/generators/nlojet++/configure.ac b/v2.5/generators/nlojet++/configure.ac index 794b03077fc626833dcc6d96669890a71b6dd1b1..67582390207e375633bc3576eb1359695bb713f1 100644 --- a/v2.5/generators/nlojet++/configure.ac +++ b/v2.5/generators/nlojet++/configure.ac @@ -8,10 +8,10 @@ # # ----------------------------------------------------------------------------- # Process this file with autoconf to produce a configure script. -# Require minimal autoconf version, 2.69 is from 2012 -AC_PREREQ([2.69]) +# Require minimal autoconf version, 2.71 is from 2021 +AC_PREREQ([2.71]) # Define subproject fastNLO_interface_nlojet -AC_INIT([fastNLO_interface_nlojet],[2.5.0],[daniel.britzger@desy.de,klaus.rabbertz@cern.ch,g.sieber@cern.ch,stober@cern.ch,wobisch@fnal.gov]) +AC_INIT([fastNLO_interface_nlojet],[2.5.1],[Daniel.Britzger@desy.de, Klaus.Rabbertz@kit.edu, Georg Sieber, Fred Stober, wobisch@latech.edu]) #Suppress verbose output when compiling (use make V=99 for verbose output) m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) # Properly include subprojects @@ -20,6 +20,7 @@ AC_CONFIG_AUX_DIR([.]) AM_INIT_AUTOMAKE([1.13 tar-ustar -Wall -Wno-override]) # Require minimal libtool version, 2.4 is from 2011 LT_PREREQ([2.4]) +# Allow opening precompiled modules at runtime LT_INIT([dlopen]) # # ATTENTION: For conditional compilation etc ... @@ -39,32 +40,15 @@ AC_PROG_CC AC_PROG_CPP AC_PROG_F77([gfortran g77]) AC_PROG_FC([gfortran g77]) -AC_CONFIG_MACRO_DIR([m4]) -#case $FC in -# gfortran) AC_SUBST([HAVE_GFORTRAN], [yes]) -# g77) AC_SUBST([HAVE_G77], [yes]) -#esac AC_PROG_INSTALL -_LT_SET_OPTION([LT_INIT],[dlopen]) -AC_DIAGNOSE([obsolete],[AC_LIBTOOL_DLOPEN: Remove this warning and the call to _LT_SET_OPTION when you -put the `dlopen' option into LT_INIT's first parameter.]) - -AC_PROG_LIBTOOL AC_PROG_LN_S AC_PROG_MAKE_SET -# AC_PROG_RANLIB # Checks for sources. # Checks for libraries. AC_F77_LIBRARY_LDFLAGS AC_CHECK_LIB([g2c], [getenv_]) -#AC_CHECK_LIB([LHAPDF], [alphas]) -#AC_CHECK_LIB([fastnlotoolkit], [libfastnlotoolkit_la-FastNLOBlockB]) -#AC_CHECK_LIB([gfortranbegin], [fmain]) -#AC_CHECK_LIB([lhpdf_cteq6], [cteq6]) -# Check twice, first to define ZLIBTEST, and second to perform default action and AC_DEFINE HAVE_LIBZ -#AX_CHECK_ZLIB([ZLIBTEST=true], ZLIBTEST="") AX_CHECK_ZLIB AM_CONDITIONAL([HAVE_LIBZ],[test "x$HAVE_LIBZ" == "xtrue"]) @@ -186,16 +170,16 @@ if test "x$with_fnlotoolkit" != "xno"; then AC_MSG_NOTICE([******************************************]) if test "x$FNLOTOOLKITBIN" != "x"; then AC_MSG_NOTICE([$TMPNAM settings:]) -# AC_SUBST([FNLOTOOLKIT], [`dirname $FNLOTOOLKITBIN`]) -# AC_SUBST([FNLOTOOLKITPREFIX], [`dirname $FNLOTOOLKIT`]) AC_SUBST([FNLOTOOLKITPREFIX], [`$FNLOTOOLKITBIN --prefix`]) AC_SUBST([FNLOTOOLKITBINPATH], ["$FNLOTOOLKITPREFIX/bin"]) AC_SUBST([FNLOTOOLKITLIBPATH], [`$FNLOTOOLKITBIN --libdir`]) AC_SUBST([FNLOTOOLKITINCLUDEPATH],[`$FNLOTOOLKITBIN --incdir`]) + AC_SUBST([FNLOTOOLKITPYTHONPATH],[`$FNLOTOOLKITBIN --pythondir`]) AC_MSG_RESULT([Using $FNLOTOOLKITPREFIX for the $TMPNAM installation path]) AC_MSG_RESULT([Using $FNLOTOOLKITBINPATH for the binaries]) AC_MSG_RESULT([Using $FNLOTOOLKITLIBPATH for the library]) AC_MSG_RESULT([Using $FNLOTOOLKITINCLUDEPATH for the includes]) + AC_MSG_RESULT([Using $FNLOTOOLKITPYTHONPATH for python extentions]) else AC_MSG_ERROR([No $TMPNAM library found. Configuration aborted!]) fi diff --git a/v2.5/generators/nlojet++/interface/check/.gitignore b/v2.5/generators/nlojet++/interface/check/.gitignore index 43baae7b81e9e4865539e02eda087f135f5fb0a6..e10473f033b235a317855e09550eb01b2777b655 100644 --- a/v2.5/generators/nlojet++/interface/check/.gitignore +++ b/v2.5/generators/nlojet++/interface/check/.gitignore @@ -3,3 +3,5 @@ fnlo-nj-*.pl fnlo-nj-*.trs *.tab *.tab.gz +output +InclusiveNJets.str diff --git a/v2.5/generators/nlojet++/interface/check/Makefile.am b/v2.5/generators/nlojet++/interface/check/Makefile.am index 2efe548b0ab672fb9d6c0d0bb55418d113eb8dd6..ade0ce8c6352c05eaf671449eff2ae105988b7b9 100644 --- a/v2.5/generators/nlojet++/interface/check/Makefile.am +++ b/v2.5/generators/nlojet++/interface/check/Makefile.am @@ -14,7 +14,8 @@ AUTOMAKE_OPTIONS = gnu # # perl script targets to check the package (distributed, but not installed) # -dist_check_SCRIPTS = fnlo-nj-wrmtest.pl fnlo-nj-lotest.pl fnlo-nj-nlotest.pl +dist_check_SCRIPTS = fnlo-nj-wrmtest.pl fnlo-nj-lotest.pl fnlo-nj-nlotest.pl fnlo-compare-tables.py +TESTS_ENVIRONMENT = LIBDIR=${FNLOTOOLKITLIBPATH} PYTHONPATH=${FNLOTOOLKITPYTHONPATH}:${PYTHONPATH} TESTS = $(dist_check_SCRIPTS) # Additional clean up for check targets diff --git a/v2.5/generators/nlojet++/interface/check/fnlo-compare-tables.py b/v2.5/generators/nlojet++/interface/check/fnlo-compare-tables.py new file mode 100755 index 0000000000000000000000000000000000000000..f00bbcce311eacc3896cb96c5bc29274fc0b88aa --- /dev/null +++ b/v2.5/generators/nlojet++/interface/check/fnlo-compare-tables.py @@ -0,0 +1,66 @@ +#!/usr/bin/env python3 + +import sys +import os + +try: + import fastnlo as fnlo +except ModuleNotFoundError: + print("fastNLO Python extension not found") + sys.exit(77) + +LIBDIR = os.environ["LIBDIR"] +DATADIR = f"{os.path.dirname(os.path.abspath(__file__))}/../data/check/" + +TYPES = ["fix", "flex"] +NAMES = ["NodesPerBin", "NodeDensity"] +SEEDS = [1000, 2000] + +# fnlo.SetGlobalVerbosity(fnlo.DEBUG) + +os.system("rm -rf output") +os.system(f"ln -sf {DATADIR}InclusiveNJets_InclusiveJets_fix.wrm") +os.system(f"ln -sf {DATADIR}InclusiveNJets_InclusiveJets_flex.wrm") + + +def generate_table(vartype: str, name: str, seed: int): + os.system(f"ln -sf {DATADIR}{vartype}_{name}.str InclusiveNJets.str") + print("Asserting that steering file InclusiveNJets.str exists") + assert os.path.exists("InclusiveNJets.str") + os.system( + "nlojet++ " + "--calculate " + "-c born " + f"-s {seed} " + f"--name {vartype}_{name}_{seed:06d} " + f" -u {LIBDIR}/fastnlo_interface_nlojet/libInclusiveNJets.la " + "--max-event 10000 " + "--save-after 10000 " + ) + expected_outfile = "output/run-hhc-born-2jet.tab.gz" + print(f"Asserting that there is a table under {expected_outfile}") + assert os.path.exists(expected_outfile) + os.system(f"mv {expected_outfile} output/{vartype}_{name}_{seed:06d}.tab.gz") + + +for vartype in TYPES: + for steering_file in NAMES: + for seed in SEEDS: + generate_table(vartype, steering_file, seed) + os.system(f"fnlo-tk-merge2 output/{vartype}_{steering_file}_??????.tab.gz " + f"output/{vartype}_{steering_file}_merged.tab.gz") + + for seed in SEEDS: + filename_0 = f"output/{vartype}_{NAMES[0]}_{seed:06d}.tab.gz" + filename_1 = f"output/{vartype}_{NAMES[1]}_{seed:06d}.tab.gz" + table_0 = fnlo.fastNLOTable(filename_0) + table_1 = fnlo.fastNLOTable(filename_1) + print(f"Asserting equal: {filename_0} <-> {filename_1}") + assert table_0.IsEquivalent(table_1, 1e-8) + + filename_0 = f"output/{vartype}_{NAMES[0]}_merged.tab.gz" + filename_1 = f"output/{vartype}_{NAMES[1]}_merged.tab.gz" + table_0_merged = fnlo.fastNLOTable(filename_0) + table_1_merged = fnlo.fastNLOTable(filename_1) + print(f"Asserting equal: {filename_0} <-> {filename_1}") + assert table_0_merged.IsEquivalent(table_1_merged, 1e-8) diff --git a/v2.5/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in b/v2.5/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in index c7a382536355f2b548b5c1ef3503bce1c048597e..96b1ea9387337cf2ce73a039a7f8d56db96e48d1 100755 --- a/v2.5/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in +++ b/v2.5/generators/nlojet++/interface/check/fnlo-nj-lotest.pl.in @@ -69,19 +69,14 @@ $ret = system("$cmd"); if ( $ret ) {die "fnlo-tk-nlotest: Ungzipping test table ${tabgz} failed: $ret, aborted!\n";} # Determine difference to default LO table -$cmd = "diff ./${tabl} output/${tabl} > lodiff.log"; +$cmd = "${src}/../data/check/compare-table-helper.py ./${tabl} output/${tabl} > lodiff.log"; print "Executing command: $cmd\n"; $ret = system("$cmd"); -if ( $ret ) {die "fnlo-nj-lotest: Result comparison with 'diff' failed: $ret, aborted!\n";} - -# The diff.log must be empty -if ( ! -z "lodiff.log" ) { - print "fnlo-nj-lotest: LO test table differs from default:\n"; - $cmd = "cat lodiff.log"; - print "Executing command: $cmd\n"; - $ret = system("$cmd"); - die "fnlo-nj-lotest: LO table production unit test failed, please fix!\n"; +if ( $ret == 77 ) { + print "fnlo-nj-lotest: Skipping LO production unit test."; + exit 77; } +if ( $ret ) {die "fnlo-nj-lotest: LO table production unit test failed, results are different!\n";} print "fnlo-nj-lotest: LO table production unit test passed.\n"; diff --git a/v2.5/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in b/v2.5/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in index 4960ed932c4b0b6032abe3182982746a858e0ce6..3ea7072a76301f117fd5464eafb60a459b45d59e 100755 --- a/v2.5/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in +++ b/v2.5/generators/nlojet++/interface/check/fnlo-nj-nlotest.pl.in @@ -69,19 +69,14 @@ $ret = system("$cmd"); if ( $ret ) {die "fnlo-tk-nlotest: Ungzipping test table ${tabgz} failed: $ret, aborted!\n";} # Determine difference to default NLO table -$cmd = "diff ./${tabn} output/${tabn} > nlodiff.log"; +$cmd = "${src}/../data/check/compare-table-helper.py ./${tabn} output/${tabn} > lodiff.log"; print "Executing command: $cmd\n"; $ret = system("$cmd"); -if ( $ret ) {die "fnlo-nj-nlotest: Result comparison with 'diff' failed: $ret, aborted!\n";} - -# The diff.log must be empty -if ( ! -z "nlodiff.log" ) { - print "fnlo-nj-nlotest: NLO test table differs from default:\n"; - $cmd = "cat nlodiff.log"; - print "Executing command: $cmd\n"; - $ret = system("$cmd"); - die "fnlo-nj-nlotest: NLO table production unit test failed, please fix!\n"; +if ( $ret == 77 ) { + print "fnlo-nj-lotest: Skipping LO production unit test."; + exit 77; } +if ( $ret ) {die "fnlo-nj-lotest: NLO table production unit test failed, results are different!\n";} print "fnlo-nj-nlotest: NLO table production unit test passed.\n"; diff --git a/v2.5/generators/nlojet++/interface/data/check/InclusiveNJets_InclusiveJets_fix.wrm b/v2.5/generators/nlojet++/interface/data/check/InclusiveNJets_InclusiveJets_fix.wrm new file mode 100644 index 0000000000000000000000000000000000000000..5d3bc43e838a590b6ef2c2e0383ad6c85ecc4b58 --- /dev/null +++ b/v2.5/generators/nlojet++/interface/data/check/InclusiveNJets_InclusiveJets_fix.wrm @@ -0,0 +1,386 @@ +# --- Use emacs in sh mode -*-sh-*- # +# This is a automatically generated file by fastNLO and holds the values of the warmup run. +# The values are valid for the scenario InclusiveJets_Example_v23_fix_ref +# and if calculated with the steerfile: InclusiveNJets +# but only if no serious changes have been performed since its creation. +# +# Delete this file, if you want fastNLO to calculate a new one. +# +# This file has been calculated using: +# 1e+09 contributions. +# 12962320896 entries. +# ( Mind: contributions != events. And contributions are not necessarily in phase space region. +# Please check by eye for reasonability of the values. +# Number of events per bin are listed below. + +Warmup.OrderInAlphasOfWarmupRunWas 2 +Warmup.CheckScaleLimitsAgainstBins true +Warmup.ScaleDescriptionScale1 "pT_jet_[GeV]" +Warmup.DifferentialDimension 2 +Warmup.DimensionLabels { + "|y|" "pT_[GeV]" +} +Warmup.DimensionIsDifferential { + "2" "2" +} + +Warmup.Values {{ + ObsBin x_min x_max pT_jet_[GeV]_min pT_jet_[GeV]_max + 0 1.0e-09 1.00e+00 18.000000 21.000000 + 1 1.0e-09 1.00e+00 21.000000 24.000000 + 2 1.0e-09 1.00e+00 24.000000 28.000000 + 3 1.0e-09 1.00e+00 28.000000 32.000000 + 4 1.0e-09 1.00e+00 32.000000 37.000000 + 5 1.0e-09 1.00e+00 37.000000 43.000000 + 6 1.0e-09 1.00e+00 43.000000 49.000000 + 7 1.0e-09 1.00e+00 49.000000 56.000000 + 8 1.0e-09 1.00e+00 56.000000 64.000000 + 9 1.0e-09 1.00e+00 64.000000 74.000000 + 10 1.0e-09 1.00e+00 74.000000 84.000000 + 11 1.0e-09 1.00e+00 84.000000 97.000000 + 12 1.0e-09 1.00e+00 97.000000 114.000000 + 13 1.0e-09 1.00e+00 114.000000 133.000000 + 14 1.0e-09 1.00e+00 133.000000 153.000000 + 15 1.0e-09 1.00e+00 153.000000 174.000000 + 16 1.0e-09 1.00e+00 174.000000 196.000000 + 17 1.0e-09 1.00e+00 196.000000 220.000000 + 18 1.0e-09 1.00e+00 220.000000 245.000000 + 19 1.0e-09 1.00e+00 245.000000 272.000000 + 20 1.0e-09 1.00e+00 272.000000 300.000000 + 21 1.0e-09 1.00e+00 300.000000 330.000000 + 22 1.0e-09 1.00e+00 330.000000 362.000000 + 23 1.0e-09 1.00e+00 362.000000 395.000000 + 24 1.0e-09 1.00e+00 395.000000 430.000000 + 25 1.0e-09 1.00e+00 430.000000 468.000000 + 26 1.0e-09 1.00e+00 468.000000 507.000000 + 27 1.0e-09 1.00e+00 507.000000 548.000000 + 28 1.0e-09 1.00e+00 548.000000 592.000000 + 29 1.0e-09 1.00e+00 592.000000 638.000000 + 30 1.0e-09 1.00e+00 638.000000 686.000000 + 31 1.0e-09 1.00e+00 686.000000 737.000000 + 32 1.0e-09 1.00e+00 737.000000 846.000000 + 33 1.0e-09 1.00e+00 846.000000 1684.000000 + 34 1.0e-09 1.00e+00 18.000000 21.000000 + 35 1.0e-09 1.00e+00 21.000000 24.000000 + 36 1.0e-09 1.00e+00 24.000000 28.000000 + 37 1.0e-09 1.00e+00 28.000000 32.000000 + 38 1.0e-09 1.00e+00 32.000000 37.000000 + 39 1.0e-09 1.00e+00 37.000000 43.000000 + 40 1.0e-09 1.00e+00 43.000000 49.000000 + 41 1.0e-09 1.00e+00 49.000000 56.000000 + 42 1.0e-09 1.00e+00 56.000000 64.000000 + 43 1.0e-09 1.00e+00 64.000000 74.000000 + 44 1.0e-09 1.00e+00 74.000000 84.000000 + 45 1.0e-09 1.00e+00 84.000000 97.000000 + 46 1.0e-09 1.00e+00 97.000000 114.000000 + 47 1.0e-09 1.00e+00 114.000000 133.000000 + 48 1.0e-09 1.00e+00 133.000000 153.000000 + 49 1.0e-09 1.00e+00 153.000000 174.000000 + 50 1.0e-09 1.00e+00 174.000000 196.000000 + 51 1.0e-09 1.00e+00 196.000000 220.000000 + 52 1.0e-09 1.00e+00 220.000000 245.000000 + 53 1.0e-09 1.00e+00 245.000000 272.000000 + 54 1.0e-09 1.00e+00 272.000000 300.000000 + 55 1.0e-09 1.00e+00 300.000000 330.000000 + 56 1.0e-09 1.00e+00 330.000000 362.000000 + 57 1.0e-09 1.00e+00 362.000000 395.000000 + 58 1.0e-09 1.00e+00 395.000000 430.000000 + 59 1.0e-09 1.00e+00 430.000000 468.000000 + 60 1.0e-09 1.00e+00 468.000000 507.000000 + 61 1.0e-09 1.00e+00 507.000000 548.000000 + 62 1.0e-09 1.00e+00 548.000000 592.000000 + 63 1.0e-09 1.00e+00 592.000000 638.000000 + 64 1.0e-09 1.00e+00 638.000000 686.000000 + 65 1.0e-09 1.00e+00 686.000000 790.000000 + 66 1.0e-09 1.00e+00 790.000000 1684.000000 + 67 1.0e-09 1.00e+00 18.000000 21.000000 + 68 1.0e-09 1.00e+00 21.000000 24.000000 + 69 1.0e-09 1.00e+00 24.000000 28.000000 + 70 1.0e-09 1.00e+00 28.000000 32.000000 + 71 1.0e-09 1.00e+00 32.000000 37.000000 + 72 1.0e-09 1.00e+00 37.000000 43.000000 + 73 1.0e-09 1.00e+00 43.000000 49.000000 + 74 1.0e-09 1.00e+00 49.000000 56.000000 + 75 1.0e-09 1.00e+00 56.000000 64.000000 + 76 1.0e-09 1.00e+00 64.000000 74.000000 + 77 1.0e-09 1.00e+00 74.000000 84.000000 + 78 1.0e-09 1.00e+00 84.000000 97.000000 + 79 1.0e-09 1.00e+00 97.000000 114.000000 + 80 1.0e-09 1.00e+00 114.000000 133.000000 + 81 1.0e-09 1.00e+00 133.000000 153.000000 + 82 1.0e-09 1.00e+00 153.000000 174.000000 + 83 1.0e-09 1.00e+00 174.000000 196.000000 + 84 1.0e-09 1.00e+00 196.000000 220.000000 + 85 1.0e-09 1.00e+00 220.000000 245.000000 + 86 1.0e-09 1.00e+00 245.000000 272.000000 + 87 1.0e-09 1.00e+00 272.000000 300.000000 + 88 1.0e-09 1.00e+00 300.000000 330.000000 + 89 1.0e-09 1.00e+00 330.000000 362.000000 + 90 1.0e-09 1.00e+00 362.000000 395.000000 + 91 1.0e-09 1.00e+00 395.000000 430.000000 + 92 1.0e-09 1.00e+00 430.000000 468.000000 + 93 1.0e-09 1.00e+00 468.000000 507.000000 + 94 1.0e-09 1.00e+00 507.000000 548.000000 + 95 1.0e-09 1.00e+00 548.000000 592.000000 + 96 1.0e-09 1.00e+00 592.000000 638.000000 + 97 1.0e-09 1.00e+00 638.000000 686.000000 + 98 1.0e-09 1.00e+00 686.000000 1410.000000 + 99 1.0e-09 1.00e+00 18.000000 21.000000 + 100 1.0e-09 1.00e+00 21.000000 24.000000 + 101 1.0e-09 1.00e+00 24.000000 28.000000 + 102 1.0e-09 1.00e+00 28.000000 32.000000 + 103 1.0e-09 1.00e+00 32.000000 37.000000 + 104 1.0e-09 1.00e+00 37.000000 43.000000 + 105 1.0e-09 1.00e+00 43.000000 49.000000 + 106 1.0e-09 1.00e+00 49.000000 56.000000 + 107 1.0e-09 1.00e+00 56.000000 64.000000 + 108 1.0e-09 1.00e+00 64.000000 74.000000 + 109 1.0e-09 1.00e+00 74.000000 84.000000 + 110 1.0e-09 1.00e+00 84.000000 97.000000 + 111 1.0e-09 1.00e+00 97.000000 114.000000 + 112 1.0e-09 1.00e+00 114.000000 133.000000 + 113 1.0e-09 1.00e+00 133.000000 153.000000 + 114 1.0e-09 1.00e+00 153.000000 174.000000 + 115 1.0e-09 1.00e+00 174.000000 196.000000 + 116 1.0e-09 1.00e+00 196.000000 220.000000 + 117 1.0e-09 1.00e+00 220.000000 245.000000 + 118 1.0e-09 1.00e+00 245.000000 272.000000 + 119 1.0e-09 1.00e+00 272.000000 300.000000 + 120 1.0e-09 1.00e+00 300.000000 330.000000 + 121 1.0e-09 1.00e+00 330.000000 362.000000 + 122 1.0e-09 1.00e+00 362.000000 395.000000 + 123 1.0e-09 1.00e+00 395.000000 430.000000 + 124 1.0e-09 1.00e+00 430.000000 468.000000 + 125 1.0e-09 1.00e+00 468.000000 507.000000 + 126 1.0e-09 1.00e+00 507.000000 548.000000 + 127 1.0e-09 1.00e+00 548.000000 1032.000000 + 128 1.0e-09 1.00e+00 18.000000 21.000000 + 129 1.0e-09 1.00e+00 21.000000 24.000000 + 130 1.0e-09 1.00e+00 24.000000 28.000000 + 131 1.0e-09 1.00e+00 28.000000 32.000000 + 132 1.0e-09 1.00e+00 32.000000 37.000000 + 133 1.0e-09 1.00e+00 37.000000 43.000000 + 134 1.0e-09 1.00e+00 43.000000 49.000000 + 135 1.0e-09 1.00e+00 49.000000 56.000000 + 136 1.0e-09 1.00e+00 56.000000 64.000000 + 137 1.0e-09 1.00e+00 64.000000 74.000000 + 138 1.0e-09 1.00e+00 74.000000 84.000000 + 139 1.0e-09 1.00e+00 84.000000 97.000000 + 140 1.0e-09 1.00e+00 97.000000 114.000000 + 141 1.0e-09 1.00e+00 114.000000 133.000000 + 142 1.0e-09 1.00e+00 133.000000 153.000000 + 143 1.0e-09 1.00e+00 153.000000 174.000000 + 144 1.0e-09 1.00e+00 174.000000 196.000000 + 145 1.0e-09 1.00e+00 196.000000 220.000000 + 146 1.0e-09 1.00e+00 220.000000 245.000000 + 147 1.0e-09 1.00e+00 245.000000 272.000000 + 148 1.0e-09 1.00e+00 272.000000 300.000000 + 149 1.0e-09 1.00e+00 300.000000 330.000000 + 150 1.0e-09 1.00e+00 330.000000 362.000000 + 151 1.0e-09 1.00e+00 362.000000 395.000000 + 152 1.0e-09 1.00e+00 395.000000 430.000000 + 153 1.0e-09 1.00e+00 430.000000 737.000000 + 154 1.0e-09 1.00e+00 18.000000 21.000000 + 155 1.0e-09 1.00e+00 21.000000 24.000000 + 156 1.0e-09 1.00e+00 24.000000 28.000000 + 157 1.0e-09 1.00e+00 28.000000 32.000000 + 158 1.0e-09 1.00e+00 32.000000 37.000000 + 159 1.0e-09 1.00e+00 37.000000 43.000000 + 160 1.0e-09 1.00e+00 43.000000 49.000000 + 161 1.0e-09 1.00e+00 49.000000 56.000000 + 162 1.0e-09 1.00e+00 56.000000 64.000000 + 163 1.0e-09 1.00e+00 64.000000 74.000000 + 164 1.0e-09 1.00e+00 74.000000 84.000000 + 165 1.0e-09 1.00e+00 84.000000 97.000000 + 166 1.0e-09 1.00e+00 97.000000 114.000000 + 167 1.0e-09 1.00e+00 114.000000 133.000000 + 168 1.0e-09 1.00e+00 133.000000 153.000000 + 169 1.0e-09 1.00e+00 153.000000 174.000000 + 170 1.0e-09 1.00e+00 174.000000 196.000000 + 171 1.0e-09 1.00e+00 196.000000 220.000000 + 172 1.0e-09 1.00e+00 220.000000 245.000000 + 173 1.0e-09 1.00e+00 245.000000 272.000000 + 174 1.0e-09 1.00e+00 272.000000 300.000000 + 175 1.0e-09 1.00e+00 300.000000 468.000000 +}} + + +Warmup.Binning {{ + ObsBin |y|_Lo |y|_Up pT_[GeV]_Lo pT_[GeV]_Up BinSize EventCount + 0 0.00000 0.500000 18.0000 21.0000 3.00000 3244885 + 1 0.00000 0.500000 21.0000 24.0000 3.00000 3509086 + 2 0.00000 0.500000 24.0000 28.0000 4.00000 5089791 + 3 0.00000 0.500000 28.0000 32.0000 4.00000 5578139 + 4 0.00000 0.500000 32.0000 37.0000 5.00000 13849486 + 5 0.00000 0.500000 37.0000 43.0000 6.00000 42220087 + 6 0.00000 0.500000 43.0000 49.0000 6.00000 63797111 + 7 0.00000 0.500000 49.0000 56.0000 7.00000 89607455 + 8 0.00000 0.500000 56.0000 64.0000 8.00000 111378666 + 9 0.00000 0.500000 64.0000 74.0000 10.0000 142213393 + 10 0.00000 0.500000 74.0000 84.0000 10.0000 138600203 + 11 0.00000 0.500000 84.0000 97.0000 13.0000 168761621 + 12 0.00000 0.500000 97.0000 114.000 17.0000 196475552 + 13 0.00000 0.500000 114.000 133.000 19.0000 187801775 + 14 0.00000 0.500000 133.000 153.000 20.0000 169574713 + 15 0.00000 0.500000 153.000 174.000 21.0000 154746214 + 16 0.00000 0.500000 174.000 196.000 22.0000 142317245 + 17 0.00000 0.500000 196.000 220.000 24.0000 137085599 + 18 0.00000 0.500000 220.000 245.000 25.0000 126718578 + 19 0.00000 0.500000 245.000 272.000 27.0000 122031084 + 20 0.00000 0.500000 272.000 300.000 28.0000 113359687 + 21 0.00000 0.500000 300.000 330.000 30.0000 109234608 + 22 0.00000 0.500000 330.000 362.000 32.0000 104985678 + 23 0.00000 0.500000 362.000 395.000 33.0000 97925128 + 24 0.00000 0.500000 395.000 430.000 35.0000 94194296 + 25 0.00000 0.500000 430.000 468.000 38.0000 92800792 + 26 0.00000 0.500000 468.000 507.000 39.0000 86523591 + 27 0.00000 0.500000 507.000 548.000 41.0000 82887126 + 28 0.00000 0.500000 548.000 592.000 44.0000 81112535 + 29 0.00000 0.500000 592.000 638.000 46.0000 77302834 + 30 0.00000 0.500000 638.000 686.000 48.0000 73685892 + 31 0.00000 0.500000 686.000 737.000 51.0000 71466808 + 32 0.00000 0.500000 737.000 846.000 109.000 133404502 + 33 0.00000 0.500000 846.000 1684.00 838.000 555151128 + 34 0.500000 1.00000 18.0000 21.0000 3.00000 3652418 + 35 0.500000 1.00000 21.0000 24.0000 3.00000 4121614 + 36 0.500000 1.00000 24.0000 28.0000 4.00000 10869243 + 37 0.500000 1.00000 28.0000 32.0000 4.00000 21632310 + 38 0.500000 1.00000 32.0000 37.0000 5.00000 39926467 + 39 0.500000 1.00000 37.0000 43.0000 6.00000 54958708 + 40 0.500000 1.00000 43.0000 49.0000 6.00000 55178704 + 41 0.500000 1.00000 49.0000 56.0000 7.00000 63711732 + 42 0.500000 1.00000 56.0000 64.0000 8.00000 72031890 + 43 0.500000 1.00000 64.0000 74.0000 10.0000 89189226 + 44 0.500000 1.00000 74.0000 84.0000 10.0000 88320155 + 45 0.500000 1.00000 84.0000 97.0000 13.0000 113800743 + 46 0.500000 1.00000 97.0000 114.000 17.0000 147458304 + 47 0.500000 1.00000 114.000 133.000 19.0000 161287756 + 48 0.500000 1.00000 133.000 153.000 20.0000 159145063 + 49 0.500000 1.00000 153.000 174.000 21.0000 151362484 + 50 0.500000 1.00000 174.000 196.000 22.0000 140190638 + 51 0.500000 1.00000 196.000 220.000 24.0000 134795983 + 52 0.500000 1.00000 220.000 245.000 25.0000 124324263 + 53 0.500000 1.00000 245.000 272.000 27.0000 119533099 + 54 0.500000 1.00000 272.000 300.000 28.0000 110665919 + 55 0.500000 1.00000 300.000 330.000 30.0000 106354192 + 56 0.500000 1.00000 330.000 362.000 32.0000 101883684 + 57 0.500000 1.00000 362.000 395.000 33.0000 94775793 + 58 0.500000 1.00000 395.000 430.000 35.0000 90787466 + 59 0.500000 1.00000 430.000 468.000 38.0000 89137881 + 60 0.500000 1.00000 468.000 507.000 39.0000 82816426 + 61 0.500000 1.00000 507.000 548.000 41.0000 78978655 + 62 0.500000 1.00000 548.000 592.000 44.0000 76859111 + 63 0.500000 1.00000 592.000 638.000 46.0000 72925993 + 64 0.500000 1.00000 638.000 686.000 48.0000 69029065 + 65 0.500000 1.00000 686.000 790.000 104.000 129318756 + 66 0.500000 1.00000 790.000 1684.00 894.000 534602418 + 67 1.00000 1.50000 18.0000 21.0000 3.00000 11359250 + 68 1.00000 1.50000 21.0000 24.0000 3.00000 16241652 + 69 1.00000 1.50000 24.0000 28.0000 4.00000 24808483 + 70 1.00000 1.50000 28.0000 32.0000 4.00000 24478552 + 71 1.00000 1.50000 32.0000 37.0000 5.00000 30146578 + 72 1.00000 1.50000 37.0000 43.0000 6.00000 35559468 + 73 1.00000 1.50000 43.0000 49.0000 6.00000 35040411 + 74 1.00000 1.50000 49.0000 56.0000 7.00000 40339229 + 75 1.00000 1.50000 56.0000 64.0000 8.00000 45514427 + 76 1.00000 1.50000 64.0000 74.0000 10.0000 56121821 + 77 1.00000 1.50000 74.0000 84.0000 10.0000 55474552 + 78 1.00000 1.50000 84.0000 97.0000 13.0000 71379882 + 79 1.00000 1.50000 97.0000 114.000 17.0000 92203391 + 80 1.00000 1.50000 114.000 133.000 19.0000 101887345 + 81 1.00000 1.50000 133.000 153.000 20.0000 106140790 + 82 1.00000 1.50000 153.000 174.000 21.0000 110465635 + 83 1.00000 1.50000 174.000 196.000 22.0000 114440872 + 84 1.00000 1.50000 196.000 220.000 24.0000 120024289 + 85 1.00000 1.50000 220.000 245.000 25.0000 116193861 + 86 1.00000 1.50000 245.000 272.000 27.0000 113484315 + 87 1.00000 1.50000 272.000 300.000 28.0000 104595897 + 88 1.00000 1.50000 300.000 330.000 30.0000 99818012 + 89 1.00000 1.50000 330.000 362.000 32.0000 94984358 + 90 1.00000 1.50000 362.000 395.000 33.0000 87580339 + 91 1.00000 1.50000 395.000 430.000 35.0000 83217708 + 92 1.00000 1.50000 430.000 468.000 38.0000 80954958 + 93 1.00000 1.50000 468.000 507.000 39.0000 74328961 + 94 1.00000 1.50000 507.000 548.000 41.0000 70068754 + 95 1.00000 1.50000 548.000 592.000 44.0000 67359915 + 96 1.00000 1.50000 592.000 638.000 46.0000 62922713 + 97 1.00000 1.50000 638.000 686.000 48.0000 58677829 + 98 1.00000 1.50000 686.000 1410.00 724.000 412025222 + 99 1.50000 2.00000 18.0000 21.0000 3.00000 12728744 + 100 1.50000 2.00000 21.0000 24.0000 3.00000 12423418 + 101 1.50000 2.00000 24.0000 28.0000 4.00000 16214380 + 102 1.50000 2.00000 28.0000 32.0000 4.00000 15861020 + 103 1.50000 2.00000 32.0000 37.0000 5.00000 19408144 + 104 1.50000 2.00000 37.0000 43.0000 6.00000 22853397 + 105 1.50000 2.00000 43.0000 49.0000 6.00000 22425802 + 106 1.50000 2.00000 49.0000 56.0000 7.00000 25707941 + 107 1.50000 2.00000 56.0000 64.0000 8.00000 28978887 + 108 1.50000 2.00000 64.0000 74.0000 10.0000 35647619 + 109 1.50000 2.00000 74.0000 84.0000 10.0000 35133084 + 110 1.50000 2.00000 84.0000 97.0000 13.0000 45000130 + 111 1.50000 2.00000 97.0000 114.000 17.0000 57979131 + 112 1.50000 2.00000 114.000 133.000 19.0000 63884730 + 113 1.50000 2.00000 133.000 153.000 20.0000 66388812 + 114 1.50000 2.00000 153.000 174.000 21.0000 68976530 + 115 1.50000 2.00000 174.000 196.000 22.0000 71512518 + 116 1.50000 2.00000 196.000 220.000 24.0000 77389235 + 117 1.50000 2.00000 220.000 245.000 25.0000 79905868 + 118 1.50000 2.00000 245.000 272.000 27.0000 85600669 + 119 1.50000 2.00000 272.000 300.000 28.0000 86526419 + 120 1.50000 2.00000 300.000 330.000 30.0000 86624748 + 121 1.50000 2.00000 330.000 362.000 32.0000 82373851 + 122 1.50000 2.00000 362.000 395.000 33.0000 74632103 + 123 1.50000 2.00000 395.000 430.000 35.0000 69485661 + 124 1.50000 2.00000 430.000 468.000 38.0000 66043047 + 125 1.50000 2.00000 468.000 507.000 39.0000 59062346 + 126 1.50000 2.00000 507.000 548.000 41.0000 53929043 + 127 1.50000 2.00000 548.000 1032.00 484.000 277256812 + 128 2.00000 2.50000 18.0000 21.0000 3.00000 8446858 + 129 2.00000 2.50000 21.0000 24.0000 3.00000 8203545 + 130 2.00000 2.50000 24.0000 28.0000 4.00000 10645292 + 131 2.00000 2.50000 28.0000 32.0000 4.00000 10380489 + 132 2.00000 2.50000 32.0000 37.0000 5.00000 12652584 + 133 2.00000 2.50000 37.0000 43.0000 6.00000 14817859 + 134 2.00000 2.50000 43.0000 49.0000 6.00000 14486416 + 135 2.00000 2.50000 49.0000 56.0000 7.00000 16570393 + 136 2.00000 2.50000 56.0000 64.0000 8.00000 18575046 + 137 2.00000 2.50000 64.0000 74.0000 10.0000 22788563 + 138 2.00000 2.50000 74.0000 84.0000 10.0000 22357286 + 139 2.00000 2.50000 84.0000 97.0000 13.0000 28559405 + 140 2.00000 2.50000 97.0000 114.000 17.0000 36634892 + 141 2.00000 2.50000 114.000 133.000 19.0000 40209204 + 142 2.00000 2.50000 133.000 153.000 20.0000 41636119 + 143 2.00000 2.50000 153.000 174.000 21.0000 43092427 + 144 2.00000 2.50000 174.000 196.000 22.0000 44605666 + 145 2.00000 2.50000 196.000 220.000 24.0000 48055329 + 146 2.00000 2.50000 220.000 245.000 25.0000 49464863 + 147 2.00000 2.50000 245.000 272.000 27.0000 52872778 + 148 2.00000 2.50000 272.000 300.000 28.0000 54323871 + 149 2.00000 2.50000 300.000 330.000 30.0000 57670655 + 150 2.00000 2.50000 330.000 362.000 32.0000 59613575 + 151 2.00000 2.50000 362.000 395.000 33.0000 52548181 + 152 2.00000 2.50000 395.000 430.000 35.0000 46075141 + 153 2.00000 2.50000 430.000 737.000 307.000 151430405 + 154 2.50000 3.00000 18.0000 21.0000 3.00000 5656238 + 155 2.50000 3.00000 21.0000 24.0000 3.00000 5485445 + 156 2.50000 3.00000 24.0000 28.0000 4.00000 7081781 + 157 2.50000 3.00000 28.0000 32.0000 4.00000 6863745 + 158 2.50000 3.00000 32.0000 37.0000 5.00000 8337637 + 159 2.50000 3.00000 37.0000 43.0000 6.00000 9712710 + 160 2.50000 3.00000 43.0000 49.0000 6.00000 9449307 + 161 2.50000 3.00000 49.0000 56.0000 7.00000 10749788 + 162 2.50000 3.00000 56.0000 64.0000 8.00000 11987227 + 163 2.50000 3.00000 64.0000 74.0000 10.0000 14638834 + 164 2.50000 3.00000 74.0000 84.0000 10.0000 14286650 + 165 2.50000 3.00000 84.0000 97.0000 13.0000 18191222 + 166 2.50000 3.00000 97.0000 114.000 17.0000 23206827 + 167 2.50000 3.00000 114.000 133.000 19.0000 25287087 + 168 2.50000 3.00000 133.000 153.000 20.0000 26054749 + 169 2.50000 3.00000 153.000 174.000 21.0000 26825953 + 170 2.50000 3.00000 174.000 196.000 22.0000 27583745 + 171 2.50000 3.00000 196.000 220.000 24.0000 29590589 + 172 2.50000 3.00000 220.000 245.000 25.0000 30301929 + 173 2.50000 3.00000 245.000 272.000 27.0000 32195240 + 174 2.50000 3.00000 272.000 300.000 28.0000 32609430 + 175 2.50000 3.00000 300.000 468.000 168.000 89452916 +}} diff --git a/v2.5/generators/nlojet++/interface/data/check/InclusiveNJets_InclusiveJets_flex.wrm b/v2.5/generators/nlojet++/interface/data/check/InclusiveNJets_InclusiveJets_flex.wrm new file mode 100644 index 0000000000000000000000000000000000000000..7c489b9b4009e8fca7d5d9d54c6e97a89f0a26d5 --- /dev/null +++ b/v2.5/generators/nlojet++/interface/data/check/InclusiveNJets_InclusiveJets_flex.wrm @@ -0,0 +1,387 @@ +# --- Use emacs in sh mode -*-sh-*- # +# This is a automatically generated file by fastNLO and holds the values of the warmup run. +# The values are valid for the scenario InclusiveJets_flex +# and if calculated with the steerfile: InclusiveNJets +# but only if no serious changes have been performed since its creation. +# +# Delete this file, if you want fastNLO to calculate a new one. +# +# This file has been calculated using: +# 100000 contributions. +# 1296561 entries. +# ( Mind: contributions != events. And contributions are not necessarily in phase space region. +# Please check by eye for reasonability of the values. +# Number of events per bin are listed below. + +Warmup.OrderInAlphasOfWarmupRunWas 2 +Warmup.CheckScaleLimitsAgainstBins true +Warmup.ScaleDescriptionScale1 "pT_jet_[GeV]" +Warmup.ScaleDescriptionScale2 "pT_max_[GeV]" +Warmup.DifferentialDimension 2 +Warmup.DimensionLabels { + "|y|" "pT_[GeV]" +} +Warmup.DimensionIsDifferential { + "2" "2" +} + +Warmup.Values {{ + ObsBin x_min x_max pT_jet_[GeV]_min pT_jet_[GeV]_max pT_max_[GeV]_min pT_max_[GeV]_max + 0 1.0e-09 1.00e+00 18.000000 21.000000 18.000000 21.000000 + 1 1.0e-09 1.00e+00 21.000000 24.000000 21.000000 24.000000 + 2 1.0e-09 1.00e+00 24.000000 28.000000 24.000000 28.000000 + 3 1.0e-09 1.00e+00 28.000000 32.000000 28.000000 32.000000 + 4 1.0e-09 1.00e+00 32.000000 37.000000 32.000000 37.000000 + 5 1.0e-09 1.00e+00 37.000000 43.000000 37.000000 43.000000 + 6 1.0e-09 1.00e+00 43.000000 49.000000 43.000000 49.000000 + 7 1.0e-09 1.00e+00 49.000000 56.000000 49.000000 56.000000 + 8 1.0e-09 1.00e+00 56.000000 64.000000 56.000000 64.000000 + 9 1.0e-09 1.00e+00 64.000000 74.000000 64.000000 74.000000 + 10 1.0e-09 1.00e+00 74.000000 84.000000 74.000000 84.000000 + 11 1.0e-09 1.00e+00 84.000000 97.000000 84.000000 97.000000 + 12 1.0e-09 1.00e+00 97.000000 114.000000 97.000000 114.000000 + 13 1.0e-09 1.00e+00 114.000000 133.000000 114.000000 133.000000 + 14 1.0e-09 1.00e+00 133.000000 153.000000 133.000000 153.000000 + 15 1.0e-09 1.00e+00 153.000000 174.000000 153.000000 174.000000 + 16 1.0e-09 1.00e+00 174.000000 196.000000 174.000000 196.000000 + 17 1.0e-09 1.00e+00 196.000000 220.000000 196.000000 220.000000 + 18 1.0e-09 1.00e+00 220.000000 245.000000 220.000000 245.000000 + 19 1.0e-09 1.00e+00 245.000000 272.000000 245.000000 272.000000 + 20 1.0e-09 1.00e+00 272.000000 300.000000 272.000000 300.000000 + 21 1.0e-09 1.00e+00 300.000000 330.000000 300.000000 330.000000 + 22 1.0e-09 1.00e+00 330.000000 362.000000 330.000000 362.000000 + 23 1.0e-09 1.00e+00 362.000000 395.000000 362.000000 395.000000 + 24 1.0e-09 1.00e+00 395.000000 430.000000 395.000000 430.000000 + 25 1.0e-09 1.00e+00 430.000000 468.000000 430.000000 468.000000 + 26 1.0e-09 1.00e+00 468.000000 507.000000 468.000000 507.000000 + 27 1.0e-09 1.00e+00 507.000000 548.000000 507.000000 548.000000 + 28 1.0e-09 1.00e+00 548.000000 592.000000 548.000000 592.000000 + 29 1.0e-09 1.00e+00 592.000000 638.000000 592.000000 638.000000 + 30 1.0e-09 1.00e+00 638.000000 686.000000 638.000000 686.000000 + 31 1.0e-09 1.00e+00 686.000000 737.000000 686.000000 737.000000 + 32 1.0e-09 1.00e+00 737.000000 846.000000 737.000000 846.000000 + 33 1.0e-09 1.00e+00 846.000000 1684.000000 846.000000 1684.000000 + 34 1.0e-09 1.00e+00 18.000000 21.000000 18.000000 21.000000 + 35 1.0e-09 1.00e+00 21.000000 24.000000 21.000000 24.000000 + 36 1.0e-09 1.00e+00 24.000000 28.000000 24.000000 28.000000 + 37 1.0e-09 1.00e+00 28.000000 32.000000 28.000000 32.000000 + 38 1.0e-09 1.00e+00 32.000000 37.000000 32.000000 37.000000 + 39 1.0e-09 1.00e+00 37.000000 43.000000 37.000000 43.000000 + 40 1.0e-09 1.00e+00 43.000000 49.000000 43.000000 49.000000 + 41 1.0e-09 1.00e+00 49.000000 56.000000 49.000000 56.000000 + 42 1.0e-09 1.00e+00 56.000000 64.000000 56.000000 64.000000 + 43 1.0e-09 1.00e+00 64.000000 74.000000 64.000000 74.000000 + 44 1.0e-09 1.00e+00 74.000000 84.000000 74.000000 84.000000 + 45 1.0e-09 1.00e+00 84.000000 97.000000 84.000000 97.000000 + 46 1.0e-09 1.00e+00 97.000000 114.000000 97.000000 114.000000 + 47 1.0e-09 1.00e+00 114.000000 133.000000 114.000000 133.000000 + 48 1.0e-09 1.00e+00 133.000000 153.000000 133.000000 153.000000 + 49 1.0e-09 1.00e+00 153.000000 174.000000 153.000000 174.000000 + 50 1.0e-09 1.00e+00 174.000000 196.000000 174.000000 196.000000 + 51 1.0e-09 1.00e+00 196.000000 220.000000 196.000000 220.000000 + 52 1.0e-09 1.00e+00 220.000000 245.000000 220.000000 245.000000 + 53 1.0e-09 1.00e+00 245.000000 272.000000 245.000000 272.000000 + 54 1.0e-09 1.00e+00 272.000000 300.000000 272.000000 300.000000 + 55 1.0e-09 1.00e+00 300.000000 330.000000 300.000000 330.000000 + 56 1.0e-09 1.00e+00 330.000000 362.000000 330.000000 362.000000 + 57 1.0e-09 1.00e+00 362.000000 395.000000 362.000000 395.000000 + 58 1.0e-09 1.00e+00 395.000000 430.000000 395.000000 430.000000 + 59 1.0e-09 1.00e+00 430.000000 468.000000 430.000000 468.000000 + 60 1.0e-09 1.00e+00 468.000000 507.000000 468.000000 507.000000 + 61 1.0e-09 1.00e+00 507.000000 548.000000 507.000000 548.000000 + 62 1.0e-09 1.00e+00 548.000000 592.000000 548.000000 592.000000 + 63 1.0e-09 1.00e+00 592.000000 638.000000 592.000000 638.000000 + 64 1.0e-09 1.00e+00 638.000000 686.000000 638.000000 686.000000 + 65 1.0e-09 1.00e+00 686.000000 790.000000 686.000000 790.000000 + 66 1.0e-09 1.00e+00 790.000000 1684.000000 790.000000 1684.000000 + 67 1.0e-09 1.00e+00 18.000000 21.000000 18.000000 21.000000 + 68 1.0e-09 1.00e+00 21.000000 24.000000 21.000000 24.000000 + 69 1.0e-09 1.00e+00 24.000000 28.000000 24.000000 28.000000 + 70 1.0e-09 1.00e+00 28.000000 32.000000 28.000000 32.000000 + 71 1.0e-09 1.00e+00 32.000000 37.000000 32.000000 37.000000 + 72 1.0e-09 1.00e+00 37.000000 43.000000 37.000000 43.000000 + 73 1.0e-09 1.00e+00 43.000000 49.000000 43.000000 49.000000 + 74 1.0e-09 1.00e+00 49.000000 56.000000 49.000000 56.000000 + 75 1.0e-09 1.00e+00 56.000000 64.000000 56.000000 64.000000 + 76 1.0e-09 1.00e+00 64.000000 74.000000 64.000000 74.000000 + 77 1.0e-09 1.00e+00 74.000000 84.000000 74.000000 84.000000 + 78 1.0e-09 1.00e+00 84.000000 97.000000 84.000000 97.000000 + 79 1.0e-09 1.00e+00 97.000000 114.000000 97.000000 114.000000 + 80 1.0e-09 1.00e+00 114.000000 133.000000 114.000000 133.000000 + 81 1.0e-09 1.00e+00 133.000000 153.000000 133.000000 153.000000 + 82 1.0e-09 1.00e+00 153.000000 174.000000 153.000000 174.000000 + 83 1.0e-09 1.00e+00 174.000000 196.000000 174.000000 196.000000 + 84 1.0e-09 1.00e+00 196.000000 220.000000 196.000000 220.000000 + 85 1.0e-09 1.00e+00 220.000000 245.000000 220.000000 245.000000 + 86 1.0e-09 1.00e+00 245.000000 272.000000 245.000000 272.000000 + 87 1.0e-09 1.00e+00 272.000000 300.000000 272.000000 300.000000 + 88 1.0e-09 1.00e+00 300.000000 330.000000 300.000000 330.000000 + 89 1.0e-09 1.00e+00 330.000000 362.000000 330.000000 362.000000 + 90 1.0e-09 1.00e+00 362.000000 395.000000 362.000000 395.000000 + 91 1.0e-09 1.00e+00 395.000000 430.000000 395.000000 430.000000 + 92 1.0e-09 1.00e+00 430.000000 468.000000 430.000000 468.000000 + 93 1.0e-09 1.00e+00 468.000000 507.000000 468.000000 507.000000 + 94 1.0e-09 1.00e+00 507.000000 548.000000 507.000000 548.000000 + 95 1.0e-09 1.00e+00 548.000000 592.000000 548.000000 592.000000 + 96 1.0e-09 1.00e+00 592.000000 638.000000 592.000000 638.000000 + 97 1.0e-09 1.00e+00 638.000000 686.000000 638.000000 686.000000 + 98 1.0e-09 1.00e+00 686.000000 1410.000000 686.000000 1410.000000 + 99 1.0e-09 1.00e+00 18.000000 21.000000 18.000000 21.000000 + 100 1.0e-09 1.00e+00 21.000000 24.000000 21.000000 24.000000 + 101 1.0e-09 1.00e+00 24.000000 28.000000 24.000000 28.000000 + 102 1.0e-09 1.00e+00 28.000000 32.000000 28.000000 32.000000 + 103 1.0e-09 1.00e+00 32.000000 37.000000 32.000000 37.000000 + 104 1.0e-09 1.00e+00 37.000000 43.000000 37.000000 43.000000 + 105 1.0e-09 1.00e+00 43.000000 49.000000 43.000000 49.000000 + 106 1.0e-09 1.00e+00 49.000000 56.000000 49.000000 56.000000 + 107 1.0e-09 1.00e+00 56.000000 64.000000 56.000000 64.000000 + 108 1.0e-09 1.00e+00 64.000000 74.000000 64.000000 74.000000 + 109 1.0e-09 1.00e+00 74.000000 84.000000 74.000000 84.000000 + 110 1.0e-09 1.00e+00 84.000000 97.000000 84.000000 97.000000 + 111 1.0e-09 1.00e+00 97.000000 114.000000 97.000000 114.000000 + 112 1.0e-09 1.00e+00 114.000000 133.000000 114.000000 133.000000 + 113 1.0e-09 1.00e+00 133.000000 153.000000 133.000000 153.000000 + 114 1.0e-09 1.00e+00 153.000000 174.000000 153.000000 174.000000 + 115 1.0e-09 1.00e+00 174.000000 196.000000 174.000000 196.000000 + 116 1.0e-09 1.00e+00 196.000000 220.000000 196.000000 220.000000 + 117 1.0e-09 1.00e+00 220.000000 245.000000 220.000000 245.000000 + 118 1.0e-09 1.00e+00 245.000000 272.000000 245.000000 272.000000 + 119 1.0e-09 1.00e+00 272.000000 300.000000 272.000000 300.000000 + 120 1.0e-09 1.00e+00 300.000000 330.000000 300.000000 330.000000 + 121 1.0e-09 1.00e+00 330.000000 362.000000 330.000000 362.000000 + 122 1.0e-09 1.00e+00 362.000000 395.000000 362.000000 395.000000 + 123 1.0e-09 1.00e+00 395.000000 430.000000 395.000000 430.000000 + 124 1.0e-09 1.00e+00 430.000000 468.000000 430.000000 468.000000 + 125 1.0e-09 1.00e+00 468.000000 507.000000 468.000000 507.000000 + 126 1.0e-09 1.00e+00 507.000000 548.000000 507.000000 548.000000 + 127 1.0e-09 1.00e+00 548.000000 1032.000000 548.000000 1032.000000 + 128 1.0e-09 1.00e+00 18.000000 21.000000 18.000000 21.000000 + 129 1.0e-09 1.00e+00 21.000000 24.000000 21.000000 24.000000 + 130 1.0e-09 1.00e+00 24.000000 28.000000 24.000000 28.000000 + 131 1.0e-09 1.00e+00 28.000000 32.000000 28.000000 32.000000 + 132 1.0e-09 1.00e+00 32.000000 37.000000 32.000000 37.000000 + 133 1.0e-09 1.00e+00 37.000000 43.000000 37.000000 43.000000 + 134 1.0e-09 1.00e+00 43.000000 49.000000 43.000000 49.000000 + 135 1.0e-09 1.00e+00 49.000000 56.000000 49.000000 56.000000 + 136 1.0e-09 1.00e+00 56.000000 64.000000 56.000000 64.000000 + 137 1.0e-09 1.00e+00 64.000000 74.000000 64.000000 74.000000 + 138 1.0e-09 1.00e+00 74.000000 84.000000 74.000000 84.000000 + 139 1.0e-09 1.00e+00 84.000000 97.000000 84.000000 97.000000 + 140 1.0e-09 1.00e+00 97.000000 114.000000 97.000000 114.000000 + 141 1.0e-09 1.00e+00 114.000000 133.000000 114.000000 133.000000 + 142 1.0e-09 1.00e+00 133.000000 153.000000 133.000000 153.000000 + 143 1.0e-09 1.00e+00 153.000000 174.000000 153.000000 174.000000 + 144 1.0e-09 1.00e+00 174.000000 196.000000 174.000000 196.000000 + 145 1.0e-09 1.00e+00 196.000000 220.000000 196.000000 220.000000 + 146 1.0e-09 1.00e+00 220.000000 245.000000 220.000000 245.000000 + 147 1.0e-09 1.00e+00 245.000000 272.000000 245.000000 272.000000 + 148 1.0e-09 1.00e+00 272.000000 300.000000 272.000000 300.000000 + 149 1.0e-09 1.00e+00 300.000000 330.000000 300.000000 330.000000 + 150 1.0e-09 1.00e+00 330.000000 362.000000 330.000000 362.000000 + 151 1.0e-09 1.00e+00 362.000000 395.000000 362.000000 395.000000 + 152 1.0e-09 1.00e+00 395.000000 430.000000 395.000000 430.000000 + 153 1.0e-09 1.00e+00 430.000000 737.000000 430.000000 737.000000 + 154 1.0e-09 1.00e+00 18.000000 21.000000 18.000000 21.000000 + 155 1.0e-09 1.00e+00 21.000000 24.000000 21.000000 24.000000 + 156 1.0e-09 1.00e+00 24.000000 28.000000 24.000000 28.000000 + 157 1.0e-09 1.00e+00 28.000000 32.000000 28.000000 32.000000 + 158 1.0e-09 1.00e+00 32.000000 37.000000 32.000000 37.000000 + 159 1.0e-09 1.00e+00 37.000000 43.000000 37.000000 43.000000 + 160 1.0e-09 1.00e+00 43.000000 49.000000 43.000000 49.000000 + 161 1.0e-09 1.00e+00 49.000000 56.000000 49.000000 56.000000 + 162 1.0e-09 1.00e+00 56.000000 64.000000 56.000000 64.000000 + 163 1.0e-09 1.00e+00 64.000000 74.000000 64.000000 74.000000 + 164 1.0e-09 1.00e+00 74.000000 84.000000 74.000000 84.000000 + 165 1.0e-09 1.00e+00 84.000000 97.000000 84.000000 97.000000 + 166 1.0e-09 1.00e+00 97.000000 114.000000 97.000000 114.000000 + 167 1.0e-09 1.00e+00 114.000000 133.000000 114.000000 133.000000 + 168 1.0e-09 1.00e+00 133.000000 153.000000 133.000000 153.000000 + 169 1.0e-09 1.00e+00 153.000000 174.000000 153.000000 174.000000 + 170 1.0e-09 1.00e+00 174.000000 196.000000 174.000000 196.000000 + 171 1.0e-09 1.00e+00 196.000000 220.000000 196.000000 220.000000 + 172 1.0e-09 1.00e+00 220.000000 245.000000 220.000000 245.000000 + 173 1.0e-09 1.00e+00 245.000000 272.000000 245.000000 272.000000 + 174 1.0e-09 1.00e+00 272.000000 300.000000 272.000000 300.000000 + 175 1.0e-09 1.00e+00 300.000000 468.000000 300.000000 468.000000 +}} + + +Warmup.Binning {{ + ObsBin |y|_Lo |y|_Up pT_[GeV]_Lo pT_[GeV]_Up BinSize EventCount + 0 0.00000 0.500000 18.0000 21.0000 3.00000 308 + 1 0.00000 0.500000 21.0000 24.0000 3.00000 399 + 2 0.00000 0.500000 24.0000 28.0000 4.00000 511 + 3 0.00000 0.500000 28.0000 32.0000 4.00000 609 + 4 0.00000 0.500000 32.0000 37.0000 5.00000 1463 + 5 0.00000 0.500000 37.0000 43.0000 6.00000 4291 + 6 0.00000 0.500000 43.0000 49.0000 6.00000 6615 + 7 0.00000 0.500000 49.0000 56.0000 7.00000 9079 + 8 0.00000 0.500000 56.0000 64.0000 8.00000 10969 + 9 0.00000 0.500000 64.0000 74.0000 10.0000 14035 + 10 0.00000 0.500000 74.0000 84.0000 10.0000 12929 + 11 0.00000 0.500000 84.0000 97.0000 13.0000 16940 + 12 0.00000 0.500000 97.0000 114.000 17.0000 19691 + 13 0.00000 0.500000 114.000 133.000 19.0000 18921 + 14 0.00000 0.500000 133.000 153.000 20.0000 17773 + 15 0.00000 0.500000 153.000 174.000 21.0000 16065 + 16 0.00000 0.500000 174.000 196.000 22.0000 14035 + 17 0.00000 0.500000 196.000 220.000 24.0000 14273 + 18 0.00000 0.500000 220.000 245.000 25.0000 12579 + 19 0.00000 0.500000 245.000 272.000 27.0000 12159 + 20 0.00000 0.500000 272.000 300.000 28.0000 11200 + 21 0.00000 0.500000 300.000 330.000 30.0000 10556 + 22 0.00000 0.500000 330.000 362.000 32.0000 9506 + 23 0.00000 0.500000 362.000 395.000 33.0000 10388 + 24 0.00000 0.500000 395.000 430.000 35.0000 9324 + 25 0.00000 0.500000 430.000 468.000 38.0000 8883 + 26 0.00000 0.500000 468.000 507.000 39.0000 8106 + 27 0.00000 0.500000 507.000 548.000 41.0000 8358 + 28 0.00000 0.500000 548.000 592.000 44.0000 7973 + 29 0.00000 0.500000 592.000 638.000 46.0000 7665 + 30 0.00000 0.500000 638.000 686.000 48.0000 7630 + 31 0.00000 0.500000 686.000 737.000 51.0000 7413 + 32 0.00000 0.500000 737.000 846.000 109.000 14644 + 33 0.00000 0.500000 846.000 1684.00 838.000 56553 + 34 0.500000 1.00000 18.0000 21.0000 3.00000 364 + 35 0.500000 1.00000 21.0000 24.0000 3.00000 385 + 36 0.500000 1.00000 24.0000 28.0000 4.00000 994 + 37 0.500000 1.00000 28.0000 32.0000 4.00000 2114 + 38 0.500000 1.00000 32.0000 37.0000 5.00000 3801 + 39 0.500000 1.00000 37.0000 43.0000 6.00000 5705 + 40 0.500000 1.00000 43.0000 49.0000 6.00000 5264 + 41 0.500000 1.00000 49.0000 56.0000 7.00000 6468 + 42 0.500000 1.00000 56.0000 64.0000 8.00000 7175 + 43 0.500000 1.00000 64.0000 74.0000 10.0000 8778 + 44 0.500000 1.00000 74.0000 84.0000 10.0000 8519 + 45 0.500000 1.00000 84.0000 97.0000 13.0000 11802 + 46 0.500000 1.00000 97.0000 114.000 17.0000 14868 + 47 0.500000 1.00000 114.000 133.000 19.0000 16394 + 48 0.500000 1.00000 133.000 153.000 20.0000 16247 + 49 0.500000 1.00000 153.000 174.000 21.0000 15547 + 50 0.500000 1.00000 174.000 196.000 22.0000 14203 + 51 0.500000 1.00000 196.000 220.000 24.0000 14105 + 52 0.500000 1.00000 220.000 245.000 25.0000 11788 + 53 0.500000 1.00000 245.000 272.000 27.0000 12047 + 54 0.500000 1.00000 272.000 300.000 28.0000 10794 + 55 0.500000 1.00000 300.000 330.000 30.0000 10227 + 56 0.500000 1.00000 330.000 362.000 32.0000 9842 + 57 0.500000 1.00000 362.000 395.000 33.0000 9366 + 58 0.500000 1.00000 395.000 430.000 35.0000 9303 + 59 0.500000 1.00000 430.000 468.000 38.0000 9205 + 60 0.500000 1.00000 468.000 507.000 39.0000 7644 + 61 0.500000 1.00000 507.000 548.000 41.0000 8162 + 62 0.500000 1.00000 548.000 592.000 44.0000 7805 + 63 0.500000 1.00000 592.000 638.000 46.0000 7504 + 64 0.500000 1.00000 638.000 686.000 48.0000 6853 + 65 0.500000 1.00000 686.000 790.000 104.000 13265 + 66 0.500000 1.00000 790.000 1684.00 894.000 53438 + 67 1.00000 1.50000 18.0000 21.0000 3.00000 1148 + 68 1.00000 1.50000 21.0000 24.0000 3.00000 1617 + 69 1.00000 1.50000 24.0000 28.0000 4.00000 2345 + 70 1.00000 1.50000 28.0000 32.0000 4.00000 2338 + 71 1.00000 1.50000 32.0000 37.0000 5.00000 2758 + 72 1.00000 1.50000 37.0000 43.0000 6.00000 3661 + 73 1.00000 1.50000 43.0000 49.0000 6.00000 3395 + 74 1.00000 1.50000 49.0000 56.0000 7.00000 4151 + 75 1.00000 1.50000 56.0000 64.0000 8.00000 4613 + 76 1.00000 1.50000 64.0000 74.0000 10.0000 5411 + 77 1.00000 1.50000 74.0000 84.0000 10.0000 5418 + 78 1.00000 1.50000 84.0000 97.0000 13.0000 7252 + 79 1.00000 1.50000 97.0000 114.000 17.0000 9149 + 80 1.00000 1.50000 114.000 133.000 19.0000 10311 + 81 1.00000 1.50000 133.000 153.000 20.0000 10822 + 82 1.00000 1.50000 153.000 174.000 21.0000 10920 + 83 1.00000 1.50000 174.000 196.000 22.0000 11760 + 84 1.00000 1.50000 196.000 220.000 24.0000 12467 + 85 1.00000 1.50000 220.000 245.000 25.0000 11557 + 86 1.00000 1.50000 245.000 272.000 27.0000 11571 + 87 1.00000 1.50000 272.000 300.000 28.0000 9898 + 88 1.00000 1.50000 300.000 330.000 30.0000 10136 + 89 1.00000 1.50000 330.000 362.000 32.0000 9618 + 90 1.00000 1.50000 362.000 395.000 33.0000 8505 + 91 1.00000 1.50000 395.000 430.000 35.0000 8043 + 92 1.00000 1.50000 430.000 468.000 38.0000 8302 + 93 1.00000 1.50000 468.000 507.000 39.0000 6783 + 94 1.00000 1.50000 507.000 548.000 41.0000 6825 + 95 1.00000 1.50000 548.000 592.000 44.0000 6867 + 96 1.00000 1.50000 592.000 638.000 46.0000 6496 + 97 1.00000 1.50000 638.000 686.000 48.0000 5929 + 98 1.00000 1.50000 686.000 1410.00 724.000 41097 + 99 1.50000 2.00000 18.0000 21.0000 3.00000 1267 + 100 1.50000 2.00000 21.0000 24.0000 3.00000 1274 + 101 1.50000 2.00000 24.0000 28.0000 4.00000 1498 + 102 1.50000 2.00000 28.0000 32.0000 4.00000 1547 + 103 1.50000 2.00000 32.0000 37.0000 5.00000 1869 + 104 1.50000 2.00000 37.0000 43.0000 6.00000 2527 + 105 1.50000 2.00000 43.0000 49.0000 6.00000 2359 + 106 1.50000 2.00000 49.0000 56.0000 7.00000 2478 + 107 1.50000 2.00000 56.0000 64.0000 8.00000 2870 + 108 1.50000 2.00000 64.0000 74.0000 10.0000 3514 + 109 1.50000 2.00000 74.0000 84.0000 10.0000 3507 + 110 1.50000 2.00000 84.0000 97.0000 13.0000 4480 + 111 1.50000 2.00000 97.0000 114.000 17.0000 5866 + 112 1.50000 2.00000 114.000 133.000 19.0000 6685 + 113 1.50000 2.00000 133.000 153.000 20.0000 6545 + 114 1.50000 2.00000 153.000 174.000 21.0000 6867 + 115 1.50000 2.00000 174.000 196.000 22.0000 6363 + 116 1.50000 2.00000 196.000 220.000 24.0000 7707 + 117 1.50000 2.00000 220.000 245.000 25.0000 7287 + 118 1.50000 2.00000 245.000 272.000 27.0000 8673 + 119 1.50000 2.00000 272.000 300.000 28.0000 8316 + 120 1.50000 2.00000 300.000 330.000 30.0000 8743 + 121 1.50000 2.00000 330.000 362.000 32.0000 7875 + 122 1.50000 2.00000 362.000 395.000 33.0000 7511 + 123 1.50000 2.00000 395.000 430.000 35.0000 6720 + 124 1.50000 2.00000 430.000 468.000 38.0000 6419 + 125 1.50000 2.00000 468.000 507.000 39.0000 5586 + 126 1.50000 2.00000 507.000 548.000 41.0000 5355 + 127 1.50000 2.00000 548.000 1032.00 484.000 28231 + 128 2.00000 2.50000 18.0000 21.0000 3.00000 854 + 129 2.00000 2.50000 21.0000 24.0000 3.00000 861 + 130 2.00000 2.50000 24.0000 28.0000 4.00000 1218 + 131 2.00000 2.50000 28.0000 32.0000 4.00000 875 + 132 2.00000 2.50000 32.0000 37.0000 5.00000 1211 + 133 2.00000 2.50000 37.0000 43.0000 6.00000 1498 + 134 2.00000 2.50000 43.0000 49.0000 6.00000 1470 + 135 2.00000 2.50000 49.0000 56.0000 7.00000 1631 + 136 2.00000 2.50000 56.0000 64.0000 8.00000 1673 + 137 2.00000 2.50000 64.0000 74.0000 10.0000 2310 + 138 2.00000 2.50000 74.0000 84.0000 10.0000 2205 + 139 2.00000 2.50000 84.0000 97.0000 13.0000 2961 + 140 2.00000 2.50000 97.0000 114.000 17.0000 3619 + 141 2.00000 2.50000 114.000 133.000 19.0000 4032 + 142 2.00000 2.50000 133.000 153.000 20.0000 4326 + 143 2.00000 2.50000 153.000 174.000 21.0000 4585 + 144 2.00000 2.50000 174.000 196.000 22.0000 4571 + 145 2.00000 2.50000 196.000 220.000 24.0000 4592 + 146 2.00000 2.50000 220.000 245.000 25.0000 5327 + 147 2.00000 2.50000 245.000 272.000 27.0000 5509 + 148 2.00000 2.50000 272.000 300.000 28.0000 5124 + 149 2.00000 2.50000 300.000 330.000 30.0000 5747 + 150 2.00000 2.50000 330.000 362.000 32.0000 5733 + 151 2.00000 2.50000 362.000 395.000 33.0000 5362 + 152 2.00000 2.50000 395.000 430.000 35.0000 4802 + 153 2.00000 2.50000 430.000 737.000 307.000 14854 + 154 2.50000 3.00000 18.0000 21.0000 3.00000 504 + 155 2.50000 3.00000 21.0000 24.0000 3.00000 427 + 156 2.50000 3.00000 24.0000 28.0000 4.00000 602 + 157 2.50000 3.00000 28.0000 32.0000 4.00000 672 + 158 2.50000 3.00000 32.0000 37.0000 5.00000 854 + 159 2.50000 3.00000 37.0000 43.0000 6.00000 917 + 160 2.50000 3.00000 43.0000 49.0000 6.00000 910 + 161 2.50000 3.00000 49.0000 56.0000 7.00000 1211 + 162 2.50000 3.00000 56.0000 64.0000 8.00000 1211 + 163 2.50000 3.00000 64.0000 74.0000 10.0000 1449 + 164 2.50000 3.00000 74.0000 84.0000 10.0000 1470 + 165 2.50000 3.00000 84.0000 97.0000 13.0000 1841 + 166 2.50000 3.00000 97.0000 114.000 17.0000 2282 + 167 2.50000 3.00000 114.000 133.000 19.0000 2590 + 168 2.50000 3.00000 133.000 153.000 20.0000 2674 + 169 2.50000 3.00000 153.000 174.000 21.0000 2779 + 170 2.50000 3.00000 174.000 196.000 22.0000 2730 + 171 2.50000 3.00000 196.000 220.000 24.0000 3283 + 172 2.50000 3.00000 220.000 245.000 25.0000 2919 + 173 2.50000 3.00000 245.000 272.000 27.0000 3227 + 174 2.50000 3.00000 272.000 300.000 28.0000 3255 + 175 2.50000 3.00000 300.000 468.000 168.000 8883 +}} diff --git a/v2.5/generators/nlojet++/interface/data/check/Makefile.am b/v2.5/generators/nlojet++/interface/data/check/Makefile.am index f00b8519ad50123a71f1eda8d00c07b71a9eb166..d6d04ceef0bd1e0a93870c532a1870a4efe1a02b 100644 --- a/v2.5/generators/nlojet++/interface/data/check/Makefile.am +++ b/v2.5/generators/nlojet++/interface/data/check/Makefile.am @@ -15,7 +15,9 @@ AUTOMAKE_OPTIONS = gnu # warmup.txt --> fnr0001midpHT_I723509_v23_fix_InclusiveNJets_warmup.txt # born.tab.gz --> fnr0001midpHT_I723509_v23_fix-hhc-born-2jet.tab.gz # nlo.tab.gz --> fnr0001midpHT_I723509_v23_fix-hhc-nlo-2jet.tab.gz -dist_check_DATA = steer.str warmup.txt born.tab.gz nlo.tab.gz +dist_check_DATA = steer.str warmup.txt born.tab.gz nlo.tab.gz compare-table-helper.py \ + fix_NodeDensity.str fix_NodesPerBin.str InclusiveNJets_InclusiveJets_fix.wrm \ + flex_NodeDensity.str flex_NodesPerBin.str InclusiveNJets_InclusiveJets_flex.wrm # Files that are required to build the project but that can be # recreated IF the necessary autotools etc. are available by: diff --git a/v2.5/generators/nlojet++/interface/data/check/compare-table-helper.py b/v2.5/generators/nlojet++/interface/data/check/compare-table-helper.py new file mode 100755 index 0000000000000000000000000000000000000000..0f40493ba7fb696c7f9f58ab0752c3d68a436cde --- /dev/null +++ b/v2.5/generators/nlojet++/interface/data/check/compare-table-helper.py @@ -0,0 +1,18 @@ +#!/usr/bin/env python3 + +import os +import sys + +try: + import fastnlo as fnlo +except ModuleNotFoundError: + print("compare-table-helper: fastNLO Python extension not found") + sys.exit(77) + +LIBDIR = os.environ["LIBDIR"] + +fnlo.SetGlobalVerbosity(fnlo.DEBUG) + +table_1 = fnlo.fastNLOTable(sys.argv[1]) +table_2 = fnlo.fastNLOTable(sys.argv[2]) +assert table_1.IsEquivalent(table_2, 1e-8) diff --git a/v2.5/generators/nlojet++/interface/data/check/fix_NodeDensity.str b/v2.5/generators/nlojet++/interface/data/check/fix_NodeDensity.str new file mode 100644 index 0000000000000000000000000000000000000000..8d2bfbd28fe3a70230e602d356942005c7c73529 --- /dev/null +++ b/v2.5/generators/nlojet++/interface/data/check/fix_NodeDensity.str @@ -0,0 +1,207 @@ +# -*-sh-*- +# ==================================================================== # +# +# A steering file for creating a fastNLO table (with NLOJet++) +# +# ==================================================================== # + +# ==================================================================== # +# +# Scenario specific settings +# +# ==================================================================== # + +# -------------------------------------------------------------------- # +# Description of scenario +# (Write each line of description in quotation marks) +# -------------------------------------------------------------------- # +ScenarioName InclusiveJets_fix +ScenarioDescription { + "d2sigma-jet_dpT_dy_[pb_GeV]" + "CMS_Collaboration" + "Inclusive_Jet_pT" + "anti-kT_R=0.5" + "CMS-PAPER-QCD-10-011, arXiv:1106.0208, Phys. Rev. Lett. 107 (2011) 132001." + "RIVET_ID=CMS_2011_S9086218/D01-x01-y01,SPIRES_ID=9086218,INSPIRE_RECORD=902309" + "THEORY_LABEL=NLOJet++" + "provided by:" + "fastNLO_2.5.0" + "If you use this table, please cite:" + " D. Britzger, T. Kluge, K. Rabbertz, F. Stober, M. Wobisch, arXiv:1109.1310" +} +PublicationUnits 12 # Unit of data cross sections (negative power of 10, e.g. 12->pb, 15->fb) + +# -------------------------------------------------------------------- # +# Global scenario settings +# -------------------------------------------------------------------- # +JetAlgo 2 # fastjet jet algorithm +# # clustering jet algos: 0 = kT, 1 = CA, 2 = anti-kT +# # cone jet algos: 10 = SISCone, 11 = CDFMidPointCone, 12 = D0RunIICone +Rjet 0.5 # Jet size parameter: Required for all jets +#OvThr 0.5 # Overlap threshold: Required for cone jets (Normally 10: 0.75; 11,12: 0.50) +# # Overall jet phase space +ptjmin 18. # Minimal jet pT (minimum set in interface to fastjet: 1 GeV) +yjmin 0.0 # Minimal jet rapidity +yjmax 3.0 # Maximal jet rapidity +# Use either rapidity or pseudorapidity but not both! If both are set, only rapidity cuts are applied. +#etajmin 0.0 # Minimal jet pseudorapidity +#etajmax 3.0 # Maximal jet pseudorapidity +#Njetmin 1 # Minimal number of jets required to be in preselected phase space +# # (Normally one, i.e. single-jet inclusive) +#obs0min x.y # +#obs0max x.y # By default these values are derived from the binning in these +#obs1min x.y # observables and are set automatically. If required the min/max +#obs1max x.y # values for each of the maximally three observables can be set +#obs2min x.y # by hand. +#obs2max x.y # + +# -------------------------------------------------------------------- # +# Observable definition, dimensioning, and normalization +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Specify, how many differential dimensions are measured. +# Number must be consistent with DimensionLabels and DimensionIsDifferential, see below +# 1 : read in 'SingleDifferentialBinning' +# 2 : read in 'DoubleDifferentialBinning' +# 3 : read in 'TripleDifferentialBinning' +# -------------------------------------------------------------------- # +LeadingOrder 2 # Number of jets for the LO process +DifferentialDimension 2 # Dimensionality of binning +DimensionLabels { # Labels (symbol and unit) for the measurement dimensions (from outer to inner "loop") + "|y|" # This defines the observables to be calculated! + "pT_[GeV]" # Implemented observables are: "|y|", "pT_[GeV]", "phi" +} +DimensionIsDifferential { # Specify for each dimension whether + 2 2 # 0 : the cross section is NOT differential, i.e. there are two bin borders, +} # but NO division (normalization) by bin width + # 1 : the cross section is point-wise differential, i.e. only one point is given + # 2 : the cross section is bin-wise differential, i.e. there are two bin borders + # and division by bin width +CalculateBinSize true # Calculate bin width from lower and upper bin boundaries +BinSizeFactor 2. # Possibility to provide additional normalization factor, e.g. of 2 for bins in |y| +#BinSize { x1 x2 x3 ... } # If 'CalculateBinSize' is 'false' provide table with bin widths 'by hand' for normalization + # + # If the calculation should not be divided by bin width, then use 'DimensionIsDifferential' equal '0' + # and set 'CalculateBinSize' 'true' for each dimension. + # +ScaleDescriptionScale1 "pT_jet_[GeV]" # This defines the scale to be used (Note: The 1st scale must always be in units of [GeV]!) +ScaleDescriptionScale2 "pT_max_[GeV]" # Specify 2nd scale name and unit (ONLY for flexible-scale tables) + # Implemented scales are: "pT_jet_[GeV]", "pT_max_[GeV]" + +# -------------------------------------------------------------------- # +# Observable binning +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Use either 'SingleDifferentialBinning' or +# 'DoubleDifferentialBinning' or +# 'TripleDifferentialBinning' +# in accord with 'DifferentialDimension' above +# -------------------------------------------------------------------- # +# Example for SingleDifferentialBinning: +#SingleDifferentialBinning { +# 7. 11. 18. 30. 50. 100. +#} + +# Example for DoubleDifferentialBinning: +DoubleDifferentialBinning {{ + 1stDimLo 1stDimUp "----- Array of bin-grid for 2nd dimension -----" + 0.0 0.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 737. 846. 1684. + 0.5 1.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 790. 1684. + 1.0 1.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 1410. + 1.5 2.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 1032. + 2.0 2.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 737. + 2.5 3.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 468. +}} + +# Example for TripleDifferentialBinning: +#TripleDifferentialBinning {{ +# 1stDimLo 1stDimUp 2ndDimLo 2ndDimUp "----- Array of bin-grid for 3rd dimension -----" +# 100. 150. -1.0 0.0 7. 11. 18. 30. 50. +# 150. 200. -1.0 0.0 7. 11. 18. 30. 50. +# 200. 400. 0.0 1.5 7. 11. 18. 30. 50. +# 400. 700. 0.0 1.5 7. 11. 18. 30. 50. +# 700. 5000. 1.5 2.5 7. 11. 18. 30. 50. +# 5000. 15000. 1.5 2.5 7. 11. 18. 30. 50. +#}} + +# ==================================================================== # +# +# Process specific and therefore at least partially theory-code +# dependent settings +# +# ==================================================================== # +CenterOfMassEnergy 7000. # Center-of-mass energy in GeV. +# Some examples from the past: 200. # RHIC +# 1800. # TeV Run I +# 1960. # TeV Run II +# 900. # LHC Injection Run +# 2360. # LHC Initial Run +# 2760. # LHC HIpp base Run +# 5020. # LHC HIpp base Run +# 7000. # LHC First Run (2010/2011) +# 8000. # LHC Second Run (2012) +# 13000. # LHC Next Run ? (2015) +# 14000. # LHC Design Run +PDF1 2212 # PDF of 1st hadron (following PDG convention). +PDF2 2212 # PDF of 2nd hadron (following PDG convention). +NPDF 2 +NPDFDim 1 + +# ==================================================================== # +# +# General fastNLO settings +# +# ==================================================================== # +#GlobalVerbosity DEBUG # Global output verbosity of fastNLO toolkit, def.=WARNING, +GlobalVerbosity INFO # Global output verbosity of fastNLO toolkit, def.=WARNING, + # (and of user scenario code if implemented). + # Possible values are: DEBUG, MANUAL, INFO, WARNING, ERROR, SILENT +OutputFilename InclusiveNJets.tab # Filename of fastNLO output table +OutputPrecision 8 # Number of decimal digits to store in output table, def.=8. +FlexibleScaleTable false # Create table fully flexible in mu_f (larger size), true, or + # table with fixed number of mu_f scale factors, def.=false. +ScaleVariationFactors { # Factorization scale variations (only needed for fixed-scale tables) + 0.5 1.0 2.0 # List of scale factors must include factor '1' +} # Scale factors will be ordered according to fastNLO convention: (1, min, ... , max) +ReadBinningFromSteering true # Specify if binning is read from this file. MUST be true for now! +IgnoreWarmupBinningCheck true # Ignore crosscheck of binning between steering and warmup + # Avoids problems with precision of bin borders e.g. in the case of Pi +#>>fastNLO-warmup.txt # Specify alternative filename to read warm-up results from, def.=SteerFileBasename_${ScenarioName}_warmup.txt + +# ==================================================================== # +# +# Specific fastNLO settings (normally do not need to be changed) +# Only change when you know what you are doing ...! +# +# ==================================================================== # +ApplyPDFReweighting true # Apply reweighting of pdfs for an optimized interpolation, def.=true. +CheckScaleLimitsAgainstBins true # Set limits for scale nodes to bin borders, if possible + +# -------------------------------------------------------------------- # +# Choose fastNLO interpolation kernels and distance measures +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Currently implemented interpolation kernels +# Catmull +# Lagrange +# OneNode +# Linear +# +# Currently implemented distance measures +# linear +# loglog025 eq. to (log(log(4*x))) +# log10 +# sqrtlog10 eq. to sqrt(log_10(x)) +# -------------------------------------------------------------------- # +X_Kernel Lagrange +X_DistanceMeasure "sqrtlog10" +X_NNodes 4 +X_NoOfNodesPerMagnitude false +X_NNodeCounting "NodeDensity" + +Mu1_Kernel Lagrange +Mu1_DistanceMeasure "loglog025" +Mu1_NNodes 6 +Mu1_NNodeCounting "NodesPerDim2" + +Mu2_Kernel Lagrange # Scale2 not used for fixed-scale tables +Mu2_DistanceMeasure "loglog025" +Mu2_NNodes 6 +Mu2_NNodeCounting "NodesPerDim2" diff --git a/v2.5/generators/nlojet++/interface/data/check/fix_NodesPerBin.str b/v2.5/generators/nlojet++/interface/data/check/fix_NodesPerBin.str new file mode 100644 index 0000000000000000000000000000000000000000..2a45d07baa6a7f6fd66ba8a0678dbf1b001a1799 --- /dev/null +++ b/v2.5/generators/nlojet++/interface/data/check/fix_NodesPerBin.str @@ -0,0 +1,207 @@ +# -*-sh-*- +# ==================================================================== # +# +# A steering file for creating a fastNLO table (with NLOJet++) +# +# ==================================================================== # + +# ==================================================================== # +# +# Scenario specific settings +# +# ==================================================================== # + +# -------------------------------------------------------------------- # +# Description of scenario +# (Write each line of description in quotation marks) +# -------------------------------------------------------------------- # +ScenarioName InclusiveJets_fix +ScenarioDescription { + "d2sigma-jet_dpT_dy_[pb_GeV]" + "CMS_Collaboration" + "Inclusive_Jet_pT" + "anti-kT_R=0.5" + "CMS-PAPER-QCD-10-011, arXiv:1106.0208, Phys. Rev. Lett. 107 (2011) 132001." + "RIVET_ID=CMS_2011_S9086218/D01-x01-y01,SPIRES_ID=9086218,INSPIRE_RECORD=902309" + "THEORY_LABEL=NLOJet++" + "provided by:" + "fastNLO_2.5.0" + "If you use this table, please cite:" + " D. Britzger, T. Kluge, K. Rabbertz, F. Stober, M. Wobisch, arXiv:1109.1310" +} +PublicationUnits 12 # Unit of data cross sections (negative power of 10, e.g. 12->pb, 15->fb) + +# -------------------------------------------------------------------- # +# Global scenario settings +# -------------------------------------------------------------------- # +JetAlgo 2 # fastjet jet algorithm +# # clustering jet algos: 0 = kT, 1 = CA, 2 = anti-kT +# # cone jet algos: 10 = SISCone, 11 = CDFMidPointCone, 12 = D0RunIICone +Rjet 0.5 # Jet size parameter: Required for all jets +#OvThr 0.5 # Overlap threshold: Required for cone jets (Normally 10: 0.75; 11,12: 0.50) +# # Overall jet phase space +ptjmin 18. # Minimal jet pT (minimum set in interface to fastjet: 1 GeV) +yjmin 0.0 # Minimal jet rapidity +yjmax 3.0 # Maximal jet rapidity +# Use either rapidity or pseudorapidity but not both! If both are set, only rapidity cuts are applied. +#etajmin 0.0 # Minimal jet pseudorapidity +#etajmax 3.0 # Maximal jet pseudorapidity +#Njetmin 1 # Minimal number of jets required to be in preselected phase space +# # (Normally one, i.e. single-jet inclusive) +#obs0min x.y # +#obs0max x.y # By default these values are derived from the binning in these +#obs1min x.y # observables and are set automatically. If required the min/max +#obs1max x.y # values for each of the maximally three observables can be set +#obs2min x.y # by hand. +#obs2max x.y # + +# -------------------------------------------------------------------- # +# Observable definition, dimensioning, and normalization +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Specify, how many differential dimensions are measured. +# Number must be consistent with DimensionLabels and DimensionIsDifferential, see below +# 1 : read in 'SingleDifferentialBinning' +# 2 : read in 'DoubleDifferentialBinning' +# 3 : read in 'TripleDifferentialBinning' +# -------------------------------------------------------------------- # +LeadingOrder 2 # Number of jets for the LO process +DifferentialDimension 2 # Dimensionality of binning +DimensionLabels { # Labels (symbol and unit) for the measurement dimensions (from outer to inner "loop") + "|y|" # This defines the observables to be calculated! + "pT_[GeV]" # Implemented observables are: "|y|", "pT_[GeV]", "phi" +} +DimensionIsDifferential { # Specify for each dimension whether + 2 2 # 0 : the cross section is NOT differential, i.e. there are two bin borders, +} # but NO division (normalization) by bin width + # 1 : the cross section is point-wise differential, i.e. only one point is given + # 2 : the cross section is bin-wise differential, i.e. there are two bin borders + # and division by bin width +CalculateBinSize true # Calculate bin width from lower and upper bin boundaries +BinSizeFactor 2. # Possibility to provide additional normalization factor, e.g. of 2 for bins in |y| +#BinSize { x1 x2 x3 ... } # If 'CalculateBinSize' is 'false' provide table with bin widths 'by hand' for normalization + # + # If the calculation should not be divided by bin width, then use 'DimensionIsDifferential' equal '0' + # and set 'CalculateBinSize' 'true' for each dimension. + # +ScaleDescriptionScale1 "pT_jet_[GeV]" # This defines the scale to be used (Note: The 1st scale must always be in units of [GeV]!) +ScaleDescriptionScale2 "pT_max_[GeV]" # Specify 2nd scale name and unit (ONLY for flexible-scale tables) + # Implemented scales are: "pT_jet_[GeV]", "pT_max_[GeV]" + +# -------------------------------------------------------------------- # +# Observable binning +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Use either 'SingleDifferentialBinning' or +# 'DoubleDifferentialBinning' or +# 'TripleDifferentialBinning' +# in accord with 'DifferentialDimension' above +# -------------------------------------------------------------------- # +# Example for SingleDifferentialBinning: +#SingleDifferentialBinning { +# 7. 11. 18. 30. 50. 100. +#} + +# Example for DoubleDifferentialBinning: +DoubleDifferentialBinning {{ + 1stDimLo 1stDimUp "----- Array of bin-grid for 2nd dimension -----" + 0.0 0.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 737. 846. 1684. + 0.5 1.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 790. 1684. + 1.0 1.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 1410. + 1.5 2.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 1032. + 2.0 2.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 737. + 2.5 3.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 468. +}} + +# Example for TripleDifferentialBinning: +#TripleDifferentialBinning {{ +# 1stDimLo 1stDimUp 2ndDimLo 2ndDimUp "----- Array of bin-grid for 3rd dimension -----" +# 100. 150. -1.0 0.0 7. 11. 18. 30. 50. +# 150. 200. -1.0 0.0 7. 11. 18. 30. 50. +# 200. 400. 0.0 1.5 7. 11. 18. 30. 50. +# 400. 700. 0.0 1.5 7. 11. 18. 30. 50. +# 700. 5000. 1.5 2.5 7. 11. 18. 30. 50. +# 5000. 15000. 1.5 2.5 7. 11. 18. 30. 50. +#}} + +# ==================================================================== # +# +# Process specific and therefore at least partially theory-code +# dependent settings +# +# ==================================================================== # +CenterOfMassEnergy 7000. # Center-of-mass energy in GeV. +# Some examples from the past: 200. # RHIC +# 1800. # TeV Run I +# 1960. # TeV Run II +# 900. # LHC Injection Run +# 2360. # LHC Initial Run +# 2760. # LHC HIpp base Run +# 5020. # LHC HIpp base Run +# 7000. # LHC First Run (2010/2011) +# 8000. # LHC Second Run (2012) +# 13000. # LHC Next Run ? (2015) +# 14000. # LHC Design Run +PDF1 2212 # PDF of 1st hadron (following PDG convention). +PDF2 2212 # PDF of 2nd hadron (following PDG convention). +NPDF 2 +NPDFDim 1 + +# ==================================================================== # +# +# General fastNLO settings +# +# ==================================================================== # +#GlobalVerbosity DEBUG # Global output verbosity of fastNLO toolkit, def.=WARNING, +GlobalVerbosity INFO # Global output verbosity of fastNLO toolkit, def.=WARNING, + # (and of user scenario code if implemented). + # Possible values are: DEBUG, MANUAL, INFO, WARNING, ERROR, SILENT +OutputFilename InclusiveNJets.tab # Filename of fastNLO output table +OutputPrecision 8 # Number of decimal digits to store in output table, def.=8. +FlexibleScaleTable false # Create table fully flexible in mu_f (larger size), true, or + # table with fixed number of mu_f scale factors, def.=false. +ScaleVariationFactors { # Factorization scale variations (only needed for fixed-scale tables) + 0.5 1.0 2.0 # List of scale factors must include factor '1' +} # Scale factors will be ordered according to fastNLO convention: (1, min, ... , max) +ReadBinningFromSteering true # Specify if binning is read from this file. MUST be true for now! +IgnoreWarmupBinningCheck true # Ignore crosscheck of binning between steering and warmup + # Avoids problems with precision of bin borders e.g. in the case of Pi +#>>fastNLO-warmup.txt # Specify alternative filename to read warm-up results from, def.=SteerFileBasename_${ScenarioName}_warmup.txt + +# ==================================================================== # +# +# Specific fastNLO settings (normally do not need to be changed) +# Only change when you know what you are doing ...! +# +# ==================================================================== # +ApplyPDFReweighting true # Apply reweighting of pdfs for an optimized interpolation, def.=true. +CheckScaleLimitsAgainstBins true # Set limits for scale nodes to bin borders, if possible + +# -------------------------------------------------------------------- # +# Choose fastNLO interpolation kernels and distance measures +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Currently implemented interpolation kernels +# Catmull +# Lagrange +# OneNode +# Linear +# +# Currently implemented distance measures +# linear +# loglog025 eq. to (log(log(4*x))) +# log10 +# sqrtlog10 eq. to sqrt(log_10(x)) +# -------------------------------------------------------------------- # +X_Kernel Lagrange +X_DistanceMeasure "sqrtlog10" +X_NNodes 12 +X_NoOfNodesPerMagnitude false +X_NNodeCounting "NodesPerBin" + +Mu1_Kernel Lagrange +Mu1_DistanceMeasure "loglog025" +Mu1_NNodes 6 +Mu1_NNodeCounting "NodesPerBin" + +Mu2_Kernel Lagrange # Scale2 not used for fixed-scale tables +Mu2_DistanceMeasure "loglog025" +Mu2_NNodes 6 +Mu2_NNodeCounting "NodesPerBin" diff --git a/v2.5/generators/nlojet++/interface/data/check/flex_NodeDensity.str b/v2.5/generators/nlojet++/interface/data/check/flex_NodeDensity.str new file mode 100644 index 0000000000000000000000000000000000000000..a3eb18b3c8de0023877e00c609613f836887b5c9 --- /dev/null +++ b/v2.5/generators/nlojet++/interface/data/check/flex_NodeDensity.str @@ -0,0 +1,207 @@ +# -*-sh-*- +# ==================================================================== # +# +# A steering file for creating a fastNLO table (with NLOJet++) +# +# ==================================================================== # + +# ==================================================================== # +# +# Scenario specific settings +# +# ==================================================================== # + +# -------------------------------------------------------------------- # +# Description of scenario +# (Write each line of description in quotation marks) +# -------------------------------------------------------------------- # +ScenarioName InclusiveJets_flex +ScenarioDescription { + "d2sigma-jet_dpT_dy_[pb_GeV]" + "CMS_Collaboration" + "Inclusive_Jet_pT" + "anti-kT_R=0.5" + "CMS-PAPER-QCD-10-011, arXiv:1106.0208, Phys. Rev. Lett. 107 (2011) 132001." + "RIVET_ID=CMS_2011_S9086218/D01-x01-y01,SPIRES_ID=9086218,INSPIRE_RECORD=902309" + "THEORY_LABEL=NLOJet++" + "provided by:" + "fastNLO_2.5.0" + "If you use this table, please cite:" + " D. Britzger, T. Kluge, K. Rabbertz, F. Stober, M. Wobisch, arXiv:1109.1310" +} +PublicationUnits 12 # Unit of data cross sections (negative power of 10, e.g. 12->pb, 15->fb) + +# -------------------------------------------------------------------- # +# Global scenario settings +# -------------------------------------------------------------------- # +JetAlgo 2 # fastjet jet algorithm +# # clustering jet algos: 0 = kT, 1 = CA, 2 = anti-kT +# # cone jet algos: 10 = SISCone, 11 = CDFMidPointCone, 12 = D0RunIICone +Rjet 0.5 # Jet size parameter: Required for all jets +#OvThr 0.5 # Overlap threshold: Required for cone jets (Normally 10: 0.75; 11,12: 0.50) +# # Overall jet phase space +ptjmin 18. # Minimal jet pT (minimum set in interface to fastjet: 1 GeV) +yjmin 0.0 # Minimal jet rapidity +yjmax 3.0 # Maximal jet rapidity +# Use either rapidity or pseudorapidity but not both! If both are set, only rapidity cuts are applied. +#etajmin 0.0 # Minimal jet pseudorapidity +#etajmax 3.0 # Maximal jet pseudorapidity +#Njetmin 1 # Minimal number of jets required to be in preselected phase space +# # (Normally one, i.e. single-jet inclusive) +#obs0min x.y # +#obs0max x.y # By default these values are derived from the binning in these +#obs1min x.y # observables and are set automatically. If required the min/max +#obs1max x.y # values for each of the maximally three observables can be set +#obs2min x.y # by hand. +#obs2max x.y # + +# -------------------------------------------------------------------- # +# Observable definition, dimensioning, and normalization +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Specify, how many differential dimensions are measured. +# Number must be consistent with DimensionLabels and DimensionIsDifferential, see below +# 1 : read in 'SingleDifferentialBinning' +# 2 : read in 'DoubleDifferentialBinning' +# 3 : read in 'TripleDifferentialBinning' +# -------------------------------------------------------------------- # +LeadingOrder 2 # Number of jets for the LO process +DifferentialDimension 2 # Dimensionality of binning +DimensionLabels { # Labels (symbol and unit) for the measurement dimensions (from outer to inner "loop") + "|y|" # This defines the observables to be calculated! + "pT_[GeV]" # Implemented observables are: "|y|", "pT_[GeV]", "phi" +} +DimensionIsDifferential { # Specify for each dimension whether + 2 2 # 0 : the cross section is NOT differential, i.e. there are two bin borders, +} # but NO division (normalization) by bin width + # 1 : the cross section is point-wise differential, i.e. only one point is given + # 2 : the cross section is bin-wise differential, i.e. there are two bin borders + # and division by bin width +CalculateBinSize true # Calculate bin width from lower and upper bin boundaries +BinSizeFactor 2. # Possibility to provide additional normalization factor, e.g. of 2 for bins in |y| +#BinSize { x1 x2 x3 ... } # If 'CalculateBinSize' is 'false' provide table with bin widths 'by hand' for normalization + # + # If the calculation should not be divided by bin width, then use 'DimensionIsDifferential' equal '0' + # and set 'CalculateBinSize' 'true' for each dimension. + # +ScaleDescriptionScale1 "pT_jet_[GeV]" # This defines the scale to be used (Note: The 1st scale must always be in units of [GeV]!) +ScaleDescriptionScale2 "pT_max_[GeV]" # Specify 2nd scale name and unit (ONLY for flexible-scale tables) + # Implemented scales are: "pT_jet_[GeV]", "pT_max_[GeV]" + +# -------------------------------------------------------------------- # +# Observable binning +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Use either 'SingleDifferentialBinning' or +# 'DoubleDifferentialBinning' or +# 'TripleDifferentialBinning' +# in accord with 'DifferentialDimension' above +# -------------------------------------------------------------------- # +# Example for SingleDifferentialBinning: +#SingleDifferentialBinning { +# 7. 11. 18. 30. 50. 100. +#} + +# Example for DoubleDifferentialBinning: +DoubleDifferentialBinning {{ + 1stDimLo 1stDimUp "----- Array of bin-grid for 2nd dimension -----" + 0.0 0.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 737. 846. 1684. + 0.5 1.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 790. 1684. + 1.0 1.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 1410. + 1.5 2.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 1032. + 2.0 2.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 737. + 2.5 3.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 468. +}} + +# Example for TripleDifferentialBinning: +#TripleDifferentialBinning {{ +# 1stDimLo 1stDimUp 2ndDimLo 2ndDimUp "----- Array of bin-grid for 3rd dimension -----" +# 100. 150. -1.0 0.0 7. 11. 18. 30. 50. +# 150. 200. -1.0 0.0 7. 11. 18. 30. 50. +# 200. 400. 0.0 1.5 7. 11. 18. 30. 50. +# 400. 700. 0.0 1.5 7. 11. 18. 30. 50. +# 700. 5000. 1.5 2.5 7. 11. 18. 30. 50. +# 5000. 15000. 1.5 2.5 7. 11. 18. 30. 50. +#}} + +# ==================================================================== # +# +# Process specific and therefore at least partially theory-code +# dependent settings +# +# ==================================================================== # +CenterOfMassEnergy 7000. # Center-of-mass energy in GeV. +# Some examples from the past: 200. # RHIC +# 1800. # TeV Run I +# 1960. # TeV Run II +# 900. # LHC Injection Run +# 2360. # LHC Initial Run +# 2760. # LHC HIpp base Run +# 5020. # LHC HIpp base Run +# 7000. # LHC First Run (2010/2011) +# 8000. # LHC Second Run (2012) +# 13000. # LHC Next Run ? (2015) +# 14000. # LHC Design Run +PDF1 2212 # PDF of 1st hadron (following PDG convention). +PDF2 2212 # PDF of 2nd hadron (following PDG convention). +NPDF 2 +NPDFDim 1 + +# ==================================================================== # +# +# General fastNLO settings +# +# ==================================================================== # +#GlobalVerbosity DEBUG # Global output verbosity of fastNLO toolkit, def.=WARNING, +GlobalVerbosity INFO # Global output verbosity of fastNLO toolkit, def.=WARNING, + # (and of user scenario code if implemented). + # Possible values are: DEBUG, MANUAL, INFO, WARNING, ERROR, SILENT +OutputFilename InclusiveNJets.tab # Filename of fastNLO output table +OutputPrecision 8 # Number of decimal digits to store in output table, def.=8. +FlexibleScaleTable true # Create table fully flexible in mu_f (larger size), true, or + # table with fixed number of mu_f scale factors, def.=false. +ScaleVariationFactors { # Factorization scale variations (only needed for fixed-scale tables) + 0.5 1.0 2.0 # List of scale factors must include factor '1' +} # Scale factors will be ordered according to fastNLO convention: (1, min, ... , max) +ReadBinningFromSteering true # Specify if binning is read from this file. MUST be true for now! +IgnoreWarmupBinningCheck true # Ignore crosscheck of binning between steering and warmup + # Avoids problems with precision of bin borders e.g. in the case of Pi +#>>fastNLO-warmup.txt # Specify alternative filename to read warm-up results from, def.=SteerFileBasename_${ScenarioName}_warmup.txt + +# ==================================================================== # +# +# Specific fastNLO settings (normally do not need to be changed) +# Only change when you know what you are doing ...! +# +# ==================================================================== # +ApplyPDFReweighting true # Apply reweighting of pdfs for an optimized interpolation, def.=true. +CheckScaleLimitsAgainstBins true # Set limits for scale nodes to bin borders, if possible + +# -------------------------------------------------------------------- # +# Choose fastNLO interpolation kernels and distance measures +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Currently implemented interpolation kernels +# Catmull +# Lagrange +# OneNode +# Linear +# +# Currently implemented distance measures +# linear +# loglog025 eq. to (log(log(4*x))) +# log10 +# sqrtlog10 eq. to sqrt(log_10(x)) +# -------------------------------------------------------------------- # +X_Kernel Lagrange +X_DistanceMeasure "sqrtlog10" +X_NNodes 4 +X_NoOfNodesPerMagnitude false +X_NNodeCounting "NodeDensity" + +Mu1_Kernel Lagrange +Mu1_DistanceMeasure "loglog025" +Mu1_NNodes 6 +Mu1_NNodeCounting "NodesPerDim2" + +Mu2_Kernel Lagrange # Scale2 not used for fixed-scale tables +Mu2_DistanceMeasure "loglog025" +Mu2_NNodes 6 +Mu2_NNodeCounting "NodesPerDim2" diff --git a/v2.5/generators/nlojet++/interface/data/check/flex_NodesPerBin.str b/v2.5/generators/nlojet++/interface/data/check/flex_NodesPerBin.str new file mode 100644 index 0000000000000000000000000000000000000000..9ec5051a957ebbc440456d0b02b1074f81e5d73a --- /dev/null +++ b/v2.5/generators/nlojet++/interface/data/check/flex_NodesPerBin.str @@ -0,0 +1,207 @@ +# -*-sh-*- +# ==================================================================== # +# +# A steering file for creating a fastNLO table (with NLOJet++) +# +# ==================================================================== # + +# ==================================================================== # +# +# Scenario specific settings +# +# ==================================================================== # + +# -------------------------------------------------------------------- # +# Description of scenario +# (Write each line of description in quotation marks) +# -------------------------------------------------------------------- # +ScenarioName InclusiveJets_flex +ScenarioDescription { + "d2sigma-jet_dpT_dy_[pb_GeV]" + "CMS_Collaboration" + "Inclusive_Jet_pT" + "anti-kT_R=0.5" + "CMS-PAPER-QCD-10-011, arXiv:1106.0208, Phys. Rev. Lett. 107 (2011) 132001." + "RIVET_ID=CMS_2011_S9086218/D01-x01-y01,SPIRES_ID=9086218,INSPIRE_RECORD=902309" + "THEORY_LABEL=NLOJet++" + "provided by:" + "fastNLO_2.5.0" + "If you use this table, please cite:" + " D. Britzger, T. Kluge, K. Rabbertz, F. Stober, M. Wobisch, arXiv:1109.1310" +} +PublicationUnits 12 # Unit of data cross sections (negative power of 10, e.g. 12->pb, 15->fb) + +# -------------------------------------------------------------------- # +# Global scenario settings +# -------------------------------------------------------------------- # +JetAlgo 2 # fastjet jet algorithm +# # clustering jet algos: 0 = kT, 1 = CA, 2 = anti-kT +# # cone jet algos: 10 = SISCone, 11 = CDFMidPointCone, 12 = D0RunIICone +Rjet 0.5 # Jet size parameter: Required for all jets +#OvThr 0.5 # Overlap threshold: Required for cone jets (Normally 10: 0.75; 11,12: 0.50) +# # Overall jet phase space +ptjmin 18. # Minimal jet pT (minimum set in interface to fastjet: 1 GeV) +yjmin 0.0 # Minimal jet rapidity +yjmax 3.0 # Maximal jet rapidity +# Use either rapidity or pseudorapidity but not both! If both are set, only rapidity cuts are applied. +#etajmin 0.0 # Minimal jet pseudorapidity +#etajmax 3.0 # Maximal jet pseudorapidity +#Njetmin 1 # Minimal number of jets required to be in preselected phase space +# # (Normally one, i.e. single-jet inclusive) +#obs0min x.y # +#obs0max x.y # By default these values are derived from the binning in these +#obs1min x.y # observables and are set automatically. If required the min/max +#obs1max x.y # values for each of the maximally three observables can be set +#obs2min x.y # by hand. +#obs2max x.y # + +# -------------------------------------------------------------------- # +# Observable definition, dimensioning, and normalization +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Specify, how many differential dimensions are measured. +# Number must be consistent with DimensionLabels and DimensionIsDifferential, see below +# 1 : read in 'SingleDifferentialBinning' +# 2 : read in 'DoubleDifferentialBinning' +# 3 : read in 'TripleDifferentialBinning' +# -------------------------------------------------------------------- # +LeadingOrder 2 # Number of jets for the LO process +DifferentialDimension 2 # Dimensionality of binning +DimensionLabels { # Labels (symbol and unit) for the measurement dimensions (from outer to inner "loop") + "|y|" # This defines the observables to be calculated! + "pT_[GeV]" # Implemented observables are: "|y|", "pT_[GeV]", "phi" +} +DimensionIsDifferential { # Specify for each dimension whether + 2 2 # 0 : the cross section is NOT differential, i.e. there are two bin borders, +} # but NO division (normalization) by bin width + # 1 : the cross section is point-wise differential, i.e. only one point is given + # 2 : the cross section is bin-wise differential, i.e. there are two bin borders + # and division by bin width +CalculateBinSize true # Calculate bin width from lower and upper bin boundaries +BinSizeFactor 2. # Possibility to provide additional normalization factor, e.g. of 2 for bins in |y| +#BinSize { x1 x2 x3 ... } # If 'CalculateBinSize' is 'false' provide table with bin widths 'by hand' for normalization + # + # If the calculation should not be divided by bin width, then use 'DimensionIsDifferential' equal '0' + # and set 'CalculateBinSize' 'true' for each dimension. + # +ScaleDescriptionScale1 "pT_jet_[GeV]" # This defines the scale to be used (Note: The 1st scale must always be in units of [GeV]!) +ScaleDescriptionScale2 "pT_max_[GeV]" # Specify 2nd scale name and unit (ONLY for flexible-scale tables) + # Implemented scales are: "pT_jet_[GeV]", "pT_max_[GeV]" + +# -------------------------------------------------------------------- # +# Observable binning +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Use either 'SingleDifferentialBinning' or +# 'DoubleDifferentialBinning' or +# 'TripleDifferentialBinning' +# in accord with 'DifferentialDimension' above +# -------------------------------------------------------------------- # +# Example for SingleDifferentialBinning: +#SingleDifferentialBinning { +# 7. 11. 18. 30. 50. 100. +#} + +# Example for DoubleDifferentialBinning: +DoubleDifferentialBinning {{ + 1stDimLo 1stDimUp "----- Array of bin-grid for 2nd dimension -----" + 0.0 0.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 737. 846. 1684. + 0.5 1.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 790. 1684. + 1.0 1.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 592. 638. 686. 1410. + 1.5 2.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 468. 507. 548. 1032. + 2.0 2.5 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 330. 362. 395. 430. 737. + 2.5 3.0 18. 21. 24. 28. 32. 37. 43. 49. 56. 64. 74. 84. 97. 114. 133. 153. 174. 196. 220. 245. 272. 300. 468. +}} + +# Example for TripleDifferentialBinning: +#TripleDifferentialBinning {{ +# 1stDimLo 1stDimUp 2ndDimLo 2ndDimUp "----- Array of bin-grid for 3rd dimension -----" +# 100. 150. -1.0 0.0 7. 11. 18. 30. 50. +# 150. 200. -1.0 0.0 7. 11. 18. 30. 50. +# 200. 400. 0.0 1.5 7. 11. 18. 30. 50. +# 400. 700. 0.0 1.5 7. 11. 18. 30. 50. +# 700. 5000. 1.5 2.5 7. 11. 18. 30. 50. +# 5000. 15000. 1.5 2.5 7. 11. 18. 30. 50. +#}} + +# ==================================================================== # +# +# Process specific and therefore at least partially theory-code +# dependent settings +# +# ==================================================================== # +CenterOfMassEnergy 7000. # Center-of-mass energy in GeV. +# Some examples from the past: 200. # RHIC +# 1800. # TeV Run I +# 1960. # TeV Run II +# 900. # LHC Injection Run +# 2360. # LHC Initial Run +# 2760. # LHC HIpp base Run +# 5020. # LHC HIpp base Run +# 7000. # LHC First Run (2010/2011) +# 8000. # LHC Second Run (2012) +# 13000. # LHC Next Run ? (2015) +# 14000. # LHC Design Run +PDF1 2212 # PDF of 1st hadron (following PDG convention). +PDF2 2212 # PDF of 2nd hadron (following PDG convention). +NPDF 2 +NPDFDim 1 + +# ==================================================================== # +# +# General fastNLO settings +# +# ==================================================================== # +#GlobalVerbosity DEBUG # Global output verbosity of fastNLO toolkit, def.=WARNING, +GlobalVerbosity INFO # Global output verbosity of fastNLO toolkit, def.=WARNING, + # (and of user scenario code if implemented). + # Possible values are: DEBUG, MANUAL, INFO, WARNING, ERROR, SILENT +OutputFilename InclusiveNJets.tab # Filename of fastNLO output table +OutputPrecision 8 # Number of decimal digits to store in output table, def.=8. +FlexibleScaleTable true # Create table fully flexible in mu_f (larger size), true, or + # table with fixed number of mu_f scale factors, def.=false. +ScaleVariationFactors { # Factorization scale variations (only needed for fixed-scale tables) + 0.5 1.0 2.0 # List of scale factors must include factor '1' +} # Scale factors will be ordered according to fastNLO convention: (1, min, ... , max) +ReadBinningFromSteering true # Specify if binning is read from this file. MUST be true for now! +IgnoreWarmupBinningCheck true # Ignore crosscheck of binning between steering and warmup + # Avoids problems with precision of bin borders e.g. in the case of Pi +#>>fastNLO-warmup.txt # Specify alternative filename to read warm-up results from, def.=SteerFileBasename_${ScenarioName}_warmup.txt + +# ==================================================================== # +# +# Specific fastNLO settings (normally do not need to be changed) +# Only change when you know what you are doing ...! +# +# ==================================================================== # +ApplyPDFReweighting true # Apply reweighting of pdfs for an optimized interpolation, def.=true. +CheckScaleLimitsAgainstBins true # Set limits for scale nodes to bin borders, if possible + +# -------------------------------------------------------------------- # +# Choose fastNLO interpolation kernels and distance measures +# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +# Currently implemented interpolation kernels +# Catmull +# Lagrange +# OneNode +# Linear +# +# Currently implemented distance measures +# linear +# loglog025 eq. to (log(log(4*x))) +# log10 +# sqrtlog10 eq. to sqrt(log_10(x)) +# -------------------------------------------------------------------- # +X_Kernel Lagrange +X_DistanceMeasure "sqrtlog10" +X_NNodes 12 +X_NoOfNodesPerMagnitude false +X_NNodeCounting "NodesPerBin" + +Mu1_Kernel Lagrange +Mu1_DistanceMeasure "loglog025" +Mu1_NNodes 6 +Mu1_NNodeCounting "NodesPerBin" + +Mu2_Kernel Lagrange # Scale2 not used for fixed-scale tables +Mu2_DistanceMeasure "loglog025" +Mu2_NNodes 6 +Mu2_NNodeCounting "NodesPerBin" diff --git a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc index e1eb191a98e7f7d5568bc54bd53639379afe0ce1..108c4e1fee6f99208e5ff2e34af8ceda3e2168c6 100644 --- a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc +++ b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc @@ -142,7 +142,7 @@ private: double obs2[3]; vector<string> ScaleLabel; // Scale labels (Scale1: must be defined; Scale2: only for flex-scale tables) // enum to switch between implemented scale definitions (max. of 2 simultaneously) - enum Scales { PTMAX, PTJETMIN, PTJETAVE, PTJETMAX }; + enum Scales { PTMAX, PTJETMIN, PTJETAVE, PTJETMAX, HTP, HTPHALF }; Scales mudef[2]; double mu[2]; int jetalgo; // Define 1st fastjet jet algorithm (no default, must be defined) @@ -181,6 +181,11 @@ struct fNLOSorter { bool operator() (const lorentzvector<double> &a, const lorentzvector<double> &b) {return (a.perp() > b.perp());}; }; +// sign function returning -1, 0, 1 +template <typename T> int sgn(T val) { + return (T(0) < val) - (val < T(0)); +} + // --- fastNLO user: check and get steering parameters once and store into static vars static std::map < std::string, bool > SteeringPars; @@ -247,34 +252,38 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l } } // scale descriptions - string label; SteeringPars["ScaleDescriptionScale1"] = ftable->TestParameterInSteering("ScaleDescriptionScale1"); + ScaleLabel.resize(2); if ( SteeringPars["ScaleDescriptionScale1"] ) { - ftable->GetParameterFromSteering("ScaleDescriptionScale1",label); - ScaleLabel.push_back(label); + ftable->GetParameterFromSteering("ScaleDescriptionScale1",ScaleLabel[0]); } else { say::error["ScenarioCode"] << "No description of scale 1, aborted!" << endl; exit(1); } SteeringPars["ScaleDescriptionScale2"] = ftable->TestParameterInSteering("ScaleDescriptionScale2"); + ScaleLabel[1] = "pT_max_[GeV]"; // default if ( SteeringPars["ScaleDescriptionScale2"] ) { - ftable->GetParameterFromSteering("ScaleDescriptionScale2",label); - ScaleLabel.push_back(label); + ftable->GetParameterFromSteering("ScaleDescriptionScale2",ScaleLabel[1]); + } else { + ScaleLabel[1] = "-"; + say::warn["ScenarioCode"] << "No description of scale 2, flexible-scale tables not possible!" << endl; } // scale descriptions define the scales - lptmax = true; + lptmax = false; for ( unsigned int i = 0; i < ScaleLabel.size(); i++ ) { if ( ScaleLabel[i] == "pT_max_[GeV]" ) { mudef[i] = PTMAX; + lptmax = true; } else if ( ScaleLabel[i] == "pT_jet_min_[GeV]" ) { mudef[i] = PTJETMIN; - lptmax = false; } else if ( ScaleLabel[i] == "pT_jet_ave_[GeV]" ) { mudef[i] = PTJETAVE; - lptmax = false; } else if ( ScaleLabel[i] == "pT_jet_max_[GeV]" ) { mudef[i] = PTJETMAX; - lptmax = false; + } else if ( ScaleLabel[i] == "HT_part_[GeV]" ) { + mudef[i] = HTP; + } else if ( ScaleLabel[i] == "HT_part/2_[GeV]" ) { + mudef[i] = HTPHALF; } else { say::error["ScenarioCode"] << "Unknown scale, i.e. scale description, aborted!" << endl; say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; @@ -283,7 +292,7 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l } } - // definition of default jet algorithm and jet phase space limits (no defaults) + // definition of jet algorithm and jet phase space limits (no defaults) // // --- fastNLO user: set the jet algorithm and size via steering file // fastjet clustering jet algos: 0 = kT, 1 = CA, 2 = anti-kT @@ -471,6 +480,17 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // Usually, pT and E are in GeV, but this may be changed. // ATTENTION: Scales must always be in GeV! + // derive partonic HT scale + double htp = 0.; + unsigned int np = p.upper(); + for (unsigned int i = 1; i <= np; i++) { + htp += p[i].perp(); + // --- debug output + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "partonic HT: parton # i, pt, htp: " << i << ", " << p[i].perp() << ", " << htp << endl; + } + } + // apply the jet algorithm(s) to partonic 4-vector array p of NLOJet++ pj = jetclusfj(p); pj2 = pj; @@ -733,6 +753,15 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // cout << "MAX iPair.first = " << iPair.first << ", sclmin = " << sclmin[iPair.first] <<", sclave = " << sclave[iPair.first]/acount[iPair.first] << ", sclmax = " << sclmax[iPair.first] << endl;} mu[i] = sclmax[iPair.first]; break; + case HTP : + // partonic sum pT + mu[i] = htp; + say::debug["ScenarioCode"] << "HTP scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; + case HTPHALF : + // half partonic sum pT + mu[i] = htp/2.; + say::debug["ScenarioCode"] << "HTPHALF scale values: " << i << " : mu[i] = " << mu[i] << endl; default : say::error["ScenarioCode"] << "Scale not yet implemented, aborted!" << endl; say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; diff --git a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc index 725d49c64773c553d1553df3608f7cd21adb3c93..607f1424b4e5a788ae81136f5b599272d0ff9bca 100644 --- a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc +++ b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetEvents.cc @@ -55,6 +55,8 @@ void inputfunc(unsigned int&, unsigned int&, unsigned int&); void psinput(phasespace_hhc *, double&); // --- fastNLO v2.2: interface to NLOJet++: user class user_base_hhc * userfunc(); +// --- dphi +double dphi(double phi2, double phi1); //----- array of the symbols symbols ----- extern "C"{ @@ -132,13 +134,13 @@ private: int NDim; // Dimensionality of distributions (no default, must be defined) vector<string> DimLabel; // Dimension labels (no default, must be defined) // enum to switch between implemented observables (max. of 3 simultaneously) - enum Obs { YMAX, YSTAR, Y1ABSRAP, Y2SIGN, MJJGEV, MJJTEV, PT12GEV, CHIJJ, HTHALFGEV, PTMAXGEV, DPHI12 }; + enum Obs { YMAX, YSTAR, Y1ABSRAP, Y2SIGN, MJJGEV, MJJTEV, PT12GEV, CHIJJ, HTGEV, HTHALFGEV, PTMAXGEV, DPHI12 }; Obs obsdef[3]; double obs[3]; vector<string> ScaleLabel; // Scale labels (Scale1: no default, must be defined; Scale2: default is "pT_max_[GeV]") // enum to switch between implemented scale definitions (max. of 2 simultaneously) // (Njet > 1!) - enum Scales { PTMAX, PT12AVE, PT123AVE, MJJHALF, PTMAXEXPYSTAR, EXPYSTAR, HTHALF }; + enum Scales { PTMAX, PT12AVE, PT123AVE, MJJHALF, PTMAXEXPYSTAR, EXPYSTAR, HT, HTHALF, HTP, HTPHALF }; Scales mudef[2]; double mu[2]; int jetalgo; // Define fastjet jet algorithm (no default, must be defined) @@ -249,6 +251,8 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l obsdef[i] = PT12GEV; } else if ( DimLabel[i] == "Chi" ) { obsdef[i] = CHIJJ; + } else if ( DimLabel[i] == "HT_[GeV]" ) { + obsdef[i] = HTGEV; } else if ( DimLabel[i] == "HT/2_[GeV]" ) { obsdef[i] = HTHALFGEV; } else if ( DimLabel[i] == "pT_max_[GeV]" ) { @@ -280,7 +284,7 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l say::warn["ScenarioCode"] << "No description of scale 2, flexible-scale tables not possible!" << endl; } // scale descriptions define the scales - for ( unsigned int i = 0; i < 2; i++ ) { + for ( unsigned int i = 0; i < ScaleLabel.size(); i++ ) { if ( ScaleLabel[i] == "pT_max_[GeV]" ) { mudef[i] = PTMAX; } else if ( ScaleLabel[i] == "<pT_1,2>_[GeV]" ) { @@ -293,8 +297,14 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l mudef[i] = PTMAXEXPYSTAR; } else if ( ScaleLabel[i] == "exp(0.3*y_star)" ) { mudef[i] = EXPYSTAR; + } else if ( ScaleLabel[i] == "HT_[GeV]" ) { + mudef[i] = HT; } else if ( ScaleLabel[i] == "HT/2_[GeV]" ) { mudef[i] = HTHALF; + } else if ( ScaleLabel[i] == "HT_part_[GeV]" ) { + mudef[i] = HTP; + } else if ( ScaleLabel[i] == "HT_part/2_[GeV]" ) { + mudef[i] = HTPHALF; } else { say::error["ScenarioCode"] << "Unknown scale, i.e. scale description, aborted!" << endl; say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; @@ -494,6 +504,17 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // Usually, pT and E are in GeV, but this may be changed. // ATTENTION: Scales must always be in GeV! + // derive partonic HT scale + double htp = 0.; + unsigned int np = p.upper(); + for (unsigned int i = 1; i <= np; i++) { + htp += p[i].perp(); + // --- debug output + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "partonic HT: parton # i, pt, htp: " << i << ", " << p[i].perp() << ", " << htp << endl; + } + } + // apply the jet algorithm to partonic 4-vector array p of NLOJet++ pj = jetclusfj(p); unsigned int nj = pj.upper(); @@ -574,11 +595,11 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // no. of central jets, pT of third central jet, and HT of central jets (i.e. inside ycjjmax) int Ncjet = 0; // double pT3c = 0; - double HT2 = 0.; + double ht = 0.; for (unsigned int k = 1; k <= njet; k++) { if ( abs(pj[k].rapidity()) < ycjjmax ) { Ncjet++; - HT2 += pj[k].perp()/2.; + ht += pj[k].perp(); } // if ( Ncjet == 3 ) {pT3c = pj[k].perp();} } @@ -618,9 +639,13 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // dijet chi obs[i] = exp(abs(y1-y2)); break; + case HTGEV : + // jet pT sum + obs[i] = ht; + break; case HTHALFGEV : // half of jet pT sum - obs[i] = HT2; + obs[i] = ht/2.; break; case PTMAXGEV : // leading jet pT @@ -701,9 +726,23 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // ATLAS definition, this works only as second scale choice! mu[i] = exp(0.3*ystar); break; + case HT : + // jet pT sum (must be in GeV!) + mu[i] = ht; + break; case HTHALF : // half of jet pT sum (must be in GeV!) - mu[i] = HT2; + mu[i] = ht/2.; + break; + case HTP : + // partonic sum pT + mu[i] = htp; + say::debug["ScenarioCode"] << "HTP scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; + case HTPHALF : + // half partonic sum pT + mu[i] = htp/2.; + say::debug["ScenarioCode"] << "HTPHALF scale values: " << i << " : mu[i] = " << mu[i] << endl; break; default : say::error["ScenarioCode"] << "Scale not yet implemented, aborted!" << endl; @@ -744,14 +783,12 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { } else { // --- event rejected if ( say::debug.GetSpeak() ) { - say::debug["ScenarioCode"] << "----------------- Event/jet rejected! ------------------" << endl; + say::debug["ScenarioCode"] << "----------------- Event rejected! ------------------" << endl; say::debug["ScenarioCode"] << "==================== End of event ====================" << endl; } } } - - //------ DON'T TOUCH THIS PART! ------ // --- fastNLO v2.2: interface to NLOJet++: read steering file, set LO of selected process @@ -833,6 +870,19 @@ void InitfNLO(const std::basic_string<char>& __file_name) { // --- set fastNLO filename according to NLOJet++ command line arguments string tabFilename = __file_name.c_str(); tabFilename += ".tab"; + +#ifdef HAVE_ZLIB + bool lgzip = true; +#else + bool lgzip = false; +#endif + + if ( SteeringPars["OutputCompression"] ) { + ftable->GetParameterFromSteering("OutputCompression",lgzip); + } + // string filename = fScenConsts.OutputFilename; + // if ( lgzip ) tabFilename += ".gz"; + tabFilename += ".gz"; ftable->SetFilename(tabFilename); } @@ -860,3 +910,14 @@ void UserHHC::end_of_event() { } } } + +// --- define function for azimuthal angular distance in [-Pi,Pi] +double dphi(double phi2, double phi1) { + double delta_phi = phi2-phi1; + if (delta_phi > M_PI) { + delta_phi -= 2*M_PI; + } else if (delta_phi < -M_PI) { + delta_phi += 2*M_PI; + } + return delta_phi; +} diff --git a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc index c04c1330809b2cdb58e6f2c1ae0561a9a364cb40..9fe3caff430909f3d0510da2b7fe3cb558cf1bf4 100644 --- a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc +++ b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJetPairs.cc @@ -1,5 +1,5 @@ // -// fastNLO v2.2 creator code for inclusive N jet pairs scenarios +// fastNLO v2.2 creator code for inclusive N jet-pairs scenarios // // ============== fastNLO user: ======================================== // To create your own scenario, it is recommended to take this @@ -139,7 +139,8 @@ private: double obs[3]; vector<string> ScaleLabel; // Scale labels (Scale1: no default, must be defined; Scale2: default is "pT_max_[GeV]") // enum to switch between implemented scale definitions (max. of 2 simultaneously) - enum Scales { PTMAX, PTJET }; + // (Njet > 1!) + enum Scales { PTMAX, PTJET, HTP, HTPHALF }; Scales mudef[2]; double mu[2]; int jetalgo; // Define fastjet jet algorithm (no default, must be defined) @@ -154,7 +155,7 @@ private: double djlkmax; // Maximal distance of neighbouring jet (default is +DBL_MAX) bool ldphi; // Switch to use jet distance dphi/true or dR/false (default is true) bool lunique; // Switch between unique entry per jet pair (true) or multiple ones (false) (default is false) - int Njetmin; // Minimal number of jets in phase space (default is 1) + int Njetmin; // Minimal number of jets in phase space (default is 2) double obsmin[3]; // Minimum in observable in nth dimension (default derived from binning) double obsmax[3]; // Maximum in observable in nth dimension (default derived from binning) }; @@ -177,6 +178,11 @@ struct fNLOSorter { bool operator() (const lorentzvector<double> &a, const lorentzvector<double> &b) {return (a.perp() > b.perp());}; }; +// sign function returning -1, 0, 1 +template <typename T> int sgn(T val) { + return (T(0) < val) - (val < T(0)); +} + // --- fastNLO user: check and get steering parameters once and store into static vars static std::map < std::string, bool > SteeringPars; @@ -260,11 +266,15 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l say::warn["ScenarioCode"] << "No description of scale 2, flexible-scale tables not possible!" << endl; } // scale descriptions define the scales - for ( unsigned int i = 0; i < 2; i++ ) { + for ( unsigned int i = 0; i < ScaleLabel.size(); i++ ) { if ( ScaleLabel[i] == "pT_max_[GeV]" ) { mudef[i] = PTMAX; } else if ( ScaleLabel[i] == "pT_jet_[GeV]" ) { mudef[i] = PTJET; + } else if ( ScaleLabel[i] == "HT_part_[GeV]" ) { + mudef[i] = HTP; + } else if ( ScaleLabel[i] == "HT_part/2_[GeV]" ) { + mudef[i] = HTPHALF; } else { say::error["ScenarioCode"] << "Unknown scale, i.e. scale description, aborted!" << endl; say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; @@ -351,14 +361,14 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l say::error["ScenarioCode"] << "If you really want to mix, the code needs to be adapted." << endl; exit(1); } - // minimal number of jets required to be within preselected jet phase space (for inclusive jets this must be one!) + // minimal number of jets required to be within preselected jet phase space (for jet pairs this must be two!) SteeringPars["Njetmin"] = ftable->TestParameterInSteering("Njetmin"); - Njetmin = 1; + Njetmin = 2; if ( SteeringPars["Njetmin"] ) { ftable->GetParameterFromSteering("Njetmin",Njetmin); } - if ( Njetmin < 1 ) { - say::error["ScenarioCode"] << "This is a 1+-jet scenario. At least one jet must be present, aborted!" << endl; + if ( Njetmin < 2 ) { + say::error["ScenarioCode"] << "This is a 2+-jet scenario. At least two jets must be present, aborted!" << endl; say::error["ScenarioCode"] << "Please correct the Njetmin requirement. Njetmin = " << Njetmin << endl; exit(1); } @@ -457,6 +467,17 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // Usually, pT and E are in GeV, but this may be changed. // ATTENTION: Scales must always be in GeV! + // derive partonic HT scale + double htp = 0.; + unsigned int np = p.upper(); + for (unsigned int i = 1; i <= np; i++) { + htp += p[i].perp(); + // --- debug output + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "partonic HT: parton # i, pt, htp: " << i << ", " << p[i].perp() << ", " << htp << endl; + } + } + // apply the jet algorithm to partonic 4-vector array p of NLOJet++ pj = jetclusfj(p); unsigned int nj = pj.upper(); @@ -559,6 +580,16 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // jet pT mu[i] = pj[k].perp(); break; + case HTP : + // partonic sum pT + mu[i] = htp; + say::debug["ScenarioCode"] << "HTP scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; + case HTPHALF : + // half partonic sum pT + mu[i] = htp/2.; + say::debug["ScenarioCode"] << "HTPHALF scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; default : say::error["ScenarioCode"] << "Scale not yet implemented, aborted!" << endl; say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; @@ -640,7 +671,7 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { ftable->FillAllSubprocesses(contribsfix,scen); } } else { - // --- jet-pair observable rejected + // --- jet pair rejected if ( say::debug.GetSpeak() ) { say::debug["ScenarioCode"] << "----------------- Jet-pair observable rejected! ------------------" << endl; } diff --git a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets.cc b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets.cc index 6f361e2d5d3c8092db05e794ed6601b352ce98c0..2db3cc9d67d09b655a58a16ee97906744692b2da 100644 --- a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets.cc +++ b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets.cc @@ -55,6 +55,8 @@ void inputfunc(unsigned int&, unsigned int&, unsigned int&); void psinput(phasespace_hhc *, double&); // --- fastNLO v2.2: interface to NLOJet++: user class user_base_hhc * userfunc(); +// --- dphi +double dphi(double phi2, double phi1); //----- array of the symbols symbols ----- extern "C"{ @@ -137,7 +139,7 @@ private: double obs[3]; vector<string> ScaleLabel; // Scale labels (Scale1: no default, must be defined; Scale2: default is "pT_max_[GeV]") // enum to switch between implemented scale definitions (max. of 2 simultaneously) - enum Scales { PTMAX, PTJET }; + enum Scales { PTMAX, PTJET, HTP, HTPHALF }; Scales mudef[2]; double mu[2]; int jetalgo; // Define fastjet jet algorithm (no default, must be defined) @@ -170,6 +172,11 @@ struct fNLOSorter { bool operator() (const lorentzvector<double> &a, const lorentzvector<double> &b) {return (a.perp() > b.perp());}; }; +// sign function returning -1, 0, 1 +template <typename T> int sgn(T val) { + return (T(0) < val) - (val < T(0)); +} + // --- fastNLO user: check and get steering parameters once and store into static vars static std::map < std::string, bool > SteeringPars; @@ -253,11 +260,15 @@ void UserHHC::phys_output(const std::basic_string<char>& __file_name, unsigned l say::warn["ScenarioCode"] << "No description of scale 2, flexible-scale tables not possible!" << endl; } // scale descriptions define the scales - for ( unsigned int i = 0; i < 2; i++ ) { + for ( unsigned int i = 0; i < ScaleLabel.size(); i++ ) { if ( ScaleLabel[i] == "pT_max_[GeV]" ) { mudef[i] = PTMAX; } else if ( ScaleLabel[i] == "pT_jet_[GeV]" ) { mudef[i] = PTJET; + } else if ( ScaleLabel[i] == "HT_part_[GeV]" ) { + mudef[i] = HTP; + } else if ( ScaleLabel[i] == "HT_part/2_[GeV]" ) { + mudef[i] = HTPHALF; } else { say::error["ScenarioCode"] << "Unknown scale, i.e. scale description, aborted!" << endl; say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; @@ -415,6 +426,17 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // Usually, pT and E are in GeV, but this may be changed. // ATTENTION: Scales must always be in GeV! + // derive partonic HT scale + double htp = 0.; + unsigned int np = p.upper(); + for (unsigned int i = 1; i <= np; i++) { + htp += p[i].perp(); + // --- debug output + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "partonic HT: parton # i, pt, htp: " << i << ", " << p[i].perp() << ", " << htp << endl; + } + } + // apply the jet algorithm to partonic 4-vector array p of NLOJet++ pj = jetclusfj(p); unsigned int nj = pj.upper(); @@ -477,16 +499,6 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { double ptmax = pj[1].perp(); for (unsigned int k = 1; k <= njet; k++) { - // derive some jet quantities - // double pt = pj[k].perp(); - // double yeta; - // if ( ! lpseudo ) { - // yeta = abs(pj[k].rapidity()); - // } else { - // yeta = abs(pj[k].prapidity()); - // } - // double phi = atan2(pj[k].Y(), pj[k].X()); - // --- calculate observable of nth dimension for ( int i = 0; i<NDim; i++ ) { switch(obsdef[i]) { @@ -545,6 +557,16 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { // jet pT mu[i] = pj[k].perp(); break; + case HTP : + // partonic sum pT + mu[i] = htp; + say::debug["ScenarioCode"] << "HTP scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; + case HTPHALF : + // half partonic sum pT + mu[i] = htp/2.; + say::debug["ScenarioCode"] << "HTPHALF scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; default : say::error["ScenarioCode"] << "Scale not yet implemented, aborted!" << endl; say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; @@ -591,8 +613,6 @@ void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { } } - - //------ DON'T TOUCH THIS PART! ------ // --- fastNLO v2.2: interface to NLOJet++: read steering file, set LO of selected process @@ -714,3 +734,14 @@ void UserHHC::end_of_event() { } } } + +// --- define function for azimuthal angular distance in [-Pi,Pi] +double dphi(double phi2, double phi1) { + double delta_phi = phi2-phi1; + if (delta_phi > M_PI) { + delta_phi -= 2*M_PI; + } else if (delta_phi < -M_PI) { + delta_phi += 2*M_PI; + } + return delta_phi; +} diff --git a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets_new.cc b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets_new.cc index e242f1cd02cfb3c2e2dda6b96938b9017e36eb81..f12c9a2562abbf4fd1f76ed785ae878f4e19e272 100644 --- a/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets_new.cc +++ b/v2.5/generators/nlojet++/interface/hadron/InclusiveNJets_new.cc @@ -59,446 +59,503 @@ using namespace std; // --- fastNLO v2.2: define user class to be used with NLOJet++ class UserHHC : public FastNLOUserHHC { public: - // --- fastNLO user: evaluate steering file and define physics output (called once before first event) - virtual void read_steering(); - // --- fastNLO user: analyze parton event (called once for each event) - virtual void userfunc(const event_hhc&, const amplitude_hhc&); + // --- fastNLO user: evaluate steering file and define physics output (called once before first event) + virtual void read_steering(); + // --- fastNLO user: analyze parton event (called once for each event) + virtual void userfunc(const event_hhc&, const amplitude_hhc&); private: - // --- fastNLO user: define the jet algorithm (for the choice of included header file above) - fastjet_jets jetclusfj; - - // --- define the jet structure - bounded_vector<lorentzvector<double> > pj; - - // --- fastNLO steering - bool lFlexibleScaleTable; // Fill fixed- or flexible-scale table - int NDim; // Dimensionality of distributions - vector<string> DimLabel; // Dimension labels - // enum to switch between implemented observables (max. of 3 simultaneously) - enum Obs { PTJETGEV, - YJET, - PHIJET }; - Obs obsdef[3]; - double obs[3]; - vector<string> ScaleLabel; // Scale labels - // enum to switch between implemented scale definitions (max. of 2 simultaneously) - // (Njet > 1!) - enum Scales { PTMAX, - PTJET }; - Scales mudef[2]; - double mu[2]; - int jetalgo; // Define fastjet jet algorithm - double jetsize; // Define jet size R - double overlapthreshold; // Define overlap threshold (for some jet algorithms) - double ptjmin; // Minimal jet pT (should be >= minimum of 1 GeV specified in interface to fastjet) - double yetajmin; // Minimal jet (pseudo-)rapidity - double yetajmax; // Maximal jet (pseudo-)rapidity - bool lpseudo; // Switch to use either jet rapidity y or jet eta - int Njetmin; // Minimal number of jets in phase space - double obsmin[3]; // Minimum in observable in nth dimension (default derived from binning) - double obsmax[3]; // Maximum in observable in nth dimension (default derived from binning) + // --- fastNLO user: define the jet algorithm (for the choice of included header file above) + fastjet_jets jetclusfj; + + // --- define the jet structure + bounded_vector<lorentzvector<double> > pj; + + // --- fastNLO steering + bool lFlexibleScaleTable; // Fill fixed- or flexible-scale table (default is fixed-scale) + int NDim; // Dimensionality of distributions (no default, must be defined) + vector<string> DimLabel; // Dimension labels (no default, must be defined) + // enum to switch between implemented observables (max. of 3 simultaneously) + enum Obs { PTJETGEV, YJET, ETAJET, PHIJET }; + Obs obsdef[3]; + double obs[3]; + vector<string> ScaleLabel; // Scale labels (Scale1: no default, must be defined; Scale2: default is "pT_max_[GeV]") + // enum to switch between implemented scale definitions (max. of 2 simultaneously) + enum Scales { PTMAX, PTJET, HTP, HTPHALF }; + Scales mudef[2]; + double mu[2]; + int jetalgo; // Define fastjet jet algorithm (no default, must be defined) + double jetsize; // Define jet size R (no default, must be defined) + double overlapthreshold; // Define overlap threshold (default is 0.5) + double ptjmin; // Minimal jet pT (no default, must be defined; should be >= minimum of 1 GeV specified in interface to fastjet) + double yetajmin; // Minimal jet (pseudo-)rapidity (no default, must be defined) + double yetajmax; // Maximal jet (pseudo-)rapidity (no default, must be defined) + bool lpseudo; // Switch to use either jet rapidity y or jet eta + int Njetmin; // Minimal number of jets in phase space (default is 1) + double obsmin[3]; // Minimum in observable in nth dimension (default derived from binning) + double obsmax[3]; // Maximum in observable in nth dimension (default derived from binning) }; // --- fastNLO user: modify the jet selection in UserHHC::userfunc (default = cutting in |y| min, |y| max and pt min) // (the return value must be true for jets to be UNselected) struct fNLOSelector { - fNLOSelector(double ymin, double ymax, double ptmin, bool pseudo = false) - : _ymin(ymin) - , _ymax(ymax) - , _ptmin(ptmin) - , _pseudo(pseudo){}; - double _ymin, _ymax, _ptmin; - bool _pseudo; - bool operator()(const lorentzvector<double>& a) - { - if (!_pseudo) - return !(_ymin <= abs(a.rapidity()) && abs(a.rapidity()) < _ymax && _ptmin <= a.perp()); - else - return !(_ymin <= abs(a.prapidity()) && abs(a.prapidity()) < _ymax && _ptmin <= a.perp()); - }; + fNLOSelector(double ymin, double ymax, double ptmin, bool pseudo=false): + _ymin (ymin), _ymax (ymax), _ptmin (ptmin), _pseudo (pseudo){}; + double _ymin, _ymax, _ptmin; + bool _pseudo; + bool operator() (const lorentzvector<double> &a) { + if (!_pseudo) return ! (_ymin <= abs(a.rapidity()) && abs(a.rapidity()) < _ymax && _ptmin <= a.perp()); + else return ! (_ymin <= abs(a.prapidity()) && abs(a.prapidity()) < _ymax && _ptmin <= a.perp()); + }; }; FastNLOUserHHC* FastNLOUserHHC::instance = new UserHHC; // --- fastNLO user: modify the jet sorting in UserHHC::userfunc (default = descending in jet pt) struct fNLOSorter { - bool operator()(const lorentzvector<double>& a, const lorentzvector<double>& b) { return (a.perp() > b.perp()); }; + bool operator() (const lorentzvector<double> &a, const lorentzvector<double> &b) {return (a.perp() > b.perp());}; }; +// sign function returning -1, 0, 1 +template <typename T> int sgn(T val) { + return (T(0) < val) - (val < T(0)); +} + // --- fastNLO user: check and get steering parameters once and store into static vars -static std::map<std::string, bool> SteeringPars; +static std::map < std::string, bool > SteeringPars; // --- fastNLO user: class UserHHC: evaluate steering file and define physics output (called once before first event) void UserHHC::read_steering() { - // --- fastNLO user: - // Here is your playground where you can evaluate the steering file settings. - // ATTENTION: Some settings are mandatory for the correct functioning! - - // get general steering parameters needed here from steering file - say::debug["UserHHC::phys_output"] << "Evaluating steering parameters ..." << endl; - // fixed- or flexible-scale table - SteeringPars["FlexibleScaleTable"] = ftable->TestParameterInSteering("FlexibleScaleTable"); - lFlexibleScaleTable = false; // default - if (SteeringPars["FlexibleScaleTable"]) { - ftable->GetParameterFromSteering("FlexibleScaleTable", lFlexibleScaleTable); - } - // dimensionality - SteeringPars["DifferentialDimension"] = ftable->TestParameterInSteering("DifferentialDimension"); - if (SteeringPars["DifferentialDimension"]) { - ftable->GetParameterFromSteering("DifferentialDimension", NDim); - } else { - say::error["ScenarioCode"] << "Dimensioning of binning not set, aborted!" << endl; - exit(1); - } - if (NDim < 1 || 3 < NDim) { - say::error["ScenarioCode"] << "Only 1- to 3-dimensional binning implemented, aborted!" << endl; - say::error["ScenarioCode"] << "Please implement the requested " << NDim << "-dimensional binning." << endl; - exit(1); - } - // dimension labels - SteeringPars["DimensionLabels"] = ftable->TestParameterInSteering("DimensionLabels"); - DimLabel.resize(NDim); - if (SteeringPars["DimensionLabels"]) { - ftable->GetParameterFromSteering("DimensionLabels", DimLabel); - } else { - say::error["ScenarioCode"] << "Dimension labels not set, aborted!" << endl; - exit(1); - } - // define the observables according to the dimension labels - for (int i = 0; i < NDim; i++) { - if (DimLabel[i] == "|y|") { - obsdef[i] = YJET; - } else if (DimLabel[i] == "pT_[GeV]") { - obsdef[i] = PTJETGEV; - } else if (DimLabel[i] == "phi") { - obsdef[i] = PHIJET; - } else { - say::error["ScenarioCode"] << "Unknown observable, i.e. dimension label, aborted!" << endl; - say::error["ScenarioCode"] << "DimLabel[" << i << "] = " << DimLabel[i] << endl; - say::error["ScenarioCode"] << "Please complement this scenario to include the requested observable." << endl; - exit(1); - } - } - // scale descriptions - SteeringPars["ScaleDescriptionScale1"] = ftable->TestParameterInSteering("ScaleDescriptionScale1"); - ScaleLabel.resize(2); - if (SteeringPars["ScaleDescriptionScale1"]) { - ftable->GetParameterFromSteering("ScaleDescriptionScale1", ScaleLabel[0]); - } else { - say::error["ScenarioCode"] << "No description of scale 1, aborted!" << endl; - exit(1); - } - SteeringPars["ScaleDescriptionScale2"] = ftable->TestParameterInSteering("ScaleDescriptionScale2"); - ScaleLabel[1] = "pT_max_[GeV]"; // default - if (SteeringPars["ScaleDescriptionScale2"]) { - ftable->GetParameterFromSteering("ScaleDescriptionScale2", ScaleLabel[1]); - } else { - ScaleLabel[1] = "-"; - say::warn["ScenarioCode"] << "No description of scale 2, flexible-scale tables not possible!" << endl; - } - // scale descriptions define the scales - for (unsigned int i = 0; i < 2; i++) { - if (ScaleLabel[i] == "pT_max_[GeV]") { - mudef[i] = PTMAX; - } else if (ScaleLabel[i] == "pT_jet_[GeV]") { - mudef[i] = PTJET; - } else { - say::error["ScenarioCode"] << "Unknown scale, i.e. scale description, aborted!" << endl; - say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; - say::error["ScenarioCode"] << "Please complement this scenario to include the requested scale." << endl; - exit(1); - } - } - - // definition of jet algorithm and jet phase space limits (no defaults) - // - // --- fastNLO user: set the jet algorithm and size via steering file - // fastjet clustering jet algos: 0 = kT, 1 = CA, 2 = anti-kT - // fastjet cone jet algos: 10 = SISCone, 11 = CDFMidPointCone, 12 = D0RunIICone - SteeringPars["JetAlgo"] = ftable->TestParameterInSteering("JetAlgo"); - if (SteeringPars["JetAlgo"]) { - ftable->GetParameterFromSteering("JetAlgo", jetalgo); - if (jetalgo < 0 || (2 < jetalgo && jetalgo < 10) || 12 < jetalgo) { - say::error["ScenarioCode"] << "Unknown jet algorithm " << jetalgo << ", aborted!" << endl; - exit(1); - } - } else { - say::error["ScenarioCode"] << "No jet algorithm selected, aborted!" << endl; - exit(1); - } - SteeringPars["Rjet"] = ftable->TestParameterInSteering("Rjet"); - if (SteeringPars["Rjet"]) { - ftable->GetParameterFromSteering("Rjet", jetsize); - } else { - say::error["ScenarioCode"] << "Jet size R not defined, aborted!" << endl; - exit(1); - } - SteeringPars["OvThr"] = ftable->TestParameterInSteering("OvThr"); - overlapthreshold = 0.5; // default - if (SteeringPars["OvThr"]) { - ftable->GetParameterFromSteering("OvThr", overlapthreshold); - } else if (jetalgo > 9) { - say::error["ScenarioCode"] << "Overlap threshold not defined for jet algorithm " << jetalgo << ", aborted!" << endl; - exit(1); - } - // --- fastNLO user: declare and initialize overall jet phase space cuts via steering file - // overall lowest pT for jets to be considered - SteeringPars["ptjmin"] = ftable->TestParameterInSteering("ptjmin"); - if (SteeringPars["ptjmin"]) { - ftable->GetParameterFromSteering("ptjmin", ptjmin); - } else { - say::error["ScenarioCode"] << "Minimal jet pT (ptjmin) not defined, aborted!" << endl; - exit(1); - } - // overall highest pT for jets not implemented, since uncritical with respect to CPU time consumption - // overall smallest |(pseudo-)rapidity| for jets to be considered, use either y or eta but not both - SteeringPars["yjmin"] = ftable->TestParameterInSteering("yjmin"); - SteeringPars["etajmin"] = ftable->TestParameterInSteering("etajmin"); - if (SteeringPars["yjmin"] && !SteeringPars["etajmin"]) { - ftable->GetParameterFromSteering("yjmin", yetajmin); - } else if (!SteeringPars["yjmin"] && SteeringPars["etajmin"]) { - ftable->GetParameterFromSteering("etajmin", yetajmin); - } else { - say::error["ScenarioCode"] << "Minimal jet (pseudo)rapidity (yjmin or etajmin) not uniquely defined, aborted!" << endl; - exit(1); - } - // overall largest |(pseudo-)rapidity| for jets to be considered, use either y or eta but not both - SteeringPars["yjmax"] = ftable->TestParameterInSteering("yjmax"); - SteeringPars["etajmax"] = ftable->TestParameterInSteering("etajmax"); - if (SteeringPars["yjmax"] && !SteeringPars["etajmax"]) { - ftable->GetParameterFromSteering("yjmax", yetajmax); - } else if (!SteeringPars["yjmax"] && SteeringPars["etajmax"]) { - ftable->GetParameterFromSteering("etajmax", yetajmax); - } else { - say::error["ScenarioCode"] << "Maximal jet (pseudo)rapidity (yjmax or etajmax) not uniquely defined, aborted!" << endl; - exit(1); - } - // define logical for decision on cuts in (pseudo-)rapidity, no mixing allowed here - if (SteeringPars["yjmin"] && SteeringPars["yjmax"]) { - lpseudo = false; - } else if (SteeringPars["etajmin"] && SteeringPars["etajmax"]) { - lpseudo = true; - } else { - say::error["ScenarioCode"] << "Phase space cuts mixed in (pseudo-)rapidity, aborted!" << endl; - say::error["ScenarioCode"] << "Booleans for cut selections are" - << " yjmin " << SteeringPars["yjmin"] << ", yjmax " << SteeringPars["yjmax"] << ", etajmin " << SteeringPars["etajmin"] << ", etajmax " << SteeringPars["etajmax"] << endl; - say::error["ScenarioCode"] << "If you really want to mix, the code needs to be adapted." << endl; - exit(1); - } - // minimal number of jets required to be within preselected jet phase space (for inclusive jets this must be one!) - SteeringPars["Njetmin"] = ftable->TestParameterInSteering("Njetmin"); - Njetmin = 1; - if (SteeringPars["Njetmin"]) { - ftable->GetParameterFromSteering("Njetmin", Njetmin); - } - - // --- fastNLO user: declare and initialize Njet phase space cuts and definitions via steering file - // overall minimum & maximum for 1st observable, e.g. maximal absolute rapidity |y_max| - SteeringPars["obs0min"] = ftable->TestParameterInSteering("obs0min"); - obsmin[0] = ftable->GetObsBinsLoBoundsMin(0); // by default derived from binning in obs0 - if (SteeringPars["obs0min"]) { - ftable->GetParameterFromSteering("obs0min", obsmin[0]); - } - SteeringPars["obs0max"] = ftable->TestParameterInSteering("obs0max"); - obsmax[0] = ftable->GetObsBinsUpBoundsMax(0); // by default derived from binning in obs0 - if (SteeringPars["obs0max"]) { - ftable->GetParameterFromSteering("obs0max", obsmax[0]); - } - // overall minimum & maximum for 2nd observable, e.g. dijet mass mjj - obsmin[1] = -DBL_MAX; - obsmax[1] = +DBL_MAX; - if (NDim > 1) { - SteeringPars["obs1min"] = ftable->TestParameterInSteering("obs1min"); - obsmin[1] = ftable->GetObsBinsLoBoundsMin(1); // by default derived from binning in obs1 - if (SteeringPars["obs1min"]) { - ftable->GetParameterFromSteering("obs1min", obsmin[1]); - } - SteeringPars["obs1max"] = ftable->TestParameterInSteering("obs1max"); - obsmax[1] = ftable->GetObsBinsUpBoundsMax(1); // by default derived from binning in obs1 - if (SteeringPars["obs1max"]) { - ftable->GetParameterFromSteering("obs1max", obsmax[1]); - } - } - // overall minimum & maximum for 3rd observable - obsmin[2] = -DBL_MAX; - obsmax[2] = +DBL_MAX; - if (NDim > 2) { - SteeringPars["obs2min"] = ftable->TestParameterInSteering("obs2min"); - obsmin[2] = ftable->GetObsBinsLoBoundsMin(2); // by default derived from binning in obs2 - if (SteeringPars["obs2min"]) { - ftable->GetParameterFromSteering("obs2min", obsmin[2]); - } - SteeringPars["obs2max"] = ftable->TestParameterInSteering("obs2max"); - obsmax[2] = ftable->GetObsBinsUpBoundsMax(2); // by default derived from binning in obs2 - if (SteeringPars["obs2max"]) { - ftable->GetParameterFromSteering("obs2max", obsmax[2]); - } - } - jetclusfj.setup(static_cast<fastjet_jets::JetAlgorithm>(jetalgo), jetsize, overlapthreshold); + // --- fastNLO user: + // Here is your playground where you can evaluate the steering file settings. + // ATTENTION: Some settings are mandatory for the correct functioning! + + // get general steering parameters needed here from steering file + say::debug["UserHHC::phys_output"] << "Evaluating steering parameters ..." << endl; + // fixed- or flexible-scale table + SteeringPars["FlexibleScaleTable"] = ftable->TestParameterInSteering("FlexibleScaleTable"); + lFlexibleScaleTable = false; // default + if ( SteeringPars["FlexibleScaleTable"] ) { + ftable->GetParameterFromSteering("FlexibleScaleTable",lFlexibleScaleTable); + } + // dimensionality + SteeringPars["DifferentialDimension"] = ftable->TestParameterInSteering("DifferentialDimension"); + if ( SteeringPars["DifferentialDimension"] ) { + ftable->GetParameterFromSteering("DifferentialDimension",NDim); + } else { + say::error["ScenarioCode"] << "Dimensioning of binning not set, aborted!" << endl; + exit(1); + } + if ( NDim < 1 || 3 < NDim ) { + say::error["ScenarioCode"] << "Only 1- to 3-dimensional binning implemented, aborted!" << endl; + say::error["ScenarioCode"] << "Please implement the requested " << NDim << "-dimensional binning." << endl; + exit(1); + } + // dimension labels + SteeringPars["DimensionLabels"] = ftable->TestParameterInSteering("DimensionLabels"); + DimLabel.resize(NDim); + if ( SteeringPars["DimensionLabels"] ) { + ftable->GetParameterFromSteering("DimensionLabels",DimLabel); + } else { + say::error["ScenarioCode"] << "Dimension labels not set, aborted!" << endl; + exit(1); + } + // define the observables according to the dimension labels + for ( int i = 0; i<NDim; i++ ) { + if ( DimLabel[i] == "|y|" ) { + obsdef[i] = YJET; + } else if ( DimLabel[i] == "|eta|" ) { + obsdef[i] = ETAJET; + } else if ( DimLabel[i] == "pT_[GeV]" ) { + obsdef[i] = PTJETGEV; + } else if ( DimLabel[i] == "phi" ) { + obsdef[i] = PHIJET; + } else { + say::error["ScenarioCode"] << "Unknown observable, i.e. dimension label, aborted!" << endl; + say::error["ScenarioCode"] << "DimLabel[" << i << "] = " << DimLabel[i] << endl; + say::error["ScenarioCode"] << "Please complement this scenario to include the requested observable." << endl; + exit(1); + } + } + // scale descriptions + SteeringPars["ScaleDescriptionScale1"] = ftable->TestParameterInSteering("ScaleDescriptionScale1"); + ScaleLabel.resize(2); + if ( SteeringPars["ScaleDescriptionScale1"] ) { + ftable->GetParameterFromSteering("ScaleDescriptionScale1",ScaleLabel[0]); + } else { + say::error["ScenarioCode"] << "No description of scale 1, aborted!" << endl; + exit(1); + } + SteeringPars["ScaleDescriptionScale2"] = ftable->TestParameterInSteering("ScaleDescriptionScale2"); + ScaleLabel[1] = "pT_max_[GeV]"; // default + if ( SteeringPars["ScaleDescriptionScale2"] ) { + ftable->GetParameterFromSteering("ScaleDescriptionScale2",ScaleLabel[1]); + } else { + ScaleLabel[1] = "-"; + say::warn["ScenarioCode"] << "No description of scale 2, flexible-scale tables not possible!" << endl; + } + // scale descriptions define the scales + for ( unsigned int i = 0; i < ScaleLabel.size(); i++ ) { + if ( ScaleLabel[i] == "pT_max_[GeV]" ) { + mudef[i] = PTMAX; + } else if ( ScaleLabel[i] == "pT_jet_[GeV]" ) { + mudef[i] = PTJET; + } else if ( ScaleLabel[i] == "HT_part_[GeV]" ) { + mudef[i] = HTP; + } else if ( ScaleLabel[i] == "HT_part/2_[GeV]" ) { + mudef[i] = HTPHALF; + } else { + say::error["ScenarioCode"] << "Unknown scale, i.e. scale description, aborted!" << endl; + say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; + say::error["ScenarioCode"] << "Please complement this scenario to include the requested scale." << endl; + exit(1); + } + } + + // definition of jet algorithm and jet phase space limits (no defaults) + // + // --- fastNLO user: set the jet algorithm and size via steering file + // fastjet clustering jet algos: 0 = kT, 1 = CA, 2 = anti-kT + // fastjet cone jet algos: 10 = SISCone, 11 = CDFMidPointCone, 12 = D0RunIICone + SteeringPars["JetAlgo"] = ftable->TestParameterInSteering("JetAlgo"); + if ( SteeringPars["JetAlgo"] ) { + ftable->GetParameterFromSteering("JetAlgo",jetalgo); + if ( jetalgo < 0 || (2 < jetalgo && jetalgo < 10) || 12 < jetalgo ) { + say::error["ScenarioCode"] << "Unknown jet algorithm " << jetalgo << ", aborted!" << endl; + exit(1); + } + } else { + say::error["ScenarioCode"] << "No jet algorithm selected, aborted!" << endl; + exit(1); + } + SteeringPars["Rjet"] = ftable->TestParameterInSteering("Rjet"); + if ( SteeringPars["Rjet"] ) { + ftable->GetParameterFromSteering("Rjet",jetsize); + } else { + say::error["ScenarioCode"] << "Jet size R not defined, aborted!" << endl; + exit(1); + } + SteeringPars["OvThr"] = ftable->TestParameterInSteering("OvThr"); + overlapthreshold = 0.5; // default + if ( SteeringPars["OvThr"] ) { + ftable->GetParameterFromSteering("OvThr",overlapthreshold); + } else if ( jetalgo > 9 ) { + say::error["ScenarioCode"] << "Overlap threshold not defined for jet algorithm " << jetalgo << ", aborted!" << endl; + exit(1); + } + // --- fastNLO user: declare and initialize overall jet phase space cuts via steering file + // overall lowest pT for jets to be considered + SteeringPars["ptjmin"] = ftable->TestParameterInSteering("ptjmin"); + if ( SteeringPars["ptjmin"] ) { + ftable->GetParameterFromSteering("ptjmin",ptjmin); + } else { + say::error["ScenarioCode"] << "Minimal jet pT (ptjmin) not defined, aborted!" << endl; + exit(1); + } + // overall highest pT for jets not implemented, since uncritical with respect to CPU time consumption + // overall smallest |(pseudo-)rapidity| for jets to be considered, use either y or eta but not both + SteeringPars["yjmin"] = ftable->TestParameterInSteering("yjmin"); + SteeringPars["etajmin"] = ftable->TestParameterInSteering("etajmin"); + if ( SteeringPars["yjmin"] && !SteeringPars["etajmin"] ) { + ftable->GetParameterFromSteering("yjmin",yetajmin); + } else if ( !SteeringPars["yjmin"] && SteeringPars["etajmin"] ) { + ftable->GetParameterFromSteering("etajmin",yetajmin); + } else { + say::error["ScenarioCode"] << "Minimal jet (pseudo)rapidity (yjmin or etajmin) not uniquely defined, aborted!" << endl; + exit(1); + } + // overall largest |(pseudo-)rapidity| for jets to be considered, use either y or eta but not both + SteeringPars["yjmax"] = ftable->TestParameterInSteering("yjmax"); + SteeringPars["etajmax"] = ftable->TestParameterInSteering("etajmax"); + if ( SteeringPars["yjmax"] && !SteeringPars["etajmax"] ) { + ftable->GetParameterFromSteering("yjmax",yetajmax); + } else if ( !SteeringPars["yjmax"] && SteeringPars["etajmax"] ) { + ftable->GetParameterFromSteering("etajmax",yetajmax); + } else { + say::error["ScenarioCode"] << "Maximal jet (pseudo)rapidity (yjmax or etajmax) not uniquely defined, aborted!" << endl; + exit(1); + } + // define logical for decision on cuts in (pseudo-)rapidity, no mixing allowed here + if ( SteeringPars["yjmin"] && SteeringPars["yjmax"] ) { + lpseudo = false; + } else if ( SteeringPars["etajmin"] && SteeringPars["etajmax"] ) { + lpseudo = true; + } else { + say::error["ScenarioCode"] << "Phase space cuts mixed in (pseudo-)rapidity, aborted!" << endl; + say::error["ScenarioCode"] << "Booleans for cut selections are" << + " yjmin " << SteeringPars["yjmin"] << + ", yjmax " << SteeringPars["yjmax"] << + ", etajmin " << SteeringPars["etajmin"] << + ", etajmax " << SteeringPars["etajmax"] << endl; + say::error["ScenarioCode"] << "If you really want to mix, the code needs to be adapted." << endl; + exit(1); + } + // minimal number of jets required to be within preselected jet phase space (for inclusive jets this must be one!) + SteeringPars["Njetmin"] = ftable->TestParameterInSteering("Njetmin"); + Njetmin = 1; + if ( SteeringPars["Njetmin"] ) { + ftable->GetParameterFromSteering("Njetmin",Njetmin); + } + if ( Njetmin < 1 ) { + say::error["ScenarioCode"] << "This is a 1+-jet scenario. At least one jet must be present, aborted!" << endl; + say::error["ScenarioCode"] << "Please correct the Njetmin requirement. Njetmin = " << Njetmin << endl; + exit(1); + } + + // --- fastNLO user: declare and initialize Njet phase space cuts and definitions via steering file + // overall minimum & maximum for 1st observable, e.g. maximal absolute rapidity |y_max| + SteeringPars["obs0min"] = ftable->TestParameterInSteering("obs0min"); + obsmin[0] = ftable->GetObsBinsLoBoundsMin(0); // by default derived from binning in obs0 + if ( SteeringPars["obs0min"] ) { + ftable->GetParameterFromSteering("obs0min",obsmin[0]); + } + SteeringPars["obs0max"] = ftable->TestParameterInSteering("obs0max"); + obsmax[0] = ftable->GetObsBinsUpBoundsMax(0); // by default derived from binning in obs0 + if ( SteeringPars["obs0max"] ) { + ftable->GetParameterFromSteering("obs0max",obsmax[0]); + } + // overall minimum & maximum for 2nd observable, e.g. dijet mass mjj + obsmin[1] = -DBL_MAX; + obsmax[1] = +DBL_MAX; + if (NDim > 1) { + SteeringPars["obs1min"] = ftable->TestParameterInSteering("obs1min"); + obsmin[1] = ftable->GetObsBinsLoBoundsMin(1); // by default derived from binning in obs1 + if ( SteeringPars["obs1min"] ) { + ftable->GetParameterFromSteering("obs1min",obsmin[1]); + } + SteeringPars["obs1max"] = ftable->TestParameterInSteering("obs1max"); + obsmax[1] = ftable->GetObsBinsUpBoundsMax(1); // by default derived from binning in obs1 + if ( SteeringPars["obs1max"] ) { + ftable->GetParameterFromSteering("obs1max",obsmax[1]); + } + } + // overall minimum & maximum for 3rd observable + obsmin[2] = -DBL_MAX; + obsmax[2] = +DBL_MAX; + if (NDim > 2) { + SteeringPars["obs2min"] = ftable->TestParameterInSteering("obs2min"); + obsmin[2] = ftable->GetObsBinsLoBoundsMin(2); // by default derived from binning in obs2 + if ( SteeringPars["obs2min"] ) { + ftable->GetParameterFromSteering("obs2min",obsmin[2]); + } + SteeringPars["obs2max"] = ftable->TestParameterInSteering("obs2max"); + obsmax[2] = ftable->GetObsBinsUpBoundsMax(2); // by default derived from binning in obs2 + if ( SteeringPars["obs2max"] ) { + ftable->GetParameterFromSteering("obs2max",obsmax[2]); + } + } + jetclusfj.setup(static_cast<fastjet_jets::JetAlgorithm>(jetalgo), jetsize, overlapthreshold); } // --- fastNLO v2.2: class UserHHC: analyze parton event (called once for each event) -void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) -{ - say::debug["UserHHC::userfunc"] << "---------- UserHHC::userfunc called ----------" << endl; - - // --- fastNLO user: - // Here is your playground where you compute your observables and - // scales for each jet or event. - // The bin number ("obsbin") gets passed to fastNLO's table filling code. - // Usually, pT and E are in GeV, but this may be changed. - // ATTENTION: Scales must always be in GeV! - - // apply the jet algorithm to partonic 4-vector array p of NLOJet++ - pj = jetclusfj(p); - unsigned int nj = pj.upper(); - - // --- check on minimal and maximal no. of jets - // ATTENTION: In principle, without cuts, there should always be two. - // For efficiency reasons though, our interface to the fastjet algorithms - // requires a minimal jet pT of 1 GeV. If this is a problem, the ptmin value - // in fj-jets.cc needs to be changed. - // There should never be more than four jets in NLOJet++ - if (nj < 1) { - say::debug["ScenarioCode"] << "This event from NLOJet++ has no jets with pT > 1 GeV. Skipped!" << endl; - return; - } else if (nj > 4) { - say::error["ScenarioCode"] << "This event from NLOJet++ has more than four jets, which should never happen. Aborted!" << endl; - exit(1); - } - - // --- give some debug output before selection and sorting - if (say::info.GetSpeak()) { - for (unsigned int i = 1; i <= nj; i++) { - double pti = pj[i].perp(); - double yi = pj[i].rapidity(); - double etai = pj[i].prapidity(); - say::info["ScenarioCode"] << "before cuts: jet # i, pt, y, eta: " << i << ", " << pti << ", " << yi << ", " << etai << endl; - } - } - - // --- select jets in y (lpseudo = false) or eta (lpseudo = true) and ptjmin - // note: failing jets are not deleted but moved to the end of the jet array pj! - fNLOSelector SelJets(yetajmin, yetajmax, ptjmin, lpseudo); - - // --- count number of selected jets left at this stage - size_t njet = std::remove_if(pj.begin(), pj.end(), SelJets) - pj.begin(); - if ((int)njet < Njetmin) - return; // Nothing to be done - - // --- sort selected n jets at beginning of jet array pj, by default decreasing in pt - static fNLOSorter SortJets; - std::sort(pj.begin(), pj.begin() + njet, SortJets); - - // --- give some debug output after selection and sorting - if (say::info.GetSpeak()) { - say::info["ScenarioCode"] << "# jets before and after phase space cuts: nj, njet = " << nj << ", " << njet << endl; - if (!lpseudo) { - say::info["ScenarioCode"] << "phase space cuts: yjmin, yjmax, ptjmin: " << yetajmin << ", " << yetajmax << ", " << ptjmin << endl; - } else { - say::info["ScenarioCode"] << "phase space cuts: etajmin, etajmax, ptjmin: " << yetajmin << ", " << yetajmax << ", " << ptjmin << endl; - } - for (unsigned int i = 1; i <= njet; i++) { - double pti = pj[i].perp(); - double yi = pj[i].rapidity(); - double etai = pj[i].prapidity(); - say::info["ScenarioCode"] << "after cuts: jet # i, pt, y, eta: " << i << ", " << pti << ", " << yi << ", " << etai << endl; - } - } - - // ---- fastNLO v2.2 - // Analyze inclusive jets in jet loop - // set one possible scale choice (Attention: Only correct if jets sorted descending in pT) - double ptmax = pj[1].perp(); - for (unsigned int k = 1; k <= njet; k++) { - - // derive some jet quantities - double pt = pj[k].perp(); - double yeta; - if (!lpseudo) { - yeta = abs(pj[k].rapidity()); - } else { - yeta = abs(pj[k].prapidity()); - } - double phi = atan2(pj[k].Y(), pj[k].X()); - - // --- calculate observable of nth dimension - for (int i = 0; i < NDim; i++) { - switch (obsdef[i]) { - case PTJETGEV: - // jet pT - obs[i] = pt; - break; - case YJET: - // jet rapidity - obs[i] = yeta; - break; - case PHIJET: - // jet azimuthal angle - obs[i] = phi; - break; - default: - say::error["ScenarioCode"] << "Observable not yet implemented, aborted!" << endl; - say::error["ScenarioCode"] << "DimLabel[" << i << "] = " << DimLabel[i] << endl; - say::error["ScenarioCode"] << "Please complement this scenario to include the requested observable." << endl; - exit(1); - } - } - - // --- Further Njet phase space cuts? - if (obsmin[0] <= obs[0] && obs[0] < obsmax[0] && (NDim < 2 || (obsmin[1] <= obs[1] && obs[1] < obsmax[1])) && (NDim < 3 || (obsmin[2] <= obs[2] && obs[2] < obsmax[2]))) { - - // --- set the renormalization and factorization scales - // --- calculate the requested scales - for (unsigned int i = 0; i < 2; i++) { - switch (mudef[i]) { - case PTMAX: - // maximal jet pT - mu[i] = ptmax; - break; - case PTJET: - // jet pT - mu[i] = pt; - break; - default: - say::error["ScenarioCode"] << "Scale not yet implemented, aborted!" << endl; - say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; - say::error["ScenarioCode"] << "Please complement this scenario to include the requested scale." << endl; - exit(1); - } - } - static vector<double> scalevars; - if (!lFlexibleScaleTable) - scalevars = ftable->GetScaleVariations(); - - // get matrix elements - static vector<fnloEvent> contribsflex; - static vector<vector<fnloEvent> > contribsfix; - if (lFlexibleScaleTable) { - contribsflex = UsefulNlojetTools::GetFlexibleScaleNlojetContribHHC(p, amp); - } else { - contribsfix = UsefulNlojetTools::GetFixedScaleNlojetContribHHC(p, amp, mu[0], scalevars); - } - - // set and fill scenario specific quantites - fnloScenario scen; - if (NDim < 1 || NDim > 3) { - say::error["ScenarioCode"] << "Less than 1D(?!) or more than 3D binning not implemented here, aborted!" << endl; - say::error["ScenarioCode"] << "DifferentialDimension NDim = " << NDim << endl; - } - for (int i = 0; i < NDim; i++) { - scen.SetObservableDimI(obs[i], i); +void UserHHC::userfunc(const event_hhc& p, const amplitude_hhc& amp) { + if ( say::debug.GetSpeak() ) { + say::debug["UserHHC::userfunc"] << "---------- UserHHC::userfunc called ----------" << endl; + say::debug["ScenarioCode"] << "==================== Start of event ====================" << endl; + } + + // --- fastNLO user: + // Here is your playground where you compute your observables and + // scales for each jet or event. + // The bin number ("obsbin") gets passed to fastNLO's table filling code. + // Usually, pT and E are in GeV, but this may be changed. + // ATTENTION: Scales must always be in GeV! + + // derive partonic HT scale + double htp = 0.; + unsigned int np = p.upper(); + for (unsigned int i = 1; i <= np; i++) { + htp += p[i].perp(); + // --- debug output + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "partonic HT: parton # i, pt, htp: " << i << ", " << p[i].perp() << ", " << htp << endl; + } + } + + // apply the jet algorithm to partonic 4-vector array p of NLOJet++ + pj = jetclusfj(p); + unsigned int nj = pj.upper(); + + // --- check on minimal and maximal no. of jets + // ATTENTION: In principle, without cuts, there should always be two. + // For efficiency reasons though, our interface to the fastjet algorithms + // requires a minimal jet pT of 1 GeV. If this is a problem, the ptmin value + // in fj-jets.cc needs to be changed. + // There should never be more than four jets in NLOJet++ + if (nj < 1) { + say::debug["ScenarioCode"] << "This event from NLOJet++ has no jets with pT > 1 GeV. Skipped!" << endl; + return; + } else if (nj > 4) { + say::error["ScenarioCode"] << "This event from NLOJet++ has more than four jets, which should never happen. Aborted!" << endl; + exit(1); + } + + // --- give some debug output before selection and sorting + if ( say::debug.GetSpeak() ) { + for (unsigned int i=1; i<=nj; i++) { + double pti = pj[i].perp(); + double yi = pj[i].rapidity(); + double etai = pj[i].prapidity(); + say::debug["ScenarioCode"] << "before cuts: jet # i, pt, y, eta: " << i << ", " << pti << ", " << yi << ", " << etai << endl; + } + } + + // --- select jets in y (lpseudo = false) or eta (lpseudo = true) and ptjmin + // note: failing jets are not deleted but moved to the end of the jet array pj! + fNLOSelector SelJets (yetajmin,yetajmax,ptjmin,lpseudo); + + // --- count number of selected jets left at this stage + size_t njet = std::remove_if(pj.begin(), pj.end(), SelJets) - pj.begin(); + if ( (int)njet < Njetmin ) return; // Nothing to be done + + // --- sort selected n jets at beginning of jet array pj, by default decreasing in pt + static fNLOSorter SortJets; + std::sort(pj.begin(), pj.begin() + njet, SortJets); + + // --- give some debug output after selection and sorting + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "# jets before and after phase space cuts: nj, njet = " << nj << ", " << njet << endl; + if ( ! lpseudo ) { + say::debug["ScenarioCode"] << "phase space cuts: yjmin, yjmax, ptjmin: " << yetajmin << ", " << yetajmax << ", " << ptjmin << endl; + } else { + say::debug["ScenarioCode"] << "phase space cuts: etajmin, etajmax, ptjmin: " << yetajmin << ", " << yetajmax << ", " << ptjmin << endl; + } + for (unsigned int i=1; i<=njet; i++) { + double pti = pj[i].perp(); + double yi = pj[i].rapidity(); + double etai = pj[i].prapidity(); + say::debug["ScenarioCode"] << "after cuts: jet # i, pt, y, eta: " << i << ", " << pti << ", " << yi << ", " << etai << endl; + } + } + + // ---- fastNLO v2.2 + // Analyze inclusive jets in jet loop + // set one possible scale choice (Attention: Only correct if jets sorted descending in pT) + double ptmax = pj[1].perp(); + for (unsigned int k = 1; k <= njet; k++) { + + // --- calculate observable of nth dimension + for ( int i = 0; i<NDim; i++ ) { + switch(obsdef[i]) { + case PTJETGEV : + // jet pT + obs[i] = pj[k].perp(); + break; + case YJET : + // jet rapidity + obs[i] = abs(pj[k].rapidity()); + break; + case ETAJET : + // jet pseudorapidity + obs[i] = abs(pj[k].prapidity()); + break; + case PHIJET : + // jet azimuthal angle + obs[i] = atan2(pj[k].Y(), pj[k].X()); + break; + default : + say::error["ScenarioCode"] << "Observable not yet implemented, aborted!" << endl; + say::error["ScenarioCode"] << "DimLabel[" << i << "] = " << DimLabel[i] << endl; + say::error["ScenarioCode"] << "Please complement this scenario to include the requested observable." << endl; + exit(1); + } + } + + // --- give some debug output before final selection + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "---------------- Before final selection ----------------" << endl; + for ( int i = 0; i<NDim; i++ ) { + say::debug["ScenarioCode"] << "Obs. min/max values: " << i << " : obsmin = " << obsmin[i] << ", obs = " << obs[i] << ", obsmax = " << obsmax[i] << endl; + } + } + + // --- Further Njet phase space cuts? + if ( obsmin[0] <= obs[0] && obs[0] < obsmax[0] && + (NDim < 2 || (obsmin[1] <= obs[1] && obs[1] < obsmax[1])) && + (NDim < 3 || (obsmin[2] <= obs[2] && obs[2] < obsmax[2])) ) { + + // --- jet accepted + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "----------------- Event/jet accepted! ------------------" << endl; + say::debug["ScenarioCode"] << "==================== End of event ====================" << endl; + } + + // --- set the renormalization and factorization scales + // --- calculate the requested scales + for ( unsigned int i = 0; i < 2; i++ ) { + switch(mudef[i]) { + case PTMAX : + // maximal jet pT + mu[i] = ptmax; + break; + case PTJET : + // jet pT + mu[i] = pj[k].perp(); + break; + case HTP : + // partonic sum pT + mu[i] = htp; + say::debug["ScenarioCode"] << "HTP scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; + case HTPHALF : + // half partonic sum pT + mu[i] = htp/2.; + say::debug["ScenarioCode"] << "HTPHALF scale values: " << i << " : mu[i] = " << mu[i] << endl; + break; + default : + say::error["ScenarioCode"] << "Scale not yet implemented, aborted!" << endl; + say::error["ScenarioCode"] << "ScaleLabel[" << i << "] = " << ScaleLabel[i] << endl; + say::error["ScenarioCode"] << "Please complement this scenario to include the requested scale." << endl; + exit(1); } + } + static vector<double> scalevars; + if ( ! lFlexibleScaleTable ) scalevars = ftable->GetScaleVariations(); + + // get matrix elements + static vector<fnloEvent> contribsflex; + static vector< vector<fnloEvent> > contribsfix; + if (lFlexibleScaleTable) { + contribsflex = UsefulNlojetTools::GetFlexibleScaleNlojetContribHHC(p,amp); + } else { + contribsfix = UsefulNlojetTools::GetFixedScaleNlojetContribHHC(p,amp,mu[0],scalevars); + } + + // set and fill scenario specific quantites + fnloScenario scen; + if ( NDim < 1 || NDim > 3 ) { + say::error["ScenarioCode"] << "Less than 1D(?!) or more than 3D binning not implemented here, aborted!" << endl; + say::error["ScenarioCode"] << "DifferentialDimension NDim = " << NDim << endl; + } + for ( int i = 0; i<NDim; i++ ) { + scen.SetObservableDimI( obs[i], i ); + } + + scen.SetObsScale1( mu[0] ); // must be consistent with 'mu' from contribs + if (lFlexibleScaleTable) { + scen.SetObsScale2( mu[1] ); + ftable->FillAllSubprocesses(contribsflex,scen); + } else { + ftable->FillAllSubprocesses(contribsfix,scen); + } + } else { + // --- jet rejected + if ( say::debug.GetSpeak() ) { + say::debug["ScenarioCode"] << "----------------- Event/jet rejected! ------------------" << endl; + say::debug["ScenarioCode"] << "==================== End of event ====================" << endl; + } + } + } +} - scen.SetObsScale1(mu[0]); // must be consistent with 'mu' from contribs - if (lFlexibleScaleTable) { - scen.SetObsScale2(mu[1]); - ftable->FillAllSubprocesses(contribsflex, scen); - } else { - ftable->FillAllSubprocesses(contribsfix, scen); - } - } - } +// --- define function for azimuthal angular distance in [-Pi,Pi] +double dphi(double phi2, double phi1) { + double delta_phi = phi2-phi1; + if (delta_phi > M_PI) { + delta_phi -= 2*M_PI; + } else if (delta_phi < -M_PI) { + delta_phi += 2*M_PI; + } + return delta_phi; } diff --git a/v2.5/generators/nlojet++/interface/hadron/Makefile.am b/v2.5/generators/nlojet++/interface/hadron/Makefile.am index c47bbdb1ce69a3a955708c07c575bb6f654c9dbe..0e55ac45988f5500174fefd1d3da84b721414003 100644 --- a/v2.5/generators/nlojet++/interface/hadron/Makefile.am +++ b/v2.5/generators/nlojet++/interface/hadron/Makefile.am @@ -21,7 +21,8 @@ pkglib_LTLIBRARIES = # Require fastjet # if HAVE_FASTJET - pkglib_LTLIBRARIES += libInclusiveNJets.la libInclusiveNJetEvents.la libInclusiveNJetPairs.la libInclusiveNJetDiffs.la libInclusiveNJetsNew.la + pkglib_LTLIBRARIES += libInclusiveNJets.la libInclusiveNJetEvents.la libInclusiveNJetPairs.la libInclusiveNJetDiffs.la +# libInclusiveNJetsNew.la endif # @@ -35,7 +36,7 @@ libInclusiveNJets_la_SOURCES = InclusiveNJets.cc $(AM_SOURCES) libInclusiveNJetEvents_la_SOURCES = InclusiveNJetEvents.cc $(AM_SOURCES) libInclusiveNJetPairs_la_SOURCES = InclusiveNJetPairs.cc $(AM_SOURCES) libInclusiveNJetDiffs_la_SOURCES = InclusiveNJetDiffs.cc $(AM_SOURCES) -libInclusiveNJetsNew_la_SOURCES = InclusiveNJets_new.cc $(AM_SOURCES) fastNLOjetpp.cc +#libInclusiveNJetsNew_la_SOURCES = InclusiveNJets_new.cc $(AM_SOURCES) fastNLOjetpp.cc # # Preprocessor flags diff --git a/v2.5/generators/nlojet++/m4/ax_check_zlib.m4 b/v2.5/generators/nlojet++/m4/ax_check_zlib.m4 index be91a86eb907deb9abf69c232b7697c129b53036..1a168430485fe1e8cf9e7c500ee95307df54fac1 100644 --- a/v2.5/generators/nlojet++/m4/ax_check_zlib.m4 +++ b/v2.5/generators/nlojet++/m4/ax_check_zlib.m4 @@ -62,7 +62,7 @@ # modified version of the Autoconf Macro, you may extend this special # exception to the GPL to apply to your modified version as well. -#serial 15 +#serial 16 AU_ALIAS([CHECK_ZLIB], [AX_CHECK_ZLIB]) AC_DEFUN([AX_CHECK_ZLIB], @@ -108,11 +108,10 @@ then LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib" CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include" fi - AC_LANG_SAVE - AC_LANG_C + AC_LANG_PUSH([C]) AC_CHECK_LIB([z], [inflateEnd], [zlib_cv_libz=yes], [zlib_cv_libz=no]) AC_CHECK_HEADER([zlib.h], [zlib_cv_zlib_h=yes], [zlib_cv_zlib_h=no]) - AC_LANG_RESTORE + AC_LANG_POP([C]) if test "$zlib_cv_libz" = "yes" && test "$zlib_cv_zlib_h" = "yes" then # diff --git a/v2.5/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4 b/v2.5/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4 index 5032bba8091d5d1074f4509b4c47b38a66389c6b..9413da624d2545123501b7788b7ac6d96fd322e8 100644 --- a/v2.5/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4 +++ b/v2.5/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4 @@ -16,7 +16,7 @@ # The second argument, if specified, indicates whether you insist on an # extended mode (e.g. -std=gnu++11) or a strict conformance mode (e.g. # -std=c++11). If neither is specified, you get whatever works, with -# preference for an extended mode. +# preference for no added switch, and then for an extended mode. # # The third argument, if specified 'mandatory' or if left unspecified, # indicates that baseline support for the specified C++ standard is @@ -33,19 +33,20 @@ # Copyright (c) 2014, 2015 Google Inc.; contributed by Alexey Sokolov <sokolov@google.com> # Copyright (c) 2015 Paul Norman <penorman@mac.com> # Copyright (c) 2015 Moritz Klammler <moritz@klammler.eu> -# Copyright (c) 2016 Krzesimir Nowak <qdlacz@gmail.com> +# Copyright (c) 2016, 2018 Krzesimir Nowak <qdlacz@gmail.com> +# Copyright (c) 2019 Enji Cooper <yaneurabeya@gmail.com> +# Copyright (c) 2020 Jason Merrill <jason@redhat.com> # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. -#serial 7 +#serial 12 dnl This macro is based on the code from the AX_CXX_COMPILE_STDCXX_11 macro dnl (serial version number 13). -AX_REQUIRE_DEFINED([AC_MSG_WARN]) AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl m4_if([$1], [11], [ax_cxx_compile_alternatives="11 0x"], [$1], [14], [ax_cxx_compile_alternatives="14 1y"], @@ -61,14 +62,16 @@ AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl [m4_fatal([invalid third argument `$3' to AX_CXX_COMPILE_STDCXX])]) AC_LANG_PUSH([C++])dnl ac_success=no - AC_CACHE_CHECK(whether $CXX supports C++$1 features by default, - ax_cv_cxx_compile_cxx$1, - [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])], - [ax_cv_cxx_compile_cxx$1=yes], - [ax_cv_cxx_compile_cxx$1=no])]) - if test x$ax_cv_cxx_compile_cxx$1 = xyes; then - ac_success=yes - fi + + m4_if([$2], [], [dnl + AC_CACHE_CHECK(whether $CXX supports C++$1 features by default, + ax_cv_cxx_compile_cxx$1, + [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])], + [ax_cv_cxx_compile_cxx$1=yes], + [ax_cv_cxx_compile_cxx$1=no])]) + if test x$ax_cv_cxx_compile_cxx$1 = xyes; then + ac_success=yes + fi]) m4_if([$2], [noext], [], [dnl if test x$ac_success = xno; then @@ -139,7 +142,6 @@ AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl [define if the compiler supports basic C++$1 syntax]) fi AC_SUBST(HAVE_CXX$1) - m4_if([$1], [17], [AC_MSG_WARN([C++17 is not yet standardized, so the checks may change in incompatible ways anytime])]) ]) @@ -199,11 +201,13 @@ namespace cxx11 struct Base { + virtual ~Base() {} virtual void f() {} }; struct Derived : public Base { + virtual ~Derived() override {} virtual void f() override {} }; @@ -587,20 +591,12 @@ m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_17], [[ #error "This is not a C++ compiler" -#elif __cplusplus <= 201402L +#elif __cplusplus < 201703L #error "This is not a C++17 compiler" #else -#if defined(__clang__) - #define REALLY_CLANG -#else - #if defined(__GNUC__) - #define REALLY_GCC - #endif -#endif - #include <initializer_list> #include <utility> #include <type_traits> @@ -608,16 +604,12 @@ m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_17], [[ namespace cxx17 { -#if !defined(REALLY_CLANG) namespace test_constexpr_lambdas { - // TODO: test it with clang++ from git - constexpr int foo = [](){return 42;}(); } -#endif // !defined(REALLY_CLANG) namespace test::nested_namespace::definitions { @@ -852,12 +844,9 @@ namespace cxx17 } -#if !defined(REALLY_CLANG) namespace test_template_argument_deduction_for_class_templates { - // TODO: test it with clang++ from git - template <typename T1, typename T2> struct pair { @@ -876,7 +865,6 @@ namespace cxx17 } } -#endif // !defined(REALLY_CLANG) namespace test_non_type_auto_template_parameters { @@ -890,12 +878,9 @@ namespace cxx17 } -#if !defined(REALLY_CLANG) namespace test_structured_bindings { - // TODO: test it with clang++ from git - int arr[2] = { 1, 2 }; std::pair<int, int> pr = { 1, 2 }; @@ -927,14 +912,10 @@ namespace cxx17 const auto [ x3, y3 ] = f3(); } -#endif // !defined(REALLY_CLANG) -#if !defined(REALLY_CLANG) namespace test_exception_spec_type_system { - // TODO: test it with clang++ from git - struct Good {}; struct Bad {}; @@ -952,7 +933,6 @@ namespace cxx17 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>); } -#endif // !defined(REALLY_CLANG) namespace test_inline_variables { @@ -977,6 +957,6 @@ namespace cxx17 } // namespace cxx17 -#endif // __cplusplus <= 201402L +#endif // __cplusplus < 201703L ]]) diff --git a/v2.5/generators/nlojet++/m4/libtool.m4 b/v2.5/generators/nlojet++/m4/libtool.m4 index 56666f0eceac29ace0fff6cfefa246a4ab93174c..c4c02946dece797da877e40488def858d724f103 100644 --- a/v2.5/generators/nlojet++/m4/libtool.m4 +++ b/v2.5/generators/nlojet++/m4/libtool.m4 @@ -1,8 +1,6 @@ # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. +# Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives @@ -10,36 +8,30 @@ # modifications, as long as this notice is preserved. m4_define([_LT_COPYING], [dnl -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. +# Copyright (C) 2014 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of of the License, or +# (at your option) any later version. # -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program or library that is built +# using GNU Libtool, you may include this file under the same +# distribution terms that you use for the rest of that program. # -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# along with this program. If not, see <http://www.gnu.org/licenses/>. ]) -# serial 57 LT_INIT +# serial 58 LT_INIT # LT_PREREQ(VERSION) @@ -67,7 +59,7 @@ esac # LT_INIT([OPTIONS]) # ------------------ AC_DEFUN([LT_INIT], -[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT +[AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl @@ -91,7 +83,7 @@ dnl Parse OPTIONS _LT_SET_OPTIONS([$0], [$1]) # This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" +LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' @@ -111,26 +103,43 @@ dnl AC_DEFUN([AC_PROG_LIBTOOL], []) dnl AC_DEFUN([AM_PROG_LIBTOOL], []) +# _LT_PREPARE_CC_BASENAME +# ----------------------- +m4_defun([_LT_PREPARE_CC_BASENAME], [ +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in @S|@*""; do + case $cc_temp in + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} +])# _LT_PREPARE_CC_BASENAME + + # _LT_CC_BASENAME(CC) # ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +# It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, +# but that macro is also expanded into generated libtool script, which +# arranges for $SED and $ECHO to be set by different means. m4_defun([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +[m4_require([_LT_PREPARE_CC_BASENAME])dnl +AC_REQUIRE([_LT_DECL_SED])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl +func_cc_basename $1 +cc_basename=$func_cc_basename_result ]) # _LT_FILEUTILS_DEFAULTS # ---------------------- # It is okay to use these file commands and assume they have been set -# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. +# sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. m4_defun([_LT_FILEUTILS_DEFAULTS], [: ${CP="cp -f"} : ${MV="mv -f"} @@ -177,15 +186,16 @@ m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_WITH_SYSROOT])dnl +m4_require([_LT_CMD_TRUNCATE])dnl _LT_CONFIG_LIBTOOL_INIT([ -# See if we are running on zsh, and set the options which allow our +# See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then +if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi ]) -if test -n "${ZSH_VERSION+set}" ; then +if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi @@ -198,7 +208,7 @@ aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then + if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi @@ -209,14 +219,14 @@ esac ofile=libtool can_build_shared=yes -# All known linkers require a `.a' archive for static linking (except MSVC, +# All known linkers require a '.a' archive for static linking (except MSVC, # which needs '.lib'). libext=a -with_gnu_ld="$lt_cv_prog_gnu_ld" +with_gnu_ld=$lt_cv_prog_gnu_ld -old_CC="$CC" -old_CFLAGS="$CFLAGS" +old_CC=$CC +old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc @@ -269,14 +279,14 @@ no_glob_subst='s/\*/\\\*/g' # _LT_PROG_LTMAIN # --------------- -# Note that this code is called both from `configure', and `config.status' +# Note that this code is called both from 'configure', and 'config.status' # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, -# `config.status' has no value for ac_aux_dir unless we are using Automake, +# 'config.status' has no value for ac_aux_dir unless we are using Automake, # so we pass a copy along to make sure it has a sensible value anyway. m4_defun([_LT_PROG_LTMAIN], [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) -ltmain="$ac_aux_dir/ltmain.sh" +ltmain=$ac_aux_dir/ltmain.sh ])# _LT_PROG_LTMAIN @@ -286,7 +296,7 @@ ltmain="$ac_aux_dir/ltmain.sh" # So that we can recreate a full libtool script including additional # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS -# in macros and then make a single call at the end using the `libtool' +# in macros and then make a single call at the end using the 'libtool' # label. @@ -421,8 +431,8 @@ m4_define([_lt_decl_all_varnames], # _LT_CONFIG_STATUS_DECLARE([VARNAME]) # ------------------------------------ -# Quote a variable value, and forward it to `config.status' so that its -# declaration there will have the same value as in `configure'. VARNAME +# Quote a variable value, and forward it to 'config.status' so that its +# declaration there will have the same value as in 'configure'. VARNAME # must have a single quote delimited value for this to work. m4_define([_LT_CONFIG_STATUS_DECLARE], [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) @@ -446,7 +456,7 @@ m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], # Output comment and list of tags supported by the script m4_defun([_LT_LIBTOOL_TAGS], [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl -available_tags="_LT_TAGS"dnl +available_tags='_LT_TAGS'dnl ]) @@ -474,7 +484,7 @@ m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl # _LT_LIBTOOL_CONFIG_VARS # ----------------------- # Produce commented declarations of non-tagged libtool config variables -# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' +# suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' # script. Tagged libtool config variables (even for the LIBTOOL CONFIG # section) are produced by _LT_LIBTOOL_TAG_VARS. m4_defun([_LT_LIBTOOL_CONFIG_VARS], @@ -500,8 +510,8 @@ m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of # variables for single and double quote escaping we saved from calls # to _LT_DECL, we can put quote escaped variables declarations -# into `config.status', and then the shell code to quote escape them in -# for loops in `config.status'. Finally, any additional code accumulated +# into 'config.status', and then the shell code to quote escape them in +# for loops in 'config.status'. Finally, any additional code accumulated # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. m4_defun([_LT_CONFIG_COMMANDS], [AC_PROVIDE_IFELSE([LT_OUTPUT], @@ -547,7 +557,7 @@ for var in lt_decl_all_varnames([[ \ ]], lt_decl_quote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -560,7 +570,7 @@ for var in lt_decl_all_varnames([[ \ ]], lt_decl_dquote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -576,7 +586,7 @@ _LT_OUTPUT_LIBTOOL_INIT # Generate a child script FILE with all initialization necessary to # reuse the environment learned by the parent script, and make the # file executable. If COMMENT is supplied, it is inserted after the -# `#!' sequence but before initialization text begins. After this +# '#!' sequence but before initialization text begins. After this # macro, additional text can be appended to FILE to form the body of # the child script. The macro ends with non-zero status if the # file could not be fully written (such as if the disk is full). @@ -598,7 +608,7 @@ AS_SHELL_SANITIZE _AS_PREPARE exec AS_MESSAGE_FD>&1 _ASEOF -test $lt_write_fail = 0 && chmod +x $1[]dnl +test 0 = "$lt_write_fail" && chmod +x $1[]dnl m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT @@ -621,7 +631,7 @@ exec AS_MESSAGE_LOG_FD>>config.log } >&AS_MESSAGE_LOG_FD lt_cl_help="\ -\`$as_me' creates a local libtool stub from the current configuration, +'$as_me' creates a local libtool stub from the current configuration, for use in further configure time tests before the real libtool is generated. @@ -643,7 +653,7 @@ Copyright (C) 2011 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation gives unlimited permision to copy, distribute and modify it." -while test $[#] != 0 +while test 0 != $[#] do case $[1] in --version | --v* | -V ) @@ -656,10 +666,10 @@ do lt_cl_silent=: ;; -*) AC_MSG_ERROR([unrecognized option: $[1] -Try \`$[0] --help' for more information.]) ;; +Try '$[0] --help' for more information.]) ;; *) AC_MSG_ERROR([unrecognized argument: $[1] -Try \`$[0] --help' for more information.]) ;; +Try '$[0] --help' for more information.]) ;; esac shift done @@ -685,7 +695,7 @@ chmod +x "$CONFIG_LT" # open by configure. Here we exec the FD to /dev/null, effectively closing # config.log, so it can be properly (re)opened and appended to by config.lt. lt_cl_success=: -test "$silent" = yes && +test yes = "$silent" && lt_config_lt_args="$lt_config_lt_args --quiet" exec AS_MESSAGE_LOG_FD>/dev/null $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false @@ -705,32 +715,46 @@ m4_defun([_LT_CONFIG], _LT_CONFIG_SAVE_COMMANDS([ m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl m4_if(_LT_TAG, [C], [ - # See if we are running on zsh, and set the options which allow our + # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then + if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi - cfgfile="${ofile}T" + cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# Generated automatically by $as_me ($PACKAGE) $VERSION # NOTE: Changes made to this file will be lost: look at ltmain.sh. -# + +# Provide generalized library-building support services. +# Written by Gordon Matzigkeit, 1996 + _LT_COPYING _LT_LIBTOOL_TAGS +# Configured defaults for sys_lib_dlsearch_path munging. +: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} + # ### BEGIN LIBTOOL CONFIG _LT_LIBTOOL_CONFIG_VARS _LT_LIBTOOL_TAG_VARS # ### END LIBTOOL CONFIG +_LT_EOF + + cat <<'_LT_EOF' >> "$cfgfile" + +# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE + +_LT_PREPARE_MUNGE_PATH_LIST +_LT_PREPARE_CC_BASENAME + +# ### END FUNCTIONS SHARED WITH CONFIGURE + _LT_EOF case $host_os in @@ -739,7 +763,7 @@ _LT_EOF # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then +if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi @@ -756,8 +780,6 @@ _LT_EOF sed '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) - _LT_PROG_REPLACE_SHELLFNS - mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" @@ -775,7 +797,6 @@ _LT_EOF [m4_if([$1], [], [ PACKAGE='$PACKAGE' VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' RM='$RM' ofile='$ofile'], []) ])dnl /_LT_CONFIG_SAVE_COMMANDS @@ -974,7 +995,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], [lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then + if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the @@ -992,7 +1013,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ cat conftest.err >&AS_MESSAGE_LOG_FD # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. - elif test -f libconftest.dylib && test $_lt_result -eq 0; then + elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&AS_MESSAGE_LOG_FD @@ -1010,7 +1031,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [lt_cv_ld_exported_symbols_list=yes], [lt_cv_ld_exported_symbols_list=no]) - LDFLAGS="$save_LDFLAGS" + LDFLAGS=$save_LDFLAGS ]) AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], @@ -1020,8 +1041,8 @@ int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD - echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD - $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$AR cr libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR cr libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF @@ -1032,7 +1053,7 @@ _LT_EOF _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD - elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then + elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&AS_MESSAGE_LOG_FD @@ -1042,32 +1063,32 @@ _LT_EOF ]) case $host_os in rhapsody* | darwin1.[[012]]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) # darwin 5.x on # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[[012]]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.0,*86*-darwin8*|10.0,*-darwin[[912]]*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + 10.[[012]][[,.]]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + 10.*|11.*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then + if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + if test yes = "$lt_cv_ld_exported_symbols_list"; then + _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi - if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= @@ -1087,29 +1108,29 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + if test yes = "$lt_cv_ld_force_load"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) else _LT_TAGVAR(whole_archive_flag_spec, $1)='' fi _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" + _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; + ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac - if test "$_lt_dar_can_shared" = "yes"; then + if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all - _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" - _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], -[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then - _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" +[ if test yes != "$lt_cv_apple_cc_single_mod"; then + _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else @@ -1129,7 +1150,7 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], # Allow to override them for all tags through lt_cv_aix_libpath. m4_defun([_LT_SYS_MODULE_PATH_AIX], [m4_require([_LT_DECL_SED])dnl -if test "${lt_cv_aix_libpath+set}" = set; then +if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], @@ -1147,7 +1168,7 @@ else _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi],[]) if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib fi ]) aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) @@ -1167,8 +1188,8 @@ m4_define([_LT_SHELL_INIT], # ----------------------- # Find how we can fake an echo command that does not interpret backslash. # In particular, with Autoconf 2.60 or later we add some code to the start -# of the generated configure script which will find a shell with a builtin -# printf (which we can use as an echo command). +# of the generated configure script that will find a shell with a builtin +# printf (that we can use as an echo command). m4_defun([_LT_PROG_ECHO_BACKSLASH], [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO @@ -1196,10 +1217,10 @@ fi # Invoke $ECHO with all args, space-separated. func_echo_all () { - $ECHO "$*" + $ECHO "$*" } -case "$ECHO" in +case $ECHO in printf*) AC_MSG_RESULT([printf]) ;; print*) AC_MSG_RESULT([print -r]) ;; *) AC_MSG_RESULT([cat]) ;; @@ -1225,16 +1246,17 @@ _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) AC_DEFUN([_LT_WITH_SYSROOT], [AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], -[ --with-sysroot[=DIR] Search for dependent libraries within DIR - (or the compiler's sysroot if not specified).], +[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], + [Search for dependent libraries within DIR (or the compiler's sysroot + if not specified).])], [], [with_sysroot=no]) dnl lt_sysroot will always be passed unquoted. We quote it here dnl in case the user passed a directory name. lt_sysroot= -case ${with_sysroot} in #( +case $with_sysroot in #( yes) - if test "$GCC" = yes; then + if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( @@ -1244,14 +1266,14 @@ case ${with_sysroot} in #( no|'') ;; #( *) - AC_MSG_RESULT([${with_sysroot}]) + AC_MSG_RESULT([$with_sysroot]) AC_MSG_ERROR([The sysroot must be an absolute path.]) ;; esac AC_MSG_RESULT([${lt_sysroot:-no}]) _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl -[dependent libraries, and in which our libraries should be installed.])]) +[dependent libraries, and where our libraries should be installed.])]) # _LT_ENABLE_LOCK # --------------- @@ -1259,31 +1281,33 @@ m4_defun([_LT_ENABLE_LOCK], [AC_ARG_ENABLE([libtool-lock], [AS_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes +test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set mode + # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) - HPUX_IA64_MODE="32" + HPUX_IA64_MODE=32 ;; *ELF-64*) - HPUX_IA64_MODE="64" + HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then + if test yes = "$lt_cv_prog_gnu_ld"; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" @@ -1312,9 +1336,46 @@ ia64-*-hpux*) rm -rf conftest* ;; -x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +mips64*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + emul=elf + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + emul="${emul}32" + ;; + *64-bit*) + emul="${emul}64" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *MSB*) + emul="${emul}btsmip" + ;; + *LSB*) + emul="${emul}ltsmip" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *N32*) + emul="${emul}n32" + ;; + esac + LD="${LD-ld} -m $emul" + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. Note that the listed cases only cover the + # situations where additional linker options are needed (such as when + # doing 32-bit compilation for a host where ld defaults to 64-bit, or + # vice versa); the common cases where no linker options are needed do + # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in @@ -1324,9 +1385,19 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) - LD="${LD-ld} -m elf_i386" + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*linux*) + LD="${LD-ld} -m elf32lppclinux" ;; - ppc64-*linux*|powerpc64-*linux*) + powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) @@ -1345,7 +1416,10 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; - ppc*-*linux*|powerpc*-*linux*) + powerpcle-*linux*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) @@ -1363,19 +1437,20 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" + SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, [AC_LANG_PUSH(C) AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then + if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" + CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in @@ -1383,7 +1458,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) case $lt_cv_prog_gnu_ld in yes*) case $host in - i?86-*-solaris*) + i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) @@ -1392,7 +1467,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD="${LD-ld}_sol2" + LD=${LD-ld}_sol2 fi ;; *) @@ -1408,7 +1483,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) ;; esac -need_locks="$enable_libtool_lock" +need_locks=$enable_libtool_lock ])# _LT_ENABLE_LOCK @@ -1417,7 +1492,7 @@ need_locks="$enable_libtool_lock" m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} -: ${AR_FLAGS=cru} +: ${AR_FLAGS=cr} _LT_DECL([], [AR], [1], [The archiver]) _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) @@ -1427,11 +1502,11 @@ AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -eq 0; then + if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -ne 0; then + if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi @@ -1439,7 +1514,7 @@ AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], ]) ]) -if test "x$lt_cv_ar_at_file" = xno; then +if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file @@ -1470,7 +1545,7 @@ old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in - openbsd*) + bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) @@ -1506,7 +1581,7 @@ AC_CACHE_CHECK([$1], [$2], [$2=no m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" + lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins @@ -1533,7 +1608,7 @@ AC_CACHE_CHECK([$1], [$2], $RM conftest* ]) -if test x"[$]$2" = xyes; then +if test yes = "[$]$2"; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) @@ -1555,7 +1630,7 @@ AC_DEFUN([_LT_LINKER_OPTION], m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no - save_LDFLAGS="$LDFLAGS" + save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $3" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then @@ -1574,10 +1649,10 @@ AC_CACHE_CHECK([$1], [$2], fi fi $RM -r conftest* - LDFLAGS="$save_LDFLAGS" + LDFLAGS=$save_LDFLAGS ]) -if test x"[$]$2" = xyes; then +if test yes = "[$]$2"; then m4_if([$4], , :, [$4]) else m4_if([$5], , :, [$5]) @@ -1598,7 +1673,7 @@ AC_DEFUN([LT_CMD_MAX_LEN], AC_MSG_CHECKING([the maximum length of command line arguments]) AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl i=0 - teststring="ABCD" + teststring=ABCD case $build_os in msdosdjgpp*) @@ -1638,7 +1713,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl lt_cv_sys_max_cmd_len=8192; ;; - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` @@ -1688,22 +1763,23 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len"; then + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do + for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. - while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ + while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough + test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring @@ -1719,7 +1795,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl ;; esac ]) -if test -n $lt_cv_sys_max_cmd_len ; then +if test -n "$lt_cv_sys_max_cmd_len"; then AC_MSG_RESULT($lt_cv_sys_max_cmd_len) else AC_MSG_RESULT(none) @@ -1747,7 +1823,7 @@ m4_defun([_LT_HEADER_DLFCN], # ---------------------------------------------------------------- m4_defun([_LT_TRY_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl -if test "$cross_compiling" = yes; then : +if test yes = "$cross_compiling"; then : [$4] else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 @@ -1794,9 +1870,9 @@ else # endif #endif -/* When -fvisbility=hidden is used, assume the code has been annotated +/* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif @@ -1822,7 +1898,7 @@ int main () return status; }] _LT_EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then + if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null lt_status=$? case x$lt_status in @@ -1843,7 +1919,7 @@ rm -fr conftest* # ------------------ AC_DEFUN([LT_SYS_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then +if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown @@ -1853,44 +1929,52 @@ else case $host_os in beos*) - lt_cv_dlopen="load_add_on" + lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin*) - lt_cv_dlopen="dlopen" + lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) - # if libdl is installed we need to link against it + # if libdl is installed we need to link against it AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ + lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ]) ;; + tpf*) + # Don't try to run any link tests for TPF. We know it's impossible + # because TPF is a cross-compiler, and we know how we open DSOs. + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + lt_cv_dlopen_self=no + ;; + *) AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], + [lt_cv_dlopen=shl_load], [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], + [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], + [lt_cv_dlopen=dlopen], [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) + [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) ]) ]) ]) @@ -1899,21 +1983,21 @@ else ;; esac - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else + if test no = "$lt_cv_dlopen"; then enable_dlopen=no + else + enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + save_CPPFLAGS=$CPPFLAGS + test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - save_LDFLAGS="$LDFLAGS" + save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - save_LIBS="$LIBS" + save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" AC_CACHE_CHECK([whether a program can dlopen itself], @@ -1923,7 +2007,7 @@ else lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) ]) - if test "x$lt_cv_dlopen_self" = xyes; then + if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" AC_CACHE_CHECK([whether a statically linked program can dlopen itself], lt_cv_dlopen_self_static, [dnl @@ -1933,9 +2017,9 @@ else ]) fi - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" + CPPFLAGS=$save_CPPFLAGS + LDFLAGS=$save_LDFLAGS + LIBS=$save_LIBS ;; esac @@ -2027,8 +2111,8 @@ m4_defun([_LT_COMPILER_FILE_LOCKS], m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_COMPILER_C_O([$1]) -hard_links="nottested" -if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then +hard_links=nottested +if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user AC_MSG_CHECKING([if we can lock with hard links]) hard_links=yes @@ -2038,8 +2122,8 @@ if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) + if test no = "$hard_links"; then + AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) need_locks=warn fi else @@ -2066,8 +2150,8 @@ objdir=$lt_cv_objdir _LT_DECL([], [objdir], [0], [The name of the directory that contains temporary libtool files])dnl m4_pattern_allow([LT_OBJDIR])dnl -AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", - [Define to the sub-directory in which libtool stores uninstalled libraries.]) +AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", + [Define to the sub-directory where libtool stores uninstalled libraries.]) ])# _LT_CHECK_OBJDIR @@ -2079,15 +2163,15 @@ m4_defun([_LT_LINKER_HARDCODE_LIBPATH], _LT_TAGVAR(hardcode_action, $1)= if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || test -n "$_LT_TAGVAR(runpath_var, $1)" || - test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then + test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then # We can hardcode non-existent directories. - if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && + if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && + test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then # Linking always hardcodes the temporary library directory. _LT_TAGVAR(hardcode_action, $1)=relink else @@ -2101,12 +2185,12 @@ else fi AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) -if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || - test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then +if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || + test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then # Fast installation is not supported enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi @@ -2130,7 +2214,7 @@ else # FIXME - insert some real tests, host_os isn't really good enough case $host_os in darwin*) - if test -n "$STRIP" ; then + if test -n "$STRIP"; then striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) @@ -2148,6 +2232,47 @@ _LT_DECL([], [striplib], [1]) ])# _LT_CMD_STRIPLIB +# _LT_PREPARE_MUNGE_PATH_LIST +# --------------------------- +# Make sure func_munge_path_list() is defined correctly. +m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], +[[# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x@S|@2 in + x) + ;; + *:) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" + ;; + x:*) + eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" + ;; + *) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + esac +} +]])# _LT_PREPARE_PATH_LIST + + # _LT_SYS_DYNAMIC_LINKER([TAG]) # ----------------------------- # PORTME Fill in your ld.so characteristics @@ -2158,17 +2283,18 @@ m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_OBJDUMP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl AC_MSG_CHECKING([dynamic linker characteristics]) m4_if([$1], [], [ -if test "$GCC" = yes; then +if test yes = "$GCC"; then case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; + darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; + *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in - mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; - *) lt_sed_strip_eq="s,=/,/,g" ;; + mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; + *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in @@ -2184,28 +2310,35 @@ if test "$GCC" = yes; then ;; esac # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. + # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + # ...but if some path component already ends with the multilib dir we assume + # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). + case "$lt_multi_os_dir; $lt_search_path_spec " in + "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) + lt_multi_os_dir= + ;; + esac for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else + if test -d "$lt_sys_path$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" + elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; +BEGIN {RS = " "; FS = "/|\n";} { + lt_foo = ""; + lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; + lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } @@ -2219,7 +2352,7 @@ BEGIN {RS=" "; FS="/|\n";} { # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; + $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else @@ -2228,7 +2361,7 @@ fi]) library_names_spec= libname_spec='lib$name' soname_spec= -shrext_cmds=".so" +shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= @@ -2245,14 +2378,17 @@ hardcode_into_libs=no # flags to be left without arguments need_version=unknown +AC_ARG_VAR([LT_SYS_LIBRARY_PATH], +[User-defined run-time library search path.]) + case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' + soname_spec='$libname$release$shared_ext$major' ;; aix[[4-9]]*) @@ -2260,41 +2396,91 @@ aix[[4-9]]*) need_lib_prefix=no need_version=no hardcode_into_libs=yes - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[[01]] | aix4.[[01]].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib<name>.so # instead of lib<name>.a to let people know that these are not # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a[(]lib.so.V[)]' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac shlibpath_var=LIBPATH fi ;; @@ -2304,18 +2490,18 @@ amigaos*) powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) - library_names_spec='${libname}${shared_ext}' + library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; @@ -2323,8 +2509,8 @@ beos*) bsdi[[45]]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" @@ -2336,7 +2522,7 @@ bsdi[[45]]*) cygwin* | mingw* | pw32* | cegcc*) version_type=windows - shrext_cmds=".dll" + shrext_cmds=.dll need_version=no need_lib_prefix=no @@ -2345,8 +2531,8 @@ cygwin* | mingw* | pw32* | cegcc*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ @@ -2362,17 +2548,17 @@ cygwin* | mingw* | pw32* | cegcc*) case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; mingw* | cegcc*) # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' @@ -2381,8 +2567,8 @@ m4_if([$1], [],[ *,cl*) # Native MSVC libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' case $build_os in mingw*) @@ -2409,7 +2595,7 @@ m4_if([$1], [],[ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) - sys_lib_search_path_spec="$LIB" + sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` @@ -2422,8 +2608,8 @@ m4_if([$1], [],[ esac # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' @@ -2436,7 +2622,7 @@ m4_if([$1], [],[ *) # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' + library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac @@ -2449,8 +2635,8 @@ darwin* | rhapsody*) version_type=darwin need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' @@ -2463,8 +2649,8 @@ dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; @@ -2482,12 +2668,13 @@ freebsd* | dragonfly*) version_type=freebsd-$objformat case $version_type in freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac @@ -2512,26 +2699,15 @@ freebsd* | dragonfly*) esac ;; -gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes + shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; @@ -2549,14 +2725,15 @@ hpux9* | hpux10* | hpux11*) dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' @@ -2564,8 +2741,8 @@ hpux9* | hpux10* | hpux11*) dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; @@ -2574,8 +2751,8 @@ hpux9* | hpux10* | hpux11*) dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... @@ -2588,8 +2765,8 @@ interix[[3-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no @@ -2600,7 +2777,7 @@ irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) - if test "$lt_cv_prog_gnu_ld" = yes; then + if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix @@ -2608,8 +2785,8 @@ irix5* | irix6* | nonstopux*) esac need_lib_prefix=no need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= @@ -2628,8 +2805,8 @@ irix5* | irix6* | nonstopux*) esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; @@ -2638,13 +2815,33 @@ linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + ;; + # This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu) +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no @@ -2669,14 +2866,15 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu) # before this can be enabled. hardcode_into_libs=yes - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - - # Append ld.so.conf contents to the search path + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -2688,17 +2886,29 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu) dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH @@ -2708,7 +2918,7 @@ netbsd*) newsos6) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; @@ -2717,58 +2927,68 @@ newsos6) version_type=qnx need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; -openbsd*) +openbsd* | bitrig*) version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" + sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no else - shlibpath_overrides_runpath=yes + need_version=yes fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' - shrext_cmds=".dll" + version_type=windows + shrext_cmds=.dll + need_version=no need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) @@ -2779,8 +2999,8 @@ solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes @@ -2790,11 +3010,11 @@ solaris*) sunos4*) version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then + if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes @@ -2802,8 +3022,8 @@ sunos4*) sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) @@ -2824,24 +3044,24 @@ sysv4 | sysv4.3*) ;; sysv4*MP*) - if test -d /usr/nec ;then + if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf + version_type=sco need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then + if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' @@ -2859,7 +3079,7 @@ tpf*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes @@ -2867,8 +3087,8 @@ tpf*) uts4*) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; @@ -2877,20 +3097,30 @@ uts4*) ;; esac AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no +test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then +if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + _LT_DECL([], [variables_saved_for_relink], [1], [Variables whose values should be saved in libtool wrapper scripts and restored at link time]) @@ -2923,39 +3153,41 @@ _LT_DECL([], [hardcode_into_libs], [0], [Whether we should hardcode library paths into libraries]) _LT_DECL([], [sys_lib_search_path_spec], [2], [Compile-time system search path for libraries]) -_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], - [Run-time system search path for libraries]) +_LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], + [Detected run-time system search path for libraries]) +_LT_DECL([], [configure_time_lt_sys_library_path], [2], + [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) ])# _LT_SYS_DYNAMIC_LINKER # _LT_PATH_TOOL_PREFIX(TOOL) # -------------------------- -# find a file program which can recognize shared library +# find a file program that can recognize shared library AC_DEFUN([_LT_PATH_TOOL_PREFIX], [m4_require([_LT_DECL_EGREP])dnl AC_MSG_CHECKING([for $1]) AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, [case $MAGIC_CMD in [[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. ac_dummy="m4_if([$2], , $PATH, [$2])" for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" + if test -f "$ac_dir/$1"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"$1" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : @@ -2978,11 +3210,11 @@ _LT_EOF break fi done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then AC_MSG_RESULT($MAGIC_CMD) else @@ -3000,7 +3232,7 @@ dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) # _LT_PATH_MAGIC # -------------- -# find a file program which can recognize a shared library +# find a file program that can recognize a shared library m4_defun([_LT_PATH_MAGIC], [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then @@ -3027,16 +3259,16 @@ m4_require([_LT_PROG_ECHO_BACKSLASH])dnl AC_ARG_WITH([gnu-ld], [AS_HELP_STRING([--with-gnu-ld], [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], + [test no = "$withval" || with_gnu_ld=yes], [with_gnu_ld=no])dnl ac_prog=ld -if test "$GCC" = yes; then +if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw + # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; @@ -3050,7 +3282,7 @@ if test "$GCC" = yes; then while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done - test -z "$LD" && LD="$ac_prog" + test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. @@ -3061,37 +3293,37 @@ if test "$GCC" = yes; then with_gnu_ld=unknown ;; esac -elif test "$with_gnu_ld" = yes; then +elif test yes = "$with_gnu_ld"; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" + lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) - test "$with_gnu_ld" != no && break + test no != "$with_gnu_ld" && break ;; *) - test "$with_gnu_ld" != yes && break + test yes != "$with_gnu_ld" && break ;; esac fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs else - lt_cv_path_LD="$LD" # Let the user override the test with a path. + lt_cv_path_LD=$LD # Let the user override the test with a path. fi]) -LD="$lt_cv_path_LD" +LD=$lt_cv_path_LD if test -n "$LD"; then AC_MSG_RESULT($LD) else @@ -3145,13 +3377,13 @@ esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in cygwin* | mingw* | pw32* | cegcc*) - if test "$GCC" != yes; then + if test yes != "$GCC"; then reload_cmds=false fi ;; darwin*) - if test "$GCC" = yes; then - reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + if test yes = "$GCC"; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi @@ -3162,6 +3394,43 @@ _LT_TAGDECL([], [reload_cmds], [2])dnl ])# _LT_CMD_RELOAD +# _LT_PATH_DD +# ----------- +# find a working dd +m4_defun([_LT_PATH_DD], +[AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD], +[printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +: ${lt_DD:=$DD} +AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], +[if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: +fi]) +rm -f conftest.i conftest2.i conftest.out]) +])# _LT_PATH_DD + + +# _LT_CMD_TRUNCATE +# ---------------- +# find command to truncate a binary pipe +m4_defun([_LT_CMD_TRUNCATE], +[m4_require([_LT_PATH_DD]) +AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], +[printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +lt_cv_truncate_bin= +if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" +fi +rm -f conftest.i conftest2.i conftest.out +test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) +_LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], + [Command to truncate a binary pipe]) +])# _LT_CMD_TRUNCATE + + # _LT_CHECK_MAGIC_METHOD # ---------------------- # how to check for library dependencies @@ -3177,13 +3446,13 @@ lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. +# 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. +# that responds to the $file_magic_cmd with a given extended regex. +# If you have 'file' or equivalent on your system and you're not sure +# whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[[4-9]]*) @@ -3210,8 +3479,7 @@ mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. - # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. - if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then + if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else @@ -3247,10 +3515,6 @@ freebsd* | dragonfly*) fi ;; -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - haiku*) lt_cv_deplibs_check_method=pass_all ;; @@ -3289,11 +3553,11 @@ irix5* | irix6* | nonstopux*) ;; # This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu) +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else @@ -3311,8 +3575,8 @@ newos6*) lt_cv_deplibs_check_method=pass_all ;; -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then +openbsd* | bitrig*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' @@ -3365,6 +3629,9 @@ sysv4 | sysv4.3*) tpf*) lt_cv_deplibs_check_method=pass_all ;; +os2*) + lt_cv_deplibs_check_method=pass_all + ;; esac ]) @@ -3405,33 +3672,38 @@ AC_DEFUN([LT_PATH_NM], AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, [if test -n "$NM"; then # Let the user override the test. - lt_cv_path_NM="$NM" + lt_cv_path_NM=$NM else - lt_nm_to_check="${ac_tool_prefix}nm" + lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + tmp_nm=$ac_dir/$lt_tmp_nm + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) + # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty + case $build_os in + mingw*) lt_bad_file=conftest.nm/nofile ;; + *) lt_bad_file=/dev/null ;; + esac + case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" - break + break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" - break + break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but @@ -3442,21 +3714,21 @@ else esac fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi]) -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" +if test no != "$lt_cv_path_NM"; then + NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) - case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in *COFF*) - DUMPBIN="$DUMPBIN -symbols" + DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: @@ -3464,8 +3736,8 @@ else esac fi AC_SUBST([DUMPBIN]) - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" + if test : != "$DUMPBIN"; then + NM=$DUMPBIN fi fi test -z "$NM" && NM=nm @@ -3511,8 +3783,8 @@ lt_cv_sharedlib_from_linklib_cmd, case $host_os in cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh - # decide which to use based on capabilities of $DLLTOOL + # two different shell functions defined in ltmain.sh; + # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib @@ -3524,7 +3796,7 @@ cygwin* | mingw* | pw32* | cegcc*) ;; *) # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd="$ECHO" + lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac ]) @@ -3551,13 +3823,28 @@ AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool lt_cv_path_mainfest_tool=yes fi rm -f conftest*]) -if test "x$lt_cv_path_mainfest_tool" != xyes; then +if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl ])# _LT_PATH_MANIFEST_TOOL +# _LT_DLL_DEF_P([FILE]) +# --------------------- +# True iff FILE is a Windows DLL '.def' file. +# Keep in sync with func_dll_def_p in the libtool script +AC_DEFUN([_LT_DLL_DEF_P], +[dnl + test DEF = "`$SED -n dnl + -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace + -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments + -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl + -e q dnl Only consider the first "real" line + $1`" dnl +])# _LT_DLL_DEF_P + + # LT_LIB_M # -------- # check for math library @@ -3569,11 +3856,11 @@ case $host in # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") ;; *) - AC_CHECK_LIB(m, cos, LIBM="-lm") + AC_CHECK_LIB(m, cos, LIBM=-lm) ;; esac AC_SUBST([LIBM]) @@ -3592,7 +3879,7 @@ m4_defun([_LT_COMPILER_NO_RTTI], _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= -if test "$GCC" = yes; then +if test yes = "$GCC"; then case $cc_basename in nvcc*) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; @@ -3644,7 +3931,7 @@ cygwin* | mingw* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then symcode='[[ABCDEGRST]]' fi ;; @@ -3677,14 +3964,44 @@ case `$NM -V 2>&1` in symcode='[[ABCDGIRSTW]]' ;; esac +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Gets list of data symbols to import. + lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + # Adjust the below global symbol transforms to fixup imported variables. + lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" + lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" + lt_c_name_lib_hook="\ + -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ + -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" +else + # Disable hooks by default. + lt_cv_sys_global_symbol_to_import= + lt_cdecl_hook= + lt_c_name_hook= + lt_c_name_lib_hook= +fi + # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" +lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +$lt_cdecl_hook\ +" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +$lt_c_name_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" + +# Transform an extracted symbol line into symbol name with lib prefix and +# symbol address. +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +$lt_c_name_lib_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= @@ -3702,21 +4019,24 @@ for ac_symprfx in "" "_"; do # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. + # Fake it for dumpbin and say T for any non-static function, + # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ +" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ +" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ +" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ +" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" @@ -3743,7 +4063,8 @@ _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" @@ -3756,11 +4077,11 @@ _LT_EOF if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime +#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE +/* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT@&t@_DLSYM_CONST -#elif defined(__osf__) +#elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT@&t@_DLSYM_CONST #else @@ -3786,7 +4107,7 @@ lt__PROGRAM__LTX_preloaded_symbols[[]] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; @@ -3806,9 +4127,9 @@ _LT_EOF mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS - LIBS="conftstm.$ac_objext" + LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then + if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS @@ -3829,7 +4150,7 @@ _LT_EOF rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then + if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= @@ -3856,12 +4177,16 @@ _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], [Take the output of nm and produce a listing of raw symbols and C names]) _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], [Transform the output of nm in a proper C declaration]) +_LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], + [Transform the output of nm into a list of symbols to manually relocate]) _LT_DECL([global_symbol_to_c_name_address], [lt_cv_sys_global_symbol_to_c_name_address], [1], [Transform the output of nm in a C name address pair]) _LT_DECL([global_symbol_to_c_name_address_lib_prefix], [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], [Transform the output of nm in a C name address pair when lib prefix is needed]) +_LT_DECL([nm_interface], [lt_cv_nm_interface], [1], + [The name lister interface]) _LT_DECL([], [nm_file_list_spec], [1], [Specify filename containing input files for $NM]) ]) # _LT_CMD_GLOBAL_SYMBOLS @@ -3877,17 +4202,18 @@ _LT_TAGVAR(lt_prog_compiler_static, $1)= m4_if([$1], [CXX], [ # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then + if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) @@ -3898,8 +4224,8 @@ m4_if([$1], [CXX], [ ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac @@ -3915,6 +4241,11 @@ m4_if([$1], [CXX], [ # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac ;; darwin* | rhapsody*) # PIC is the default on this platform @@ -3964,7 +4295,7 @@ m4_if([$1], [CXX], [ case $host_os in aix[[4-9]]*) # All AIX code is PIC. - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else @@ -4005,14 +4336,14 @@ m4_if([$1], [CXX], [ case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - if test "$host_cpu" != ia64; then + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + if test ia64 != "$host_cpu"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' fi ;; aCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default @@ -4041,7 +4372,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler @@ -4049,7 +4380,7 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; ecpc* ) - # old Intel C++ for x86_64 which still supported -KPIC. + # old Intel C++ for x86_64, which still supported -KPIC. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' @@ -4105,7 +4436,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise @@ -4194,17 +4525,18 @@ m4_if([$1], [CXX], [ fi ], [ - if test "$GCC" = yes; then + if test yes = "$GCC"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) @@ -4215,8 +4547,8 @@ m4_if([$1], [CXX], [ ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac @@ -4233,6 +4565,11 @@ m4_if([$1], [CXX], [ # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac ;; darwin* | rhapsody*) @@ -4303,7 +4640,7 @@ m4_if([$1], [CXX], [ case $host_os in aix*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else @@ -4311,11 +4648,30 @@ m4_if([$1], [CXX], [ fi ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + case $cc_basename in + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac ;; hpux9* | hpux10* | hpux11*) @@ -4331,7 +4687,7 @@ m4_if([$1], [CXX], [ ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) @@ -4340,14 +4696,20 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. + # old Intel for x86_64, which still supported -KPIC. ecc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; + # flang / f18. f95 an alias for gfortran or flang on Debian + flang* | f18* | f95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) @@ -4367,6 +4729,12 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) @@ -4464,7 +4832,7 @@ m4_if([$1], [CXX], [ ;; sysv4*MP*) - if test -d /usr/nec ;then + if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi @@ -4493,7 +4861,7 @@ m4_if([$1], [CXX], [ fi ]) case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: + # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; @@ -4559,17 +4927,21 @@ m4_if([$1], [CXX], [ case $host_os in aix[[4-9]]*) # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global defined - # symbols, whereas GNU nm marks them as "W". + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) - _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" + _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds ;; cygwin* | mingw* | cegcc*) case $cc_basename in @@ -4582,6 +4954,9 @@ m4_if([$1], [CXX], [ ;; esac ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; @@ -4615,9 +4990,9 @@ m4_if([$1], [CXX], [ # included in the symbol list _LT_TAGVAR(include_expsyms, $1)= # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. + # it will be wrapped by ' (' and ')$', so one must not match beginning or + # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', + # as well as any symbol that contains 'd'. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if @@ -4633,7 +5008,7 @@ dnl Note also adjust exclude_expsyms for C++ above. # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. - if test "$GCC" != yes; then + if test yes != "$GCC"; then with_gnu_ld=no fi ;; @@ -4641,9 +5016,12 @@ dnl Note also adjust exclude_expsyms for C++ above. # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; - openbsd*) + openbsd* | bitrig*) with_gnu_ld=no ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes @@ -4651,7 +5029,7 @@ dnl Note also adjust exclude_expsyms for C++ above. # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no - if test "$with_gnu_ld" = yes; then + if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility @@ -4673,24 +5051,24 @@ dnl Note also adjust exclude_expsyms for C++ above. esac fi - if test "$lt_use_gnu_ld_interface" = yes; then + if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' + wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no - case `$LD -v 2>&1` in + case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... @@ -4703,7 +5081,7 @@ dnl Note also adjust exclude_expsyms for C++ above. case $host_os in aix[[3-9]]*) # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then + if test ia64 != "$host_cpu"; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 @@ -4722,7 +5100,7 @@ _LT_EOF case $host_cpu in powerpc) # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) @@ -4738,7 +5116,7 @@ _LT_EOF _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -4748,7 +5126,7 @@ _LT_EOF # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes @@ -4756,61 +5134,89 @@ _LT_EOF _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no - if test "$host_os" = linux-dietlibc; then + if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no + && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; @@ -4821,42 +5227,47 @@ _LT_EOF lf95*) # Lahey Fortran 8.1 _LT_TAGVAR(whole_archive_flag_spec, $1)= tmp_sharedflag='--shared' ;; + nagfor*) # NAGFOR 5.3 + tmp_sharedflag='-Wl,-shared' ;; xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac - _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then + if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in + tcc*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' + ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then + if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac @@ -4865,13 +5276,13 @@ _LT_EOF fi ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; @@ -4889,8 +5300,8 @@ _LT_EOF _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -4902,7 +5313,7 @@ _LT_EOF _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify @@ -4917,9 +5328,9 @@ _LT_EOF # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -4936,15 +5347,15 @@ _LT_EOF *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac - if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then + if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then runpath_var= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= @@ -4960,7 +5371,7 @@ _LT_EOF # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. _LT_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_TAGVAR(hardcode_direct, $1)=unsupported @@ -4968,34 +5379,57 @@ _LT_EOF ;; aix[[4-9]]*) - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' - no_entry_flag="" + no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global - # defined symbols, whereas GNU nm marks them as "W". + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi ;; esac @@ -5014,13 +5448,21 @@ _LT_EOF _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # traditional, no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac - if test "$GCC" = yes; then + if test yes = "$GCC"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` + collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then @@ -5039,61 +5481,80 @@ _LT_EOF ;; esac shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag="$shared_flag "'$wl-G' fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' else # not using gcc - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' else - shared_flag='${wl}-bM:SRE' + shared_flag='$wl-bM:SRE' fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' fi fi - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; @@ -5102,7 +5563,7 @@ _LT_EOF case $host_cpu in powerpc) # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) @@ -5132,16 +5593,17 @@ _LT_EOF # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" + shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes @@ -5150,18 +5612,18 @@ _LT_EOF # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' ;; *) # Assume MSVC wrapper @@ -5170,7 +5632,7 @@ _LT_EOF # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" + shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. @@ -5220,33 +5682,33 @@ _LT_EOF ;; hpux9*) - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; hpux10*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + if test yes,no = "$GCC,$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes @@ -5254,25 +5716,25 @@ _LT_EOF ;; hpux11*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then + if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) m4_if($1, [], [ @@ -5280,14 +5742,14 @@ _LT_EOF # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) _LT_LINKER_OPTION([if $CC understands -b], _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) ;; esac fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in @@ -5298,7 +5760,7 @@ _LT_EOF *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. @@ -5309,16 +5771,16 @@ _LT_EOF ;; irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], [lt_cv_irix_exported_symbol], - [save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + [save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" AC_LINK_IFELSE( [AC_LANG_SOURCE( [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], @@ -5331,22 +5793,33 @@ _LT_EOF end]])])], [lt_cv_irix_exported_symbol=yes], [lt_cv_irix_exported_symbol=no]) - LDFLAGS="$save_LDFLAGS"]) - if test "$lt_cv_irix_exported_symbol" = yes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + LDFLAGS=$save_LDFLAGS]) + if test yes = "$lt_cv_irix_exported_symbol"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi + _LT_TAGVAR(link_all_deplibs, $1)=no else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes _LT_TAGVAR(link_all_deplibs, $1)=yes ;; - netbsd*) + linux*) + case $cc_basename in + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(ld_shlibs, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else @@ -5360,7 +5833,7 @@ _LT_EOF newsos6) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; @@ -5368,27 +5841,19 @@ _LT_EOF *nto* | *qnx*) ;; - openbsd*) + openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' fi else _LT_TAGVAR(ld_shlibs, $1)=no @@ -5399,33 +5864,53 @@ _LT_EOF _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; osf3*) - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ - $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' @@ -5436,24 +5921,24 @@ _LT_EOF solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + if test yes = "$GCC"; then + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' - _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi @@ -5463,11 +5948,11 @@ _LT_EOF solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', + # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + if test yes = "$GCC"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' fi @@ -5477,10 +5962,10 @@ _LT_EOF ;; sunos4*) - if test "x$host_vendor" = xsequent; then + if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi @@ -5529,43 +6014,43 @@ _LT_EOF ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not + # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; @@ -5580,17 +6065,17 @@ _LT_EOF ;; esac - if test x$host_vendor = xsni; then + if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' ;; esac fi fi ]) AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) -test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no +test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld @@ -5607,7 +6092,7 @@ x|xyes) # Assume -lc should be added _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - if test "$enable_shared" = yes && test "$GCC" = yes; then + if test yes,yes = "$GCC,$enable_shared"; then case $_LT_TAGVAR(archive_cmds, $1) in *'~'*) # FIXME: we may have to deal with multi-command sequences. @@ -5687,12 +6172,12 @@ _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], _LT_TAGDECL([], [hardcode_libdir_separator], [1], [Whether we need a single "-rpath" flag with a separated argument]) _LT_TAGDECL([], [hardcode_direct], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_direct_absolute], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary and the resulting library dependency is - "absolute", i.e impossible to change by setting ${shlibpath_var} if the + "absolute", i.e impossible to change by setting $shlibpath_var if the library is relocated]) _LT_TAGDECL([], [hardcode_minus_L], [0], [Set to "yes" if using the -LDIR flag during linking hardcodes DIR @@ -5733,10 +6218,10 @@ dnl [Compiler flag to generate thread safe objects]) # ------------------------ # Ensure that the configuration variables for a C compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. +# the compiler configuration to 'libtool'. m4_defun([_LT_LANG_C_CONFIG], [m4_require([_LT_DECL_EGREP])dnl -lt_save_CC="$CC" +lt_save_CC=$CC AC_LANG_PUSH(C) # Source file extension for C test sources. @@ -5776,18 +6261,18 @@ if test -n "$compiler"; then LT_SYS_DLOPEN_SELF _LT_CMD_STRIPLIB - # Report which library types will actually be built + # Report what library types will actually be built AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no + test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) - test "$enable_shared" = yes && enable_static=no + test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' @@ -5795,8 +6280,12 @@ if test -n "$compiler"; then ;; aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac fi ;; esac @@ -5804,13 +6293,13 @@ if test -n "$compiler"; then AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes + test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_CONFIG($1) fi AC_LANG_POP -CC="$lt_save_CC" +CC=$lt_save_CC ])# _LT_LANG_C_CONFIG @@ -5818,14 +6307,14 @@ CC="$lt_save_CC" # -------------------------- # Ensure that the configuration variables for a C++ compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. +# the compiler configuration to 'libtool'. m4_defun([_LT_LANG_CXX_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then +if test -n "$CXX" && ( test no != "$CXX" && + ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || + (test g++ != "$CXX"))); then AC_PROG_CXXCPP else _lt_caught_CXX_error=yes @@ -5867,7 +6356,7 @@ _LT_TAGVAR(objext, $1)=$objext # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_caught_CXX_error" != yes; then +if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" @@ -5909,35 +6398,35 @@ if test "$_lt_caught_CXX_error" != yes; then if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately - if test "$GXX" = yes; then + if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi - if test "$GXX" = yes; then + if test yes = "$GXX"; then # Set up default GNU C++ configuration LT_PATH_LD # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + if test yes = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) - wlarc='${wl}' + wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi @@ -5956,7 +6445,7 @@ if test "$_lt_caught_CXX_error" != yes; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else GXX=no @@ -5973,18 +6462,30 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=no ;; aix[[4-9]]*) - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' - no_entry_flag="" + no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do case $ld_flag in @@ -5994,6 +6495,13 @@ if test "$_lt_caught_CXX_error" != yes; then ;; esac done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi ;; esac @@ -6012,13 +6520,21 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac - if test "$GXX" = yes; then + if test yes = "$GXX"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` + collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then @@ -6036,64 +6552,84 @@ if test "$_lt_caught_CXX_error" != yes; then fi esac shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag=$shared_flag' $wl-G' fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' else # not using gcc - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' else - shared_flag='${wl}-bM:SRE' + shared_flag='$wl-bM:SRE' fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' fi fi - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # The "-G" linker flag allows undefined symbols. + _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared - # libraries. - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared + # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; @@ -6103,7 +6639,7 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -6131,57 +6667,58 @@ if test "$_lt_caught_CXX_error" != yes; then # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" + shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - func_to_tool_file "$lt_outputfile"~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -6192,6 +6729,34 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_DARWIN_LINKER_FEATURES($1) ;; + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + dgux*) case $cc_basename in ec++*) @@ -6226,18 +6791,15 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=yes ;; - gnu*) - ;; - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; hpux9*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default @@ -6249,7 +6811,7 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. @@ -6258,11 +6820,11 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) - if test "$GXX" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + if test yes = "$GXX"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no @@ -6272,15 +6834,15 @@ if test "$_lt_caught_CXX_error" != yes; then ;; hpux10*|hpux11*) - if test $with_gnu_ld = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) ;; *) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; esac fi @@ -6306,13 +6868,13 @@ if test "$_lt_caught_CXX_error" != yes; then aCC*) case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists @@ -6323,20 +6885,20 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi @@ -6351,22 +6913,22 @@ if test "$_lt_caught_CXX_error" != yes; then interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is @@ -6375,22 +6937,22 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi _LT_TAGVAR(link_all_deplibs, $1)=yes ;; esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler @@ -6398,8 +6960,8 @@ if test "$_lt_caught_CXX_error" != yes; then # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. @@ -6408,10 +6970,10 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. @@ -6425,59 +6987,59 @@ if test "$_lt_caught_CXX_error" != yes; then # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac - _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ - $RANLIB $oldlib' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' @@ -6491,18 +7053,18 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) @@ -6510,10 +7072,10 @@ if test "$_lt_caught_CXX_error" != yes; then *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes # Not sure whether something based on @@ -6571,22 +7133,17 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=yes ;; - openbsd2*) - # C++ shared libraries are fairly broken - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - openbsd*) + openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else @@ -6602,9 +7159,9 @@ if test "$_lt_caught_CXX_error" != yes; then # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using @@ -6622,17 +7179,17 @@ if test "$_lt_caught_CXX_error" != yes; then cxx*) case $host in osf3*) - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; *) _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ - $RM $lib.exp' + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ + $RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' ;; esac @@ -6647,27 +7204,27 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' case $host in osf3*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else # FIXME: insert proper C++ library support @@ -6707,9 +7264,9 @@ if test "$_lt_caught_CXX_error" != yes; then # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no @@ -6717,7 +7274,7 @@ if test "$_lt_caught_CXX_error" != yes; then solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. + # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; @@ -6734,42 +7291,42 @@ if test "$_lt_caught_CXX_error" != yes; then ;; gcx*) # Green Hills C++ Compiler - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else - # g++ 2.7 appears to require `-G' NOT `-shared' on this + # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. - _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi @@ -6778,52 +7335,52 @@ if test "$_lt_caught_CXX_error" != yes; then ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not + # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ - '"$_LT_TAGVAR(old_archive_cmds, $1)" + '"$_LT_TAGVAR(old_archive_cmds, $1)" _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ - '"$_LT_TAGVAR(reload_cmds, $1)" + '"$_LT_TAGVAR(reload_cmds, $1)" ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; @@ -6854,10 +7411,10 @@ if test "$_lt_caught_CXX_error" != yes; then esac AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) - test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no + test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no - _LT_TAGVAR(GCC, $1)="$GXX" - _LT_TAGVAR(LD, $1)="$LD" + _LT_TAGVAR(GCC, $1)=$GXX + _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change @@ -6884,7 +7441,7 @@ if test "$_lt_caught_CXX_error" != yes; then lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test "$_lt_caught_CXX_error" != yes +fi # test yes != "$_lt_caught_CXX_error" AC_LANG_POP ])# _LT_LANG_CXX_CONFIG @@ -6906,13 +7463,14 @@ AC_REQUIRE([_LT_DECL_SED]) AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) func_stripname_cnf () { - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + case @S|@2 in + .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; + *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; esac } # func_stripname_cnf ])# _LT_FUNC_STRIPNAME_CNF + # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose @@ -6996,13 +7554,13 @@ if AC_TRY_EVAL(ac_compile); then pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do - case ${prev}${p} in + case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. - if test $p = "-L" || - test $p = "-R"; then + if test x-L = "$p" || + test x-R = "$p"; then prev=$p continue fi @@ -7018,16 +7576,16 @@ if AC_TRY_EVAL(ac_compile); then case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac - if test "$pre_test_object_deps_done" = no; then - case ${prev} in + if test no = "$pre_test_object_deps_done"; then + case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then - _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" + _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p else - _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" + _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" fi ;; # The "-l" case would never come before the object being @@ -7035,9 +7593,9 @@ if AC_TRY_EVAL(ac_compile); then esac else if test -z "$_LT_TAGVAR(postdeps, $1)"; then - _LT_TAGVAR(postdeps, $1)="${prev}${p}" + _LT_TAGVAR(postdeps, $1)=$prev$p else - _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" + _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" fi fi prev= @@ -7052,15 +7610,15 @@ if AC_TRY_EVAL(ac_compile); then continue fi - if test "$pre_test_object_deps_done" = no; then + if test no = "$pre_test_object_deps_done"; then if test -z "$_LT_TAGVAR(predep_objects, $1)"; then - _LT_TAGVAR(predep_objects, $1)="$p" + _LT_TAGVAR(predep_objects, $1)=$p else _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" fi else if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then - _LT_TAGVAR(postdep_objects, $1)="$p" + _LT_TAGVAR(postdep_objects, $1)=$p else _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" fi @@ -7091,51 +7649,6 @@ interix[[3-9]]*) _LT_TAGVAR(postdep_objects,$1)= _LT_TAGVAR(postdeps,$1)= ;; - -linux*) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; - -solaris*) - case $cc_basename in - CC* | sunCC*) - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - # Adding this requires a known-good setup of shared libraries for - # Sun compiler versions before 5.6, else PIC objects from an old - # archive will be linked into the output, leading to subtle bugs. - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; esac ]) @@ -7144,7 +7657,7 @@ case " $_LT_TAGVAR(postdeps, $1) " in esac _LT_TAGVAR(compiler_lib_search_dirs, $1)= if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then - _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` + _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi _LT_TAGDECL([], [compiler_lib_search_dirs], [1], [The directories searched by this compiler when creating a shared library]) @@ -7164,10 +7677,10 @@ _LT_TAGDECL([], [compiler_lib_search_path], [1], # -------------------------- # Ensure that the configuration variables for a Fortran 77 compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_F77_CONFIG], [AC_LANG_PUSH(Fortran 77) -if test -z "$F77" || test "X$F77" = "Xno"; then +if test -z "$F77" || test no = "$F77"; then _lt_disable_F77=yes fi @@ -7204,7 +7717,7 @@ _LT_TAGVAR(objext, $1)=$objext # the F77 compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_F77" != yes; then +if test yes != "$_lt_disable_F77"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t @@ -7226,7 +7739,7 @@ if test "$_lt_disable_F77" != yes; then _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. - lt_save_CC="$CC" + lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${F77-"f77"} @@ -7240,21 +7753,25 @@ if test "$_lt_disable_F77" != yes; then AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no + test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) - test "$enable_shared" = yes && enable_static=no + test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac fi ;; esac @@ -7262,11 +7779,11 @@ if test "$_lt_disable_F77" != yes; then AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes + test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) - _LT_TAGVAR(GCC, $1)="$G77" - _LT_TAGVAR(LD, $1)="$LD" + _LT_TAGVAR(GCC, $1)=$G77 + _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change @@ -7283,9 +7800,9 @@ if test "$_lt_disable_F77" != yes; then fi # test -n "$compiler" GCC=$lt_save_GCC - CC="$lt_save_CC" - CFLAGS="$lt_save_CFLAGS" -fi # test "$_lt_disable_F77" != yes + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test yes != "$_lt_disable_F77" AC_LANG_POP ])# _LT_LANG_F77_CONFIG @@ -7295,11 +7812,11 @@ AC_LANG_POP # ------------------------- # Ensure that the configuration variables for a Fortran compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_FC_CONFIG], [AC_LANG_PUSH(Fortran) -if test -z "$FC" || test "X$FC" = "Xno"; then +if test -z "$FC" || test no = "$FC"; then _lt_disable_FC=yes fi @@ -7336,7 +7853,7 @@ _LT_TAGVAR(objext, $1)=$objext # the FC compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_FC" != yes; then +if test yes != "$_lt_disable_FC"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t @@ -7358,7 +7875,7 @@ if test "$_lt_disable_FC" != yes; then _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. - lt_save_CC="$CC" + lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${FC-"f95"} @@ -7374,21 +7891,25 @@ if test "$_lt_disable_FC" != yes; then AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no + test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) - test "$enable_shared" = yes && enable_static=no + test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac fi ;; esac @@ -7396,11 +7917,11 @@ if test "$_lt_disable_FC" != yes; then AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes + test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) - _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" - _LT_TAGVAR(LD, $1)="$LD" + _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu + _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change @@ -7420,7 +7941,7 @@ if test "$_lt_disable_FC" != yes; then GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS -fi # test "$_lt_disable_FC" != yes +fi # test yes != "$_lt_disable_FC" AC_LANG_POP ])# _LT_LANG_FC_CONFIG @@ -7430,7 +7951,7 @@ AC_LANG_POP # -------------------------- # Ensure that the configuration variables for the GNU Java Compiler compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GCJ_CONFIG], [AC_REQUIRE([LT_PROG_GCJ])dnl AC_LANG_SAVE @@ -7464,7 +7985,7 @@ CC=${GCJ-"gcj"} CFLAGS=$GCJFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" +_LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # GCJ did not exist at the time GCC didn't implicitly link libc in. @@ -7501,7 +8022,7 @@ CFLAGS=$lt_save_CFLAGS # -------------------------- # Ensure that the configuration variables for the GNU Go compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GO_CONFIG], [AC_REQUIRE([LT_PROG_GO])dnl AC_LANG_SAVE @@ -7535,7 +8056,7 @@ CC=${GOC-"gccgo"} CFLAGS=$GOFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" +_LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # Go did not exist at the time GCC didn't implicitly link libc in. @@ -7572,7 +8093,7 @@ CFLAGS=$lt_save_CFLAGS # ------------------------- # Ensure that the configuration variables for the Windows resource compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_RC_CONFIG], [AC_REQUIRE([LT_PROG_RC])dnl AC_LANG_SAVE @@ -7588,7 +8109,7 @@ _LT_TAGVAR(objext, $1)=$objext lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" +lt_simple_link_test_code=$lt_simple_compile_test_code # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER @@ -7598,7 +8119,7 @@ _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. -lt_save_CC="$CC" +lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC= @@ -7627,7 +8148,7 @@ AC_DEFUN([LT_PROG_GCJ], [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], [AC_CHECK_TOOL(GCJ, gcj,) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" + test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" AC_SUBST(GCJFLAGS)])])[]dnl ]) @@ -7738,7 +8259,7 @@ lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue + test ! -f "$lt_ac_sed" && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in @@ -7755,9 +8276,9 @@ for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break + test 10 -lt "$lt_ac_count" && break lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then + if test "$lt_ac_count" -gt "$lt_ac_max"; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi @@ -7781,27 +8302,7 @@ dnl AC_DEFUN([LT_AC_PROG_SED], []) # Find out whether the shell is Bourne or XSI compatible, # or has some other useful features. m4_defun([_LT_CHECK_SHELL_FEATURES], -[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,b/c, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -AC_MSG_RESULT([$xsi_shell]) -_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) - -AC_MSG_CHECKING([whether the shell understands "+="]) -lt_shell_append=no -( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -AC_MSG_RESULT([$lt_shell_append]) -_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then +[if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false @@ -7825,102 +8326,9 @@ _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl ])# _LT_CHECK_SHELL_FEATURES -# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) -# ------------------------------------------------------ -# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and -# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. -m4_defun([_LT_PROG_FUNCTION_REPLACE], -[dnl { -sed -e '/^$1 ()$/,/^} # $1 /c\ -$1 ()\ -{\ -m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) -} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: -]) - - -# _LT_PROG_REPLACE_SHELLFNS -# ------------------------- -# Replace existing portable implementations of several shell functions with -# equivalent extended shell implementations where those features are available.. -m4_defun([_LT_PROG_REPLACE_SHELLFNS], -[if test x"$xsi_shell" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl - # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are - # positional parameters, so assign one to ordinary parameter first. - func_stripname_result=${3} - func_stripname_result=${func_stripname_result#"${1}"} - func_stripname_result=${func_stripname_result%"${2}"}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl - func_split_long_opt_name=${1%%=*} - func_split_long_opt_arg=${1#*=}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl - func_split_short_opt_arg=${1#??} - func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) - - _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl - case ${1} in - *.lo) func_lo2o_result=${1%.lo}.${objext} ;; - *) func_lo2o_result=${1} ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) - - _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) - - _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) -fi - -if test x"$lt_shell_append" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) - - _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl - func_quote_for_eval "${2}" -dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ - eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) - - # Save a `func_append' function call where possible by direct use of '+=' - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -else - # Save a `func_append' function call even when '+=' is not available - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -fi - -if test x"$_lt_function_replace_fail" = x":"; then - AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) -fi -]) - # _LT_PATH_CONVERSION_FUNCTIONS # ----------------------------- -# Determine which file name conversion functions should be used by +# Determine what file name conversion functions should be used by # func_to_host_file (and, implicitly, by func_to_host_path). These are needed # for certain cross-compile configurations and native mingw. m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], diff --git a/v2.5/generators/nlojet++/m4/ltoptions.m4 b/v2.5/generators/nlojet++/m4/ltoptions.m4 index 5d9acd8e23bcfd20d353804aff13666ecbed54f4..94b082976667c0c9edf2e9ff7a668c1fd7d997bf 100644 --- a/v2.5/generators/nlojet++/m4/ltoptions.m4 +++ b/v2.5/generators/nlojet++/m4/ltoptions.m4 @@ -1,14 +1,14 @@ # Helper functions for option handling. -*- Autoconf -*- # -# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software +# Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. -# serial 7 ltoptions.m4 +# serial 8 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) @@ -29,7 +29,7 @@ m4_define([_LT_SET_OPTION], [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), _LT_MANGLE_DEFUN([$1], [$2]), - [m4_warning([Unknown $1 option `$2'])])[]dnl + [m4_warning([Unknown $1 option '$2'])])[]dnl ]) @@ -75,13 +75,15 @@ m4_if([$1],[LT_INIT],[ dnl dnl If no reference was made to various pairs of opposing options, then dnl we run the default mode handler for the pair. For example, if neither - dnl `shared' nor `disable-shared' was passed, we enable building of shared + dnl 'shared' nor 'disable-shared' was passed, we enable building of shared dnl archives by default: _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], - [_LT_ENABLE_FAST_INSTALL]) + [_LT_ENABLE_FAST_INSTALL]) + _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], + [_LT_WITH_AIX_SONAME([aix])]) ]) ])# _LT_SET_OPTIONS @@ -112,7 +114,7 @@ AU_DEFUN([AC_LIBTOOL_DLOPEN], [_LT_SET_OPTION([LT_INIT], [dlopen]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `dlopen' option into LT_INIT's first parameter.]) +put the 'dlopen' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: @@ -148,7 +150,7 @@ AU_DEFUN([AC_LIBTOOL_WIN32_DLL], _LT_SET_OPTION([LT_INIT], [win32-dll]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `win32-dll' option into LT_INIT's first parameter.]) +put the 'win32-dll' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: @@ -157,9 +159,9 @@ dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) # _LT_ENABLE_SHARED([DEFAULT]) # ---------------------------- -# implement the --enable-shared flag, and supports the `shared' and -# `disable-shared' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +# implement the --enable-shared flag, and supports the 'shared' and +# 'disable-shared' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_SHARED], [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([shared], @@ -172,14 +174,14 @@ AC_ARG_ENABLE([shared], *) enable_shared=no # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) @@ -211,9 +213,9 @@ dnl AC_DEFUN([AM_DISABLE_SHARED], []) # _LT_ENABLE_STATIC([DEFAULT]) # ---------------------------- -# implement the --enable-static flag, and support the `static' and -# `disable-static' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +# implement the --enable-static flag, and support the 'static' and +# 'disable-static' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_STATIC], [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([static], @@ -226,14 +228,14 @@ AC_ARG_ENABLE([static], *) enable_static=no # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], [enable_static=]_LT_ENABLE_STATIC_DEFAULT) @@ -265,9 +267,9 @@ dnl AC_DEFUN([AM_DISABLE_STATIC], []) # _LT_ENABLE_FAST_INSTALL([DEFAULT]) # ---------------------------------- -# implement the --enable-fast-install flag, and support the `fast-install' -# and `disable-fast-install' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +# implement the --enable-fast-install flag, and support the 'fast-install' +# and 'disable-fast-install' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_FAST_INSTALL], [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([fast-install], @@ -280,14 +282,14 @@ AC_ARG_ENABLE([fast-install], *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) @@ -304,14 +306,14 @@ AU_DEFUN([AC_ENABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `fast-install' option into LT_INIT's first parameter.]) +the 'fast-install' option into LT_INIT's first parameter.]) ]) AU_DEFUN([AC_DISABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], [disable-fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `disable-fast-install' option into LT_INIT's first parameter.]) +the 'disable-fast-install' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: @@ -319,11 +321,64 @@ dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) +# _LT_WITH_AIX_SONAME([DEFAULT]) +# ---------------------------------- +# implement the --with-aix-soname flag, and support the `aix-soname=aix' +# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT +# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. +m4_define([_LT_WITH_AIX_SONAME], +[m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl +shared_archive_member_spec= +case $host,$enable_shared in +power*-*-aix[[5-9]]*,yes) + AC_MSG_CHECKING([which variant of shared library versioning to provide]) + AC_ARG_WITH([aix-soname], + [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], + [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], + [case $withval in + aix|svr4|both) + ;; + *) + AC_MSG_ERROR([Unknown argument to --with-aix-soname]) + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname], + [AC_CACHE_VAL([lt_cv_with_aix_soname], + [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) + with_aix_soname=$lt_cv_with_aix_soname]) + AC_MSG_RESULT([$with_aix_soname]) + if test aix != "$with_aix_soname"; then + # For the AIX way of multilib, we name the shared archive member + # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', + # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. + # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, + # the AIX toolchain works better with OBJECT_MODE set (default 32). + if test 64 = "${OBJECT_MODE-32}"; then + shared_archive_member_spec=shr_64 + else + shared_archive_member_spec=shr + fi + fi + ;; +*) + with_aix_soname=aix + ;; +esac + +_LT_DECL([], [shared_archive_member_spec], [0], + [Shared archive member basename, for filename based shared library versioning on AIX])dnl +])# _LT_WITH_AIX_SONAME + +LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) + + # _LT_WITH_PIC([MODE]) # -------------------- -# implement the --with-pic flag, and support the `pic-only' and `no-pic' +# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' # LT_INIT options. -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. +# MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. m4_define([_LT_WITH_PIC], [AC_ARG_WITH([pic], [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], @@ -334,19 +389,17 @@ m4_define([_LT_WITH_PIC], *) pic_mode=default # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], - [pic_mode=default]) - -test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) + [pic_mode=m4_default([$1], [default])]) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC @@ -359,7 +412,7 @@ AU_DEFUN([AC_LIBTOOL_PICMODE], [_LT_SET_OPTION([LT_INIT], [pic-only]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `pic-only' option into LT_INIT's first parameter.]) +put the 'pic-only' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: diff --git a/v2.5/generators/nlojet++/m4/ltversion.m4 b/v2.5/generators/nlojet++/m4/ltversion.m4 index 07a8602d48d615a65800b14446d8c8c8694f2818..fa04b52a3bf868bd57e7ba796d64385a51e7ec5a 100644 --- a/v2.5/generators/nlojet++/m4/ltversion.m4 +++ b/v2.5/generators/nlojet++/m4/ltversion.m4 @@ -1,6 +1,6 @@ # ltversion.m4 -- version numbers -*- Autoconf -*- # -# Copyright (C) 2004 Free Software Foundation, Inc. +# Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives @@ -9,15 +9,15 @@ # @configure_input@ -# serial 3337 ltversion.m4 +# serial 4179 ltversion.m4 # This file is part of GNU Libtool -m4_define([LT_PACKAGE_VERSION], [2.4.2]) -m4_define([LT_PACKAGE_REVISION], [1.3337]) +m4_define([LT_PACKAGE_VERSION], [2.4.6]) +m4_define([LT_PACKAGE_REVISION], [2.4.6]) AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.4.2' -macro_revision='1.3337' +[macro_version='2.4.6' +macro_revision='2.4.6' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) diff --git a/v2.5/generators/nlojet++/mygitcl b/v2.5/generators/nlojet++/mygitcl new file mode 100755 index 0000000000000000000000000000000000000000..b14d7563a397e6b4177e1cceeee07cf3d1d4f76d --- /dev/null +++ b/v2.5/generators/nlojet++/mygitcl @@ -0,0 +1 @@ +git log --pretty --numstat --summary -p . | git2cl > ChangeLog.new diff --git a/v2.5/toolkit/AUTHORS b/v2.5/toolkit/AUTHORS index f6ab37e95b0545eccbd75a640c12ca4bd8392a96..8d19150ed36b6a2e9dba4884a1142373d31e3cda 100644 --- a/v2.5/toolkit/AUTHORS +++ b/v2.5/toolkit/AUTHORS @@ -4,6 +4,10 @@ Daniel Britzger [daniel.britzger@desy.de], Klaus Rabbertz [klaus.rabbertz@cern.ch], Markus Wobisch [wobisch@latech.edu] +Current contributors are: +------------------------- +Johannes Gäßler: [johannes.gaessler@cern.ch] + Former contributors are: ------------------------ -Thomas Kluge, Georg Sieber, Jakob Stark, Fred Stober +Thomas Kluge, Bettina Schillinger, Georg Sieber, Jakob Stark, Fred Stober diff --git a/v2.5/toolkit/ChangeLog b/v2.5/toolkit/ChangeLog index 017c4c687b388dd043868f3706b3fd7d8fa2b319..120573c1ae1bba37d0df6a69393150caa66d106a 100644 --- a/v2.5/toolkit/ChangeLog +++ b/v2.5/toolkit/ChangeLog @@ -1,32 +1,282 @@ +2023-07-12 Public release of the fastNLO_toolkit package version 2.5.1, tag 2888 + ===================================================================== + +2023-07-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/README, + v2.5/toolkit/TODO, v2.5/toolkit/configure.ac, + v2.5/toolkit/doc/paper/fnlo-paper.tex, + v2.5/toolkit/fastnlotoolkit/fastNLOCRunDec.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOLHAPDF.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOLHAPDF.h, + v2.5/toolkit/m4/ax_prog_doxygen.m4, + v2.5/toolkit/src/fnlo-tk-config.in, + v2.5/toolkit/src/fnlo-tk-cppread.cc, + v2.5/toolkit/src/fnlo-tk-example.cc, + v2.5/toolkit/src/fnlo-tk-rootout.cc, + v2.5/toolkit/src/fnlo-tk-statunc.cc, + v2.5/toolkit/src/fnlo-tk-yodaout.cc: Fix pythondir prefix + inconsistency; drop all LHAPDF5 stuff; by default no doxygen use + +2023-07-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/configure.ac, v2.5/toolkit/src/fnlo-tk-config.in: + Require Python3 for pyext; add --pythondir option to fnlo-tk-config + +2023-07-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * : Merge bin_density into master + +2023-07-02 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h: + Removed obsolete code + +2023-07-02 JohannesGaessler <johannesg@5d6.de> + + * test/.gitignore, test/InclusiveNJets_InclusiveJets_fix.wrm, + test/InclusiveNJets_InclusiveJets_flex.wrm, test/compare_tables.py, + test/fix_NodeDensity.str, test/fix_NodesPerBin.str, + test/flex_NodeDensity.str, test/flex_NodesPerBin.str: Added + NodesPerBin <-> BinDensity test files + +2023-03-13 Johannes Gäßler <Johannes Gäßler> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h + , v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h: + Table merging for x density + +2023-03-13 Johannes Gäßler <Johannes Gäßler> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc: Fix DIS fill code + +2023-03-12 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddBase.h + , + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFix.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h + , v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOEvent.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h: + Deduplication of table fill code + +2023-03-09 Johannes Gäßler <Johannes Gäßler> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants + .h: DIS for x density, floats as density + +2023-03-07 Johannes Gäßler <Johannes Gäßler> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc: Steering file + strings to control warmup + +2023-03-06 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc: Bugfixes, flex scale + with NPDFDim == 2 + +2023-03-06 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h: Slow + NPDFDim == 2 for x density + +2023-03-05 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolCatmullRom.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLinear.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolCatmul + lRom.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLinear + .h: Catmull and Linear kernels for x node density + +2023-02-26 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h + , v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h: Bin + density implementation for flexible scale + +2023-02-25 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h: + Utility functions for extending X dims + +2023-02-23 Johannes Gäßler <Johannes Gäßler> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddBase.h + , v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h: + Utility function for checking vectors, untested + +2023-02-21 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolCatmullRom.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLagrange.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLinear.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolBase.h: + Bugfixes for fixed scale + +2023-02-20 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h + , v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h: WIP + flex scale without warmup + +2023-02-13 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants + .h: WIP merge tables for density + +2023-01-30 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc: Skip warmup if using + NodeDensity + +2023-01-15 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCoeffBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLagrange.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOTable.cc, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFix.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffBase.h, + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolBase.h + , + v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLagran + ge.h, v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTable.h: + Ignore warmup, start with small x grid + +2023-01-15 JohannesGaessler <johannesg@5d6.de> + + * v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc, + v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLagrange.cc: x grid can + be extended after warmup + +2023-02-11 Public release of the fastNLO_toolkit package version 2.5.0, tag 2856 + ===================================================================== + +2023-02-11 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/mygitcl: Add command for updating ChangeLog + +2023-02-10 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/configure.ac, v2.5/toolkit/m4/ax_check_zlib.m4, + v2.5/toolkit/m4/ax_cxx_compile_stdcxx.m4, + v2.5/toolkit/m4/ax_prog_doxygen.m4, v2.5/toolkit/m4/libtool.m4, + v2.5/toolkit/m4/ltoptions.m4, v2.5/toolkit/m4/ltversion.m4: + autotools update + +2022-12-13 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/configure.ac: Fixes in configure + 2022-10-05 Public release of the fastNLO_toolkit package version 2.5.0, tag 2848 ===================================================================== 2022-10-05 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/ChangeLog, v2.5/toolkit/NEWS: Update news and + changelog + +2022-10-05 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/check/fnlo-tk-qcdnumastest2.pl.in, + v2.5/toolkit/check/fnlo-tk-stattest.pl.in, + v2.5/toolkit/data/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fi + x-hhc-born-2jet_stat.log, + v2.5/toolkit/data/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fi + x-hhc-nlo-2jet_stat.log: Fix a few issues with unit tests + 2022-09-01 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/check/fnlo-tk-hoppetastest2.pl.in: Fix cmdline in + HOPPER check + 2022-07-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> - Fix a few issues with unit tests and autotools + * v2.5/toolkit/Makefile.am, v2.5/toolkit/configure.ac, + v2.5/toolkit/m4/libtool.m4, v2.5/toolkit/m4/ltoptions.m4, + v2.5/toolkit/m4/ltsugar.m4, v2.5/toolkit/m4/ltversion.m4, + v2.5/toolkit/m4/lt~obsolete.m4: Fix issues with autotools + +2022-07-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/ChangeLog, v2.5/toolkit/NEWS: Update news and + checngelog + +2022-07-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> + * v2.5/toolkit/check/fnlo-tk-cppnormtest.pl.in, + v2.5/toolkit/check/fnlo-tk-cppscalestest.pl.in, + v2.5/toolkit/check/fnlo-tk-cpptest2.pl.in, + v2.5/toolkit/check/fnlo-tk-rundecastest2.pl.in, + v2.5/toolkit/data/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fi + x-hhc-born-2jet_stat.log, + v2.5/toolkit/data/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fi + x-hhc-nlo-2jet_stat.log: Fix small issues in make check; two lines + in stat check needed tiny updates of numbers (why? gcc?) 2022-07-20 Public release of the fastNLO_toolkit package version 2.5.0, tag 2844 ===================================================================== -2022-07-14 Klaus Rabbertz <klaus.rabbertz@cern.ch> +2022-07-20 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/ChangeLog, v2.5/toolkit/NEWS: Complement changelog + and news for release - * tools/plotting/fastnnlo_pdfunc.py, - tools/plotting/fastnnlo_scaleunc.py: Fix for issue when using - matplotlib > 3.2.x +2022-07-20 Klaus Rabbertz <klaus.rabbertz@cern.ch> + + * v2.5/toolkit/ChangeLog, v2.5/toolkit/NEWS, v2.5/toolkit/TODO: + Complement changelog and news for release 2022-07-03 Klaus Rabbertz <klaus.rabbertz@cern.ch> * v2.5/toolkit/src/fnlo-tk-cppread.cc: Added option for Ecms reweighting in fnlo-tk-cppread; TODO use getopt for cmdlines -2022-06-14 Klaus Rabbertz <klaus.rabbertz@cern.ch> - - * tools/plotting/fastnnlo_multigridclosure.py: Fix python issue with - ambiguous boolean - 2022-06-13 Klaus Rabbertz <klaus.rabbertz@cern.ch> * v2.5/toolkit/src/fnlo-tk-yodaout.cc: Allow rescaling uncertainty @@ -57,24 +307,9 @@ v2.5/toolkit/src/fnlo-tk-yodaout.cc: Add possibility of having sclfac*scale as central choice, e.g. m12 -> m2/2 -2022-05-20 Klaus Rabbertz <klaus.rabbertz@cern.ch> - - * tools/plotting/fastnnlo_statunc.py: Add option for stat. - uncertainty - -2022-02-25 Klaus Rabbertz <klaus.rabbertz@cern.ch> - - * tools/plotting/fastnnlo_runtime.py, - tools/plotting/fastnnlo_statunc.py: Fix two scripts for law usage up - to NLO only - -2022-02-08 Klaus Rabbertz <klaus.rabbertz@cern.ch> - - * tools/fnlo-add-tables.pl: Use merge2 in fnlo-add-tables - 2022-02-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * tools/fnlo-add-tables.pl, v2.5/toolkit/src/fnlo-tk-example.cc, + * v2.5/toolkit/src/fnlo-tk-example.cc, v2.5/toolkit/src/fnlo-tk-rootout.cc, v2.5/toolkit/src/fnlo-tk-statunc.cc, v2.5/toolkit/src/fnlo-tk-yodaout.cc: A few fixes for stat. @@ -82,23 +317,10 @@ 2022-01-05 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * tools/plotting/fastnnlo_absolute.py, - tools/plotting/fastnnlo_kfaccomp.py, - tools/plotting/fastnnlo_multigridclosure.py, - tools/plotting/fastnnlo_scaleclosure.py, - tools/plotting/fastnnlo_scaleunc.py, - v2.5/toolkit/src/fnlo-tk-modify.cc, + * v2.5/toolkit/src/fnlo-tk-modify.cc, v2.5/toolkit/src/fnlo-tk-yodaout.cc: Changes required for yoda plot x-y-rescaling for DataComparison task in law -2021-09-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> - - * tools/README.installation: Add forgotten readme file - -2021-08-24 Klaus Rabbertz <klaus.rabbertz@cern.ch> - - * tools/fnlosrc_install.csh: Update version no. to install - 2021-08-21 Klaus Rabbertz <klaus.rabbertz@cern.ch> * v2.5/toolkit/ChangeLog, v2.5/toolkit/NEWS: Update changelog and @@ -130,8 +352,7 @@ 2021-05-26 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * v2.3/generators/nlojet++/configure.ac, - v2.3/toolkit/data/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fi + * v2.3/toolkit/data/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fi x-hhc-born-2jet_stat.log, v2.3/toolkit/data/check/InclusiveNJets_fnr0001midpHT_I723509_v23_fi x-hhc-nlo-2jet_stat.log, v2.3/toolkit/data/modify/SteerModify.str, @@ -219,11 +440,7 @@ 2020-09-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * - v2.3/generators/nlojet++/interface/include/fnlo_int_nlojet/fnlo_int - _hhc_nlojet.h, - v2.3/generators/nlojet++/interface/tools/fnlo_int_hhc_nlojet.cc, - v2.3/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants + *v2.3/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants .h: Compatibility update of nlojet++ interface 2020-09-07 Klaus Rabbertz <klaus.rabbertz@cern.ch> @@ -484,11 +701,7 @@ 2019-02-01 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * v2.0/generators/nlojet++/m4/ax_check_zlib.m4, - v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4, - v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx_11.m4, - v2.0/generators/nlojet++/m4/ax_require_defined.m4, - v2.0/toolkit/TODO, v2.0/toolkit/fastnlotoolkit/CRunDec.cc, + * v2.0/toolkit/TODO, v2.0/toolkit/fastnlotoolkit/CRunDec.cc, v2.0/toolkit/fastnlotoolkit/HoppetInterface.cc, v2.0/toolkit/fastnlotoolkit/fastNLOAlphas.cc, v2.0/toolkit/fastnlotoolkit/fastNLOCRunDec.cc, @@ -559,8 +772,7 @@ 2019-01-30 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * v2.0/generators/nlojet++/interface/hadron/InclusiveNJetDiffs.cc, - v2.0/toolkit/fastnlotoolkit/fastNLOCreate.cc, + * v2.0/toolkit/fastnlotoolkit/fastNLOCreate.cc, v2.0/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOEvent.h: Propagate weight for x section diffs; TODO decide which version @@ -758,8 +970,7 @@ 2018-03-24 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * v2.0/generators/nlojet++/interface/hadron/fastNLOjetpp.cc, - v2.0/toolkit/configure.ac, v2.0/toolkit/doxygen.cfg, + * v2.0/toolkit/configure.ac, v2.0/toolkit/doxygen.cfg, v2.0/toolkit/fastnlotoolkit/fastNLOTable.cc, v2.0/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOConstants.h.in , v2.0/toolkit/src/fnlo-tk-config.in: SVNREV --> GITREV @@ -1100,13 +1311,7 @@ 2017-08-15 Klaus Rabbertz <klaus.rabbertz@cern.ch> - * v2.0/generators/nlojet++/m4/ax_check_zlib.m4, - v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx.m4, - v2.0/generators/nlojet++/m4/ax_cxx_compile_stdcxx_11.m4, - v2.0/generators/nlojet++/m4/ax_prog_doxygen.m4, - v2.0/generators/nlojet++/m4/ax_python_devel.m4, - v2.0/generators/nlojet++/m4/ax_require_defined.m4, - v2.0/toolkit/m4/ax_check_zlib.m4, + * v2.0/toolkit/m4/ax_check_zlib.m4, v2.0/toolkit/m4/ax_cxx_compile_stdcxx.m4, v2.0/toolkit/m4/ax_cxx_compile_stdcxx_11.m4, v2.0/toolkit/m4/ax_require_defined.m4: Deal with m4 macro issues git-svn-id: diff --git a/v2.5/toolkit/NEWS b/v2.5/toolkit/NEWS index 58326700377e12212f67dc419af02bd659b6810e..1a52bfdf0f36f25d74b2a93b233076e9a0ef9253 100644 --- a/v2.5/toolkit/NEWS +++ b/v2.5/toolkit/NEWS @@ -1,3 +1,22 @@ +Notes for public release of the fastNLO_toolkit package version 2.5.1, tag 2890 +=============================================================================== +Remove leftover debug printout + + +Notes for public release of the fastNLO_toolkit package version 2.5.1, tag 2888 +=============================================================================== +Major improvement (Johannes Gäßler): +- optional on-the-fly x-binning extension with given bin density +Other: +- LHAPDF5 support removed +- By default NO Doxygen documentation anymore; must be switched on explicitly + + +Notes for public release of the fastNLO_toolkit package version 2.5.0, tag 2856 +=============================================================================== +autotools updates. + + Notes for public release of the fastNLO_toolkit package version 2.5.0, tag 2848 =============================================================================== A few bug fixes for unit tests. diff --git a/v2.5/toolkit/README b/v2.5/toolkit/README index 607317cd226fb53bc8ee17c86347f0f08173e039..ba811370395c7af9680a3ee3dfa37edaff60d349 100644 --- a/v2.5/toolkit/README +++ b/v2.5/toolkit/README @@ -28,7 +28,7 @@ cd fastnlo_toolkit-v.v.v-nnnn ./configure --prefix=/path/to/your/local/installation_directory # If the same installation directory or other system-wide known installation directories -# contain already a version of LHAPDF version 5 or 6, LHAPDF will be found and used +# contain already a version of LHAPDF version 6, LHAPDF will be found and used # automatically. # If not, please specify the path to where LHAPDF is installed, i.e. where # 'bin/lhapdf-config' can be found: @@ -95,7 +95,7 @@ fnlo-tk-example -h # or fnlo-tk-cppread -h # for some usage explanations. -# In case of LHAPDF6, the PDF sets have to be specified without extension. +# For LHAPDF6, the PDF sets have to be specified without extension. # For developers ONLY: diff --git a/v2.5/toolkit/TODO b/v2.5/toolkit/TODO index faea2dec6fa9482a7eb75c8cedf894a1e5e23acd..98fe785d9d4577518223ac9baeb33bdef721a733 100644 --- a/v2.5/toolkit/TODO +++ b/v2.5/toolkit/TODO @@ -9,7 +9,6 @@ TODO list for fastNLO_toolkit (ordered by priority) - Add checks for HOPPET, CRunDec, QCDNUM - Change everything to use LHAPDF6 features instead of deprecated LHAGLUE; partially done in HOPPET interface -- Drop LHAPDF5 support - Use binary read/write table to save storage space and read in times (Mark's suggestion) (Not clear that binary storage actually saves anything ...! Test first.) - Provide features to allow -> APPLgrid conversion and the inverse -> fastNLO @@ -35,6 +34,7 @@ TODO list for fastNLO_toolkit (ordered by priority) ======================================================================= DONE ======================================================================= + - Drop LHAPDF5 support - Include stat. uncertainties into table - Modifier & Concatenator for tables/bins - fast Warmup-run (just some events and then 'guess' PS boundaries) diff --git a/v2.5/toolkit/configure.ac b/v2.5/toolkit/configure.ac index fe58d7a31d2126ffdae08a13d965adf95cd5a5e0..5cc798a2f00d055f8df26ce02723a1494597e05d 100644 --- a/v2.5/toolkit/configure.ac +++ b/v2.5/toolkit/configure.ac @@ -7,10 +7,10 @@ # # ----------------------------------------------------------------------------- # Process this file with autoconf to produce a configure script. -# Require minimal autoconf version, 2.69 is from 2012 -AC_PREREQ([2.69]) +# Require minimal autoconf version, 2.71 is from 2021 +AC_PREREQ([2.71]) # Define subproject fastNLO_toolkit -AC_INIT([fastNLO_toolkit],[2.5.0],[daniel.britzger@desy.de,klaus.rabbertz@cern.ch,wobisch@latech.edu]) +AC_INIT([fastNLO_toolkit],[2.5.1],[Daniel.Britzger@desy.de, Klaus.Rabbertz@kit.edu, Georg Sieber, Fred Stober, wobisch@latech.edu]) #Suppress verbose output when compiling (use make V=99 for verbose output) m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])]) # Properly include subprojects @@ -19,7 +19,8 @@ AC_CONFIG_AUX_DIR([.]) AM_INIT_AUTOMAKE([1.13 tar-ustar -Wall -Wno-override]) # Require minimal libtool version, 2.4 is from 2011 LT_PREREQ([2.4]) -#LT_INIT([dlopen]) +# Allow opening precompiled modules at runtime +LT_INIT([dlopen]) # # ATTENTION: For conditional compilation etc ... # AC_DEFINE preprocessor definitions are written to config.h @@ -38,32 +39,15 @@ AC_PROG_CC AC_PROG_CPP AC_PROG_F77([gfortran g77]) AC_PROG_FC([gfortran g77]) -AC_CONFIG_MACRO_DIR([m4]) -#case $FC in -# gfortran) AC_SUBST([HAVE_GFORTRAN], [yes]) -# g77) AC_SUBST([HAVE_G77], [yes]) -#esac AC_PROG_INSTALL -_LT_SET_OPTION([LT_INIT],[dlopen]) -AC_DIAGNOSE([obsolete],[AC_LIBTOOL_DLOPEN: Remove this warning and the call to _LT_SET_OPTION when you -put the `dlopen' option into LT_INIT's first parameter.]) - -LT_INIT AC_PROG_LN_S AC_PROG_MAKE_SET -# AC_PROG_RANLIB # Checks for sources. # Checks for libraries. AC_F77_LIBRARY_LDFLAGS AC_CHECK_LIB([g2c], [getenv_]) -#AC_CHECK_LIB([LHAPDF], [alphas]) -#AC_CHECK_LIB([fastnlotoolkit], [libfastnlotoolkit_la-FastNLOBlockB]) -#AC_CHECK_LIB([gfortranbegin], [fmain]) -#AC_CHECK_LIB([lhpdf_cteq6], [cteq6]) -# Check twice, first to define ZLIBTEST, and second to perform default action and AC_DEFINE HAVE_LIBZ -#AX_CHECK_ZLIB([ZLIBTEST=true], ZLIBTEST="") AX_CHECK_ZLIB AM_CONDITIONAL([HAVE_LIBZ],[test "x$HAVE_LIBZ" == "xtrue"]) @@ -499,7 +483,7 @@ AM_CONDITIONAL(HAVE_ROOT, test "x$ROOTPREFIX" != "x") # Create code documentation with Doxygen AC_MSG_NOTICE([******************************************]) AC_MSG_NOTICE([Checking whether doxygen code documentation is requested ...]) -AC_MSG_NOTICE([Use en/disable_doxygen_doc to switch on/off.]) +AC_MSG_NOTICE([Use --enable-doxygen-doc to switch on.]) AC_MSG_NOTICE([******************************************]) if test "x$enable_doxygen_chi" != "x"; then AC_MSG_WARN([Option en/disable_doxygen_chi is not implemented and simply IGNORED!]) @@ -528,7 +512,7 @@ fi if test "x$enable_doxygen_dot" != "x"; then AC_MSG_WARN([Option en/disable_doxygen_dot is not implemented. Dot will be used if available.]) fi -if test "x$enable_doxygen_doc" != "xno"; then +if test "x$enable_doxygen_doc" != "x" && test "x$enable_doxygen_doc" != "xno"; then # Check on DOXYGEN AC_MSG_NOTICE([Doxygen code documentation desired.]) AC_CHECK_PROGS(DOXYGEN, doxygen, doxygen) @@ -621,32 +605,23 @@ fi AM_CONDITIONAL(HAVE_PDFLATEX, test "x$PDFLATEX" != "x") AM_CONDITIONAL(HAVE_LATEXDVIPDFM, test "x$LATEX" != "x" && test "x$DVIPDFM" != "x") -# Python extension +# Python extension (requires Python3!) AC_MSG_NOTICE([******************************************]) AC_MSG_NOTICE([Checking whether Python extension is requested ...]) AC_MSG_NOTICE([******************************************]) AC_ARG_ENABLE([pyext], - [AS_HELP_STRING([--enable-pyext],[Optionally build Python module to interface C++ library. Default is no.])], + [AS_HELP_STRING([--enable-pyext],[Optionally build Python3 module to interface C++ library. Default is no.])], [], [enable_pyext="no"]) -AC_ARG_ENABLE([pyext3], - [AS_HELP_STRING([--enable-pyext3],[Optionally build Python3 module to interface C++ library. Default is no. Overrides enable_pyext.])], - [], - [enable_pyext3="no"]) # Basic Python checks -if test "x$enable_pyext3" = "xyes"; then +if test "x$enable_pyext" = "xyes"; then AM_PATH_PYTHON([3]) AX_PYTHON_DEVEL -else - if test "x$enable_pyext" = "xyes"; then - AM_PATH_PYTHON - AX_PYTHON_DEVEL([>='2.3.1']) - fi fi # Check on existence of SWIG to interface to Python -if test \( "x$enable_pyext" = "xyes" -o "x$enable_pyext3" = "xyes" \) -a ! -e pyext/FastNLOReader_wrap.cpp; then +if test \( "x$enable_pyext" = "xyes" \) -a ! -e pyext/FastNLOReader_wrap.cpp; then AC_PATH_PROG(SWIG, swig) if test "x$SWIG" = "x"; then AC_MSG_ERROR([swig not found, interfacing to Python not possible! Please install swig first or disable Python extension. Configuration aborted!]) @@ -657,18 +632,14 @@ fi AC_MSG_NOTICE([******************************************]) -if test "x$enable_pyext3" = "xyes"; then +if test "x$enable_pyext" = "xyes"; then AC_MSG_NOTICE([All Python3 checks successful. Requested Python3 extension will be built.]) else - if test "x$enable_pyext" = "xyes"; then - AC_MSG_NOTICE([All Python checks successful. Requested Python extension will be built.]) - else - AC_MSG_NOTICE([No Python extension requested. Continue without pyext.]) - fi + AC_MSG_NOTICE([No Python extension requested. Continue without pyext.]) fi AC_MSG_NOTICE([******************************************]) -AM_CONDITIONAL(ENABLE_PYEXT, [test "x$enable_pyext" = "xyes" -o "x$enable_pyext3" = "xyes"]) +AM_CONDITIONAL(ENABLE_PYEXT, [test "x$enable_pyext" = "xyes"]) # Fortran extension AC_MSG_NOTICE([******************************************]) diff --git a/v2.5/toolkit/doc/paper/fnlo-paper.tex b/v2.5/toolkit/doc/paper/fnlo-paper.tex index 215cf9da012f43b1a2da88fca91b12309c0364b1..dd7274f25bed319cd8ba8f25f91602e626fecea2 100644 --- a/v2.5/toolkit/doc/paper/fnlo-paper.tex +++ b/v2.5/toolkit/doc/paper/fnlo-paper.tex @@ -200,7 +200,7 @@ How to use fastNLOReader: \paragraph{Inheritance structure of fastNLOReader} \paragraph{fastNLOReader} \subsubsection{Predefined fastNLOReader interfaces} -\paragraph{LHAPDF5 and LHAPDF6} +\paragraph{LHAPDF6} \paragraph{QCDNUM} \paragraph{Hoppet} \subsection{Implementing a new PDF interface} diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOCRunDec.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOCRunDec.cc index 2be97d3e850e85f7a41a88aef00cbb4b0119b7b1..4173b338be9493bce4df12d9832c8ebc84358dde 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOCRunDec.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOCRunDec.cc @@ -123,7 +123,6 @@ void fastNLOCRunDec::SetPDGValues() { } void fastNLOCRunDec::SetLHAPDFValues(std::string LHAPDFFile, int PDFMem) { -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 // AlphaS_MZ can vary among PDF members, so we really need the PDF member info from LHAPDF const LHAPDF::PDFInfo PDFMemInfo(LHAPDFFile, PDFMem); QMass[0] = PDFMemInfo.get_entry_as<double>("MDown"); @@ -162,19 +161,6 @@ void fastNLOCRunDec::SetLHAPDFValues(std::string LHAPDFFile, int PDFMem) { exit(11); } fAlphasMz = PDFMemInfo.get_entry_as<double>("AlphaS_MZ"); -#else - // TODO: Remove old LHAPDF5 stuff - cerr << "LHAPDF5 not supported anymore! Please update." << endl; - exit(1); - // fAlphasMz = LHAPDF::alphasPDF(fiPDFMember,fMz); - // fnLoop = LHAPDF::getOrderAlphaS(fiPDFMember) + 1; - // for (int i = 0; i < 6; i++) - // QMass[i] = LHAPDF::getQMass(fiPDFMember,i+1); - // fAlphasMz = LHAPDF::alphasPDF(fMz); - // fnLoop = LHAPDF::getOrderAlphaS() + 1; - // for (int i = 0; i < 6; i++) - // QMass[i] = LHAPDF::getQMass(i+1); -#endif } diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc index 19aac25463065297717b8da7db3a612d930f72bb..1bca96f556c5c113305317fa62a3ba2ed918381c 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddBase.cc @@ -4,6 +4,9 @@ #include "fastnlotk/fastNLOCoeffAddBase.h" #include "fastnlotk/fastNLOTools.h" +#include "fastnlotk/fastNLOEvent.h" +#include "fastnlotk/fastNLOInterpolBase.h" +#include "fastnlotk/fastNLOTools.h" using namespace std; using namespace fastNLO; @@ -374,6 +377,14 @@ void fastNLOCoeffAddBase::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge } } + for (int i = 0; i < fNObsBins; i++) { + fastNLOTools::ExtendHead(XNode1[i], other.XNode1[i]); + } + if (NPDFDim > 1) { + for (int i = 0; i < fNObsBins; i++) { + fastNLOTools::ExtendHead(XNode2[i], other.XNode2[i]); + } + } if ( moption==fastNLO::kAttach ) { //Nevt = Nevt;// stays! @@ -471,29 +482,14 @@ bool fastNLOCoeffAddBase::IsCompatible(const fastNLOCoeffAddBase& other) const { //return false; warn["IsCompatible"]<<"Continuing! (experimental: This is needed for kAttach, but may causes bugs otherwise. Please report!)"<<endl; } - // check x-nodes briefly - if ( fNObsBins != other.GetNObsBin() ){ - warn["IsCompatible"]<<"Different number of bins detected."<<endl; + // check x-nodes + if (!fastNLOTools::SameTails(GetAllXNodes1(), other.GetAllXNodes1())) { + warn["IsCompatible"] << "XNodes1 not compatible, set verbosity to debug for more information." << endl; return false; } - // check x-nodes briefly - for ( int i = 0 ; i< fNObsBins ;i++ ){ - if ( GetNxmax(i) != other.GetNxmax(i) ){ - error["IsCompatible"]<<"Different number of x-nodes detected: "<<GetNxmax(i)<<" <-> "<<other.GetNxmax(i)<<endl; - return false; - } - if ( GetNxtot1(i) != other.GetNxtot1(i) ){ - error["IsCompatible"]<<"Different number of x-nodes detected: "<<GetNxtot1(i)<<" <-> "<<other.GetNxtot1(i)<<endl; - return false; - } - if ( GetXNode1(i,0) != other.GetXNode1(i,0) ){ - warn["IsCompatible"]<<"Different values for x-nodes detected. Lowest x-node: "<<GetXNode1(i,0)<<" <-> "<<other.GetXNode1(i,0)<<endl; - return false; - } - // if ( GetXNode1(i,1) != other.GetXNode1(i,1) ){ - // warn["IsCompatible"]<<"Different values for x-nodes detected."<<endl; - // return false; - // } + if (!fastNLOTools::SameTails(GetAllXNodes2(), other.GetAllXNodes2())) { + warn["IsCompatible"] << "XNodes2 not compatible, set verbosity to debug for more information." << endl; + return false; } // succesful! return true; @@ -851,3 +847,37 @@ void fastNLOCoeffAddBase::CatBin(const fastNLOCoeffAddBase& other, unsigned int } fastNLOCoeffBase::CatBin(other, iObsIdx); } + + +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddBase::ExtendX(int ObsBin, std::vector<fastNLOInterpolBase*>& KernX1, std::vector<fastNLOInterpolBase*>& KernX2) { + unsigned int oldXSize1 = GetNxtot1(ObsBin); + unsigned int oldXSize2 = GetNxtot2(ObsBin); + bool x1Extended = fastNLOTools::ExtendHead(XNode1[ObsBin], KernX1[ObsBin]->fgrid); + if (NPDFDim > 1) { + bool x2Extended = fastNLOTools::ExtendHead(XNode2[ObsBin], KernX2[ObsBin]->fgrid); + if (!x1Extended && !x2Extended) { + return; + } + } else { + if (!x1Extended) { + return; + } + } + ExtendSigmaTildeX(ObsBin, oldXSize1, oldXSize2); +} + + +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddBase::ExtendSigmaTildeX(int ObsBin, unsigned int OldXSize1, unsigned int OldXSize2) { + error["ExtendSigmaTildeX"] << "Method not implemented for fastNLOCoeffAddBase subclass. Exiting." << endl; + exit(1); +} + + +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddBase::Fill(fnloEvent& Event, int ObsBin, int X, int scalevar, + const std::vector<std::pair<int, double>>& nmu1, const std::vector<std::pair<int, double>>& nmu2, int SubProcess, double w) { + error["Fill"] << "Method not implemented for fastNLOCoeffAddBase subclass. Exiting." << endl; + exit(1); +} diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc index bb92b49048a73be109c1ad42c6e7262383fc8277..6d3ee3dec03cf29c1952071d8844d4f544e49dc5 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFix.cc @@ -1,6 +1,8 @@ #include <cstdlib> +#include <fastnlotk/fastNLOEvent.h> #include <iostream> #include <cmath> +#include <algorithm> #include "fastnlotk/fastNLOCoeffAddFix.h" #include "fastnlotk/fastNLOTools.h" @@ -193,15 +195,46 @@ void fastNLOCoeffAddFix::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge m return; } const fastNLOCoeffAddFix& othfix = (const fastNLOCoeffAddFix&)other; - if ( moption==fastNLO::kMerge ) fastNLOTools::AddVectors( SigmaTilde , othfix.SigmaTilde); - else if ( moption==fastNLO::kAttach ) { + + fastNLO::v5d otherSigmaTilde = othfix.SigmaTilde; + for(int obsBin=0 ; obsBin<fNObsBins ; obsBin++){ + for(int scalevar=0 ; scalevar<GetTotalScalevars() ; scalevar++){ + for(int scalenode=0 ; scalenode<GetTotalScalenodes() ; scalenode++){ + fastNLO::v2d& thisX = SigmaTilde[obsBin][scalevar][scalenode]; + fastNLO::v2d& otherX = otherSigmaTilde[obsBin][scalevar][scalenode]; + int thisNxtot1 = GetNxtot1(obsBin); + int thisNxtot2 = GetNxtot2(obsBin); + int otherNxtot1 = othfix.GetNxtot1(obsBin); + int otherNxtot2 = othfix.GetNxtot2(obsBin); + if (thisNxtot1 < otherNxtot1) { + fastNLOTools::ExtendSigmaTildeX(thisX, thisNxtot1, otherNxtot1, + thisNxtot2, thisNxtot2, NPDFDim, fastNLO::v1d(NSubproc)); + } else if (thisNxtot1 > otherNxtot1) { + fastNLOTools::ExtendSigmaTildeX(otherX, otherNxtot1, thisNxtot1, + otherNxtot2, otherNxtot2, NPDFDim, fastNLO::v1d(NSubproc)); + } + int maxNxtot1 = max(thisNxtot1, otherNxtot1); + if (thisNxtot2 < otherNxtot2) { + fastNLOTools::ExtendSigmaTildeX(thisX, maxNxtot1, maxNxtot1, + thisNxtot2, otherNxtot2, NPDFDim, fastNLO::v1d(NSubproc)); + } else if (thisNxtot2 > otherNxtot2) { + fastNLOTools::ExtendSigmaTildeX(otherX, maxNxtot1, maxNxtot1, + otherNxtot2, thisNxtot2, NPDFDim, fastNLO::v1d(NSubproc)); + } + } + } + } + + if ( moption==fastNLO::kMerge ) { + fastNLOTools::AddVectors(SigmaTilde, otherSigmaTilde); + } else if ( moption==fastNLO::kAttach ) { for( int i=0 ; i<fNObsBins ; i++ ){ int nxmax = GetNxmax(i); for( int k=0 ; k<GetTotalScalevars() ; k++ ){ for( int l=0 ; l<GetTotalScalenodes() ; l++ ){ for( int m=0 ; m<nxmax ; m++ ){ for( int n=0 ; n<other.GetNSubproc() ; n++ ){ // attach all other subprocesses - double s2 = othfix.SigmaTilde[i][k][l][m][n]; + double s2 = otherSigmaTilde[i][k][l][m][n]; s2 *= this->Nevt/other.GetNevt(); this->SigmaTilde[i][k][l][m].push_back(s2); } @@ -220,7 +253,7 @@ void fastNLOCoeffAddFix::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge m double w1 = this->GetMergeWeight(moption,n,i); double w2 = other.GetMergeWeight(moption,n,i); double& s1 = this->SigmaTilde[i][k][l][m][n]; - double s2 = othfix.SigmaTilde[i][k][l][m][n]; + double s2 = otherSigmaTilde[i][k][l][m][n]; if ( s1!=0 || s2!=0 ) { if ( w1==0 || w2==0 ) { error["fastNLOCoeffAddFix"]<<"Mergeing weight is 0, but sigma tilde is non-zero. Cannot proceed!"<<endl; @@ -325,6 +358,127 @@ bool fastNLOCoeffAddFix::IsCatenable(const fastNLOCoeffAddFix& other) const { } +//________________________________________________________________________________________________________________ // +bool fastNLOCoeffAddFix::IsEquivalent(const fastNLOCoeffBase& other, double rtol) const { + const fastNLOCoeffAddFix* op = dynamic_cast<const fastNLOCoeffAddFix*>(&other); + if (op == nullptr) { + debug["IsEquivalent"] << "other is not of type fastNLOCoeffAddFix." << endl; + return false; + } + + if (NPDFDim != op->GetNPDFDim()) { + debug["IsEquivalent"] << "NPDFDim is different: " << NPDFDim << " <-> " << op->GetNPDFDim() << endl; + return false; + } + if (!fastNLOTools::SameTails(GetAllXNodes1(), op->GetAllXNodes1(), rtol)) { + debug["IsEquivalent"] << "XNode1 not equivalent, see above." << endl; + return false; + } + if (!fastNLOTools::SameTails(GetAllXNodes2(), op->GetAllXNodes2(), rtol)) { + debug["IsEquivalent"] << "XNode2 not equivalent, see above." << endl; + return false; + } + fastNLO::v5d ost5 = op->SigmaTilde; + if (SigmaTilde.size() != ost5.size()) { + debug["IsEquivalent"] << "Number of observable bins is different." << endl; + return false; + } + for (unsigned int obsBin = 0; obsBin < SigmaTilde.size(); obsBin++) { + unsigned int tOffsetXN1, oOffsetXN1, tOffsetXN2, oOffsetXN2; + int tnb1 = GetNxtot1(obsBin); + int onb1 = op->GetNxtot1(obsBin); + int tnb2 = GetNxtot2(obsBin); + int onb2 = op->GetNxtot2(obsBin); + int x1Max = std::min(tnb1, onb1); + int x2Max = std::min(tnb2, onb2); + if (tnb1 > onb1) { + tOffsetXN1 = tnb1 - onb1; + oOffsetXN1 = 0; + } else { + tOffsetXN1 = 0; + oOffsetXN1 = onb1 - tnb1; + } + if (NPDFDim > 1) { + if (tnb2 > onb2) { + tOffsetXN2 = tnb2 - onb2; + oOffsetXN2 = 0; + } else { + tOffsetXN2 = 0; + oOffsetXN2 = onb2 - tnb2; + } + } else { + tOffsetXN2 = tOffsetXN1; + oOffsetXN2 = oOffsetXN1; + } + + fastNLO::v4d tst4 = SigmaTilde[obsBin]; + fastNLO::v4d ost4 = ost5[obsBin]; + if (tst4.size() != ost4.size()) { + return false; + } + for (unsigned int scaleVar = 0; scaleVar < tst4.size(); scaleVar++) { + fastNLO::v3d tst3 = tst4[scaleVar]; + fastNLO::v3d ost3 = ost4[scaleVar]; + if (tst3.size() != ost3.size()) { + return false; + } + for (unsigned int scaleNode = 0; scaleNode < tst3.size(); scaleNode++) { + fastNLO::v2d tst2 = tst3[scaleNode]; + fastNLO::v2d ost2 = ost3[scaleNode]; + int xIt2Max; + switch (NPDFDim) { + case 0: + xIt2Max = 1; + break; + case 1: + xIt2Max = x1Max; + break; + case 2: + xIt2Max = x2Max; + break; + default: + error["IsEquivalent"] << "Unsupported NPDFDim: " << NPDFDim << endl; + exit(1); + } + for (int xIt2 = 0; xIt2 < xIt2Max; xIt2++) { + int xIt1Max; + switch (NPDFDim) { + case 0: + case 2: + xIt1Max = x1Max; + break; + case 1: + xIt1Max = xIt2 + 1; + break; + default: + error["IsEquivalent"] << "Unsupported NPDFDim: " << NPDFDim << endl; + exit(1); + } + for (int xIt1 = 0; xIt1 < xIt1Max; xIt1++) { + fastNLO::v1d tst1 = tst2[GetXIndex(obsBin, xIt1 + tOffsetXN1, xIt2 + tOffsetXN2)]; + fastNLO::v1d ost1 = ost2[op->GetXIndex(obsBin, xIt1 + oOffsetXN1, xIt2 + oOffsetXN2)]; + if (tst1.size() != ost1.size()) { + return false; + } + for (unsigned int subProcess = 0; subProcess < tst1.size(); subProcess++) { + double rdiff = std::abs((tst1[subProcess] - ost1[subProcess]) / tst1[subProcess]); + if (rdiff > rtol) { + debug["IsEquivalent"] << "SigmaTilde rdiff too high: obsBin=" << obsBin << " scaleVar=" << scaleVar + << " scaleNode=" << scaleNode << " x1=" << (xIt1 - x1Max) << " x2=" << (xIt2 - x2Max) + << " subProcess=" << subProcess << " t=" << tst1[subProcess] << " o=" << ost1[subProcess] + << " rdiff=" << rdiff << endl; + return false; + } + } + } + } + } + } + } + return true; +} + + //________________________________________________________________________________________________________________ // void fastNLOCoeffAddFix::Clear() { //! Set all elelments of SigmaTilde to zero. @@ -458,3 +612,28 @@ void fastNLOCoeffAddFix::CatBin(const fastNLOCoeffAddFix& other, unsigned int iO } fastNLOCoeffAddBase::CatBin(other, iObsIdx, ITabVersionRead); } + + +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddFix::ExtendSigmaTildeX(int ObsBin, unsigned int OldXSize1, unsigned int OldXSize2) { + int nScalevar = GetNScalevar(); + int nScaleNode = GetNScaleNode(); + int newXSize1 = GetNxtot1(ObsBin); + int newXSize2 = GetNxtot2(ObsBin); + for (int scaleVar = 0; scaleVar < nScalevar; scaleVar++) { + for (int scaleNode = 0; scaleNode < nScaleNode; scaleNode++) { + fastNLOTools::ExtendSigmaTildeX( + SigmaTilde[ObsBin][scaleVar][scaleNode], OldXSize1, newXSize1, OldXSize2, newXSize2, + NPDFDim, fastNLO::v1d(NSubproc)); + } + } +} + + +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddFix::Fill(fnloEvent& Event, int ObsBin, int X, int scalevar, const vector<pair<int, double>>& nmu1, + const vector<pair<int, double>>& nmu2, int SubProcess, double w) { + for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { + SigmaTilde[ObsBin][scalevar][nmu1[m1].first][X][SubProcess] += Event._w * nmu1[m1].second * w; + } +} diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc index 758b8cb11334842b38352e322de9a10e561b17ff..fea21182b224a8c7cff75747b4114f9b3e665326 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffAddFlex.cc @@ -5,6 +5,7 @@ #include "fastnlotk/fastNLOTable.h" #include "fastnlotk/fastNLOTools.h" #include "fastnlotk/fastNLOCoeffAddFlex.h" +#include "fastnlotk/fastNLOEvent.h" using namespace std; @@ -218,13 +219,17 @@ void fastNLOCoeffAddFlex::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge } const fastNLOCoeffAddFlex& othflex = (const fastNLOCoeffAddFlex&) other; if ( moption==fastNLO::kMerge ) { - fastNLOTools::AddVectors( SigmaTildeMuIndep , othflex.SigmaTildeMuIndep ); + ExtendSigmaTilde(othflex, SigmaTildeMuIndep, othflex.SigmaTildeMuIndep); + fastNLOTools::AddVectors(SigmaTildeMuIndep, othflex.SigmaTildeMuIndep); if ( NScaleDep==3 || NScaleDep>=5 ) { - fastNLOTools::AddVectors( SigmaTildeMuFDep , othflex.SigmaTildeMuFDep ); - fastNLOTools::AddVectors( SigmaTildeMuRDep , othflex.SigmaTildeMuRDep ); + ExtendSigmaTilde(othflex, SigmaTildeMuFDep, othflex.SigmaTildeMuFDep); + fastNLOTools::AddVectors(SigmaTildeMuFDep, othflex.SigmaTildeMuFDep); + ExtendSigmaTilde(othflex, SigmaTildeMuRDep, othflex.SigmaTildeMuRDep); + fastNLOTools::AddVectors(SigmaTildeMuRDep, othflex.SigmaTildeMuRDep); if (( NScaleDep>=6 || !SigmaTildeMuRRDep.empty()) // both tables contain log^2 contributions (default case) && (othflex.NScaleDep>=6 || !othflex.SigmaTildeMuRRDep.empty()) ) { - fastNLOTools::AddVectors( SigmaTildeMuRRDep , othflex.SigmaTildeMuRRDep ); + ExtendSigmaTilde(othflex, SigmaTildeMuRRDep, othflex.SigmaTildeMuRRDep); + fastNLOTools::AddVectors(SigmaTildeMuRRDep, othflex.SigmaTildeMuRRDep); } else if ( NScaleDep==6 && othflex.NScaleDep==5 ) { // this tables contains log^2 contributions, but the other does not // nothing todo. @@ -234,8 +239,10 @@ void fastNLOCoeffAddFlex::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge NScaleDep = 6; } if ( NScaleDep>=7 || !SigmaTildeMuFFDep.empty()) { - fastNLOTools::AddVectors( SigmaTildeMuFFDep , othflex.SigmaTildeMuFFDep ); - fastNLOTools::AddVectors( SigmaTildeMuRFDep , othflex.SigmaTildeMuRFDep ); + ExtendSigmaTilde(othflex, SigmaTildeMuFFDep, othflex.SigmaTildeMuFFDep); + fastNLOTools::AddVectors(SigmaTildeMuFFDep, othflex.SigmaTildeMuFFDep); + ExtendSigmaTilde(othflex, SigmaTildeMuRFDep, othflex.SigmaTildeMuRFDep); + fastNLOTools::AddVectors(SigmaTildeMuRFDep, othflex.SigmaTildeMuRFDep); } } fastNLOTools::AddVectors( SigmaRefMixed , othflex.SigmaRefMixed ); @@ -253,6 +260,9 @@ void fastNLOCoeffAddFlex::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge exit(1); } } + for ( int im = 0 ; im<cMax ; im++ ) { // mu-indep, mur, muf, ... + ExtendSigmaTilde(othflex, *st1[im], *st2[im]); + } for ( int iObs = 0 ; iObs<GetNObsBin(); iObs++ ) { for (unsigned int jS1=0; jS1<GetNScaleNode1(iObs); jS1++) { for (unsigned int kS2=0; kS2<GetNScaleNode2(iObs); kS2++) { @@ -307,6 +317,9 @@ void fastNLOCoeffAddFlex::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge } } } + for ( int im = 0 ; im<cMax ; im++ ) { // mu-indep, mur, muf, ... + ExtendSigmaTilde(othflex, *st1[im], *st2[im]); + } for ( int iObs = 0 ; iObs<GetNObsBin(); iObs++ ) { for (unsigned int jS1=0; jS1<GetNScaleNode1(iObs); jS1++) { for (unsigned int kS2=0; kS2<GetNScaleNode2(iObs); kS2++) { @@ -353,6 +366,37 @@ void fastNLOCoeffAddFlex::Add(const fastNLOCoeffAddBase& other, fastNLO::EMerge } +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddFlex::ExtendSigmaTilde( + const fastNLOCoeffAddFlex& othflex, fastNLO::v5d& ThisSigmaTilde, fastNLO::v5d OtherSigmaTilde) { + for(int obsBin=0 ; obsBin<fNObsBins ; obsBin++){ + fastNLO::v3d insertValue = fastNLO::v3d( + GetNScaleNode1(obsBin), fastNLO::v2d(GetNScaleNode2(obsBin), fastNLO::v1d(GetNSubproc()))); + fastNLO::v4d& thisX = ThisSigmaTilde[obsBin]; + fastNLO::v4d& otherX = OtherSigmaTilde[obsBin]; + int thisNxtot1 = GetNxtot1(obsBin); + int thisNxtot2 = GetNxtot2(obsBin); + int otherNxtot1 = othflex.GetNxtot1(obsBin); + int otherNxtot2 = othflex.GetNxtot2(obsBin); + if (thisNxtot1 < otherNxtot1) { + fastNLOTools::ExtendSigmaTildeX(thisX, thisNxtot1, otherNxtot1, + thisNxtot2, thisNxtot2, NPDFDim, insertValue); + } else if (thisNxtot1 > otherNxtot1) { + fastNLOTools::ExtendSigmaTildeX(otherX, otherNxtot1, thisNxtot1, + otherNxtot2, otherNxtot2, NPDFDim, insertValue); + } + int maxNxtot1 = max(thisNxtot1, otherNxtot1); + if (thisNxtot2 < otherNxtot2) { + fastNLOTools::ExtendSigmaTildeX(thisX, maxNxtot1, maxNxtot1, + thisNxtot2, otherNxtot2, NPDFDim, insertValue); + } else if (thisNxtot2 > otherNxtot2) { + fastNLOTools::ExtendSigmaTildeX(otherX, maxNxtot1, maxNxtot1, + otherNxtot2, thisNxtot2, NPDFDim, insertValue); + } + } +} + + //________________________________________________________________________________________________________________ // void fastNLOCoeffAddFlex::Clear() { //! Set all elements of sigma tilde to zero @@ -577,3 +621,156 @@ void fastNLOCoeffAddFlex::CatBin(const fastNLOCoeffAddFlex& other, unsigned int } fastNLOCoeffAddBase::CatBin(other, iObsIdx, ITabVersionRead); } + + +//________________________________________________________________________________________________________________ // +bool fastNLOCoeffAddFlex::IsEquivalent(const fastNLOCoeffBase& other, double rtol) const { + const fastNLOCoeffAddFlex* op = dynamic_cast<const fastNLOCoeffAddFlex*>(&other); + if (op == nullptr) { + debug["IsEquivalent"] << "other is not of type fastNLOCoeffAddFlex." << endl; + return false; + } + + if (!fastNLOTools::SameTails(GetAllXNodes1(), op->GetAllXNodes1(), rtol)) { + debug["IsEquivalent"] << "XNode1 not equivalent, see above." << endl; + return false; + } + if (!fastNLOTools::SameTails(GetAllXNodes2(), op->GetAllXNodes2(), rtol)) { + debug["IsEquivalent"] << "XNode2 not equivalent, see above." << endl; + return false; + } + std::vector<const fastNLO::v5d*> tst6 = GetSigmaTildes(); + std::vector<const fastNLO::v5d*> ost6 = op->GetSigmaTildes(); + std::vector<std::string> names = {"MuIndep", "MuRDep", "MuFDep", "MuRRDep", "MuFFDep", "MuRFDep"}; + for (unsigned int i = 0; i < tst6.size(); i++) { + const fastNLO::v5d* tst5 = tst6[i]; + const fastNLO::v5d* ost5 = ost6[i]; + if (!IsSigmaTildeEquivalent(op, tst5, ost5, rtol, names[i])) { + return false; + } + } + return true; +} + + +//________________________________________________________________________________________________________________ // +bool fastNLOCoeffAddFlex::IsSigmaTildeEquivalent(const fastNLOCoeffAddFlex* op, const fastNLO::v5d *tst5, const fastNLO::v5d *ost5, double rtol, std::string name) const { + if (tst5->size() != ost5->size()) { + debug["IsSigmaTildeEquivalent"] << name << ": Number of observable bins is different." << endl; + return false; + } + if (NPDFDim != op->GetNPDFDim()) { + debug["IsSigmaTildeEquivalent"] << name << ": NPDFDim is different: " << NPDFDim << " <-> " << op->GetNPDFDim() << endl; + return false; + } + for (unsigned int obsBin = 0; obsBin < tst5->size(); obsBin++) { + unsigned int tOffsetXN1, oOffsetXN1, tOffsetXN2, oOffsetXN2; + int tnb1 = GetNxtot1(obsBin); + int onb1 = op->GetNxtot1(obsBin); + int tnb2 = GetNxtot2(obsBin); + int onb2 = op->GetNxtot2(obsBin); + int x1Max = std::min(tnb1, onb1); + int x2Max = std::min(tnb2, onb2); + if (tnb1 > onb1) { + tOffsetXN1 = tnb1 - onb1; + oOffsetXN1 = 0; + } else { + tOffsetXN1 = 0; + oOffsetXN1 = onb1 - tnb1; + } + if (NPDFDim > 1) { + if (tnb2 > onb2) { + tOffsetXN2 = tnb2 - onb2; + oOffsetXN2 = 0; + } else { + tOffsetXN2 = 0; + oOffsetXN2 = onb2 - tnb2; + } + } else { + tOffsetXN2 = tOffsetXN1; + oOffsetXN2 = oOffsetXN1; + } + + fastNLO::v4d tst4 = tst5->at(obsBin); + fastNLO::v4d ost4 = ost5->at(obsBin); + + int xIt2Max = NPDFDim > 1 ? x2Max : x1Max; + for (int xIt2 = 0; xIt2 < xIt2Max; xIt2++) { + int xIt1Max = NPDFDim > 1 ? x1Max : xIt2 + 1; + for (int xIt1 = 0; xIt1 < xIt1Max; xIt1++) { + fastNLO::v3d tst3 = tst4[GetXIndex(obsBin, xIt1 + tOffsetXN1, xIt2 + tOffsetXN2)]; + fastNLO::v3d ost3 = ost4[op->GetXIndex(obsBin, xIt1 + oOffsetXN1, xIt2 + oOffsetXN2)]; + if (tst3.size() != ost3.size()) { + return false; + } + for (unsigned int scaleNode1 = 0; scaleNode1 < tst3.size(); scaleNode1++) { + fastNLO::v2d tst2 = tst3[scaleNode1]; + fastNLO::v2d ost2 = ost3[scaleNode1]; + if (tst2.size() != ost2.size()) { + return false; + } + for (unsigned int scaleNode2 = 0; scaleNode2 < tst2.size(); scaleNode2++) { + fastNLO::v1d tst1 = tst2[scaleNode2]; + fastNLO::v1d ost1 = ost2[scaleNode2]; + if (tst1.size() != ost1.size()) { + return false; + } + for (unsigned int subProcess = 0; subProcess < tst1.size(); subProcess++) { + double rdiff = std::abs((tst1[subProcess] - ost1[subProcess]) / tst1[subProcess]); + if (rdiff > rtol) { + debug["IsSigmaTildeEquivalent"] << name << " rdiff too high: obsBin=" << obsBin << " scaleNode1=" + << scaleNode1 << " scaleNode2=" << scaleNode2 << " x1=" << (xIt1 - x1Max) << " x2=" << (xIt2 - x2Max) + << " subProcess=" << subProcess << " t=" << tst1[subProcess] << " o=" << ost1[subProcess] + << " rdiff=" << rdiff << endl; + return false; + } + } + } + } + } + } + } + return true; +} + + +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddFlex::ExtendSigmaTildeX(int ObsBin, unsigned int OldXSize1, unsigned int OldXSize2) { + fastNLO::v3d insertValue = fastNLO::v3d( + GetNScaleNode1(ObsBin), fastNLO::v2d(GetNScaleNode2(ObsBin), fastNLO::v1d(GetNSubproc()))); + unsigned int newXSize1 = GetNxtot1(ObsBin); + unsigned int newXSize2 = GetNxtot2(ObsBin); + fastNLOTools::ExtendSigmaTildeX( + SigmaTildeMuIndep[ObsBin], OldXSize1, newXSize1, OldXSize2, newXSize2, NPDFDim, insertValue); + fastNLOTools::ExtendSigmaTildeX( + SigmaTildeMuRDep[ObsBin], OldXSize1, newXSize1, OldXSize2, newXSize2, NPDFDim, insertValue); + fastNLOTools::ExtendSigmaTildeX( + SigmaTildeMuFDep[ObsBin], OldXSize1, newXSize1, OldXSize2, newXSize2, NPDFDim, insertValue); + fastNLOTools::ExtendSigmaTildeX( + SigmaTildeMuRRDep[ObsBin], OldXSize1, newXSize1, OldXSize2, newXSize2, NPDFDim, insertValue); + fastNLOTools::ExtendSigmaTildeX( + SigmaTildeMuFFDep[ObsBin], OldXSize1, newXSize1, OldXSize2, newXSize2, NPDFDim, insertValue); + fastNLOTools::ExtendSigmaTildeX( + SigmaTildeMuRFDep[ObsBin], OldXSize1, newXSize1, OldXSize2, newXSize2, NPDFDim, insertValue); +} + + +//________________________________________________________________________________________________________________ // +void fastNLOCoeffAddFlex::Fill(fnloEvent& Event, int ObsBin, int X, int scalevar, const vector<pair<int, double>>& nmu1, + const vector<pair<int, double>>& nmu2, int SubProcess, double w) { + for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { + for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { + double wfnlo = nmu1[m1].second * nmu2[mu2].second * w; + SigmaTildeMuIndep[ObsBin][X][nmu1[m1].first][nmu2[mu2].first][SubProcess] += Event._w * wfnlo; + if (Event._wf != 0 || Event._wr != 0) { + SigmaTildeMuFDep[ObsBin][X][nmu1[m1].first][nmu2[mu2].first][SubProcess] += Event._wf * wfnlo; + SigmaTildeMuRDep[ObsBin][X][nmu1[m1].first][nmu2[mu2].first][SubProcess] += Event._wr * wfnlo; + } + if (Event._wrr != 0 || Event._wff != 0 || Event._wrf != 0) { + SigmaTildeMuRRDep[ObsBin][X][nmu1[m1].first][nmu2[mu2].first][SubProcess] += Event._wrr * wfnlo; + SigmaTildeMuFFDep[ObsBin][X][nmu1[m1].first][nmu2[mu2].first][SubProcess] += Event._wff * wfnlo; + SigmaTildeMuRFDep[ObsBin][X][nmu1[m1].first][nmu2[mu2].first][SubProcess] += Event._wrf * wfnlo; + } + } + } +} diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffBase.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffBase.cc index 97b90d68a5d6bb452168a8cb4847568815efd1b8..ef2cca4699b66bd2505e9e8c3632d29b254c2352 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffBase.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOCoeffBase.cc @@ -164,9 +164,15 @@ bool fastNLOCoeffBase::IsCatenable(const fastNLOCoeffBase& other) const { return true; } + //________________________________________________________________________________________________________________ // +bool fastNLOCoeffBase::IsEquivalent(const fastNLOCoeffBase& other, double rtol) const { + error["IsEquivalent"] << "IsEquivalent not implemented by subclass!" << endl; + exit(1); +} +//________________________________________________________________________________________________________________ // void fastNLOCoeffBase::SetCoeffAddDefaults(){ SetIDataFlag(0); SetIAddMultFlag(0); diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc index 5423714ab6e816924a7b492cc04006480efff24e..504ea25100df3460fd4c7e970b824876fe404e29 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOCreate.cc @@ -239,7 +239,7 @@ fastNLOCreate::fastNLOCreate(const fastNLO::GeneratorConstants& GenConsts, const ReadSteeringFile(steerfile,steeringNameSpace); } // DEBUG - PRINTALL(); + // PRINTALL(); //! Update constants from steering namespace, but only if either of warmup or steering file exist! if ( lwarm || lsteer ) { SetGenConstsFromSteering(); @@ -692,9 +692,11 @@ void fastNLOCreate::SetScenConstsDefaults() { fScenConsts.Mu1_Kernel = "Lagrange"; fScenConsts.Mu1_DistanceMeasure = "loglog025"; fScenConsts.Mu1_NNodes = 6; + fScenConsts.Mu1_NNodeCounting = "NodesPerBin"; fScenConsts.Mu2_Kernel = "Lagrange"; fScenConsts.Mu2_DistanceMeasure = "loglog025"; fScenConsts.Mu2_NNodes = 6; + fScenConsts.Mu2_NNodeCounting = "NodesPerBin"; } @@ -747,14 +749,16 @@ void fastNLOCreate::SetScenConstsFromSteering() { if (EXIST_NS(CheckScaleLimitsAgainstBins,fSteerfile)) fScenConsts.CheckScaleLimitsAgainstBins = BOOL_NS(CheckScaleLimitsAgainstBins,fSteerfile); if (EXIST_NS(X_Kernel,fSteerfile)) fScenConsts.X_Kernel = STRING_NS(X_Kernel,fSteerfile); if (EXIST_NS(X_DistanceMeasure,fSteerfile)) fScenConsts.X_DistanceMeasure = STRING_NS(X_DistanceMeasure,fSteerfile); - if (EXIST_NS(X_NNodes,fSteerfile)) fScenConsts.X_NNodes = INT_NS(X_NNodes,fSteerfile); + if (EXIST_NS(X_NNodes,fSteerfile)) fScenConsts.X_NNodes = DOUBLE_NS(X_NNodes,fSteerfile); if (EXIST_NS(X_NNodeCounting,fSteerfile)) fScenConsts.X_NNodeCounting = STRING_NS(X_NNodeCounting,fSteerfile); if (EXIST_NS(Mu1_Kernel,fSteerfile)) fScenConsts.Mu1_Kernel = STRING_NS(Mu1_Kernel,fSteerfile); if (EXIST_NS(Mu1_DistanceMeasure,fSteerfile)) fScenConsts.Mu1_DistanceMeasure = STRING_NS(Mu1_DistanceMeasure,fSteerfile); - if (EXIST_NS(Mu1_NNodes,fSteerfile)) fScenConsts.Mu1_NNodes = INT_NS(Mu1_NNodes,fSteerfile); + if (EXIST_NS(Mu1_NNodes,fSteerfile)) fScenConsts.Mu1_NNodes = DOUBLE_NS(Mu1_NNodes,fSteerfile); + if (EXIST_NS(Mu1_NNodeCounting,fSteerfile)) fScenConsts.Mu1_NNodeCounting = STRING_NS(Mu1_NNodeCounting,fSteerfile); if (EXIST_NS(Mu2_Kernel,fSteerfile)) fScenConsts.Mu2_Kernel = STRING_NS(Mu2_Kernel,fSteerfile); if (EXIST_NS(Mu2_DistanceMeasure,fSteerfile)) fScenConsts.Mu2_DistanceMeasure = STRING_NS(Mu2_DistanceMeasure,fSteerfile); - if (EXIST_NS(Mu2_NNodes,fSteerfile)) fScenConsts.Mu2_NNodes = INT_NS(Mu2_NNodes,fSteerfile); + if (EXIST_NS(Mu2_NNodes,fSteerfile)) fScenConsts.Mu2_NNodes = DOUBLE_NS(Mu2_NNodes,fSteerfile); + if (EXIST_NS(Mu2_NNodeCounting,fSteerfile)) fScenConsts.Mu2_NNodeCounting = STRING_NS(Mu2_NNodeCounting,fSteerfile); if (EXIST_NS(GeneratorName,fSteerfile)) fGenConsts.Name = STRING_NS(GeneratorName,fSteerfile); if (EXIST_NS(GeneratorReferences,fSteerfile)) fGenConsts.References = STRING_ARR_NS(GeneratorReferences,fSteerfile); @@ -819,9 +823,11 @@ void fastNLOCreate::PrintScenConsts() { logger.info["PrintScenConsts"] << "Interpolation kernel in mu1 space: " << fScenConsts.Mu1_Kernel << endl; logger.info["PrintScenConsts"] << "Distance measure in mu1 space: " << fScenConsts.Mu1_DistanceMeasure << endl; logger.info["PrintScenConsts"] << "No. of interpolation nodes in mu1 space: " << fScenConsts.Mu1_NNodes << endl; + logger.info["PrintScenConsts"] << "Distribution of node numbers in mu1 space: " << fScenConsts.Mu1_NNodeCounting << endl; logger.info["PrintScenConsts"] << "Interpolation kernel in mu2 space: " << fScenConsts.Mu2_Kernel << endl; logger.info["PrintScenConsts"] << "Distance measure in mu2 space: " << fScenConsts.Mu2_DistanceMeasure << endl; logger.info["PrintScenConsts"] << "No. of interpolation nodes in mu2 space: " << fScenConsts.Mu2_NNodes << endl; + logger.info["PrintScenConsts"] << "Distribution of node numbers in mu2 space: " << fScenConsts.Mu2_NNodeCounting << endl; logger.info["PrintScenConsts"] << "==================================================================" << endl; } @@ -969,6 +975,8 @@ void fastNLOCreate::Instantiate() { //! and prepare for filling logger.debug["Instantiate"]<<"Instantiate all internal members and prepare for filling " << endl; logger.debug["Instantiate"]<<"X_NNodeCounting is set to: "<<fScenConsts.X_NNodeCounting<<endl; + logger.debug["Instantiate"]<<"Mu1_NNodeCounting is set to: "<<fScenConsts.Mu1_NNodeCounting<<endl; + logger.debug["Instantiate"]<<"Mu2_NNodeCounting is set to: "<<fScenConsts.Mu2_NNodeCounting<<endl; // init member variables fReader = NULL; @@ -1131,7 +1139,7 @@ void fastNLOCreate::ReadSteering(string steerfile, string steeringNameSpace) { } // if (logger.info.GetSpeak()) - PRINTALL(); + // PRINTALL(); } @@ -1932,7 +1940,10 @@ void fastNLOCreate::GetWarmupValues() { //! logger.debug["GetWarmupValues"]<<endl; - if (!fWarmupConsts.Values.empty()) { + if (!WarmupNeeded()) { + logger.info["GetWarmupValues"]<<"Warmup not needed to determine bin edges."<<endl; + fIsWarmup=false; + } else if (!fWarmupConsts.Values.empty()) { //! Check if warmup values already set by user logger.info["GetWarmupValues"]<<"Found warmup values in fWarmupConsts without reading warmup-steering file."<<endl; fIsWarmup=false; @@ -2055,6 +2066,9 @@ bool fastNLOCreate::CheckWarmupConsistency() { vector<vector<double> > warmup = fWarmupConsts.Values;//DOUBLE_TAB_NS(Warmup.Values,fSteerfile); bool ret = true; + if (!WarmupNeeded()) { + return ret; + } const string wrmuphelp = "Please check your warmup-file for compatibility with your steering.\nTo calculate a new warmup-file compatible to your steering, remove the old one.\nAlternatively use 'IgnoreWarmupBinningCheck=true' to ignore precision-related binning differences or\nuse 'ReadBinningFromSteering=false' to read all binning-related information from the warmup file.\n"; @@ -2432,78 +2446,8 @@ void fastNLOCreate::FillAllSubprocesses(const vector<vector<fnloEvent> >& events //! events is expected to be of the form: //! events[nscalevar][nsubproc] - // KR TODO Check to replace wgtfac by _wo - // cout << "WWW: wgtfac = " << wgtfac << "_wo = " << scen._wo << endl; - const bool bFasterCode = true; // experimental developement: try to make code faster - if (bFasterCode && !fIsWarmup && !fIsFlexibleScale) { - // make filling code a little bit faster ... ~40% - // if filling step "+=" is commented, then code is a factor ~6 faster - fEvent = events[0][0]; - fScenario = scen; - - // KR: Also check for nan or inf in the faster code!!! - if (!CheckWeightIsFinite()) return; - - const int ObsBin = GetBin(); - if (ObsBin < 0 || ObsBin >= (int)GetNObsBin()) return; - - // stats - fStats._nEvPS++; - - fastNLOCoeffAddFix* c = (fastNLOCoeffAddFix*)GetTheCoeffTable(); - // do interpolation - double xmin = GetTheCoeffTable()->GetNPDFDim() == 1 ? std::min(fEvent._x1,fEvent._x2) : fEvent._x1; - double xmax = GetTheCoeffTable()->GetNPDFDim() == 1 ? std::max(fEvent._x1,fEvent._x2) : fEvent._x2; - vector<pair<int,double> > nxlo = fKernX1[ObsBin]->GetNodeValues(xmin); - vector<pair<int,double> > nxup = fKernX2[ObsBin]->GetNodeValues(xmax); - - if (fApplyPDFReweight) { - fKernX1[ObsBin]->CheckX(xmin); - fKernX2[ObsBin]->CheckX(xmax); - ApplyPDFWeight(nxlo,xmin,fKernX1[ObsBin]->GetGridPtr()); // changes node values - ApplyPDFWeight(nxup,xmax,fKernX2[ObsBin]->GetGridPtr()); // changes node values - } - - - fastNLO::v4d& st = c->SigmaTilde[ObsBin]; - for (unsigned int is = 0 ; is<events.size() ; is++) { - double mu = fScenario._m1 * fScaleFac[is]; - const vector<pair<int,double> >& nmu = fKernMuS[ObsBin][is]->GetNodeValues(mu); - for (unsigned int m1 = 0 ; m1<nmu.size() ; m1++) { - fastNLO::v2d& stm1 = st[is][nmu[m1].first]; - for (unsigned int p = 0 ; p<events[is].size() ; p++) { - double wgt = wgtfac * events[is][p]._w * nmu[m1].second / BinSize[ObsBin]; - // ....................................................................................... - for (unsigned int x1 = 0 ; x1<nxlo.size() ; x1++) { - for (unsigned int x2 = 0 ; x2<nxup.size() ; x2++) { - //int p = fEvent._p; - int xminbin = nxlo[x1].first; - int xmaxbin = nxup[x2].first; - int proc = events[is][p]._p; - HalfMatrixCheck(fEvent._x1,fEvent._x2,xminbin,xmaxbin,proc); - int ixHM = GetXIndex(ObsBin,xminbin,xmaxbin); - stm1[ixHM][proc] += nxlo[x1].second * nxup[x2].second * wgt;//nmu[m1].second * wp[p]; - // for (unsigned int x1 = 0 ; x1<nxup.size() ; x1++) { - // for (unsigned int x2 = 0 ; x2<nxlo.size() ; x2++) { - // int xmaxbin = nxup[x1].first; - // int xminbin = nxlo[x2].first; - // int proc = events[is][p]._p; - // HalfMatrixCheck(fEvent._x1,fEvent._x2,xminbin,xmaxbin,proc); - // int ixHM = GetXIndex(ObsBin,xminbin,xmaxbin); - // // double ww = nxup[x1].second * nxlo[x2].second * wgt + stm1[ixHM][proc]; - // // double& sti = stm1[ixHM][proc]; - // // sti = ww; // this assignment is time consuming ?! - // stm1[ixHM][proc] += nxup[x1].second * nxlo[x2].second * wgt;//nmu[m1].second * wp[p]; - // // c->SigmaTilde[ObsBin][is][nmu[m1].first][ixHM][proc] += nxup[x1].second * nxlo[x2].second * wgt;//nmu[m1].second * wp[p]; - } - } - } - } - } - } else { - for (unsigned int is = 0 ; is<events.size() ; is++) { // all scalevars - FillAllSubprocesses(events[is], scen, is, wgtfac); - } + for (unsigned int is = 0 ; is<events.size() ; is++) { // all scalevars + FillAllSubprocesses(events[is], scen, is, wgtfac); } } @@ -2856,140 +2800,57 @@ void fastNLOCreate::FillContribution(int scalevar, const double wgtfac) { exit(1); } - // hier - // cout<<"Fill ObsBin="<<ObsBin<<", w="<<fEvent._w<<", x1="<<fEvent._x1<<", x2="<<fEvent._x2 - // <<", o0="<<fScenario._o[0] - // <<", m1="<<fScenario._m1 - // <<", m2="<<fScenario._m2 - // <<", OB="<<fScenario._iOB - // <<"\tproc="<<fEvent._p - // <<", wr="<<fEvent._wr - // <<", wf="<<fEvent._wf - // <<endl; - // static double wsum = 0; - // wsum+= fEvent._w; //hier - // cout<<" * wSum = "<<wsum<<endl; - - - // --- statistics and weights**2 - - - //logger.debug["FillContributionFixHHC"]<<"The process Id is p = "<<p<<endl; - - // ---- DIS ---- // - if (c->GetNPDF() == 1 && fastNLOCoeffAddFlex::CheckCoeffConstants(c,true)) { - // todo - FillContributionFlexDIS((fastNLOCoeffAddFlex*)GetTheCoeffTable(), ObsBin, wgtfac); - //{logger.error["FillContribution"]<<"Don't know how to fill this table. Exiting."<<endl; exit(1); } - } else if (c->GetNPDF() == 1 && fastNLOCoeffAddFix::CheckCoeffConstants(c,true)) { - // todo - FillContributionFixDIS((fastNLOCoeffAddFix*)GetTheCoeffTable(), ObsBin, scalevar, wgtfac); - //{logger.error["FillContribution"]<<"Don't know how to fill this table (DIS: fix-scale tables!). Exiting."<<endl; exit(1); } - } - // ---- pp/ppbar ---- // - else if (c->GetNPDF() == 2 && fastNLOCoeffAddFlex::CheckCoeffConstants(c,true)) - FillContributionFlexHHC((fastNLOCoeffAddFlex*)GetTheCoeffTable(), ObsBin, wgtfac); - else if (c->GetNPDF() == 2 && fastNLOCoeffAddFix::CheckCoeffConstants(c,true)) - FillContributionFixHHC((fastNLOCoeffAddFix*)GetTheCoeffTable(), ObsBin, scalevar, wgtfac); - else { - logger.error["FillContribution"]<<"Don't know how to fill this table. Exiting."<<endl; - exit(1); - } -} - - - -// ___________________________________________________________________________________________________ -void fastNLOCreate::FillContributionFixHHC(fastNLOCoeffAddFix* c, int ObsBin, int scalevar, const double wgtfac) { - //! read informatio from 'Event' and 'Scenario' - //! do the interpolation - //! and fill into the tables. - //logger.debug["FillContributionFixHHC"]<<endl; - if ( wgtfac != 1.0 ) { - logger.debug["FillContributionFixHHC"]<<"Experimental: Additional weight factor wgtfac = " << wgtfac << "not much tested so far!"<<endl; + logger.error[__func__]<<"Additional weight factor wgtfac = " << wgtfac << "not yet implemented for flex-scale tables, aborted!"<<endl; + exit(1); } - if (fEvent._w == 0) return; // nothing todo. + if (fEvent._w == 0 && fEvent._wf==0 && fEvent._wr==0 && fEvent._wrr==0 && fEvent._wff==0 && fEvent._wrf==0) return; // nothing todo. + int NPDFDim = c->GetNPDFDim(); // do interpolation - double xmin = GetTheCoeffTable()->GetNPDFDim() == 1 ? std::min(fEvent._x1,fEvent._x2) : fEvent._x1; - double xmax = GetTheCoeffTable()->GetNPDFDim() == 1 ? std::max(fEvent._x1,fEvent._x2) : fEvent._x2; - - vector<pair<int,double> > nxlo = fKernX1[ObsBin]->GetNodeValues(xmin); - vector<pair<int,double> > nxup = fKernX2[ObsBin]->GetNodeValues(xmax); - - const double mu = fScenario._m1 * fScaleFac[scalevar]; - const vector<pair<int,double> >& nmu = fKernMuS[ObsBin][scalevar]->GetNodeValues(mu); - - if (fApplyPDFReweight) { - fKernX1[ObsBin]->CheckX(xmin); - fKernX2[ObsBin]->CheckX(xmax); - ApplyPDFWeight(nxlo,xmin,fKernX1[ObsBin]->GetGridPtr()); - ApplyPDFWeight(nxup,xmax,fKernX2[ObsBin]->GetGridPtr()); - } - - - // fill grid - if (!CheckWeightIsFinite()) return; - double wgt = wgtfac * fEvent._w / BinSize[ObsBin]; - for (unsigned int x1 = 0 ; x1<nxlo.size() ; x1++) { - for (unsigned int x2 = 0 ; x2<nxup.size() ; x2++) { - int p = fEvent._p; - int xminbin = nxlo[x1].first; - int xmaxbin = nxup[x2].first; - HalfMatrixCheck(fEvent._x1,fEvent._x2,xminbin,xmaxbin,p); - //HalfMatrixCheck(xminbin,xmaxbin,p); - int ixHM = GetXIndex(ObsBin,xminbin,xmaxbin); - - for (unsigned int m1 = 0 ; m1<nmu.size() ; m1++) { - double w = wgt * nxlo[x1].second * nxup[x2].second * nmu[m1].second ; - if (! std::isfinite(w)) { - logger.error["FillContributionFixHHC"]<<"Weight w is not finite, w = " << w << "!"<<endl; - logger.error["FillContributionFixHHC"]<<"This should have been captured before, aborting ..."<<endl; - exit(1); - } - // cout<<" Fill * : i="<<ObsBin<<" svar="<<scalevar<<" imu="<<m1<<" ix="<<ixHM<<", im1="<<nmu[m1].first<<", p="<<p<<", w="<<nxup[x1].second * nxlo[x2].second * nmu[m1].second / BinSize[ObsBin] - // <<",\tfEvent._w="<<fEvent._w<<",\twx="<<nxup[x1].second * nxlo[x2].second<<",\tws="<<nmu[m1].second<<endl; - c->SigmaTilde[ObsBin][scalevar][nmu[m1].first][ixHM][p] += w; - } + //cout<<"try to interpol. ObsBin="<<ObsBin<<" ,x1="<<fEvent._x1<<", x2="<<fEvent._x2<<", mu1="<<Scenario._m1<<", mu2="<<Scenario._m2<<endl; + double xmin = NPDFDim == 1 ? std::min(fEvent._x1,fEvent._x2) : fEvent._x1; + double xmax = NPDFDim == 1 ? std::max(fEvent._x1,fEvent._x2) : fEvent._x2; + vector<pair<int,double> > nxlo; + vector<pair<int,double> > nxup; + if (NPDFDim == 1) { + nxlo = fKernX1[ObsBin]->GetNodeValues(xmin); + nxup = fKernX1[ObsBin]->GetNodeValues(xmax); + } else if (NPDFDim > 1) { + nxlo = fKernX1[ObsBin]->GetNodeValues(xmin); + nxup = fKernX2[ObsBin]->GetNodeValues(xmax); + } else { + if (xmin < xmax) { + nxlo = fKernX1[ObsBin]->GetNodeValues(xmin); + nxup = fKernX1[ObsBin]->GetNodeValues(xmax); + } else { + nxup = fKernX1[ObsBin]->GetNodeValues(xmax); + nxlo = fKernX1[ObsBin]->GetNodeValues(xmin); } } -} - - + c->ExtendX(ObsBin, fKernX1, fKernX2); -// ___________________________________________________________________________________________________ -void fastNLOCreate::FillContributionFlexHHC(fastNLOCoeffAddFlex* c, int ObsBin, const double wgtfac) { - //! read informatio from 'Event' and 'Scenario' - //! do the interpolation - //! and fill into the tables. - //logger.debug["FillContributionFlexHHC"]<<endl; - - if ( wgtfac != 1.0 ) { - logger.error["FillContributionFlexHHC"]<<"Additional weight factor wgtfac = " << wgtfac << "not yet implemented for flex-scale tables, aborted!"<<endl; - exit(1); + vector<pair<int,double>> nmu1; + vector<pair<int,double>> nmu2; + if (fIsFlexibleScale) { + nmu1 = fKernMu1[ObsBin]->GetNodeValues(fScenario._m1); + nmu2 = fKernMu2[ObsBin]->GetNodeValues(fScenario._m2); + } else { + nmu1 = fKernMuS[ObsBin][scalevar]->GetNodeValues(fScenario._m1 * fScaleFac[scalevar]); } - if (fEvent._w == 0 && fEvent._wf==0 && fEvent._wr==0 && fEvent._wrr==0 && fEvent._wff==0 && fEvent._wrf==0) return; // nothing todo. - - // do interpolation - //cout<<"try to interpol. ObsBin="<<ObsBin<<" ,x1="<<fEvent._x1<<", x2="<<fEvent._x2<<", mu1="<<Scenario._m1<<", mu2="<<Scenario._m2<<endl; - double xmin = GetTheCoeffTable()->GetNPDFDim() == 1 ? std::min(fEvent._x1,fEvent._x2) : fEvent._x1; - double xmax = GetTheCoeffTable()->GetNPDFDim() == 1 ? std::max(fEvent._x1,fEvent._x2) : fEvent._x2; - vector<pair<int,double> > nxlo = fKernX1[ObsBin]->GetNodeValues(xmin); - vector<pair<int,double> > nxup = fKernX2[ObsBin]->GetNodeValues(xmax); - const vector<pair<int,double> >& nmu1 = fKernMu1[ObsBin]->GetNodeValues(fScenario._m1); - const vector<pair<int,double> >& nmu2 = fKernMu2[ObsBin]->GetNodeValues(fScenario._m2); - if (fApplyPDFReweight) { fKernX1[ObsBin]->CheckX(xmin); fKernX2[ObsBin]->CheckX(xmax); ApplyPDFWeight(nxlo,xmin,fKernX1[ObsBin]->GetGridPtr()); - ApplyPDFWeight(nxup,xmax,fKernX2[ObsBin]->GetGridPtr()); + if (NPDFDim > 1) { + ApplyPDFWeight(nxup,xmax,fKernX2[ObsBin]->GetGridPtr()); + } else { + ApplyPDFWeight(nxup,xmax,fKernX1[ObsBin]->GetGridPtr()); + } } - // fill grid //if (!CheckWeightIsFinite()) return; for (unsigned int x1 = 0 ; x1<nxlo.size() ; x1++) { @@ -3000,267 +2861,13 @@ void fastNLOCreate::FillContributionFlexHHC(fastNLOCoeffAddFlex* c, int ObsBin, HalfMatrixCheck(fEvent._x1,fEvent._x2,xminbin,xmaxbin,p); //HalfMatrixCheck(xminbin,xmaxbin,p); int ixHM = GetXIndex(ObsBin,xminbin,xmaxbin); - - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nxlo[x1].second * nxup[x2].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - if ( wfnlo == 0 ) continue; - if (! std::isfinite(wfnlo)) { - logger.error["FillContributionFlexHHC"]<<"Weight wfnlo is not finite, wfnlo = " << wfnlo << "!"<<endl; - logger.error["FillContributionFlexHHC"]<<"This should have been captured before, aborting ..."<<endl; - fKernX1[ObsBin]->PrintGrid(); - fKernX2[ObsBin]->PrintGrid(); - fKernMu1[ObsBin]->PrintGrid(); - fKernMu2[ObsBin]->PrintGrid(); - cout<<"ix1="<<x1<<", ix2="<<x2<<", im1="<<m1<<", im2="<<mu2<<endl; - cout<<"x1="<<nxlo[x1].second<<", x1="<<x1<<", xval="<<xmin<<endl; - cout<<"x2="<<nxup[x2].second<<", x2="<<x2<<", xval="<<xmax<<endl; - cout<<"m1="<< nmu1[m1].second<<", m1="<<m1<<", mu1val="<<fScenario._m1<<endl; - cout<<"m2="<<nmu2[mu2].second<<", m2="<<mu2<<", mu2val="<<fScenario._m2<<endl; - exit(1); - } - if (fEvent._w != 0) { - c->SigmaTildeMuIndep[ObsBin][ixHM][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._w * wfnlo; - //wsum+= fEvent._w * wfnlo; - } - if (fEvent._wf != 0) { - //cout<<" Fill F : ix="<<ixHM<<", im1="<<nmu1[m1].first<<", im2="<<nmu2[mu2].first<<", p="<<p<<", w="<<fEvent._wf * wfnlo<<endl; - c->SigmaTildeMuFDep [ObsBin][ixHM][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wf * wfnlo; - } - if (fEvent._wr != 0) { - //cout<<" Fill R : ix="<<ixHM<<", im1="<<nmu1[m1].first<<", im2="<<nmu2[mu2].first<<", p="<<p<<", w="<<fEvent._wr * wfnlo<<endl; - c->SigmaTildeMuRDep [ObsBin][ixHM][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wr * wfnlo; - } - if (fEvent._wrr != 0) { - c->SigmaTildeMuRRDep [ObsBin][ixHM][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wrr * wfnlo; - } - if (fEvent._wff != 0) { - c->SigmaTildeMuFFDep [ObsBin][ixHM][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wff * wfnlo; - } - if (fEvent._wrf != 0) { - c->SigmaTildeMuRFDep [ObsBin][ixHM][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wrf * wfnlo; - } - } - } + double wfnlo = wgtfac * nxlo[x1].second * nxup[x2].second / BinSize[ObsBin]; + c->Fill(fEvent, ObsBin, ixHM, scalevar, nmu1, nmu2, p, wfnlo); } } - //cout<<" * wSumW = "<<wsum<<endl; } - - -// ___________________________________________________________________________________________________ -void fastNLOCreate::FillContributionFlexDIS(fastNLOCoeffAddFlex* c, int ObsBin, const double wgtfac) { - //! read information from 'Event' and 'Scenario' - //! do the interpolation - //! and fill into the tables. - //logger.debug["FillContributionFlexDIS"]<<endl; - - if ( wgtfac != 1.0 ) { - logger.error["FillContributionFlexDIS"]<<"Additional weight factor wgtfac = " << wgtfac << "not yet implemented for flex-scale tables, aborted!"<<endl; - exit(1); - } - - if (fEvent._w == 0 && fEvent._wf==0 && fEvent._wr==0 && fEvent._wrr==0 && fEvent._wrf==0) return; // nothing todo. - - // do interpolation - //cout<<"try to interpol. ObsBin="<<ObsBin<<" ,x1="<<fEvent._x1<<", x2="<<fEvent._x2<<", mu1="<<Scenario._m1<<", mu2="<<Scenario._m2<<endl; - - // todo, just: 'x' - double x = fEvent._x1; - vector<pair<int,double> > nx = fKernX1[ObsBin]->GetNodeValues(x); - vector<pair<int,double> > nmu1 = fKernMu1[ObsBin]->GetNodeValues(fScenario._m1); - vector<pair<int,double> > nmu2 = fKernMu2[ObsBin]->GetNodeValues(fScenario._m2); - - - if (fApplyPDFReweight) { - fKernX1[ObsBin]->CheckX(x); - ApplyPDFWeight(nx,x,fKernX1[ObsBin]->GetGridPtr()); - } - - // fill grid - if (!CheckWeightIsFinite()) return; - /* - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int p = fEvent._p; - int xIdx = nx[ix].first; - //HalfMatrixCheck(xminbin,xmaxbin,p); - //int ixHM = GetXIndex(ObsBin,xminbin,xmaxbin); - - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nx[ix].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - // if (! std::isfinite(wfnlo)) { - // logger.error["FillContributionFlexDIS"]<<"Weight wfnlo is not finite, wfnlo = " << wfnlo << "!"<<endl; - // logger.error["FillContributionFlexDIS"]<<"This should have been captured before, aborting ..."<<endl; - // fKernX1[ObsBin]->PrintGrid(); - // fKernMu1[ObsBin]->PrintGrid(); - // fKernMu2[ObsBin]->PrintGrid(); - // cout<<"ix1="<<ix<<", im1="<<m1<<", im2="<<mu2<<endl; - // cout<<"x1="<<nx[ix].second<<", ix="<<ix<<", xval="<<x<<endl; - // cout<<"m1="<< nmu1[m1].second<<", m1="<<m1<<", mu1val="<<fScenario._m1<<endl; - // cout<<"m2="<<nmu2[mu2].second<<", m2="<<mu2<<", mu2val="<<fScenario._m2<<endl; - // exit(1); - // } - if (fEvent._w != 0) { - //cout<<" Fill * : ix="<<ix<<", im1="<<nmu1[m1].first<<", im2="<<nmu2[mu2].first<<", p="<<p<<", w="<<fEvent._w * wfnlo<<endl; - c->SigmaTildeMuIndep[ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._w * wfnlo; - } - if (fEvent._wf != 0) { - //cout<<" Fill F : ix="<<ix<<", im1="<<nmu1[m1].first<<", im2="<<nmu2[mu2].first<<", p="<<p<<", w="<<fEvent._wf * wfnlo<<endl; - c->SigmaTildeMuFDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wf * wfnlo; - } - if (fEvent._wr != 0) { - //cout<<" Fill R : ix="<<ix<<", im1="<<nmu1[m1].first<<", im2="<<nmu2[mu2].first<<", p="<<p<<", w="<<fEvent._wr * wfnlo<<endl; - c->SigmaTildeMuRDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wr * wfnlo; - } - if (fEvent._wrr != 0) { - c->SigmaTildeMuRRDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wrr * wfnlo; - } - if (fEvent._wff != 0) { - c->SigmaTildeMuFFDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wff * wfnlo; - } - if (fEvent._wrf != 0) { - c->SigmaTildeMuRFDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wrf * wfnlo; - } - } - } - } - */ - - int p = fEvent._p; - if (fEvent._w != 0) { - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int xIdx = nx[ix].first; - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nx[ix].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - c->SigmaTildeMuIndep[ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._w * wfnlo; - } - } - } - } - if (fEvent._wf != 0) { - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int xIdx = nx[ix].first; - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nx[ix].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - c->SigmaTildeMuFDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wf * wfnlo; - } - } - } - } - if (fEvent._wr != 0) { - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int xIdx = nx[ix].first; - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nx[ix].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - c->SigmaTildeMuRDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wr * wfnlo; - } - } - } - } - if (fEvent._wrr != 0) { - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int xIdx = nx[ix].first; - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nx[ix].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - c->SigmaTildeMuRRDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wrr * wfnlo; - } - } - } - } - if (fEvent._wff != 0) { - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int xIdx = nx[ix].first; - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nx[ix].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - c->SigmaTildeMuFFDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wff * wfnlo; - } - } - } - } - if (fEvent._wrf != 0) { - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int xIdx = nx[ix].first; - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - for (unsigned int mu2 = 0 ; mu2<nmu2.size() ; mu2++) { - double wfnlo = nx[ix].second * nmu1[m1].second * nmu2[mu2].second / BinSize[ObsBin]; - c->SigmaTildeMuRFDep [ObsBin][xIdx][nmu1[m1].first][nmu2[mu2].first][p] += fEvent._wrf * wfnlo; - } - } - } - } -} - - -// ___________________________________________________________________________________________________ -void fastNLOCreate::FillContributionFixDIS(fastNLOCoeffAddFix* c, int ObsBin, int scalevar, const double wgtfac) { - //! read information from 'Event' and 'Scenario' - //! do the interpolation - //! and fill into the tables. - //logger.debug["FillContributionFixDIS"]<<endl; - - if ( wgtfac != 1.0 ) { - logger.warn["FillContributionFixDIS"]<<"Attention! Additional weight factor wgtfac = " << wgtfac << "not really tested so far!"<<endl; - } - - if (fEvent._w == 0) return; // nothing todo. - if (scalevar >= (int)fScaleFac.size()) { - logger.error["FillContributionFixDIS"]<<"Error! Scale variation scalevar="<<scalevar<<" requested" - <<", but only "<<fScaleFac.size()<<" variations are initialized. Exiting."<<endl; - exit(3); - } - - // do interpolation - //cout<<"try to interpol. ObsBin="<<ObsBin<<" ,x1="<<fEvent._x1<<", x2="<<fEvent._x2<<", mu1="<<fScenario._m1<<endl; - - // todo, just: 'x' - double x = fEvent._x1; - vector<pair<int,double> > nx = fKernX1[ObsBin]->GetNodeValues(x); - vector<pair<int,double> > nmu1 = fKernMuS[ObsBin][scalevar]->GetNodeValues(fScenario._m1); - - - if (fApplyPDFReweight) { - fKernX1[ObsBin]->CheckX(x); - ApplyPDFWeight(nx,x,fKernX1[ObsBin]->GetGridPtr()); - } - - // fill grid - if (!CheckWeightIsFinite()) return; - for (unsigned int ix = 0 ; ix<nx.size() ; ix++) { - int p = fEvent._p; - int xIdx = nx[ix].first; - //HalfMatrixCheck(xminbin,xmaxbin,p); - //int ixHM = GetXIndex(ObsBin,xminbin,xmaxbin); - - for (unsigned int m1 = 0 ; m1<nmu1.size() ; m1++) { - double wfnlo = wgtfac * nx[ix].second * nmu1[m1].second / BinSize[ObsBin]; - if (! std::isfinite(wfnlo)) { - logger.error["FillContributionFixDIS"]<<"Weight wfnlo is not finite, wfnlo = " << wfnlo << "!"<<endl; - logger.error["FillContributionFixDIS"]<<"This should have been captured before, aborting ..."<<endl; - fKernX1[ObsBin]->PrintGrid(); - fKernMu1[ObsBin]->PrintGrid(); - cout<<"ix1="<<ix<<", im1="<<m1<<endl; - cout<<"x1="<<nx[ix].second<<", ix="<<ix<<", xval="<<x<<endl; - cout<<"m1="<< nmu1[m1].second<<", m1="<<m1<<", mu1val="<<fScenario._m1<<endl; - exit(1); - } - if (fEvent._w != 0) { - //cout<<" Fill * : ix="<<xIdx<<", im1="<<nmu1[m1].first<<", im2="<<", p="<<p<<", w="<<fEvent._w * wfnlo<<endl; - c->SigmaTilde[ObsBin][scalevar][nmu1[m1].first][xIdx][p] += fEvent._w * wfnlo; - } - } - } -} - - - // ___________________________________________________________________________________________________ void fastNLOCreate::FillRefContribution(int scalevar, const double wgtfac) { //! This is a reference table. @@ -4407,18 +4014,50 @@ void fastNLOCreate::InitInterpolationKernels() { vector<double> wrmMu1Up, wrmMu1Dn; vector<double> wrmMu2Up, wrmMu2Dn; if (GetTheCoeffTable()->GetIRef() == 0) { - wrmX = GetColumnFromTable(fWarmupConsts.Values, 1) ;// DOUBLE_COL_NS(Warmup.Values,x_min,fSteerfile); - wrmMu1Dn = GetColumnFromTable(fWarmupConsts.Values, 3) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(0,"min"),fSteerfile); - wrmMu1Up = GetColumnFromTable(fWarmupConsts.Values, 4) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(0,"max"),fSteerfile); - if (wrmMu1Dn.size()!=GetNObsBin() || wrmMu1Up.size()!= GetNObsBin()) { - logger.error["InitInterpolationKernels"]<<"Insufficient no. of rows for warmup values of Mu1. Exiting."<<endl; + if (fScenConsts.Mu1_NNodeCounting == "NodesPerDim1") { + wrmMu1Dn = GetObsBinsLoBounds(0); + wrmMu1Up = GetObsBinsUpBounds(0); + } else if (fScenConsts.Mu1_NNodeCounting == "NodesPerDim2") { + wrmMu1Dn = GetObsBinsLoBounds(1); + wrmMu1Up = GetObsBinsUpBounds(1); + } else if (fScenConsts.Mu1_NNodeCounting == "NodesPerDim3") { + wrmMu1Dn = GetObsBinsLoBounds(2); + wrmMu1Up = GetObsBinsUpBounds(2); + } else if (fScenConsts.Mu1_NNodeCounting == "NodesPerBin") { + wrmX = GetColumnFromTable(fWarmupConsts.Values, 1) ;// DOUBLE_COL_NS(Warmup.Values,x_min,fSteerfile); + wrmMu1Dn = GetColumnFromTable(fWarmupConsts.Values, 3) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(0,"min"),fSteerfile); + wrmMu1Up = GetColumnFromTable(fWarmupConsts.Values, 4) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(0,"max"),fSteerfile); + if (wrmMu1Dn.size()!=GetNObsBin() || wrmMu1Up.size()!= GetNObsBin()) { + logger.error["InitInterpolationKernels"]<<"Insufficient no. of rows for warmup values of Mu1. Exiting."<<endl; + exit(1); + } + } else { + logger.error["InitInterpolationKernels"] << "Unknown value for Mu1_NNodeCounting: " << fScenConsts.Mu1_NNodeCounting << endl; + logger.error["InitInterpolationKernels"] << "Supported values: NodesPerBin, NodesPerDim1, NodesPerDim2, NodesPerDim3" << endl; + logger.error["InitInterpolationKernels"] << "Exiting." << endl; exit(1); } if (fIsFlexibleScale) { - wrmMu2Dn = GetColumnFromTable(fWarmupConsts.Values, 5) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(1,"min"),fSteerfile); - wrmMu2Up = GetColumnFromTable(fWarmupConsts.Values, 6) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(1,"max"),fSteerfile); - if (wrmMu2Dn.size()!=GetNObsBin() || wrmMu2Up.size()!= GetNObsBin()) { - logger.error["InitInterpolationKernels"]<<"Insufficient no. of rows for warmup values for Mu2. Exiting."<<endl; + if (fScenConsts.Mu2_NNodeCounting == "NodesPerDim1") { + wrmMu2Dn = GetObsBinsLoBounds(0); + wrmMu2Up = GetObsBinsUpBounds(0); + } else if (fScenConsts.Mu2_NNodeCounting == "NodesPerDim2") { + wrmMu2Dn = GetObsBinsLoBounds(1); + wrmMu2Up = GetObsBinsUpBounds(1); + } else if (fScenConsts.Mu2_NNodeCounting == "NodesPerDim3") { + wrmMu2Dn = GetObsBinsLoBounds(2); + wrmMu2Up = GetObsBinsUpBounds(2); + } else if (fScenConsts.Mu2_NNodeCounting == "NodesPerBin") { + wrmMu2Dn = GetColumnFromTable(fWarmupConsts.Values, 5) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(1,"min"),fSteerfile); + wrmMu2Up = GetColumnFromTable(fWarmupConsts.Values, 6) ;//read_steer::getdoublecolumn("Warmup.Values",GetWarmupHeader(1,"max"),fSteerfile); + if (wrmMu2Dn.size()!=GetNObsBin() || wrmMu2Up.size()!= GetNObsBin()) { + logger.error["InitInterpolationKernels"]<<"Insufficient no. of rows for warmup values for Mu2. Exiting."<<endl; + exit(1); + } + } else { + logger.error["InitInterpolationKernels"] << "Unknown value for Mu2_NNodeCounting: " << fScenConsts.Mu2_NNodeCounting << endl; + logger.error["InitInterpolationKernels"] << "Supported values: NodesPerBin, NodesPerDim1, NodesPerDim2, NodesPerDim3" << endl; + logger.error["InitInterpolationKernels"] << "Exiting." << endl; exit(1); } } @@ -4446,7 +4085,10 @@ void fastNLOCreate::InitInterpolationKernels() { // Create x grids with X_NNodes+1 nodes up to x_max = 1. // The additional last node will be removed again below. - int nxtot = fScenConsts.X_NNodes + 1; + double nxtot = fScenConsts.X_NNodes; + if (fScenConsts.X_NNodeCounting != "NodeDensity") { + nxtot += 1; + } if (fScenConsts.X_NNodeCounting == "NodesPerMagnitude") { // "NodesMax","NodesPerBin","NodesPerMagnitude" logger.debug["InitInterpolationKernels"]<<"Setting x nodes per magnitude: "<<fScenConsts.X_NNodeCounting<<endl; fKernX1[i] = MakeInterpolationKernels(fScenConsts.X_Kernel,wrmX[i],1,fScenConsts.X_DistanceMeasure); // use 1 as upper x-value @@ -4487,10 +4129,18 @@ void fastNLOCreate::InitInterpolationKernels() { fKernX2[i]->MakeGrids(nxbin); // fReduceXmin accounted for above } delete kernmin; + } else if(fScenConsts.X_NNodeCounting == "NodeDensity") { + logger.debug["InitInterpolationKernels"]<<"Setting x nodes as a density: "<<fScenConsts.X_NNodeCounting<<endl; + fKernX1[i] = MakeInterpolationKernels(fScenConsts.X_Kernel,nxtot,fScenConsts.X_DistanceMeasure); // use 1 as upper x-value + fKernX1[i]->MakeGrids(4,fReduceXmin); + if (npdf == 2) { + fKernX2[i] = MakeInterpolationKernels(fScenConsts.X_Kernel,nxtot,fScenConsts.X_DistanceMeasure); // use 1 as upper x-value + fKernX2[i]->MakeGrids(4,fReduceXmin); + } } else { // error logger.error["InitInterpolationKernels"]<<"Cannot understand node counting: "<<fScenConsts.X_NNodeCounting<<"."<<endl; - logger.error["InitInterpolationKernels"]<<"Supported options are: 'NodesPerMagnitude', 'NodesPerBin' and 'NodesMax'."<<endl; + logger.error["InitInterpolationKernels"]<<"Supported options are: 'NodesPerMagnitude', 'NodesPerBin', 'NodesMax' and 'NodeDensity'."<<endl; } // Remove last node at x = 1; is multiplied by PDFs equalling zero anyway. @@ -4543,7 +4193,6 @@ std::vector<double> fastNLOCreate::GetColumnFromTable(const std::vector<std::vec } - // ___________________________________________________________________________________________________ fastNLOInterpolBase* fastNLOCreate::MakeInterpolationKernels(string KernelName, double xdn, double xup, const std::string& distancemeasure) { //! This function identifies the string-identifier @@ -4559,13 +4208,33 @@ fastNLOInterpolBase* fastNLOCreate::MakeInterpolationKernels(string KernelName, return new fastNLOInterpolLinear(xdn,xup,type); else if (KernelName == "OneNode") return new fastNLOInterpolOneNode(xdn,xup,type); - // else if ( KernelName == "...") // todo implement other kernels here! - // return ... else { - logger.warn["MakeInterpolationKernels"]<<"Cannot find kernel routine:" <<KernelName<<" or kernel not (yet) implemented. Exiting."<<endl; + logger.error["MakeInterpolationKernels"]<<"Cannot find kernel routine:" <<KernelName<<" or kernel not (yet) implemented. Exiting."<<endl; + exit(1); + } +} + + +// ___________________________________________________________________________________________________ +fastNLOInterpolBase* fastNLOCreate::MakeInterpolationKernels(string KernelName, double density, const std::string& distancemeasure) { + //! This function identifies the string-identifier + //! and creates the corresponding fastNLO Interpolation kernel + + fastNLOGrid::GridType type = fastNLOInterpolBase::TranslateGridType(distancemeasure); + + if (KernelName == "CatmullRom" || KernelName == "Catmull") + return new fastNLOInterpolCatmullRom(density,type); + else if (KernelName == "Lagrange") + return new fastNLOInterpolLagrange(density,type); + else if (KernelName == "Linear") + return new fastNLOInterpolLinear(density,type); + else if (KernelName == "OneNode") { + logger.error["MakeInterpolationKernels"]<<"Cannot create a OneNode kernel with a density. Exiting."<<endl; + exit(1); + } else { + logger.error["MakeInterpolationKernels"]<<"Cannot find kernel routine:" <<KernelName<<" or kernel not (yet) implemented. Exiting."<<endl; exit(1); } - return NULL; // default return } @@ -4640,7 +4309,9 @@ fastNLOReader* fastNLOCreate::SetIsReferenceTable(fastNLOReader* fnloread) { //fScenConsts.X_NoOfNodesPerMagnitude = false; fScenConsts.X_NNodeCounting = "NodesPerBin"; fScenConsts.Mu1_NNodes = 1; + fScenConsts.Mu1_NNodeCounting = "NodesPerBin"; fScenConsts.Mu2_NNodes = 1; + fScenConsts.Mu2_NNodeCounting = "NodesPerBin"; fScenConsts.X_Kernel = "OneNode"; fScenConsts.Mu1_Kernel = "OneNode"; fScenConsts.Mu2_Kernel = "OneNode"; @@ -4860,3 +4531,17 @@ bool fastNLOCreate::GetParameterFromSteering(const string& key, vector<vector<do val = read_steer::getdoubletable(key,fSteerfile); return exist; } + +// ___________________________________________________________________________________________________ +bool fastNLOCreate::WarmupNeeded() const { + if (fScenConsts.X_NNodeCounting != "NodeDensity") { + return true; + } + if (fScenConsts.Mu1_NNodeCounting == "NodesPerBin") { + return true; + } + if (fIsFlexibleScale && fScenConsts.Mu2_NNodeCounting == "NodesPerBin") { + return true; + } + return false; +} diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc index 1420164da094e6a81d41eba160dd0ae44d60c347..88fd0d71a3a494fadd01a6e8ba715f3d4e6f6be2 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolBase.cc @@ -23,6 +23,53 @@ fastNLOInterpolBase::fastNLOInterpolBase(double min, double max, fastNLOGrid::Gr } +//______________________________________________________________________________ +fastNLOInterpolBase::fastNLOInterpolBase(double density, fastNLOGrid::GridType type, int nMinNodes) : + PrimalScream("fastNLOInterpol"),fNMinNodes(nMinNodes) { + debug["fastNLOInterpolBase"]<<"New fastNLOInterpolBase instance (density contructor)."<<endl; + fLastGridPointWasRemoved=false; + debug["fastNLOInterpolBase"]<<"Distance measure = "<<type<<endl; + debug["fastNLOInterpolBase"]<<"nMinNodes = "<<nMinNodes<<endl; + fdm = type; + fExtendLow = true; + + fvalmax = 1.0; + double valMaxH; + const double valMinOffsetH = -(nMinNodes - 1) / density; + switch (fdm) { + case fastNLOGrid::kLinear: + fvalmin = fvalmax - valMinOffsetH; + break; + case fastNLOGrid::kLogLog025: + valMaxH = Function_loglog025(fvalmax); + fvalmin = Function_loglog025_inv(valMaxH - valMinOffsetH); + break; + case fastNLOGrid::kLog10: + valMaxH = Function_log10(fvalmax); + fvalmin = Function_log10_inv(valMaxH - valMinOffsetH); + break; + case fastNLOGrid::kSqrtLog10: + valMaxH = Function_sqrtlog10(fvalmax); + fvalmin = Function_sqrtlog10_inv(valMaxH - valMinOffsetH); + break; + case fastNLOGrid::kLogLog: + valMaxH = Function_loglog(fvalmax); + fvalmin = Function_loglog_inv(valMaxH - valMinOffsetH); + break; + case fastNLOGrid::k3rdrtLog10: + valMaxH = Function_3rdrtlog10(fvalmax); + fvalmin = Function_3rdrtlog10_inv(valMaxH - valMinOffsetH); + break; + case fastNLOGrid::k4thrtLog10: + valMaxH = Function_4thrtlog10(fvalmax); + fvalmin = Function_4thrtlog10_inv(valMaxH - valMinOffsetH); + break; + default: + error["MakeGridFromHGrid"]<<"Unknown grid type."<<endl; + } +} + + //______________________________________________________________________________ @@ -128,15 +175,27 @@ void fastNLOInterpolBase::MakeGrids(int nNodes, double ReduceXmin){ } -int fastNLOInterpolBase::FindLargestPossibleNode(double x){ +int fastNLOInterpolBase::FindLargestPossibleNode(double x, bool canExtend = false){ // --- find x position in range: 0 <= node1 < nnode1-1 int node1 = fgrid.size()-2; // --- initialize with largest possible value if ( fLastGridPointWasRemoved ) node1=fgrid.size()-1; - if ( x < fgrid[0] ) { - warn["FindLargestPossibleNode"]<<"Value is smaller than smallest node. Using first node. This may bias the result! x="<<x<<endl; - return 0; + if (canExtend && fExtendLow) { + bool gridExtended = false; + while ( x < fgrid[1] ) { + double newxH = fHgrid[0] - (fHgrid[1] - fHgrid[0]); + fHgrid.insert(fHgrid.begin(), newxH); + fgrid.insert(fgrid.begin(), Function_sqrtlog10_inv(newxH)); + debug["FindLargestPossibleNode"]<<"Value is smaller than smallest node. Extending grid. x="<<x<<endl; + gridExtended = true; + } + if (gridExtended) { + return 1; + } } - else if ( x==fgrid[0] ) { + if ( x==fgrid[0] ) { + return 0; + } else if ( x < fgrid[0] ) { + warn["FindLargestPossibleNode"]<<"Value is smaller than smallest node. Using first node. This may bias the result! x="<<x<<endl; return 0; } if ( x > fgrid.back() ) { @@ -332,7 +391,7 @@ bool fastNLOInterpolBase::CheckX(double& x) { return true; } //printf("x=%e, %e; fgrid=%e, %e; ratio: %e\n",x,x-1.,fgrid[0],fgrid[0]-1,x/fgrid[0]-1); - if ( x < fgrid[0] ) { + if ( x < fgrid[0] && !fExtendLow) { if ( x!=fLastVal[1] && fgrid[0]/x-1>1.e-6) warn["CheckX"]<<"Value "<<x<<" is smaller than smallest node (min="<<fgrid[0]<<"). Using this first node."<<endl; fLastVal[1] = x; // use this to monitor whenever there was an incident diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolCatmullRom.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolCatmullRom.cc index 45536a92fd18e8c1751af0f1d8965840b8691e87..c31c4481131f72d302615683e847dd021281ac91 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolCatmullRom.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolCatmullRom.cc @@ -19,6 +19,12 @@ fastNLOInterpolCatmullRom::fastNLOInterpolCatmullRom(double min, double max, fas } +//______________________________________________________________________________ +fastNLOInterpolCatmullRom::fastNLOInterpolCatmullRom(double density, fastNLOGrid::GridType type) : fastNLOInterpolBase(density,type,4) { + debug["fastNLOInterpolLagrange"]<<"New fastNLOInterpolCatmullRom instance."<<endl; +} + + //______________________________________________________________________________ @@ -44,6 +50,8 @@ void fastNLOInterpolCatmullRom::CalcNodeValues(vector<pair<int,double> >& nodes, static const unsigned int nS = 4; // number of nodes that receive contributions from this interpolation + int nnode = FindLargestPossibleNode(x, true); + // --- relative distance delta - in function fdm H(x) // deltascale (Interpol(.,.,.delta,.): relative distance of value to node 'nnode' double delta = GetDelta(x); @@ -52,7 +60,6 @@ void fastNLOInterpolCatmullRom::CalcNodeValues(vector<pair<int,double> >& nodes, // --- get scale interpolation kernel and updated scalenode position: 1 <= nmu < ntot-2 int nmod = 0; // --- variable for final node - int nnode = FindLargestPossibleNode(x); int nmax = fgrid.size()-2; if (fLastGridPointWasRemoved) nmax=fgrid.size()-1; diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLagrange.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLagrange.cc index e568192d4bdb4f9f39476a84ad88a765f1c151b4..5458be9bbab3ce55463fa947746dfc292f6baff5 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLagrange.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLagrange.cc @@ -17,6 +17,12 @@ fastNLOInterpolLagrange::fastNLOInterpolLagrange(double min, double max, fastNLO } +//______________________________________________________________________________ +fastNLOInterpolLagrange::fastNLOInterpolLagrange(double density, fastNLOGrid::GridType type) : fastNLOInterpolBase(density,type,4) { + debug["fastNLOInterpolLagrange"]<<"New fastNLOInterpolLagrange instance."<<endl; +} + + //______________________________________________________________________________ fastNLOInterpolLagrange::~fastNLOInterpolLagrange(void) { } @@ -33,6 +39,8 @@ void fastNLOInterpolLagrange::CalcNodeValues(vector<pair<int,double> >& nodes, d static const unsigned int nS = 4; // number of nodes that receive contributions from this interpolation + int nnode = FindLargestPossibleNode(x, true); + // --- relative distance delta - in function fdm H(x) // deltascale (Interpol(.,.,.delta,.): relative distance of value to node 'nnode' double delta = GetDelta(x); @@ -41,7 +49,6 @@ void fastNLOInterpolLagrange::CalcNodeValues(vector<pair<int,double> >& nodes, d // --- get scale interpolation kernel and updated scalenode position: 1 <= nmu < ntot-2 int nmod = 0; // --- variable for final node - int nnode = FindLargestPossibleNode(x); int nmax = fgrid.size()-2; if (fLastGridPointWasRemoved) nmax=fgrid.size()-1; diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLinear.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLinear.cc index fceef1212752f4f9e5c793798d7b971c0856f057..2872ff6bcc88de3bc5544e4d6d2405c305e507f8 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLinear.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOInterpolLinear.cc @@ -17,6 +17,12 @@ fastNLOInterpolLinear::fastNLOInterpolLinear(double min, double max, fastNLOGrid } +//______________________________________________________________________________ +fastNLOInterpolLinear::fastNLOInterpolLinear(double density, fastNLOGrid::GridType type) : fastNLOInterpolBase(density,type,4) { + debug["fastNLOInterpolLagrange"]<<"New fastNLOInterpolLinear instance."<<endl; +} + + //______________________________________________________________________________ fastNLOInterpolLinear::~fastNLOInterpolLinear(void) { } @@ -31,11 +37,12 @@ void fastNLOInterpolLinear::CalcNodeValues(vector<pair<int,double> >& nodes, dou //! - the value, which this node obtains. //! + // get scale interpolation kernel and updated scalenode position: 1 <= nmu < ntot-2 + int nnode = FindLargestPossibleNode(x, true); + // --- relative distance delta - in function fdm H(x) // deltascale (Interpol(.,.,.delta,.): relative distance of value to node 'nnode' double delta = GetDelta(x); - // --- get scale interpolation kernel and updated scalenode position: 1 <= nmu < ntot-2 - int nnode = FindLargestPossibleNode(x); // --- set nodes nodes.resize(2); nodes[0] = make_pair(nnode, 1.-delta); diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOLHAPDF.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOLHAPDF.cc index 0c871d40b7cec30762e4aaf59e65a645ba741f85..126b6294697533eff49ba82e9727f174b830aa6d 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOLHAPDF.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOLHAPDF.cc @@ -33,10 +33,8 @@ using namespace std; fastNLOLHAPDF::fastNLOLHAPDF(string name) : fastNLOReader(name), fnPDFs(0) , fiPDFMember(0) , fchksum(0.) { logger.info["fastNLOLHAPDF"]<<"Please initialize a PDF file using SetLHAPDFFilename( PDFFile ) and a PDF set using SetLHAPDFMember(int PDFMember)"<<std::endl; - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 PDFSet = NULL; PDF = NULL; - #endif } //______________________________________________________________________________ @@ -45,29 +43,24 @@ fastNLOLHAPDF::fastNLOLHAPDF(string name) : fastNLOReader(name), fnPDFs(0) , fiP fastNLOLHAPDF::fastNLOLHAPDF(const fastNLOTable& table) : fastNLOReader(table), fnPDFs(0) , fiPDFMember(0) , fchksum(0.) { logger.info["fastNLOLHAPDF"]<<"Please initialize a PDF file using SetLHAPDFFilename( PDFFile ) and a PDF set using SetLHAPDFMember(int PDFMember)"<<std::endl; - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 PDFSet = NULL; PDF = NULL; - #endif } //______________________________________________________________________________ fastNLOLHAPDF::~fastNLOLHAPDF() { - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 + delete PDFSet; delete PDF; - #endif } //______________________________________________________________________________ fastNLOLHAPDF::fastNLOLHAPDF(string name, string LHAPDFFile, int PDFMember) : fastNLOReader(name), fnPDFs(0) , fiPDFMember(0) , fchksum(0.) { - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 PDFSet = NULL; PDF = NULL; - #endif SetLHAPDFFilename(LHAPDFFile); SetLHAPDFMember(PDFMember); // Call additional initialization. Not necessary for LHAPDF. @@ -78,10 +71,8 @@ fastNLOLHAPDF::fastNLOLHAPDF(string name, string LHAPDFFile, int PDFMember) : fa fastNLOLHAPDF::fastNLOLHAPDF(const fastNLOTable& table, string LHAPDFFile, int PDFMember) : fastNLOReader(table), fnPDFs(0) , fiPDFMember(0) , fchksum(0.) { - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 PDFSet = NULL; PDF = NULL; - #endif SetLHAPDFFilename(LHAPDFFile); SetLHAPDFMember(PDFMember); // Call additional initialization. Not necessary for LHAPDF. @@ -110,10 +101,7 @@ int fastNLOLHAPDF::GetNFlavor() const { } double fastNLOLHAPDF::GetAlphasMz() const { - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 return PDF->alphasQ(91.1876); - #endif - return LHAPDF::alphasPDF(91.1876); } int fastNLOLHAPDF::GetIPDFMember() const { @@ -140,11 +128,8 @@ double fastNLOLHAPDF::EvolveAlphas(double Q) const { // WARNING: You cannot change alpha_s(Mz), but is is // defined with the pdf. 'alphasMz' is not used here! // - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 return PDF->alphasQ(Q); - #else - return LHAPDF::alphasPDF(Q); - #endif + } @@ -166,31 +151,9 @@ bool fastNLOLHAPDF::InitPDF() { return false; } - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 // Suppress LHAPDF6 output at each member change LHAPDF::setVerbosity(0); return true; - - #else - //LHAPDF::setVerbosity(LHAPDF::SILENT); - LHAPDF::setVerbosity(LHAPDF::LOWKEY); - // Do not use the ByName feature, destroys ease of use on the grid without LHAPDF - //LHAPDF::initPDFSetByName(fLHAPDFFilename); - //cout << "PDF set name " << fLHAPDFFilename << endl; - if (fchksum == 0 || fchksum != CalcChecksum(1.)) { - // need to reset LHAPDF. - logger.debug["InitPDF"]<<"Need to reset lhapdf. fchksum="<<fchksum<<"\tCalcChecksum(1.)="<<CalcChecksum(1.)<<endl; - LHAPDF::initPDFSet(fLHAPDFFilename); - fnPDFs = LHAPDF::numberPDF()+1; // LHAPDF counts 0-44 and returns, 44 which must be 45 - if (fnPDFs < fiPDFMember+1) { - logger.error["InitPDF"]<<"There are only "<<fnPDFs<<" pdf sets within this LHAPDF file. You were looking for set number "<<fiPDFMember<<std::endl; - return false; - } - LHAPDF::initPDF(fiPDFMember); - } - fchksum = CalcChecksum(1.); - return true; - #endif } @@ -203,15 +166,11 @@ vector<double> fastNLOLHAPDF::GetXFX(double xp, double muf) const { // GetXFX is used to get the parton array from the // pre-defined pdf-interface. // - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 // vector<double> xfx(13); // PDF->xfxQ(xp, muf, xfx); vector <double> xfx(13); PDF->xfxQ(xp,muf,xfx); return xfx; - #else - return LHAPDF::xfx(xp,muf); - #endif } @@ -221,18 +180,10 @@ vector<double> fastNLOLHAPDF::GetXFX(double xp, double muf) const { void fastNLOLHAPDF::SetLHAPDFFilename(string filename) { if (filename != fLHAPDFFilename) fchksum = 0; fLHAPDFFilename = filename; - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 if ( PDFSet ) delete PDFSet; PDFSet = new LHAPDF::PDFSet(filename); fnPDFs = PDFSet->size(); SetLHAPDFMember(0); - #else - // Reset pdfset member to zero - fiPDFMember = 0; - // KR: Reactivated this. Why was it switched off? - // --> Mass settings etc. can be read from LHAPDF after setting the filename, i.e. the set. - InitPDF(); - #endif } @@ -240,22 +191,9 @@ void fastNLOLHAPDF::SetLHAPDFFilename(string filename) { void fastNLOLHAPDF::SetLHAPDFMember(int set) { - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 if ( PDF ) delete PDF; PDF = PDFSet->mkPDF(set); fiPDFMember=set; - #else - fiPDFMember = set; - if (fchksum == CalcChecksum(1.)) { // nothin has changed? we set only the pdfmember - logger.debug["SetLHAPDFMember"]<<"Changing only pdfmember!"<<endl; - LHAPDF::initPDF(fiPDFMember); - fchksum = CalcChecksum(1.); - } else { - logger.debug["SetLHAPDFMember"]<<"Demanding full re-initalization of PDF."<<endl; - fchksum = 0; - } - //InitPDF(); - #endif } @@ -273,18 +211,7 @@ void fastNLOLHAPDF::PrintPDFInformation() const { // second instance with another pdf. Then also the first one is using this // pdf when evaluating CalcCrossSection (after a PDFCacheRefilling). // - - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 cout << PDFSet->description(); - #else - printf(" ##################################################################################\n"); - printf(" # fastNLOLHAPDF::PrintCurrentLHAPDFInformation.\n"); - printf(" # Your currently initalized pdf is called:\n"); - LHAPDF::getDescription(); - printf(" # Information about current PDFMember in current LHAPDF-file cannot be displayed.\n"); - printf(" # Please use fastNLOReader::SetLHAPDFMember(int) to choose a pdf-set.\n"); - printf(" ##################################################################################\n"); - #endif } void fastNLOLHAPDF::SetMz(double Mz) { @@ -313,7 +240,6 @@ void fastNLOLHAPDF::InitEvolveAlphas() { -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 //______________________________________________________________________________ vector<LHAPDF::PDFUncertainty> fastNLOLHAPDF::GetPDFUncertaintyLHAPDF(double cl, bool alternative) { //! Calculate PDF uncertainty on cross sections. @@ -417,7 +343,6 @@ vector<double> fastNLOLHAPDF::CalcPDFUncertaintySymm(const vector<LHAPDF::PDFUn ret[iObs] = PDFUnc[iObs].errsymm; return ret; } -#endif //______________________________________________________________________________ @@ -454,14 +379,12 @@ XsUncertainty fastNLOLHAPDF::GetPDFUncertainty(const fastNLO::EPDFUncertaintySty logger.error["GetPDFUncertainty"]<<"ERROR! HERAPDF1.0 uncertainty style not yet implemented, exiting."<<endl; logger.error["GetPDFUncertainty"]<<"ePDFUnc = "<<ePDFUnc<<endl; exit(1); -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 } else if ( ePDFUnc == fastNLO::kLHAPDF6 ) { if ( lNorm ) { logger.error["GetPDFUncertainty"]<<"Normalization option does not work with LHAPDF6 PDF uncertainties, aborted!"<<endl; } else { logger.info["GetPDFUncertainty"]<<"Calculating LHAPDF6 PDF uncertainties."<<endl; } -#endif } else { logger.error["GetPDFUncertainty"]<<"ERROR! Selected PDF uncertainty style not yet implemented, exiting."<<endl; logger.error["GetPDFUncertainty"]<<"ePDFUnc = "<<ePDFUnc<<endl; @@ -597,14 +520,12 @@ XsUncertainty fastNLOLHAPDF::GetPDFUncertainty(const fastNLO::EPDFUncertaintySty logger.debug["GetPDFUncertainty"]<<"iobs = " << iobs << ", dxsl = " << XsUnc.dxsl[iobs] << ", dxsu = " << XsUnc.dxsu[iobs] <<endl; } } else { -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 // Default is no alternative for NNPDF replica uncertainties vector<LHAPDF::PDFUncertainty> L6PDFUnc = GetPDFUncertaintyLHAPDF(100*erf(1/sqrt(2)),false); // vector<LHAPDF::PDFUncertainty> L6PDFUnc = GetPDFUncertaintyLHAPDF(); XsUnc.xs = CalcPDFUncertaintyCentral(L6PDFUnc); XsUnc.dxsu = CalcPDFUncertaintyRelPlus(L6PDFUnc); XsUnc.dxsl = CalcPDFUncertaintyRelMinus(L6PDFUnc); -#endif } logger.info["GetPDFUncertainty"]<<"Setting PDF member back to default of zero."<<endl; diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOTable.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOTable.cc index 9114c586bdadc5c852a58464c491ddbf30e21d2b..5339a173eb0095007952064cd088ff61cf988f98 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOTable.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOTable.cc @@ -549,6 +549,17 @@ bool fastNLOTable::IsCatenableScenario(const fastNLOTable& other) const { } +// ___________________________________________________________________________________________________ +bool fastNLOTable::IsEquivalent(const fastNLOTable& other, double rtol=1e-6) const { + for (int i = 0; i < 1; i++) { + if (!GetCoeffTable(i)->IsEquivalent(*other.GetCoeffTable(i), rtol)) { + return false; + } + } + return true; +} + + // ___________________________________________________________________________________________________ void fastNLOTable::SetUserWeights(double wgt) { //!< Set 'user' weights, which can be used for subsequent mergeing diff --git a/v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc b/v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc index ec1df25f17fdbb90a338d8306784b7f3155b7786..287717f8a25b3e10a9e07ef8d7bd51bf459ddbd8 100644 --- a/v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc +++ b/v2.5/toolkit/fastnlotoolkit/fastNLOTools.cc @@ -532,4 +532,88 @@ namespace fastNLOTools { } } + //______________________________________________________________________________ + std::pair<fastNLO::v1d, fastNLO::v1d> GetTails(fastNLO::v1d& vector1, fastNLO::v1d& vector2) { + if (vector1.size() > vector2.size()) { + return std::make_pair(fastNLO::v1d(vector1.begin() + (vector1.size() - vector2.size()), vector1.end()), vector2); + } else if (vector1.size() < vector2.size()) { + return std::make_pair(vector1, fastNLO::v1d(vector2.begin() + (vector2.size() - vector1.size()), vector2.end())); + } else { + return std::make_pair(vector1, vector2); + } + } + + //______________________________________________________________________________ + bool SameTails(fastNLO::v1d vector1, fastNLO::v1d vector2, double rtol) { + std::tie(vector1, vector2) = GetTails(vector1, vector2); + for (unsigned int i = 0; i < vector1.size(); i++) { + if (abs(vector1[i] - vector2[i]) > abs(rtol * vector1[i])) { + debug["SameTails"] << "1D vector index is " << i << ". val1=" << vector1[i] + << " val2=" << vector2[i] << " rdiff=" + << abs((vector1[i]-vector2[i])/vector1[i]) << " rtol=" << rtol << endl; + return false; + } + } + return true; + } + + //______________________________________________________________________________ + bool SameTails(fastNLO::v2d vector1, fastNLO::v2d vector2, double rtol) { + if (vector1.size() != vector2.size()) { + debug["SameTails"] << "2D vectors have different sizes." << endl; + return false; + } + for (unsigned int i = 0; i < vector1.size(); i++) { + if (!SameTails(vector1[i], vector2[i], rtol)) { + debug["SameTails"] << "2D vector index is " << i << endl; + return false; + } + } + return true; + } + + //______________________________________________________________________________ + bool ExtendHead(fastNLO::v1d& vector1, const fastNLO::v1d& vector2) { + if (vector1.size() < vector2.size()) { + vector1.insert(vector1.begin(), vector2.begin(), vector2.begin() + (vector2.size() - vector1.size())); + return true; + } + return false; + } + + //______________________________________________________________________________ + template <typename T> void ExtendSigmaTildeX( + std::vector<T>& SigmaTildeX, unsigned int OldDimSize1, unsigned int NewDimSize1, + unsigned int OldDimSize2, unsigned int NewDimSize2, int NPDFDim, T InsertValue) { + if (NPDFDim == 0) { + for (unsigned int i = OldDimSize1; i < NewDimSize1; i++) { + SigmaTildeX.insert(SigmaTildeX.begin(), InsertValue); + } + } else if (NPDFDim == 1) { + for (unsigned int i = OldDimSize1; i < NewDimSize1; i++) { + for (unsigned int j = 0; j <= i; j++) { + SigmaTildeX.insert(SigmaTildeX.begin() + (j * (j + 1) / 2), InsertValue); + } + } + } else if (NPDFDim == 2) { + for (unsigned int i = 0; i < OldDimSize2; i++) { + for (unsigned int j = OldDimSize1; j < NewDimSize1; j++) { + SigmaTildeX.insert(SigmaTildeX.begin() + i * NewDimSize1, InsertValue); + } + } + for (unsigned int i = OldDimSize2; i < NewDimSize2; i++) { + for (unsigned int j = 0; j < NewDimSize1; j++) { + SigmaTildeX.insert(SigmaTildeX.begin(), InsertValue); + } + } + } else { + error["ExtendSigmaTildeX"] << "Unsupported NPDFDim for x node density: " << NPDFDim << endl; + exit(1); + } + } + template void ExtendSigmaTildeX<fastNLO::v1d>( + fastNLO::v2d&, unsigned int, unsigned int, unsigned int, unsigned int, int, fastNLO::v1d); + template void ExtendSigmaTildeX<fastNLO::v3d>( + fastNLO::v4d&, unsigned int, unsigned int, unsigned int, unsigned int, int, fastNLO::v3d); + } // end namespace fastNLO diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddBase.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddBase.h index 63543b94630ec045e8901462f217bbdabbce02c0..9023a4089c290d42e6f4ecab8407d669aebecd3f 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddBase.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddBase.h @@ -4,6 +4,8 @@ #include "fastNLOCoeffBase.h" #include "fastNLOConstants.h" +#include "fastNLOInterpolBase.h" +#include "fastNLOEvent.h" namespace fastNLO { struct WgtStat { @@ -158,6 +160,9 @@ public: std::vector < double > GetXNodes1(int iObsBin) const { return XNode1[iObsBin]; } std::vector < double > GetXNodes2(int iObsBin) const { return XNode2[iObsBin]; } + fastNLO::v2d GetAllXNodes1() const { return XNode1; } + fastNLO::v2d GetAllXNodes2() const { return XNode2; } + bool IsReference() const {return IRef>0;}; bool IsCompatible(const fastNLOCoeffAddBase& other) const; bool IsCatenable(const fastNLOCoeffAddBase& other) const; @@ -173,6 +178,11 @@ public: fastNLO::WgtStat& AccessWgtStat() { return fWgt;} //!< Get weight and event counts double GetMergeWeight(fastNLO::EMerge moption, int proc, int bin) const ; //!< Get merge weight for a given bin and subprocess + void ExtendX(int ObsBin, std::vector<fastNLOInterpolBase*>& KernX1, std::vector<fastNLOInterpolBase*>& KernX2); + virtual void ExtendSigmaTildeX(int ObsBin, unsigned int OldXSize1, unsigned int OldXSize2); + virtual void Fill(fnloEvent& Event, int ObsBin, int X, int scalevar, const std::vector<std::pair<int, double>>& nmu1, + const std::vector<std::pair<int, double>>& nmu2, int SubProcess, double w); + protected: void ReadCoeffAddBase(std::istream& table, int ITabVersionRead); int GetScaledimfromvar(int scalevar) const; diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFix.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFix.h index 19b8e8844b1e6688efdf40d60a2ced1dad5b720b..6c97460ec1c0bed1585b5734d447cb95a80c7c60 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFix.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFix.h @@ -3,6 +3,7 @@ #include "fastNLOCoeffAddBase.h" #include "fastNLOConstants.h" +#include "fastNLOEvent.h" class fastNLOCoeffAddFix : public fastNLOCoeffAddBase { @@ -56,6 +57,11 @@ public: void ResizeSigmaTilde(); bool IsCompatible(const fastNLOCoeffAddFix& other) const; //!< Check for compatibility of two contributions for merging/adding bool IsCatenable(const fastNLOCoeffAddFix& other) const; //!< Check for compatibility of two contributions for merging/adding + bool IsEquivalent(const fastNLOCoeffBase& other, double rtol) const; + + void ExtendSigmaTildeX(int ObsBin, unsigned int OldXSize1, unsigned int OldXSize2); + void Fill(fnloEvent& Event, int ObsBin, int X, int scalevar, const std::vector<std::pair<int, double>>& nmu1, + const std::vector<std::pair<int, double>>& nmu2, int SubProcess, double w); protected: void ReadCoeffAddFix(std::istream& table, int ITabVersionRead); diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h index 51f8cd6c669b78347f070eb173ef6fc3da529116..be8e61da97048dee7e68c3e49962b88df5c8aaf0 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffAddFlex.h @@ -48,10 +48,17 @@ public: std::vector<const fastNLO::v5d*> GetSigmaTildes() const { return {&SigmaTildeMuIndep,&SigmaTildeMuRDep,&SigmaTildeMuFDep,&SigmaTildeMuRRDep,&SigmaTildeMuFFDep,&SigmaTildeMuRFDep}; };//!< Get access to sigma tilde + bool IsEquivalent(const fastNLOCoeffBase& other, double rtol) const; + bool IsSigmaTildeEquivalent(const fastNLOCoeffAddFlex* op, const fastNLO::v5d *tst5, const fastNLO::v5d *ost5, double rtol, std::string name) const; + + void ExtendSigmaTildeX(int ObsBin, unsigned int OldXSize1, unsigned int OldXSize2); + void Fill(fnloEvent& Event, int ObsBin, int X, int scalevar, const std::vector<std::pair<int, double>>& nmu1, + const std::vector<std::pair<int, double>>& nmu2, int SubProcess, double w); protected: void ReadCoeffAddFlex(std::istream& table, int ITabVersionRead); + void ExtendSigmaTilde(const fastNLOCoeffAddFlex& othflex, fastNLO::v5d& ThisSigmaTilde, fastNLO::v5d OtherSigmaTilde); int fILOord; // obtained from Scenario int fSTildeDISFormat = 1; // format of sigma-tilde coefficients (0: log(mu2/q2), 1: log(mu2)) diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffBase.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffBase.h index 678cd6b7bf4cf9c496a1500978d0e9135aac8529..3df2691442a68a65cc7115d39f5aed1a3d3fb9b2 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffBase.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCoeffBase.h @@ -35,6 +35,7 @@ public: virtual void CatBin(const fastNLOCoeffBase& other, unsigned int iObsIdx); bool IsCatenable(const fastNLOCoeffBase& other) const; + virtual bool IsEquivalent(const fastNLOCoeffBase& other, double rtol) const; void SetCoeffAddDefaults(); diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h index 8744661e053720df84b770eb1ade2fff9935b6b4..8bace7e196db4047d184f03fb82a362ac91aeabb 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOCreate.h @@ -165,14 +165,6 @@ protected: inline double CalcPDFReweight(double x) const; //!< Fill contribution into table void FillContribution(int scalevar = 0, const double wgtfac=1.0); - //!< Fill flexible scale contribution in pp/ppbar - void FillContributionFlexHHC(fastNLOCoeffAddFlex* c, int ObsBin, const double wgtfac=1.0); - //!< fill flexible scale contribution in DIS - void FillContributionFlexDIS(fastNLOCoeffAddFlex* c, int ObsBin, const double wgtfac=1.0); - //!< fill fixed scale table in pp/ppbar - void FillContributionFixHHC(fastNLOCoeffAddFix* c, int ObsBin, int scalevar, const double wgtfac=1.0); - //!< fill fixed scale contribution in DIS - void FillContributionFixDIS(fastNLOCoeffAddFix* c, int ObsBin, int scalevar, const double wgtfac=1.0); //!< fill contribution if this is a reference table void FillRefContribution(int scalevar = 0, const double wgtfac=1.0); // KR: Don't see any use for shouldReadSteeringFile ==> remove it @@ -198,6 +190,7 @@ protected: void InitCoeffTable(); void InitInterpolationKernels(); fastNLOInterpolBase* MakeInterpolationKernels(std::string KernelName, double xdn, double xup, const std::string& distancemeasure); + fastNLOInterpolBase* MakeInterpolationKernels(std::string KernelName, double density, const std::string& distancemeasure); void InitGrids(); void GetWarmupValues(); bool CheckWarmupConsistency(); //!< Check consistency of warmup bin-grid and variables with steering values. @@ -267,6 +260,7 @@ protected: void FillWeightCache(int scalevar); //!< Fill weight into cache, merge weights for identical phase space points void FlushCache(); //!< Fill weights from cache into table + bool WarmupNeeded() const; struct fnloStats { //! structre to keep track of statisics. Just for fun and information. diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOEvent.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOEvent.h index 0955c84a10a938cc9cfcffda37957d27157bc703..9f4176810923034a7a4229f80de67ed12ae5c089 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOEvent.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOEvent.h @@ -54,6 +54,8 @@ class fnloEvent { //! Useful class to keep all process related variables. //! e.g x-values, weights, process identifiers, etc. friend class fastNLOCreate; + friend class fastNLOCoeffAddFix; + friend class fastNLOCoeffAddFlex; public: fnloEvent(){Reset();} diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolBase.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolBase.h index 5dbc40ac5ace296cf80a41038dff246d561b243c..9a7169e3fdd63f0a74919c112ccdc690b808b3fe 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolBase.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolBase.h @@ -29,6 +29,7 @@ class fastNLOInterpolBase : public PrimalScream { public: fastNLOInterpolBase(double min, double max, fastNLOGrid::GridType type, int nMinNodes); + fastNLOInterpolBase(double density, fastNLOGrid::GridType type, int nMinNodes); virtual ~fastNLOInterpolBase(void); const std::vector<std::pair<int,double> >& GetNodeValues(double val); @@ -45,6 +46,7 @@ public: bool CheckX(double&); static fastNLOGrid::GridType TranslateGridType(std::string in); + std::vector<double> fgrid; protected: @@ -57,7 +59,7 @@ protected: //virtual std::vector<std::pair<int,double> > CalcNodeValues(double val) = 0; virtual void CalcNodeValues(std::vector<std::pair<int,double> >& nodes, double val) = 0; - int FindLargestPossibleNode(double); + int FindLargestPossibleNode(double, bool); inline double Function_loglog025( double mu ){ // function H(mu) = log(log( mu / 0.25 )) @@ -104,9 +106,9 @@ protected: double fLastVal[5] = {M_PI,M_PI,M_PI,M_PI,M_PI}; bool fLastGridPointWasRemoved; // odd boolean to agree with original code; fastNLOGrid::GridType fdm; // distance measure - std::vector<double> fgrid; std::vector<double> fHgrid; int fnmod ; // variable for final nodes. Has to be filled by inherited algorithm + bool fExtendLow = false; }; diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolCatmullRom.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolCatmullRom.h index 444224ddaf73bd8c0eac1fbf5c1ec7b6c40de4e2..0df406e253195691adadda613e7c3514f2157b1a 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolCatmullRom.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolCatmullRom.h @@ -16,6 +16,7 @@ class fastNLOInterpolCatmullRom : public fastNLOInterpolBase { public: fastNLOInterpolCatmullRom(double min, double max, fastNLOGrid::GridType type); + fastNLOInterpolCatmullRom(double density, fastNLOGrid::GridType type); ~fastNLOInterpolCatmullRom(void); // vector<pair<int,double> > CalcNodeValues(double val); diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLagrange.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLagrange.h index 0ad205bcd929bf5e01e122cdcb5b32edbcaaa94c..deff97057022efa674cc199ec1a303378eea34e9 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLagrange.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLagrange.h @@ -23,6 +23,7 @@ class fastNLOInterpolLagrange : public fastNLOInterpolBase { public: fastNLOInterpolLagrange(double min, double max, fastNLOGrid::GridType type); + fastNLOInterpolLagrange(double density, fastNLOGrid::GridType type); ~fastNLOInterpolLagrange(void); // vector<pair<int,double> > CalcNodeValues(double val); diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLinear.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLinear.h index 0bb2922cf825cf8f3444efdac3aae6231d8cd9d5..ceb174b1385fd30be25daf0fec5b4980a6d313e8 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLinear.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOInterpolLinear.h @@ -22,6 +22,7 @@ class fastNLOInterpolLinear : public fastNLOInterpolBase { public: fastNLOInterpolLinear(double min, double max, fastNLOGrid::GridType type); + fastNLOInterpolLinear(double density, fastNLOGrid::GridType type); ~fastNLOInterpolLinear(void); // vector<pair<int,double> > CalcNodeValues(double val); diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOLHAPDF.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOLHAPDF.h index 3b4ecaeec97736ac2779e0fa26cc448b7fd30711..cba4a9a3db932cbe60ad975b60e8281efb6375f3 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOLHAPDF.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOLHAPDF.h @@ -57,7 +57,7 @@ public: int GetNFlavor() const; LHAPDF::PDFSet* GetPDFSet() const { return PDFSet;}; LHAPDF::PDF* GetPDF() const { return PDF;}; - + double GetAlphasMz() const; //! Return struct with vectors containing the cross section values and the selected a_s(M_Z) uncertainty @@ -73,7 +73,6 @@ public: // Deprecated: Replaced by struct as return object: Return vector of pairs with all cross section values first and pairs of PDF uncertainties second // vector < pair < double, pair <double, double> > > GetPDFUncertainty(const EPDFUncertaintyStyle ePDFUnc); -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 std::vector<LHAPDF::PDFUncertainty> GetPDFUncertaintyLHAPDF(double cl=100*erf(1/sqrt(2)), bool alternative=false); //!< return PDF uncertainty, formulae taken from LHAPDF6 std::vector<double> CalcPDFUncertaintyMinus(const std::vector<LHAPDF::PDFUncertainty>& ) const; //!<get vector<double> for PDF-minus uncertainty. Uncertainties are POSITIVE! std::vector<double> CalcPDFUncertaintyPlus(const std::vector<LHAPDF::PDFUncertainty>& ) const; //!<get vector<double> for PDF-up uncertainty @@ -81,7 +80,6 @@ public: std::vector<double> CalcPDFUncertaintyRelPlus(const std::vector<LHAPDF::PDFUncertainty>& ) const; //!<get vector<double> for relative PDF-up uncertainty std::vector<double> CalcPDFUncertaintySymm(const std::vector<LHAPDF::PDFUncertainty>& ) const; //!< get vector<double> for symmetrized PDF uncertainty std::vector<double> CalcPDFUncertaintyCentral(const std::vector<LHAPDF::PDFUncertainty>& ) const; //!< get vector<double> for 'new' central value -#endif // inherited functions virtual double EvolveAlphas(double Q) const ; @@ -92,10 +90,8 @@ protected: // ---- LHAPDF vars ---- // std::string fLHAPDFFilename; - #if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 LHAPDF::PDFSet* PDFSet; LHAPDF::PDF* PDF; - #endif int fnPDFs; int fiPDFMember; diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTable.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTable.h index 4582f045a3480e8e14fe9692801a5738187d9e8c..42c9049a4f370e26e2afc5c56004b753f4f080fc 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTable.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTable.h @@ -32,6 +32,7 @@ class fastNLOTable { bool IsCompatibleScenario(const fastNLOTable& other) const; bool IsCatenable(const fastNLOTable& other) const; bool IsCatenableScenario(const fastNLOTable& other) const; + bool IsEquivalent(const fastNLOTable& other, double rtol) const; // --- function previously included in fastNLOBase // header diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants.h index 89e225a95412028797ac42828d72b270048eb908..55e2b876482f60dbc1a62efb4509216d3ec7f04b 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTableConstants.h @@ -133,16 +133,18 @@ namespace fastNLO { */ std::string X_Kernel{"Lagrange"}; //!< "Lagrange" std::string X_DistanceMeasure{"sqrtlog10"}; //!< "sqrtlog10" - int X_NNodes{15}; //!< 15 + double X_NNodes{15}; //!< 15 std::string X_NNodeCounting{"NodesPerBin"}; //!< "NodesPerBin" ("NodesMax", "NodesPerMagnitude") std::string Mu1_Kernel{"Lagrange"}; //!< "Lagrange" std::string Mu1_DistanceMeasure{"loglog025"}; //!< "loglog025" - int Mu1_NNodes{6}; //!< 6 + double Mu1_NNodes{6}; //!< 6 + std::string Mu1_NNodeCounting{"NodesPerBin"}; std::string Mu2_Kernel{"Lagrange"}; //!< "Lagrange"; Scale2 not used for fixed-scale tables std::string Mu2_DistanceMeasure{"loglog025"}; //!< "loglog025" - int Mu2_NNodes{6}; //!< 6 + double Mu2_NNodes{6}; //!< 6 + std::string Mu2_NNodeCounting{"NodesPerBin"}; // KR: Defaults can be set using SetScenConstsDefaults(). // If the struct is directly created within another project, diff --git a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h index d5c625f25d772d3f3ff3043a899f72e8799fa0ff..caa8341ac15aced0fba212579b71d36e4a5ed443 100644 --- a/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h +++ b/v2.5/toolkit/fastnlotoolkit/include/fastnlotk/fastNLOTools.h @@ -90,6 +90,14 @@ namespace fastNLOTools { //! Function prototype for string to enum conversion of central scale choice fastNLO::EScaleFunctionalForm GetScaleEnum(const std::string); + std::pair<fastNLO::v1d, fastNLO::v1d> GetTails(fastNLO::v1d& vector1, fastNLO::v1d& vector2); + bool SameTails(fastNLO::v1d vector1, fastNLO::v1d vector2, double rtol=0.0); + bool SameTails(fastNLO::v2d vector1, fastNLO::v2d vector2, double rtol=0.0); + bool ExtendHead(fastNLO::v1d& vector1, const fastNLO::v1d& vector2); + template <typename T> void ExtendSigmaTildeX( + std::vector<T>& SigmaTildeX, unsigned int OldDimSize1, unsigned int NewDimSize1, + unsigned int OldDimSize2, unsigned int NewDimSize2, int NPDFDim, T InsertValue); + }; diff --git a/v2.5/toolkit/m4/ax_check_zlib.m4 b/v2.5/toolkit/m4/ax_check_zlib.m4 index be91a86eb907deb9abf69c232b7697c129b53036..1a168430485fe1e8cf9e7c500ee95307df54fac1 100644 --- a/v2.5/toolkit/m4/ax_check_zlib.m4 +++ b/v2.5/toolkit/m4/ax_check_zlib.m4 @@ -62,7 +62,7 @@ # modified version of the Autoconf Macro, you may extend this special # exception to the GPL to apply to your modified version as well. -#serial 15 +#serial 16 AU_ALIAS([CHECK_ZLIB], [AX_CHECK_ZLIB]) AC_DEFUN([AX_CHECK_ZLIB], @@ -108,11 +108,10 @@ then LDFLAGS="$LDFLAGS -L${ZLIB_HOME}/lib" CPPFLAGS="$CPPFLAGS -I${ZLIB_HOME}/include" fi - AC_LANG_SAVE - AC_LANG_C + AC_LANG_PUSH([C]) AC_CHECK_LIB([z], [inflateEnd], [zlib_cv_libz=yes], [zlib_cv_libz=no]) AC_CHECK_HEADER([zlib.h], [zlib_cv_zlib_h=yes], [zlib_cv_zlib_h=no]) - AC_LANG_RESTORE + AC_LANG_POP([C]) if test "$zlib_cv_libz" = "yes" && test "$zlib_cv_zlib_h" = "yes" then # diff --git a/v2.5/toolkit/m4/ax_cxx_compile_stdcxx.m4 b/v2.5/toolkit/m4/ax_cxx_compile_stdcxx.m4 index 5032bba8091d5d1074f4509b4c47b38a66389c6b..9413da624d2545123501b7788b7ac6d96fd322e8 100644 --- a/v2.5/toolkit/m4/ax_cxx_compile_stdcxx.m4 +++ b/v2.5/toolkit/m4/ax_cxx_compile_stdcxx.m4 @@ -16,7 +16,7 @@ # The second argument, if specified, indicates whether you insist on an # extended mode (e.g. -std=gnu++11) or a strict conformance mode (e.g. # -std=c++11). If neither is specified, you get whatever works, with -# preference for an extended mode. +# preference for no added switch, and then for an extended mode. # # The third argument, if specified 'mandatory' or if left unspecified, # indicates that baseline support for the specified C++ standard is @@ -33,19 +33,20 @@ # Copyright (c) 2014, 2015 Google Inc.; contributed by Alexey Sokolov <sokolov@google.com> # Copyright (c) 2015 Paul Norman <penorman@mac.com> # Copyright (c) 2015 Moritz Klammler <moritz@klammler.eu> -# Copyright (c) 2016 Krzesimir Nowak <qdlacz@gmail.com> +# Copyright (c) 2016, 2018 Krzesimir Nowak <qdlacz@gmail.com> +# Copyright (c) 2019 Enji Cooper <yaneurabeya@gmail.com> +# Copyright (c) 2020 Jason Merrill <jason@redhat.com> # # Copying and distribution of this file, with or without modification, are # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. -#serial 7 +#serial 12 dnl This macro is based on the code from the AX_CXX_COMPILE_STDCXX_11 macro dnl (serial version number 13). -AX_REQUIRE_DEFINED([AC_MSG_WARN]) AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl m4_if([$1], [11], [ax_cxx_compile_alternatives="11 0x"], [$1], [14], [ax_cxx_compile_alternatives="14 1y"], @@ -61,14 +62,16 @@ AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl [m4_fatal([invalid third argument `$3' to AX_CXX_COMPILE_STDCXX])]) AC_LANG_PUSH([C++])dnl ac_success=no - AC_CACHE_CHECK(whether $CXX supports C++$1 features by default, - ax_cv_cxx_compile_cxx$1, - [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])], - [ax_cv_cxx_compile_cxx$1=yes], - [ax_cv_cxx_compile_cxx$1=no])]) - if test x$ax_cv_cxx_compile_cxx$1 = xyes; then - ac_success=yes - fi + + m4_if([$2], [], [dnl + AC_CACHE_CHECK(whether $CXX supports C++$1 features by default, + ax_cv_cxx_compile_cxx$1, + [AC_COMPILE_IFELSE([AC_LANG_SOURCE([_AX_CXX_COMPILE_STDCXX_testbody_$1])], + [ax_cv_cxx_compile_cxx$1=yes], + [ax_cv_cxx_compile_cxx$1=no])]) + if test x$ax_cv_cxx_compile_cxx$1 = xyes; then + ac_success=yes + fi]) m4_if([$2], [noext], [], [dnl if test x$ac_success = xno; then @@ -139,7 +142,6 @@ AC_DEFUN([AX_CXX_COMPILE_STDCXX], [dnl [define if the compiler supports basic C++$1 syntax]) fi AC_SUBST(HAVE_CXX$1) - m4_if([$1], [17], [AC_MSG_WARN([C++17 is not yet standardized, so the checks may change in incompatible ways anytime])]) ]) @@ -199,11 +201,13 @@ namespace cxx11 struct Base { + virtual ~Base() {} virtual void f() {} }; struct Derived : public Base { + virtual ~Derived() override {} virtual void f() override {} }; @@ -587,20 +591,12 @@ m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_17], [[ #error "This is not a C++ compiler" -#elif __cplusplus <= 201402L +#elif __cplusplus < 201703L #error "This is not a C++17 compiler" #else -#if defined(__clang__) - #define REALLY_CLANG -#else - #if defined(__GNUC__) - #define REALLY_GCC - #endif -#endif - #include <initializer_list> #include <utility> #include <type_traits> @@ -608,16 +604,12 @@ m4_define([_AX_CXX_COMPILE_STDCXX_testbody_new_in_17], [[ namespace cxx17 { -#if !defined(REALLY_CLANG) namespace test_constexpr_lambdas { - // TODO: test it with clang++ from git - constexpr int foo = [](){return 42;}(); } -#endif // !defined(REALLY_CLANG) namespace test::nested_namespace::definitions { @@ -852,12 +844,9 @@ namespace cxx17 } -#if !defined(REALLY_CLANG) namespace test_template_argument_deduction_for_class_templates { - // TODO: test it with clang++ from git - template <typename T1, typename T2> struct pair { @@ -876,7 +865,6 @@ namespace cxx17 } } -#endif // !defined(REALLY_CLANG) namespace test_non_type_auto_template_parameters { @@ -890,12 +878,9 @@ namespace cxx17 } -#if !defined(REALLY_CLANG) namespace test_structured_bindings { - // TODO: test it with clang++ from git - int arr[2] = { 1, 2 }; std::pair<int, int> pr = { 1, 2 }; @@ -927,14 +912,10 @@ namespace cxx17 const auto [ x3, y3 ] = f3(); } -#endif // !defined(REALLY_CLANG) -#if !defined(REALLY_CLANG) namespace test_exception_spec_type_system { - // TODO: test it with clang++ from git - struct Good {}; struct Bad {}; @@ -952,7 +933,6 @@ namespace cxx17 static_assert (std::is_same_v<Good, decltype(f(g1, g2))>); } -#endif // !defined(REALLY_CLANG) namespace test_inline_variables { @@ -977,6 +957,6 @@ namespace cxx17 } // namespace cxx17 -#endif // __cplusplus <= 201402L +#endif // __cplusplus < 201703L ]]) diff --git a/v2.5/toolkit/m4/ax_prog_doxygen.m4 b/v2.5/toolkit/m4/ax_prog_doxygen.m4 index a371f7fdfe81f9424ec270acf838107b8d4d9e40..9a34322cee78c1dbe33186ac2c242413eb2f6677 100644 --- a/v2.5/toolkit/m4/ax_prog_doxygen.m4 +++ b/v2.5/toolkit/m4/ax_prog_doxygen.m4 @@ -97,23 +97,23 @@ # and this notice are preserved. This file is offered as-is, without any # warranty. -#serial 23 +#serial 24 ## ----------## ## Defaults. ## ## ----------## DX_ENV="" -AC_DEFUN([DX_FEATURE_doc], ON) +AC_DEFUN([DX_FEATURE_doc], OFF) AC_DEFUN([DX_FEATURE_dot], OFF) AC_DEFUN([DX_FEATURE_man], OFF) -AC_DEFUN([DX_FEATURE_html], ON) +AC_DEFUN([DX_FEATURE_html], OFF) AC_DEFUN([DX_FEATURE_chm], OFF) AC_DEFUN([DX_FEATURE_chi], OFF) AC_DEFUN([DX_FEATURE_rtf], OFF) AC_DEFUN([DX_FEATURE_xml], OFF) -AC_DEFUN([DX_FEATURE_pdf], ON) -AC_DEFUN([DX_FEATURE_ps], ON) +AC_DEFUN([DX_FEATURE_pdf], OFF) +AC_DEFUN([DX_FEATURE_ps], OFF) ## --------------- ## ## Private macros. ## @@ -164,7 +164,7 @@ AC_DEFUN([DX_TEST_FEATURE], [test "$DX_FLAG_$1" = 1]) AC_DEFUN([DX_CHECK_DEPEND], [ test "$DX_FLAG_$1" = "$2" \ || AC_MSG_ERROR([doxygen-DX_CURRENT_FEATURE ifelse([$2], 1, - requires, contradicts) doxygen-DX_CURRENT_FEATURE]) + requires, contradicts) doxygen-$1]) ]) # DX_CLEAR_DEPEND(FEATURE, REQUIRED_FEATURE, REQUIRED_STATE) diff --git a/v2.5/toolkit/m4/libtool.m4 b/v2.5/toolkit/m4/libtool.m4 index 56666f0eceac29ace0fff6cfefa246a4ab93174c..c4c02946dece797da877e40488def858d724f103 100644 --- a/v2.5/toolkit/m4/libtool.m4 +++ b/v2.5/toolkit/m4/libtool.m4 @@ -1,8 +1,6 @@ # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*- # -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. +# Copyright (C) 1996-2001, 2003-2015 Free Software Foundation, Inc. # Written by Gordon Matzigkeit, 1996 # # This file is free software; the Free Software Foundation gives @@ -10,36 +8,30 @@ # modifications, as long as this notice is preserved. m4_define([_LT_COPYING], [dnl -# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, -# 2006, 2007, 2008, 2009, 2010, 2011 Free Software -# Foundation, Inc. -# Written by Gordon Matzigkeit, 1996 -# -# This file is part of GNU Libtool. -# -# GNU Libtool is free software; you can redistribute it and/or -# modify it under the terms of the GNU General Public License as -# published by the Free Software Foundation; either version 2 of -# the License, or (at your option) any later version. +# Copyright (C) 2014 Free Software Foundation, Inc. +# This is free software; see the source for copying conditions. There is NO +# warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + +# GNU Libtool is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of of the License, or +# (at your option) any later version. # -# As a special exception to the GNU General Public License, -# if you distribute this file as part of a program or library that -# is built using GNU Libtool, you may include this file under the -# same distribution terms that you use for the rest of that program. +# As a special exception to the GNU General Public License, if you +# distribute this file as part of a program or library that is built +# using GNU Libtool, you may include this file under the same +# distribution terms that you use for the rest of that program. # -# GNU Libtool is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of +# GNU Libtool is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with GNU Libtool; see the file COPYING. If not, a copy -# can be downloaded from http://www.gnu.org/licenses/gpl.html, or -# obtained by writing to the Free Software Foundation, Inc., -# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. +# along with this program. If not, see <http://www.gnu.org/licenses/>. ]) -# serial 57 LT_INIT +# serial 58 LT_INIT # LT_PREREQ(VERSION) @@ -67,7 +59,7 @@ esac # LT_INIT([OPTIONS]) # ------------------ AC_DEFUN([LT_INIT], -[AC_PREREQ([2.58])dnl We use AC_INCLUDES_DEFAULT +[AC_PREREQ([2.62])dnl We use AC_PATH_PROGS_FEATURE_CHECK AC_REQUIRE([AC_CONFIG_AUX_DIR_DEFAULT])dnl AC_BEFORE([$0], [LT_LANG])dnl AC_BEFORE([$0], [LT_OUTPUT])dnl @@ -91,7 +83,7 @@ dnl Parse OPTIONS _LT_SET_OPTIONS([$0], [$1]) # This can be used to rebuild libtool when needed -LIBTOOL_DEPS="$ltmain" +LIBTOOL_DEPS=$ltmain # Always use our own libtool. LIBTOOL='$(SHELL) $(top_builddir)/libtool' @@ -111,26 +103,43 @@ dnl AC_DEFUN([AC_PROG_LIBTOOL], []) dnl AC_DEFUN([AM_PROG_LIBTOOL], []) +# _LT_PREPARE_CC_BASENAME +# ----------------------- +m4_defun([_LT_PREPARE_CC_BASENAME], [ +# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +func_cc_basename () +{ + for cc_temp in @S|@*""; do + case $cc_temp in + compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; + distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; + \-*) ;; + *) break;; + esac + done + func_cc_basename_result=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +} +])# _LT_PREPARE_CC_BASENAME + + # _LT_CC_BASENAME(CC) # ------------------- -# Calculate cc_basename. Skip known compiler wrappers and cross-prefix. +# It would be clearer to call AC_REQUIREs from _LT_PREPARE_CC_BASENAME, +# but that macro is also expanded into generated libtool script, which +# arranges for $SED and $ECHO to be set by different means. m4_defun([_LT_CC_BASENAME], -[for cc_temp in $1""; do - case $cc_temp in - compile | *[[\\/]]compile | ccache | *[[\\/]]ccache ) ;; - distcc | *[[\\/]]distcc | purify | *[[\\/]]purify ) ;; - \-*) ;; - *) break;; - esac -done -cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` +[m4_require([_LT_PREPARE_CC_BASENAME])dnl +AC_REQUIRE([_LT_DECL_SED])dnl +AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH])dnl +func_cc_basename $1 +cc_basename=$func_cc_basename_result ]) # _LT_FILEUTILS_DEFAULTS # ---------------------- # It is okay to use these file commands and assume they have been set -# sensibly after `m4_require([_LT_FILEUTILS_DEFAULTS])'. +# sensibly after 'm4_require([_LT_FILEUTILS_DEFAULTS])'. m4_defun([_LT_FILEUTILS_DEFAULTS], [: ${CP="cp -f"} : ${MV="mv -f"} @@ -177,15 +186,16 @@ m4_require([_LT_CHECK_SHAREDLIB_FROM_LINKLIB])dnl m4_require([_LT_CMD_OLD_ARCHIVE])dnl m4_require([_LT_CMD_GLOBAL_SYMBOLS])dnl m4_require([_LT_WITH_SYSROOT])dnl +m4_require([_LT_CMD_TRUNCATE])dnl _LT_CONFIG_LIBTOOL_INIT([ -# See if we are running on zsh, and set the options which allow our +# See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes INIT. -if test -n "\${ZSH_VERSION+set}" ; then +if test -n "\${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi ]) -if test -n "${ZSH_VERSION+set}" ; then +if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi @@ -198,7 +208,7 @@ aix3*) # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. - if test "X${COLLECT_NAMES+set}" != Xset; then + if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi @@ -209,14 +219,14 @@ esac ofile=libtool can_build_shared=yes -# All known linkers require a `.a' archive for static linking (except MSVC, +# All known linkers require a '.a' archive for static linking (except MSVC, # which needs '.lib'). libext=a -with_gnu_ld="$lt_cv_prog_gnu_ld" +with_gnu_ld=$lt_cv_prog_gnu_ld -old_CC="$CC" -old_CFLAGS="$CFLAGS" +old_CC=$CC +old_CFLAGS=$CFLAGS # Set sane defaults for various variables test -z "$CC" && CC=cc @@ -269,14 +279,14 @@ no_glob_subst='s/\*/\\\*/g' # _LT_PROG_LTMAIN # --------------- -# Note that this code is called both from `configure', and `config.status' +# Note that this code is called both from 'configure', and 'config.status' # now that we use AC_CONFIG_COMMANDS to generate libtool. Notably, -# `config.status' has no value for ac_aux_dir unless we are using Automake, +# 'config.status' has no value for ac_aux_dir unless we are using Automake, # so we pass a copy along to make sure it has a sensible value anyway. m4_defun([_LT_PROG_LTMAIN], [m4_ifdef([AC_REQUIRE_AUX_FILE], [AC_REQUIRE_AUX_FILE([ltmain.sh])])dnl _LT_CONFIG_LIBTOOL_INIT([ac_aux_dir='$ac_aux_dir']) -ltmain="$ac_aux_dir/ltmain.sh" +ltmain=$ac_aux_dir/ltmain.sh ])# _LT_PROG_LTMAIN @@ -286,7 +296,7 @@ ltmain="$ac_aux_dir/ltmain.sh" # So that we can recreate a full libtool script including additional # tags, we accumulate the chunks of code to send to AC_CONFIG_COMMANDS -# in macros and then make a single call at the end using the `libtool' +# in macros and then make a single call at the end using the 'libtool' # label. @@ -421,8 +431,8 @@ m4_define([_lt_decl_all_varnames], # _LT_CONFIG_STATUS_DECLARE([VARNAME]) # ------------------------------------ -# Quote a variable value, and forward it to `config.status' so that its -# declaration there will have the same value as in `configure'. VARNAME +# Quote a variable value, and forward it to 'config.status' so that its +# declaration there will have the same value as in 'configure'. VARNAME # must have a single quote delimited value for this to work. m4_define([_LT_CONFIG_STATUS_DECLARE], [$1='`$ECHO "$][$1" | $SED "$delay_single_quote_subst"`']) @@ -446,7 +456,7 @@ m4_defun([_LT_CONFIG_STATUS_DECLARATIONS], # Output comment and list of tags supported by the script m4_defun([_LT_LIBTOOL_TAGS], [_LT_FORMAT_COMMENT([The names of the tagged configurations supported by this script])dnl -available_tags="_LT_TAGS"dnl +available_tags='_LT_TAGS'dnl ]) @@ -474,7 +484,7 @@ m4_ifval([$2], [_$2])[]m4_popdef([_libtool_name])[]dnl # _LT_LIBTOOL_CONFIG_VARS # ----------------------- # Produce commented declarations of non-tagged libtool config variables -# suitable for insertion in the LIBTOOL CONFIG section of the `libtool' +# suitable for insertion in the LIBTOOL CONFIG section of the 'libtool' # script. Tagged libtool config variables (even for the LIBTOOL CONFIG # section) are produced by _LT_LIBTOOL_TAG_VARS. m4_defun([_LT_LIBTOOL_CONFIG_VARS], @@ -500,8 +510,8 @@ m4_define([_LT_TAGVAR], [m4_ifval([$2], [$1_$2], [$1])]) # Send accumulated output to $CONFIG_STATUS. Thanks to the lists of # variables for single and double quote escaping we saved from calls # to _LT_DECL, we can put quote escaped variables declarations -# into `config.status', and then the shell code to quote escape them in -# for loops in `config.status'. Finally, any additional code accumulated +# into 'config.status', and then the shell code to quote escape them in +# for loops in 'config.status'. Finally, any additional code accumulated # from calls to _LT_CONFIG_LIBTOOL_INIT is expanded. m4_defun([_LT_CONFIG_COMMANDS], [AC_PROVIDE_IFELSE([LT_OUTPUT], @@ -547,7 +557,7 @@ for var in lt_decl_all_varnames([[ \ ]], lt_decl_quote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -560,7 +570,7 @@ for var in lt_decl_all_varnames([[ \ ]], lt_decl_dquote_varnames); do case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in *[[\\\\\\\`\\"\\\$]]*) - eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" + eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\"" ## exclude from sc_prohibit_nested_quotes ;; *) eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\"" @@ -576,7 +586,7 @@ _LT_OUTPUT_LIBTOOL_INIT # Generate a child script FILE with all initialization necessary to # reuse the environment learned by the parent script, and make the # file executable. If COMMENT is supplied, it is inserted after the -# `#!' sequence but before initialization text begins. After this +# '#!' sequence but before initialization text begins. After this # macro, additional text can be appended to FILE to form the body of # the child script. The macro ends with non-zero status if the # file could not be fully written (such as if the disk is full). @@ -598,7 +608,7 @@ AS_SHELL_SANITIZE _AS_PREPARE exec AS_MESSAGE_FD>&1 _ASEOF -test $lt_write_fail = 0 && chmod +x $1[]dnl +test 0 = "$lt_write_fail" && chmod +x $1[]dnl m4_popdef([AS_MESSAGE_LOG_FD])])])# _LT_GENERATED_FILE_INIT # LT_OUTPUT @@ -621,7 +631,7 @@ exec AS_MESSAGE_LOG_FD>>config.log } >&AS_MESSAGE_LOG_FD lt_cl_help="\ -\`$as_me' creates a local libtool stub from the current configuration, +'$as_me' creates a local libtool stub from the current configuration, for use in further configure time tests before the real libtool is generated. @@ -643,7 +653,7 @@ Copyright (C) 2011 Free Software Foundation, Inc. This config.lt script is free software; the Free Software Foundation gives unlimited permision to copy, distribute and modify it." -while test $[#] != 0 +while test 0 != $[#] do case $[1] in --version | --v* | -V ) @@ -656,10 +666,10 @@ do lt_cl_silent=: ;; -*) AC_MSG_ERROR([unrecognized option: $[1] -Try \`$[0] --help' for more information.]) ;; +Try '$[0] --help' for more information.]) ;; *) AC_MSG_ERROR([unrecognized argument: $[1] -Try \`$[0] --help' for more information.]) ;; +Try '$[0] --help' for more information.]) ;; esac shift done @@ -685,7 +695,7 @@ chmod +x "$CONFIG_LT" # open by configure. Here we exec the FD to /dev/null, effectively closing # config.log, so it can be properly (re)opened and appended to by config.lt. lt_cl_success=: -test "$silent" = yes && +test yes = "$silent" && lt_config_lt_args="$lt_config_lt_args --quiet" exec AS_MESSAGE_LOG_FD>/dev/null $SHELL "$CONFIG_LT" $lt_config_lt_args || lt_cl_success=false @@ -705,32 +715,46 @@ m4_defun([_LT_CONFIG], _LT_CONFIG_SAVE_COMMANDS([ m4_define([_LT_TAG], m4_if([$1], [], [C], [$1]))dnl m4_if(_LT_TAG, [C], [ - # See if we are running on zsh, and set the options which allow our + # See if we are running on zsh, and set the options that allow our # commands through without removal of \ escapes. - if test -n "${ZSH_VERSION+set}" ; then + if test -n "${ZSH_VERSION+set}"; then setopt NO_GLOB_SUBST fi - cfgfile="${ofile}T" + cfgfile=${ofile}T trap "$RM \"$cfgfile\"; exit 1" 1 2 15 $RM "$cfgfile" cat <<_LT_EOF >> "$cfgfile" #! $SHELL - -# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services. -# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION -# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`: +# Generated automatically by $as_me ($PACKAGE) $VERSION # NOTE: Changes made to this file will be lost: look at ltmain.sh. -# + +# Provide generalized library-building support services. +# Written by Gordon Matzigkeit, 1996 + _LT_COPYING _LT_LIBTOOL_TAGS +# Configured defaults for sys_lib_dlsearch_path munging. +: \${LT_SYS_LIBRARY_PATH="$configure_time_lt_sys_library_path"} + # ### BEGIN LIBTOOL CONFIG _LT_LIBTOOL_CONFIG_VARS _LT_LIBTOOL_TAG_VARS # ### END LIBTOOL CONFIG +_LT_EOF + + cat <<'_LT_EOF' >> "$cfgfile" + +# ### BEGIN FUNCTIONS SHARED WITH CONFIGURE + +_LT_PREPARE_MUNGE_PATH_LIST +_LT_PREPARE_CC_BASENAME + +# ### END FUNCTIONS SHARED WITH CONFIGURE + _LT_EOF case $host_os in @@ -739,7 +763,7 @@ _LT_EOF # AIX sometimes has problems with the GCC collect2 program. For some # reason, if we set the COLLECT_NAMES environment variable, the problems # vanish in a puff of smoke. -if test "X${COLLECT_NAMES+set}" != Xset; then +if test set != "${COLLECT_NAMES+set}"; then COLLECT_NAMES= export COLLECT_NAMES fi @@ -756,8 +780,6 @@ _LT_EOF sed '$q' "$ltmain" >> "$cfgfile" \ || (rm -f "$cfgfile"; exit 1) - _LT_PROG_REPLACE_SHELLFNS - mv -f "$cfgfile" "$ofile" || (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile") chmod +x "$ofile" @@ -775,7 +797,6 @@ _LT_EOF [m4_if([$1], [], [ PACKAGE='$PACKAGE' VERSION='$VERSION' - TIMESTAMP='$TIMESTAMP' RM='$RM' ofile='$ofile'], []) ])dnl /_LT_CONFIG_SAVE_COMMANDS @@ -974,7 +995,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod], [lt_cv_apple_cc_single_mod=no - if test -z "${LT_MULTI_MODULE}"; then + if test -z "$LT_MULTI_MODULE"; then # By default we will add the -single_module flag. You can override # by either setting the environment variable LT_MULTI_MODULE # non-empty at configure time, or by adding -multi_module to the @@ -992,7 +1013,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ cat conftest.err >&AS_MESSAGE_LOG_FD # Otherwise, if the output was created with a 0 exit code from # the compiler, it worked. - elif test -f libconftest.dylib && test $_lt_result -eq 0; then + elif test -f libconftest.dylib && test 0 = "$_lt_result"; then lt_cv_apple_cc_single_mod=yes else cat conftest.err >&AS_MESSAGE_LOG_FD @@ -1010,7 +1031,7 @@ m4_defun_once([_LT_REQUIRED_DARWIN_CHECKS],[ AC_LINK_IFELSE([AC_LANG_PROGRAM([],[])], [lt_cv_ld_exported_symbols_list=yes], [lt_cv_ld_exported_symbols_list=no]) - LDFLAGS="$save_LDFLAGS" + LDFLAGS=$save_LDFLAGS ]) AC_CACHE_CHECK([for -force_load linker flag],[lt_cv_ld_force_load], @@ -1020,8 +1041,8 @@ int forced_loaded() { return 2;} _LT_EOF echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&AS_MESSAGE_LOG_FD $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&AS_MESSAGE_LOG_FD - echo "$AR cru libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD - $AR cru libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD + echo "$AR cr libconftest.a conftest.o" >&AS_MESSAGE_LOG_FD + $AR cr libconftest.a conftest.o 2>&AS_MESSAGE_LOG_FD echo "$RANLIB libconftest.a" >&AS_MESSAGE_LOG_FD $RANLIB libconftest.a 2>&AS_MESSAGE_LOG_FD cat > conftest.c << _LT_EOF @@ -1032,7 +1053,7 @@ _LT_EOF _lt_result=$? if test -s conftest.err && $GREP force_load conftest.err; then cat conftest.err >&AS_MESSAGE_LOG_FD - elif test -f conftest && test $_lt_result -eq 0 && $GREP forced_load conftest >/dev/null 2>&1 ; then + elif test -f conftest && test 0 = "$_lt_result" && $GREP forced_load conftest >/dev/null 2>&1; then lt_cv_ld_force_load=yes else cat conftest.err >&AS_MESSAGE_LOG_FD @@ -1042,32 +1063,32 @@ _LT_EOF ]) case $host_os in rhapsody* | darwin1.[[012]]) - _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; + _lt_dar_allow_undefined='$wl-undefined ${wl}suppress' ;; darwin1.*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; darwin*) # darwin 5.x on # if running on 10.5 or later, the deployment target defaults # to the OS version, if on x86, and 10.4, the deployment # target defaults to 10.4. Don't you love it? case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in - 10.0,*86*-darwin8*|10.0,*-darwin[[91]]*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; - 10.[[012]]*) - _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; - 10.*) - _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; + 10.0,*86*-darwin8*|10.0,*-darwin[[912]]*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; + 10.[[012]][[,.]]*) + _lt_dar_allow_undefined='$wl-flat_namespace $wl-undefined ${wl}suppress' ;; + 10.*|11.*) + _lt_dar_allow_undefined='$wl-undefined ${wl}dynamic_lookup' ;; esac ;; esac - if test "$lt_cv_apple_cc_single_mod" = "yes"; then + if test yes = "$lt_cv_apple_cc_single_mod"; then _lt_dar_single_mod='$single_module' fi - if test "$lt_cv_ld_exported_symbols_list" = "yes"; then - _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' + if test yes = "$lt_cv_ld_exported_symbols_list"; then + _lt_dar_export_syms=' $wl-exported_symbols_list,$output_objdir/$libname-symbols.expsym' else - _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' + _lt_dar_export_syms='~$NMEDIT -s $output_objdir/$libname-symbols.expsym $lib' fi - if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then + if test : != "$DSYMUTIL" && test no = "$lt_cv_ld_force_load"; then _lt_dsymutil='~$DSYMUTIL $lib || :' else _lt_dsymutil= @@ -1087,29 +1108,29 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_automatic, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=unsupported - if test "$lt_cv_ld_force_load" = "yes"; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' + if test yes = "$lt_cv_ld_force_load"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience $wl-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' m4_case([$1], [F77], [_LT_TAGVAR(compiler_needs_object, $1)=yes], [FC], [_LT_TAGVAR(compiler_needs_object, $1)=yes]) else _LT_TAGVAR(whole_archive_flag_spec, $1)='' fi _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined" + _LT_TAGVAR(allow_undefined_flag, $1)=$_lt_dar_allow_undefined case $cc_basename in - ifort*) _lt_dar_can_shared=yes ;; + ifort*|nagfor*) _lt_dar_can_shared=yes ;; *) _lt_dar_can_shared=$GCC ;; esac - if test "$_lt_dar_can_shared" = "yes"; then + if test yes = "$_lt_dar_can_shared"; then output_verbose_link_cmd=func_echo_all - _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" - _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" - _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" + _LT_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dsymutil" + _LT_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod$_lt_dar_export_syms$_lt_dsymutil" + _LT_TAGVAR(module_expsym_cmds, $1)="sed -e 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags$_lt_dar_export_syms$_lt_dsymutil" m4_if([$1], [CXX], -[ if test "$lt_cv_apple_cc_single_mod" != "yes"; then - _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" - _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" +[ if test yes != "$lt_cv_apple_cc_single_mod"; then + _LT_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dsymutil" + _LT_TAGVAR(archive_expsym_cmds, $1)="sed 's|^|_|' < \$export_symbols > \$output_objdir/\$libname-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \$lib-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$lib-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring$_lt_dar_export_syms$_lt_dsymutil" fi ],[]) else @@ -1129,7 +1150,7 @@ m4_defun([_LT_DARWIN_LINKER_FEATURES], # Allow to override them for all tags through lt_cv_aix_libpath. m4_defun([_LT_SYS_MODULE_PATH_AIX], [m4_require([_LT_DECL_SED])dnl -if test "${lt_cv_aix_libpath+set}" = set; then +if test set = "${lt_cv_aix_libpath+set}"; then aix_libpath=$lt_cv_aix_libpath else AC_CACHE_VAL([_LT_TAGVAR([lt_cv_aix_libpath_], [$1])], @@ -1147,7 +1168,7 @@ else _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` fi],[]) if test -z "$_LT_TAGVAR([lt_cv_aix_libpath_], [$1])"; then - _LT_TAGVAR([lt_cv_aix_libpath_], [$1])="/usr/lib:/lib" + _LT_TAGVAR([lt_cv_aix_libpath_], [$1])=/usr/lib:/lib fi ]) aix_libpath=$_LT_TAGVAR([lt_cv_aix_libpath_], [$1]) @@ -1167,8 +1188,8 @@ m4_define([_LT_SHELL_INIT], # ----------------------- # Find how we can fake an echo command that does not interpret backslash. # In particular, with Autoconf 2.60 or later we add some code to the start -# of the generated configure script which will find a shell with a builtin -# printf (which we can use as an echo command). +# of the generated configure script that will find a shell with a builtin +# printf (that we can use as an echo command). m4_defun([_LT_PROG_ECHO_BACKSLASH], [ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO @@ -1196,10 +1217,10 @@ fi # Invoke $ECHO with all args, space-separated. func_echo_all () { - $ECHO "$*" + $ECHO "$*" } -case "$ECHO" in +case $ECHO in printf*) AC_MSG_RESULT([printf]) ;; print*) AC_MSG_RESULT([print -r]) ;; *) AC_MSG_RESULT([cat]) ;; @@ -1225,16 +1246,17 @@ _LT_DECL([], [ECHO], [1], [An echo program that protects backslashes]) AC_DEFUN([_LT_WITH_SYSROOT], [AC_MSG_CHECKING([for sysroot]) AC_ARG_WITH([sysroot], -[ --with-sysroot[=DIR] Search for dependent libraries within DIR - (or the compiler's sysroot if not specified).], +[AS_HELP_STRING([--with-sysroot@<:@=DIR@:>@], + [Search for dependent libraries within DIR (or the compiler's sysroot + if not specified).])], [], [with_sysroot=no]) dnl lt_sysroot will always be passed unquoted. We quote it here dnl in case the user passed a directory name. lt_sysroot= -case ${with_sysroot} in #( +case $with_sysroot in #( yes) - if test "$GCC" = yes; then + if test yes = "$GCC"; then lt_sysroot=`$CC --print-sysroot 2>/dev/null` fi ;; #( @@ -1244,14 +1266,14 @@ case ${with_sysroot} in #( no|'') ;; #( *) - AC_MSG_RESULT([${with_sysroot}]) + AC_MSG_RESULT([$with_sysroot]) AC_MSG_ERROR([The sysroot must be an absolute path.]) ;; esac AC_MSG_RESULT([${lt_sysroot:-no}]) _LT_DECL([], [lt_sysroot], [0], [The root where to search for ]dnl -[dependent libraries, and in which our libraries should be installed.])]) +[dependent libraries, and where our libraries should be installed.])]) # _LT_ENABLE_LOCK # --------------- @@ -1259,31 +1281,33 @@ m4_defun([_LT_ENABLE_LOCK], [AC_ARG_ENABLE([libtool-lock], [AS_HELP_STRING([--disable-libtool-lock], [avoid locking (might break parallel builds)])]) -test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes +test no = "$enable_libtool_lock" || enable_libtool_lock=yes # Some flags need to be propagated to the compiler or linker for good # libtool support. case $host in ia64-*-hpux*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set mode + # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.$ac_objext` in *ELF-32*) - HPUX_IA64_MODE="32" + HPUX_IA64_MODE=32 ;; *ELF-64*) - HPUX_IA64_MODE="64" + HPUX_IA64_MODE=64 ;; esac fi rm -rf conftest* ;; *-*-irix6*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then - if test "$lt_cv_prog_gnu_ld" = yes; then + if test yes = "$lt_cv_prog_gnu_ld"; then case `/usr/bin/file conftest.$ac_objext` in *32-bit*) LD="${LD-ld} -melf32bsmip" @@ -1312,9 +1336,46 @@ ia64-*-hpux*) rm -rf conftest* ;; -x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ +mips64*-*linux*) + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. + echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext + if AC_TRY_EVAL(ac_compile); then + emul=elf + case `/usr/bin/file conftest.$ac_objext` in + *32-bit*) + emul="${emul}32" + ;; + *64-bit*) + emul="${emul}64" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *MSB*) + emul="${emul}btsmip" + ;; + *LSB*) + emul="${emul}ltsmip" + ;; + esac + case `/usr/bin/file conftest.$ac_objext` in + *N32*) + emul="${emul}n32" + ;; + esac + LD="${LD-ld} -m $emul" + fi + rm -rf conftest* + ;; + +x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. Note that the listed cases only cover the + # situations where additional linker options are needed (such as when + # doing 32-bit compilation for a host where ld defaults to 64-bit, or + # vice versa); the common cases where no linker options are needed do + # not appear in the list. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in @@ -1324,9 +1385,19 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) LD="${LD-ld} -m elf_i386_fbsd" ;; x86_64-*linux*) - LD="${LD-ld} -m elf_i386" + case `/usr/bin/file conftest.o` in + *x86-64*) + LD="${LD-ld} -m elf32_x86_64" + ;; + *) + LD="${LD-ld} -m elf_i386" + ;; + esac + ;; + powerpc64le-*linux*) + LD="${LD-ld} -m elf32lppclinux" ;; - ppc64-*linux*|powerpc64-*linux*) + powerpc64-*linux*) LD="${LD-ld} -m elf32ppclinux" ;; s390x-*linux*) @@ -1345,7 +1416,10 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) x86_64-*linux*) LD="${LD-ld} -m elf_x86_64" ;; - ppc*-*linux*|powerpc*-*linux*) + powerpcle-*linux*) + LD="${LD-ld} -m elf64lppc" + ;; + powerpc-*linux*) LD="${LD-ld} -m elf64ppc" ;; s390*-*linux*|s390*-*tpf*) @@ -1363,19 +1437,20 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) *-*-sco3.2v5*) # On SCO OpenServer 5, we need -belf to get full-featured binaries. - SAVE_CFLAGS="$CFLAGS" + SAVE_CFLAGS=$CFLAGS CFLAGS="$CFLAGS -belf" AC_CACHE_CHECK([whether the C compiler needs -belf], lt_cv_cc_needs_belf, [AC_LANG_PUSH(C) AC_LINK_IFELSE([AC_LANG_PROGRAM([[]],[[]])],[lt_cv_cc_needs_belf=yes],[lt_cv_cc_needs_belf=no]) AC_LANG_POP]) - if test x"$lt_cv_cc_needs_belf" != x"yes"; then + if test yes != "$lt_cv_cc_needs_belf"; then # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf - CFLAGS="$SAVE_CFLAGS" + CFLAGS=$SAVE_CFLAGS fi ;; *-*solaris*) - # Find out which ABI we are using. + # Find out what ABI is being produced by ac_compile, and set linker + # options accordingly. echo 'int i;' > conftest.$ac_ext if AC_TRY_EVAL(ac_compile); then case `/usr/bin/file conftest.o` in @@ -1383,7 +1458,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) case $lt_cv_prog_gnu_ld in yes*) case $host in - i?86-*-solaris*) + i?86-*-solaris*|x86_64-*-solaris*) LD="${LD-ld} -m elf_x86_64" ;; sparc*-*-solaris*) @@ -1392,7 +1467,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) esac # GNU ld 2.21 introduced _sol2 emulations. Use them if available. if ${LD-ld} -V | grep _sol2 >/dev/null 2>&1; then - LD="${LD-ld}_sol2" + LD=${LD-ld}_sol2 fi ;; *) @@ -1408,7 +1483,7 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*) ;; esac -need_locks="$enable_libtool_lock" +need_locks=$enable_libtool_lock ])# _LT_ENABLE_LOCK @@ -1417,7 +1492,7 @@ need_locks="$enable_libtool_lock" m4_defun([_LT_PROG_AR], [AC_CHECK_TOOLS(AR, [ar], false) : ${AR=ar} -: ${AR_FLAGS=cru} +: ${AR_FLAGS=cr} _LT_DECL([], [AR], [1], [The archiver]) _LT_DECL([], [AR_FLAGS], [1], [Flags to create an archive]) @@ -1427,11 +1502,11 @@ AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], [echo conftest.$ac_objext > conftest.lst lt_ar_try='$AR $AR_FLAGS libconftest.a @conftest.lst >&AS_MESSAGE_LOG_FD' AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -eq 0; then + if test 0 -eq "$ac_status"; then # Ensure the archiver fails upon bogus file names. rm -f conftest.$ac_objext libconftest.a AC_TRY_EVAL([lt_ar_try]) - if test "$ac_status" -ne 0; then + if test 0 -ne "$ac_status"; then lt_cv_ar_at_file=@ fi fi @@ -1439,7 +1514,7 @@ AC_CACHE_CHECK([for archiver @FILE support], [lt_cv_ar_at_file], ]) ]) -if test "x$lt_cv_ar_at_file" = xno; then +if test no = "$lt_cv_ar_at_file"; then archiver_list_spec= else archiver_list_spec=$lt_cv_ar_at_file @@ -1470,7 +1545,7 @@ old_postuninstall_cmds= if test -n "$RANLIB"; then case $host_os in - openbsd*) + bitrig* | openbsd*) old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$tool_oldlib" ;; *) @@ -1506,7 +1581,7 @@ AC_CACHE_CHECK([$1], [$2], [$2=no m4_if([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4]) echo "$lt_simple_compile_test_code" > conftest.$ac_ext - lt_compiler_flag="$3" + lt_compiler_flag="$3" ## exclude from sc_useless_quotes_in_assignment # Insert the option either (1) after the last *FLAGS variable, or # (2) before a word containing "conftest.", or (3) at the end. # Note that $ac_compile itself does not contain backslashes and begins @@ -1533,7 +1608,7 @@ AC_CACHE_CHECK([$1], [$2], $RM conftest* ]) -if test x"[$]$2" = xyes; then +if test yes = "[$]$2"; then m4_if([$5], , :, [$5]) else m4_if([$6], , :, [$6]) @@ -1555,7 +1630,7 @@ AC_DEFUN([_LT_LINKER_OPTION], m4_require([_LT_DECL_SED])dnl AC_CACHE_CHECK([$1], [$2], [$2=no - save_LDFLAGS="$LDFLAGS" + save_LDFLAGS=$LDFLAGS LDFLAGS="$LDFLAGS $3" echo "$lt_simple_link_test_code" > conftest.$ac_ext if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then @@ -1574,10 +1649,10 @@ AC_CACHE_CHECK([$1], [$2], fi fi $RM -r conftest* - LDFLAGS="$save_LDFLAGS" + LDFLAGS=$save_LDFLAGS ]) -if test x"[$]$2" = xyes; then +if test yes = "[$]$2"; then m4_if([$4], , :, [$4]) else m4_if([$5], , :, [$5]) @@ -1598,7 +1673,7 @@ AC_DEFUN([LT_CMD_MAX_LEN], AC_MSG_CHECKING([the maximum length of command line arguments]) AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl i=0 - teststring="ABCD" + teststring=ABCD case $build_os in msdosdjgpp*) @@ -1638,7 +1713,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl lt_cv_sys_max_cmd_len=8192; ;; - netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) + bitrig* | darwin* | dragonfly* | freebsd* | netbsd* | openbsd*) # This has been around since 386BSD, at least. Likely further. if test -x /sbin/sysctl; then lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` @@ -1688,22 +1763,23 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl ;; *) lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` - if test -n "$lt_cv_sys_max_cmd_len"; then + if test -n "$lt_cv_sys_max_cmd_len" && \ + test undefined != "$lt_cv_sys_max_cmd_len"; then lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` else # Make teststring a little bigger before we do anything with it. # a 1K string should be a reasonable start. - for i in 1 2 3 4 5 6 7 8 ; do + for i in 1 2 3 4 5 6 7 8; do teststring=$teststring$teststring done SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} # If test is not a shell built-in, we'll probably end up computing a # maximum length that is only half of the actual maximum length, but # we can't tell. - while { test "X"`env echo "$teststring$teststring" 2>/dev/null` \ + while { test X`env echo "$teststring$teststring" 2>/dev/null` \ = "X$teststring$teststring"; } >/dev/null 2>&1 && - test $i != 17 # 1/2 MB should be enough + test 17 != "$i" # 1/2 MB should be enough do i=`expr $i + 1` teststring=$teststring$teststring @@ -1719,7 +1795,7 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl ;; esac ]) -if test -n $lt_cv_sys_max_cmd_len ; then +if test -n "$lt_cv_sys_max_cmd_len"; then AC_MSG_RESULT($lt_cv_sys_max_cmd_len) else AC_MSG_RESULT(none) @@ -1747,7 +1823,7 @@ m4_defun([_LT_HEADER_DLFCN], # ---------------------------------------------------------------- m4_defun([_LT_TRY_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl -if test "$cross_compiling" = yes; then : +if test yes = "$cross_compiling"; then : [$4] else lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 @@ -1794,9 +1870,9 @@ else # endif #endif -/* When -fvisbility=hidden is used, assume the code has been annotated +/* When -fvisibility=hidden is used, assume the code has been annotated correspondingly for the symbols needed. */ -#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) +#if defined __GNUC__ && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) int fnord () __attribute__((visibility("default"))); #endif @@ -1822,7 +1898,7 @@ int main () return status; }] _LT_EOF - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext} 2>/dev/null; then + if AC_TRY_EVAL(ac_link) && test -s "conftest$ac_exeext" 2>/dev/null; then (./conftest; exit; ) >&AS_MESSAGE_LOG_FD 2>/dev/null lt_status=$? case x$lt_status in @@ -1843,7 +1919,7 @@ rm -fr conftest* # ------------------ AC_DEFUN([LT_SYS_DLOPEN_SELF], [m4_require([_LT_HEADER_DLFCN])dnl -if test "x$enable_dlopen" != xyes; then +if test yes != "$enable_dlopen"; then enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown @@ -1853,44 +1929,52 @@ else case $host_os in beos*) - lt_cv_dlopen="load_add_on" + lt_cv_dlopen=load_add_on lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ;; mingw* | pw32* | cegcc*) - lt_cv_dlopen="LoadLibrary" + lt_cv_dlopen=LoadLibrary lt_cv_dlopen_libs= ;; cygwin*) - lt_cv_dlopen="dlopen" + lt_cv_dlopen=dlopen lt_cv_dlopen_libs= ;; darwin*) - # if libdl is installed we need to link against it + # if libdl is installed we need to link against it AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"],[ - lt_cv_dlopen="dyld" + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl],[ + lt_cv_dlopen=dyld lt_cv_dlopen_libs= lt_cv_dlopen_self=yes ]) ;; + tpf*) + # Don't try to run any link tests for TPF. We know it's impossible + # because TPF is a cross-compiler, and we know how we open DSOs. + lt_cv_dlopen=dlopen + lt_cv_dlopen_libs= + lt_cv_dlopen_self=no + ;; + *) AC_CHECK_FUNC([shl_load], - [lt_cv_dlopen="shl_load"], + [lt_cv_dlopen=shl_load], [AC_CHECK_LIB([dld], [shl_load], - [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"], + [lt_cv_dlopen=shl_load lt_cv_dlopen_libs=-ldld], [AC_CHECK_FUNC([dlopen], - [lt_cv_dlopen="dlopen"], + [lt_cv_dlopen=dlopen], [AC_CHECK_LIB([dl], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-ldl], [AC_CHECK_LIB([svld], [dlopen], - [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"], + [lt_cv_dlopen=dlopen lt_cv_dlopen_libs=-lsvld], [AC_CHECK_LIB([dld], [dld_link], - [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"]) + [lt_cv_dlopen=dld_link lt_cv_dlopen_libs=-ldld]) ]) ]) ]) @@ -1899,21 +1983,21 @@ else ;; esac - if test "x$lt_cv_dlopen" != xno; then - enable_dlopen=yes - else + if test no = "$lt_cv_dlopen"; then enable_dlopen=no + else + enable_dlopen=yes fi case $lt_cv_dlopen in dlopen) - save_CPPFLAGS="$CPPFLAGS" - test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" + save_CPPFLAGS=$CPPFLAGS + test yes = "$ac_cv_header_dlfcn_h" && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" - save_LDFLAGS="$LDFLAGS" + save_LDFLAGS=$LDFLAGS wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" - save_LIBS="$LIBS" + save_LIBS=$LIBS LIBS="$lt_cv_dlopen_libs $LIBS" AC_CACHE_CHECK([whether a program can dlopen itself], @@ -1923,7 +2007,7 @@ else lt_cv_dlopen_self=no, lt_cv_dlopen_self=cross) ]) - if test "x$lt_cv_dlopen_self" = xyes; then + if test yes = "$lt_cv_dlopen_self"; then wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" AC_CACHE_CHECK([whether a statically linked program can dlopen itself], lt_cv_dlopen_self_static, [dnl @@ -1933,9 +2017,9 @@ else ]) fi - CPPFLAGS="$save_CPPFLAGS" - LDFLAGS="$save_LDFLAGS" - LIBS="$save_LIBS" + CPPFLAGS=$save_CPPFLAGS + LDFLAGS=$save_LDFLAGS + LIBS=$save_LIBS ;; esac @@ -2027,8 +2111,8 @@ m4_defun([_LT_COMPILER_FILE_LOCKS], m4_require([_LT_FILEUTILS_DEFAULTS])dnl _LT_COMPILER_C_O([$1]) -hard_links="nottested" -if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != no; then +hard_links=nottested +if test no = "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" && test no != "$need_locks"; then # do not overwrite the value of need_locks provided by the user AC_MSG_CHECKING([if we can lock with hard links]) hard_links=yes @@ -2038,8 +2122,8 @@ if test "$_LT_TAGVAR(lt_cv_prog_compiler_c_o, $1)" = no && test "$need_locks" != ln conftest.a conftest.b 2>&5 || hard_links=no ln conftest.a conftest.b 2>/dev/null && hard_links=no AC_MSG_RESULT([$hard_links]) - if test "$hard_links" = no; then - AC_MSG_WARN([`$CC' does not support `-c -o', so `make -j' may be unsafe]) + if test no = "$hard_links"; then + AC_MSG_WARN(['$CC' does not support '-c -o', so 'make -j' may be unsafe]) need_locks=warn fi else @@ -2066,8 +2150,8 @@ objdir=$lt_cv_objdir _LT_DECL([], [objdir], [0], [The name of the directory that contains temporary libtool files])dnl m4_pattern_allow([LT_OBJDIR])dnl -AC_DEFINE_UNQUOTED(LT_OBJDIR, "$lt_cv_objdir/", - [Define to the sub-directory in which libtool stores uninstalled libraries.]) +AC_DEFINE_UNQUOTED([LT_OBJDIR], "$lt_cv_objdir/", + [Define to the sub-directory where libtool stores uninstalled libraries.]) ])# _LT_CHECK_OBJDIR @@ -2079,15 +2163,15 @@ m4_defun([_LT_LINKER_HARDCODE_LIBPATH], _LT_TAGVAR(hardcode_action, $1)= if test -n "$_LT_TAGVAR(hardcode_libdir_flag_spec, $1)" || test -n "$_LT_TAGVAR(runpath_var, $1)" || - test "X$_LT_TAGVAR(hardcode_automatic, $1)" = "Xyes" ; then + test yes = "$_LT_TAGVAR(hardcode_automatic, $1)"; then # We can hardcode non-existent directories. - if test "$_LT_TAGVAR(hardcode_direct, $1)" != no && + if test no != "$_LT_TAGVAR(hardcode_direct, $1)" && # If the only mechanism to avoid hardcoding is shlibpath_var, we # have to relink, otherwise we might link with an installed library # when we should be linking with a yet-to-be-installed one - ## test "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" != no && - test "$_LT_TAGVAR(hardcode_minus_L, $1)" != no; then + ## test no != "$_LT_TAGVAR(hardcode_shlibpath_var, $1)" && + test no != "$_LT_TAGVAR(hardcode_minus_L, $1)"; then # Linking always hardcodes the temporary library directory. _LT_TAGVAR(hardcode_action, $1)=relink else @@ -2101,12 +2185,12 @@ else fi AC_MSG_RESULT([$_LT_TAGVAR(hardcode_action, $1)]) -if test "$_LT_TAGVAR(hardcode_action, $1)" = relink || - test "$_LT_TAGVAR(inherit_rpath, $1)" = yes; then +if test relink = "$_LT_TAGVAR(hardcode_action, $1)" || + test yes = "$_LT_TAGVAR(inherit_rpath, $1)"; then # Fast installation is not supported enable_fast_install=no -elif test "$shlibpath_overrides_runpath" = yes || - test "$enable_shared" = no; then +elif test yes = "$shlibpath_overrides_runpath" || + test no = "$enable_shared"; then # Fast installation is not necessary enable_fast_install=needless fi @@ -2130,7 +2214,7 @@ else # FIXME - insert some real tests, host_os isn't really good enough case $host_os in darwin*) - if test -n "$STRIP" ; then + if test -n "$STRIP"; then striplib="$STRIP -x" old_striplib="$STRIP -S" AC_MSG_RESULT([yes]) @@ -2148,6 +2232,47 @@ _LT_DECL([], [striplib], [1]) ])# _LT_CMD_STRIPLIB +# _LT_PREPARE_MUNGE_PATH_LIST +# --------------------------- +# Make sure func_munge_path_list() is defined correctly. +m4_defun([_LT_PREPARE_MUNGE_PATH_LIST], +[[# func_munge_path_list VARIABLE PATH +# ----------------------------------- +# VARIABLE is name of variable containing _space_ separated list of +# directories to be munged by the contents of PATH, which is string +# having a format: +# "DIR[:DIR]:" +# string "DIR[ DIR]" will be prepended to VARIABLE +# ":DIR[:DIR]" +# string "DIR[ DIR]" will be appended to VARIABLE +# "DIRP[:DIRP]::[DIRA:]DIRA" +# string "DIRP[ DIRP]" will be prepended to VARIABLE and string +# "DIRA[ DIRA]" will be appended to VARIABLE +# "DIR[:DIR]" +# VARIABLE will be replaced by "DIR[ DIR]" +func_munge_path_list () +{ + case x@S|@2 in + x) + ;; + *:) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'` \@S|@@S|@1\" + ;; + x:*) + eval @S|@1=\"\@S|@@S|@1 `$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + *::*) + eval @S|@1=\"\@S|@@S|@1\ `$ECHO @S|@2 | $SED -e 's/.*:://' -e 's/:/ /g'`\" + eval @S|@1=\"`$ECHO @S|@2 | $SED -e 's/::.*//' -e 's/:/ /g'`\ \@S|@@S|@1\" + ;; + *) + eval @S|@1=\"`$ECHO @S|@2 | $SED 's/:/ /g'`\" + ;; + esac +} +]])# _LT_PREPARE_PATH_LIST + + # _LT_SYS_DYNAMIC_LINKER([TAG]) # ----------------------------- # PORTME Fill in your ld.so characteristics @@ -2158,17 +2283,18 @@ m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_OBJDUMP])dnl m4_require([_LT_DECL_SED])dnl m4_require([_LT_CHECK_SHELL_FEATURES])dnl +m4_require([_LT_PREPARE_MUNGE_PATH_LIST])dnl AC_MSG_CHECKING([dynamic linker characteristics]) m4_if([$1], [], [ -if test "$GCC" = yes; then +if test yes = "$GCC"; then case $host_os in - darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; - *) lt_awk_arg="/^libraries:/" ;; + darwin*) lt_awk_arg='/^libraries:/,/LR/' ;; + *) lt_awk_arg='/^libraries:/' ;; esac case $host_os in - mingw* | cegcc*) lt_sed_strip_eq="s,=\([[A-Za-z]]:\),\1,g" ;; - *) lt_sed_strip_eq="s,=/,/,g" ;; + mingw* | cegcc*) lt_sed_strip_eq='s|=\([[A-Za-z]]:\)|\1|g' ;; + *) lt_sed_strip_eq='s|=/|/|g' ;; esac lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` case $lt_search_path_spec in @@ -2184,28 +2310,35 @@ if test "$GCC" = yes; then ;; esac # Ok, now we have the path, separated by spaces, we can step through it - # and add multilib dir if necessary. + # and add multilib dir if necessary... lt_tmp_lt_search_path_spec= - lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + lt_multi_os_dir=/`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` + # ...but if some path component already ends with the multilib dir we assume + # that all is fine and trust -print-search-dirs as is (GCC 4.2? or newer). + case "$lt_multi_os_dir; $lt_search_path_spec " in + "/; "* | "/.; "* | "/./; "* | *"$lt_multi_os_dir "* | *"$lt_multi_os_dir/ "*) + lt_multi_os_dir= + ;; + esac for lt_sys_path in $lt_search_path_spec; do - if test -d "$lt_sys_path/$lt_multi_os_dir"; then - lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" - else + if test -d "$lt_sys_path$lt_multi_os_dir"; then + lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path$lt_multi_os_dir" + elif test -n "$lt_multi_os_dir"; then test -d "$lt_sys_path" && \ lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" fi done lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' -BEGIN {RS=" "; FS="/|\n";} { - lt_foo=""; - lt_count=0; +BEGIN {RS = " "; FS = "/|\n";} { + lt_foo = ""; + lt_count = 0; for (lt_i = NF; lt_i > 0; lt_i--) { if ($lt_i != "" && $lt_i != ".") { if ($lt_i == "..") { lt_count++; } else { if (lt_count == 0) { - lt_foo="/" $lt_i lt_foo; + lt_foo = "/" $lt_i lt_foo; } else { lt_count--; } @@ -2219,7 +2352,7 @@ BEGIN {RS=" "; FS="/|\n";} { # for these hosts. case $host_os in mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ - $SED 's,/\([[A-Za-z]]:\),\1,g'` ;; + $SED 's|/\([[A-Za-z]]:\)|\1|g'` ;; esac sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` else @@ -2228,7 +2361,7 @@ fi]) library_names_spec= libname_spec='lib$name' soname_spec= -shrext_cmds=".so" +shrext_cmds=.so postinstall_cmds= postuninstall_cmds= finish_cmds= @@ -2245,14 +2378,17 @@ hardcode_into_libs=no # flags to be left without arguments need_version=unknown +AC_ARG_VAR([LT_SYS_LIBRARY_PATH], +[User-defined run-time library search path.]) + case $host_os in aix3*) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' + library_names_spec='$libname$release$shared_ext$versuffix $libname.a' shlibpath_var=LIBPATH # AIX 3 has no versioning support, so we append a major version to the name. - soname_spec='${libname}${release}${shared_ext}$major' + soname_spec='$libname$release$shared_ext$major' ;; aix[[4-9]]*) @@ -2260,41 +2396,91 @@ aix[[4-9]]*) need_lib_prefix=no need_version=no hardcode_into_libs=yes - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 supports IA64 - library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$major $libname$release$shared_ext$versuffix $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH else # With GCC up to 2.95.x, collect2 would create an import file # for dependence libraries. The import file would start with - # the line `#! .'. This would cause the generated library to - # depend on `.', always an invalid library. This was fixed in + # the line '#! .'. This would cause the generated library to + # depend on '.', always an invalid library. This was fixed in # development snapshots of GCC prior to 3.0. case $host_os in aix4 | aix4.[[01]] | aix4.[[01]].*) if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' echo ' yes ' - echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then + echo '#endif'; } | $CC -E - | $GREP yes > /dev/null; then : else can_build_shared=no fi ;; esac - # AIX (on Power*) has no versioning support, so currently we can not hardcode correct + # Using Import Files as archive members, it is possible to support + # filename-based versioning of shared library archives on AIX. While + # this would work for both with and without runtime linking, it will + # prevent static linking of such archives. So we do filename-based + # shared library versioning with .so extension only, which is used + # when both runtime linking and shared linking is enabled. + # Unfortunately, runtime linking may impact performance, so we do + # not want this to be the default eventually. Also, we use the + # versioned .so libs for executables only if there is the -brtl + # linker flag in LDFLAGS as well, or --with-aix-soname=svr4 only. + # To allow for filename-based versioning support, we need to create + # libNAME.so.V as an archive file, containing: + # *) an Import File, referring to the versioned filename of the + # archive as well as the shared archive member, telling the + # bitwidth (32 or 64) of that shared object, and providing the + # list of exported symbols of that shared object, eventually + # decorated with the 'weak' keyword + # *) the shared object with the F_LOADONLY flag set, to really avoid + # it being seen by the linker. + # At run time we better use the real file rather than another symlink, + # but for link time we create the symlink libNAME.so -> libNAME.so.V + + case $with_aix_soname,$aix_use_runtimelinking in + # AIX (on Power*) has no versioning support, so currently we cannot hardcode correct # soname into executable. Probably we can add versioning support to # collect2, so additional links can be useful in future. - if test "$aix_use_runtimelinking" = yes; then + aix,yes) # traditional libtool + dynamic_linker='AIX unversionable lib.so' # If using run time linking (on AIX 4.2 or later) use lib<name>.so # instead of lib<name>.a to let people know that these are not # typical AIX shared libraries. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - else + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + ;; + aix,no) # traditional AIX only + dynamic_linker='AIX lib.a[(]lib.so.V[)]' # We preserve .a as extension for shared libraries through AIX4.2 # and later when we are not doing run time linking. - library_names_spec='${libname}${release}.a $libname.a' - soname_spec='${libname}${release}${shared_ext}$major' - fi + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + ;; + svr4,*) # full svr4 only + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,yes) # both, prefer svr4 + dynamic_linker="AIX lib.so.V[(]$shared_archive_member_spec.o[)], lib.a[(]lib.so.V[)]" + library_names_spec='$libname$release$shared_ext$major $libname$shared_ext' + # unpreferred sharedlib libNAME.a needs extra handling + postinstall_cmds='test -n "$linkname" || linkname="$realname"~func_stripname "" ".so" "$linkname"~$install_shared_prog "$dir/$func_stripname_result.$libext" "$destdir/$func_stripname_result.$libext"~test -z "$tstripme" || test -z "$striplib" || $striplib "$destdir/$func_stripname_result.$libext"' + postuninstall_cmds='for n in $library_names $old_library; do :; done~func_stripname "" ".so" "$n"~test "$func_stripname_result" = "$n" || func_append rmfiles " $odir/$func_stripname_result.$libext"' + # We do not specify a path in Import Files, so LIBPATH fires. + shlibpath_overrides_runpath=yes + ;; + *,no) # both, prefer aix + dynamic_linker="AIX lib.a[(]lib.so.V[)], lib.so.V[(]$shared_archive_member_spec.o[)]" + library_names_spec='$libname$release.a $libname.a' + soname_spec='$libname$release$shared_ext$major' + # unpreferred sharedlib libNAME.so.V and symlink libNAME.so need extra handling + postinstall_cmds='test -z "$dlname" || $install_shared_prog $dir/$dlname $destdir/$dlname~test -z "$tstripme" || test -z "$striplib" || $striplib $destdir/$dlname~test -n "$linkname" || linkname=$realname~func_stripname "" ".a" "$linkname"~(cd "$destdir" && $LN_S -f $dlname $func_stripname_result.so)' + postuninstall_cmds='test -z "$dlname" || func_append rmfiles " $odir/$dlname"~for n in $old_library $library_names; do :; done~func_stripname "" ".a" "$n"~func_append rmfiles " $odir/$func_stripname_result.so"' + ;; + esac shlibpath_var=LIBPATH fi ;; @@ -2304,18 +2490,18 @@ amigaos*) powerpc) # Since July 2007 AmigaOS4 officially supports .so libraries. # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' ;; m68k) library_names_spec='$libname.ixlibrary $libname.a' # Create ${libname}_ixlibrary.a entries in /sys/libs. - finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' + finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([[^/]]*\)\.ixlibrary$%\1%'\''`; $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' ;; esac ;; beos*) - library_names_spec='${libname}${shared_ext}' + library_names_spec='$libname$shared_ext' dynamic_linker="$host_os ld.so" shlibpath_var=LIBRARY_PATH ;; @@ -2323,8 +2509,8 @@ beos*) bsdi[[45]]*) version_type=linux # correct to gnu/linux during the next big refactor need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" @@ -2336,7 +2522,7 @@ bsdi[[45]]*) cygwin* | mingw* | pw32* | cegcc*) version_type=windows - shrext_cmds=".dll" + shrext_cmds=.dll need_version=no need_lib_prefix=no @@ -2345,8 +2531,8 @@ cygwin* | mingw* | pw32* | cegcc*) # gcc library_names_spec='$libname.dll.a' # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname~ @@ -2362,17 +2548,17 @@ cygwin* | mingw* | pw32* | cegcc*) case $host_os in cygwin*) # Cygwin DLLs use 'cyg' prefix rather than 'lib' - soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + soname_spec='`echo $libname | sed -e 's/^lib/cyg/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' m4_if([$1], [],[ sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"]) ;; mingw* | cegcc*) # MinGW DLLs use traditional 'lib' prefix - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; pw32*) # pw32 DLLs use 'pw' prefix rather than 'lib' - library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' + library_names_spec='`echo $libname | sed -e 's/^lib/pw/'``echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' ;; esac dynamic_linker='Win32 ld.exe' @@ -2381,8 +2567,8 @@ m4_if([$1], [],[ *,cl*) # Native MSVC libname_spec='$name' - soname_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext}' - library_names_spec='${libname}.dll.lib' + soname_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext' + library_names_spec='$libname.dll.lib' case $build_os in mingw*) @@ -2409,7 +2595,7 @@ m4_if([$1], [],[ sys_lib_search_path_spec=`cygpath --path --unix "$sys_lib_search_path_spec" | $SED -e "s/$PATH_SEPARATOR/ /g"` ;; *) - sys_lib_search_path_spec="$LIB" + sys_lib_search_path_spec=$LIB if $ECHO "$sys_lib_search_path_spec" | [$GREP ';[c-zC-Z]:/' >/dev/null]; then # It is most probably a Windows format PATH. sys_lib_search_path_spec=`$ECHO "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'` @@ -2422,8 +2608,8 @@ m4_if([$1], [],[ esac # DLL is installed to $(libdir)/../bin by postinstall_cmds - postinstall_cmds='base_file=`basename \${file}`~ - dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; echo \$dlname'\''`~ dldir=$destdir/`dirname \$dlpath`~ test -d \$dldir || mkdir -p \$dldir~ $install_prog $dir/$dlname \$dldir/$dlname' @@ -2436,7 +2622,7 @@ m4_if([$1], [],[ *) # Assume MSVC wrapper - library_names_spec='${libname}`echo ${release} | $SED -e 's/[[.]]/-/g'`${versuffix}${shared_ext} $libname.lib' + library_names_spec='$libname`echo $release | $SED -e 's/[[.]]/-/g'`$versuffix$shared_ext $libname.lib' dynamic_linker='Win32 ld.exe' ;; esac @@ -2449,8 +2635,8 @@ darwin* | rhapsody*) version_type=darwin need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' - soname_spec='${libname}${release}${major}$shared_ext' + library_names_spec='$libname$release$major$shared_ext $libname$shared_ext' + soname_spec='$libname$release$major$shared_ext' shlibpath_overrides_runpath=yes shlibpath_var=DYLD_LIBRARY_PATH shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' @@ -2463,8 +2649,8 @@ dgux*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; @@ -2482,12 +2668,13 @@ freebsd* | dragonfly*) version_type=freebsd-$objformat case $version_type in freebsd-elf*) - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' need_version=no need_lib_prefix=no ;; freebsd-*) - library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' need_version=yes ;; esac @@ -2512,26 +2699,15 @@ freebsd* | dragonfly*) esac ;; -gnu*) - version_type=linux # correct to gnu/linux during the next big refactor - need_lib_prefix=no - need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - shlibpath_var=LD_LIBRARY_PATH - shlibpath_overrides_runpath=no - hardcode_into_libs=yes - ;; - haiku*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no dynamic_linker="$host_os runtime_loader" - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LIBRARY_PATH - shlibpath_overrides_runpath=yes + shlibpath_overrides_runpath=no sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib' hardcode_into_libs=yes ;; @@ -2549,14 +2725,15 @@ hpux9* | hpux10* | hpux11*) dynamic_linker="$host_os dld.so" shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' - if test "X$HPUX_IA64_MODE" = X32; then + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' + if test 32 = "$HPUX_IA64_MODE"; then sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" + sys_lib_dlsearch_path_spec=/usr/lib/hpux32 else sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" + sys_lib_dlsearch_path_spec=/usr/lib/hpux64 fi - sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; hppa*64*) shrext_cmds='.sl' @@ -2564,8 +2741,8 @@ hpux9* | hpux10* | hpux11*) dynamic_linker="$host_os dld.sl" shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; @@ -2574,8 +2751,8 @@ hpux9* | hpux10* | hpux11*) dynamic_linker="$host_os dld.sl" shlibpath_var=SHLIB_PATH shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' ;; esac # HP-UX runs *really* slowly unless shared libraries are mode 555, ... @@ -2588,8 +2765,8 @@ interix[[3-9]]*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no @@ -2600,7 +2777,7 @@ irix5* | irix6* | nonstopux*) case $host_os in nonstopux*) version_type=nonstopux ;; *) - if test "$lt_cv_prog_gnu_ld" = yes; then + if test yes = "$lt_cv_prog_gnu_ld"; then version_type=linux # correct to gnu/linux during the next big refactor else version_type=irix @@ -2608,8 +2785,8 @@ irix5* | irix6* | nonstopux*) esac need_lib_prefix=no need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$release$shared_ext $libname$shared_ext' case $host_os in irix5* | nonstopux*) libsuff= shlibsuff= @@ -2628,8 +2805,8 @@ irix5* | irix6* | nonstopux*) esac shlibpath_var=LD_LIBRARY${shlibsuff}_PATH shlibpath_overrides_runpath=no - sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" - sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" + sys_lib_search_path_spec="/usr/lib$libsuff /lib$libsuff /usr/local/lib$libsuff" + sys_lib_dlsearch_path_spec="/usr/lib$libsuff /lib$libsuff" hardcode_into_libs=yes ;; @@ -2638,13 +2815,33 @@ linux*oldld* | linux*aout* | linux*coff*) dynamic_linker=no ;; +linux*android*) + version_type=none # Android doesn't support versioned libraries. + need_lib_prefix=no + need_version=no + library_names_spec='$libname$release$shared_ext' + soname_spec='$libname$release$shared_ext' + finish_cmds= + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes + + # This implies no fast_install, which is unacceptable. + # Some rework will be needed to allow for fast_install + # before this can be enabled. + hardcode_into_libs=yes + + dynamic_linker='Android linker' + # Don't embed -rpath directories since the linker doesn't support them. + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + ;; + # This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu) +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no @@ -2669,14 +2866,15 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu) # before this can be enabled. hardcode_into_libs=yes - # Add ABI-specific directories to the system library path. - sys_lib_dlsearch_path_spec="/lib64 /usr/lib64 /lib /usr/lib" - - # Append ld.so.conf contents to the search path + # Ideally, we could use ldconfig to report *all* directores which are + # searched for libraries, however this is still not possible. Aside from not + # being certain /sbin/ldconfig is available, command + # 'ldconfig -N -X -v | grep ^/' on 64bit Fedora does not report /usr/lib64, + # even though it is searched at run-time. Try to do the best guess by + # appending ld.so.conf contents (and includes) to the search path. if test -f /etc/ld.so.conf; then lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` - sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec $lt_ld_extra" - + sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" fi # We used to test for /lib/ld.so.1 and disable shared libraries on @@ -2688,17 +2886,29 @@ linux* | k*bsd*-gnu | kopensolaris*-gnu) dynamic_linker='GNU/Linux ld.so' ;; +netbsdelf*-gnu) + version_type=linux + need_lib_prefix=no + need_version=no + library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' + soname_spec='${libname}${release}${shared_ext}$major' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=no + hardcode_into_libs=yes + dynamic_linker='NetBSD ld.elf_so' + ;; + netbsd*) version_type=sunos need_lib_prefix=no need_version=no if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' dynamic_linker='NetBSD (a.out) ld.so' else - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' dynamic_linker='NetBSD ld.elf_so' fi shlibpath_var=LD_LIBRARY_PATH @@ -2708,7 +2918,7 @@ netbsd*) newsos6) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes ;; @@ -2717,58 +2927,68 @@ newsos6) version_type=qnx need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes dynamic_linker='ldqnx.so' ;; -openbsd*) +openbsd* | bitrig*) version_type=sunos - sys_lib_dlsearch_path_spec="/usr/lib" + sys_lib_dlsearch_path_spec=/usr/lib need_lib_prefix=no - # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. - case $host_os in - openbsd3.3 | openbsd3.3.*) need_version=yes ;; - *) need_version=no ;; - esac - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' - finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' - shlibpath_var=LD_LIBRARY_PATH - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - case $host_os in - openbsd2.[[89]] | openbsd2.[[89]].*) - shlibpath_overrides_runpath=no - ;; - *) - shlibpath_overrides_runpath=yes - ;; - esac + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then + need_version=no else - shlibpath_overrides_runpath=yes + need_version=yes fi + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' + finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' + shlibpath_var=LD_LIBRARY_PATH + shlibpath_overrides_runpath=yes ;; os2*) libname_spec='$name' - shrext_cmds=".dll" + version_type=windows + shrext_cmds=.dll + need_version=no need_lib_prefix=no - library_names_spec='$libname${shared_ext} $libname.a' + # OS/2 can only load a DLL with a base name of 8 characters or less. + soname_spec='`test -n "$os2dllname" && libname="$os2dllname"; + v=$($ECHO $release$versuffix | tr -d .-); + n=$($ECHO $libname | cut -b -$((8 - ${#v})) | tr . _); + $ECHO $n$v`$shared_ext' + library_names_spec='${libname}_dll.$libext' dynamic_linker='OS/2 ld.exe' - shlibpath_var=LIBPATH + shlibpath_var=BEGINLIBPATH + sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec + postinstall_cmds='base_file=`basename \$file`~ + dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\$base_file'\''i; $ECHO \$dlname'\''`~ + dldir=$destdir/`dirname \$dlpath`~ + test -d \$dldir || mkdir -p \$dldir~ + $install_prog $dir/$dlname \$dldir/$dlname~ + chmod a+x \$dldir/$dlname~ + if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then + eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; + fi' + postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; $ECHO \$dlname'\''`~ + dlpath=$dir/\$dldll~ + $RM \$dlpath' ;; osf3* | osf4* | osf5*) version_type=osf need_lib_prefix=no need_version=no - soname_spec='${libname}${release}${shared_ext}$major' - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + soname_spec='$libname$release$shared_ext$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" - sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" + sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec ;; rdos*) @@ -2779,8 +2999,8 @@ solaris*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes @@ -2790,11 +3010,11 @@ solaris*) sunos4*) version_type=sunos - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' + library_names_spec='$libname$release$shared_ext$versuffix $libname$shared_ext$versuffix' finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes - if test "$with_gnu_ld" = yes; then + if test yes = "$with_gnu_ld"; then need_lib_prefix=no fi need_version=yes @@ -2802,8 +3022,8 @@ sunos4*) sysv4 | sysv4.3*) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH case $host_vendor in sni) @@ -2824,24 +3044,24 @@ sysv4 | sysv4.3*) ;; sysv4*MP*) - if test -d /usr/nec ;then + if test -d /usr/nec; then version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' - soname_spec='$libname${shared_ext}.$major' + library_names_spec='$libname$shared_ext.$versuffix $libname$shared_ext.$major $libname$shared_ext' + soname_spec='$libname$shared_ext.$major' shlibpath_var=LD_LIBRARY_PATH fi ;; sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) - version_type=freebsd-elf + version_type=sco need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=yes hardcode_into_libs=yes - if test "$with_gnu_ld" = yes; then + if test yes = "$with_gnu_ld"; then sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' else sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' @@ -2859,7 +3079,7 @@ tpf*) version_type=linux # correct to gnu/linux during the next big refactor need_lib_prefix=no need_version=no - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' shlibpath_var=LD_LIBRARY_PATH shlibpath_overrides_runpath=no hardcode_into_libs=yes @@ -2867,8 +3087,8 @@ tpf*) uts4*) version_type=linux # correct to gnu/linux during the next big refactor - library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' - soname_spec='${libname}${release}${shared_ext}$major' + library_names_spec='$libname$release$shared_ext$versuffix $libname$release$shared_ext$major $libname$shared_ext' + soname_spec='$libname$release$shared_ext$major' shlibpath_var=LD_LIBRARY_PATH ;; @@ -2877,20 +3097,30 @@ uts4*) ;; esac AC_MSG_RESULT([$dynamic_linker]) -test "$dynamic_linker" = no && can_build_shared=no +test no = "$dynamic_linker" && can_build_shared=no variables_saved_for_relink="PATH $shlibpath_var $runpath_var" -if test "$GCC" = yes; then +if test yes = "$GCC"; then variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" fi -if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then - sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" +if test set = "${lt_cv_sys_lib_search_path_spec+set}"; then + sys_lib_search_path_spec=$lt_cv_sys_lib_search_path_spec fi -if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then - sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" + +if test set = "${lt_cv_sys_lib_dlsearch_path_spec+set}"; then + sys_lib_dlsearch_path_spec=$lt_cv_sys_lib_dlsearch_path_spec fi +# remember unaugmented sys_lib_dlsearch_path content for libtool script decls... +configure_time_dlsearch_path=$sys_lib_dlsearch_path_spec + +# ... but it needs LT_SYS_LIBRARY_PATH munging for other configure-time code +func_munge_path_list sys_lib_dlsearch_path_spec "$LT_SYS_LIBRARY_PATH" + +# to be used as default LT_SYS_LIBRARY_PATH value in generated libtool +configure_time_lt_sys_library_path=$LT_SYS_LIBRARY_PATH + _LT_DECL([], [variables_saved_for_relink], [1], [Variables whose values should be saved in libtool wrapper scripts and restored at link time]) @@ -2923,39 +3153,41 @@ _LT_DECL([], [hardcode_into_libs], [0], [Whether we should hardcode library paths into libraries]) _LT_DECL([], [sys_lib_search_path_spec], [2], [Compile-time system search path for libraries]) -_LT_DECL([], [sys_lib_dlsearch_path_spec], [2], - [Run-time system search path for libraries]) +_LT_DECL([sys_lib_dlsearch_path_spec], [configure_time_dlsearch_path], [2], + [Detected run-time system search path for libraries]) +_LT_DECL([], [configure_time_lt_sys_library_path], [2], + [Explicit LT_SYS_LIBRARY_PATH set during ./configure time]) ])# _LT_SYS_DYNAMIC_LINKER # _LT_PATH_TOOL_PREFIX(TOOL) # -------------------------- -# find a file program which can recognize shared library +# find a file program that can recognize shared library AC_DEFUN([_LT_PATH_TOOL_PREFIX], [m4_require([_LT_DECL_EGREP])dnl AC_MSG_CHECKING([for $1]) AC_CACHE_VAL(lt_cv_path_MAGIC_CMD, [case $MAGIC_CMD in [[\\/*] | ?:[\\/]*]) - lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. + lt_cv_path_MAGIC_CMD=$MAGIC_CMD # Let the user override the test with a path. ;; *) - lt_save_MAGIC_CMD="$MAGIC_CMD" - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + lt_save_MAGIC_CMD=$MAGIC_CMD + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR dnl $ac_dummy forces splitting on constant user-supplied paths. dnl POSIX.2 word splitting is done only on the output of word expansions, dnl not every word. This closes a longstanding sh security hole. ac_dummy="m4_if([$2], , $PATH, [$2])" for ac_dir in $ac_dummy; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. - if test -f $ac_dir/$1; then - lt_cv_path_MAGIC_CMD="$ac_dir/$1" + if test -f "$ac_dir/$1"; then + lt_cv_path_MAGIC_CMD=$ac_dir/"$1" if test -n "$file_magic_test_file"; then case $deplibs_check_method in "file_magic "*) file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` - MAGIC_CMD="$lt_cv_path_MAGIC_CMD" + MAGIC_CMD=$lt_cv_path_MAGIC_CMD if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | $EGREP "$file_magic_regex" > /dev/null; then : @@ -2978,11 +3210,11 @@ _LT_EOF break fi done - IFS="$lt_save_ifs" - MAGIC_CMD="$lt_save_MAGIC_CMD" + IFS=$lt_save_ifs + MAGIC_CMD=$lt_save_MAGIC_CMD ;; esac]) -MAGIC_CMD="$lt_cv_path_MAGIC_CMD" +MAGIC_CMD=$lt_cv_path_MAGIC_CMD if test -n "$MAGIC_CMD"; then AC_MSG_RESULT($MAGIC_CMD) else @@ -3000,7 +3232,7 @@ dnl AC_DEFUN([AC_PATH_TOOL_PREFIX], []) # _LT_PATH_MAGIC # -------------- -# find a file program which can recognize a shared library +# find a file program that can recognize a shared library m4_defun([_LT_PATH_MAGIC], [_LT_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH) if test -z "$lt_cv_path_MAGIC_CMD"; then @@ -3027,16 +3259,16 @@ m4_require([_LT_PROG_ECHO_BACKSLASH])dnl AC_ARG_WITH([gnu-ld], [AS_HELP_STRING([--with-gnu-ld], [assume the C compiler uses GNU ld @<:@default=no@:>@])], - [test "$withval" = no || with_gnu_ld=yes], + [test no = "$withval" || with_gnu_ld=yes], [with_gnu_ld=no])dnl ac_prog=ld -if test "$GCC" = yes; then +if test yes = "$GCC"; then # Check if gcc -print-prog-name=ld gives a path. AC_MSG_CHECKING([for ld used by $CC]) case $host in *-*-mingw*) - # gcc leaves a trailing carriage return which upsets mingw + # gcc leaves a trailing carriage return, which upsets mingw ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; *) ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; @@ -3050,7 +3282,7 @@ if test "$GCC" = yes; then while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` done - test -z "$LD" && LD="$ac_prog" + test -z "$LD" && LD=$ac_prog ;; "") # If it fails, then pretend we aren't using GCC. @@ -3061,37 +3293,37 @@ if test "$GCC" = yes; then with_gnu_ld=unknown ;; esac -elif test "$with_gnu_ld" = yes; then +elif test yes = "$with_gnu_ld"; then AC_MSG_CHECKING([for GNU ld]) else AC_MSG_CHECKING([for non-GNU ld]) fi AC_CACHE_VAL(lt_cv_path_LD, [if test -z "$LD"; then - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then - lt_cv_path_LD="$ac_dir/$ac_prog" + lt_cv_path_LD=$ac_dir/$ac_prog # Check to see if the program is GNU ld. I'd rather use --version, # but apparently some variants of GNU ld only accept -v. # Break only if it was the GNU/non-GNU ld that we prefer. case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in *GNU* | *'with BFD'*) - test "$with_gnu_ld" != no && break + test no != "$with_gnu_ld" && break ;; *) - test "$with_gnu_ld" != yes && break + test yes != "$with_gnu_ld" && break ;; esac fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs else - lt_cv_path_LD="$LD" # Let the user override the test with a path. + lt_cv_path_LD=$LD # Let the user override the test with a path. fi]) -LD="$lt_cv_path_LD" +LD=$lt_cv_path_LD if test -n "$LD"; then AC_MSG_RESULT($LD) else @@ -3145,13 +3377,13 @@ esac reload_cmds='$LD$reload_flag -o $output$reload_objs' case $host_os in cygwin* | mingw* | pw32* | cegcc*) - if test "$GCC" != yes; then + if test yes != "$GCC"; then reload_cmds=false fi ;; darwin*) - if test "$GCC" = yes; then - reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' + if test yes = "$GCC"; then + reload_cmds='$LTCC $LTCFLAGS -nostdlib $wl-r -o $output$reload_objs' else reload_cmds='$LD$reload_flag -o $output$reload_objs' fi @@ -3162,6 +3394,43 @@ _LT_TAGDECL([], [reload_cmds], [2])dnl ])# _LT_CMD_RELOAD +# _LT_PATH_DD +# ----------- +# find a working dd +m4_defun([_LT_PATH_DD], +[AC_CACHE_CHECK([for a working dd], [ac_cv_path_lt_DD], +[printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +: ${lt_DD:=$DD} +AC_PATH_PROGS_FEATURE_CHECK([lt_DD], [dd], +[if "$ac_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && ac_cv_path_lt_DD="$ac_path_lt_DD" ac_path_lt_DD_found=: +fi]) +rm -f conftest.i conftest2.i conftest.out]) +])# _LT_PATH_DD + + +# _LT_CMD_TRUNCATE +# ---------------- +# find command to truncate a binary pipe +m4_defun([_LT_CMD_TRUNCATE], +[m4_require([_LT_PATH_DD]) +AC_CACHE_CHECK([how to truncate binary pipes], [lt_cv_truncate_bin], +[printf 0123456789abcdef0123456789abcdef >conftest.i +cat conftest.i conftest.i >conftest2.i +lt_cv_truncate_bin= +if "$ac_cv_path_lt_DD" bs=32 count=1 <conftest2.i >conftest.out 2>/dev/null; then + cmp -s conftest.i conftest.out \ + && lt_cv_truncate_bin="$ac_cv_path_lt_DD bs=4096 count=1" +fi +rm -f conftest.i conftest2.i conftest.out +test -z "$lt_cv_truncate_bin" && lt_cv_truncate_bin="$SED -e 4q"]) +_LT_DECL([lt_truncate_bin], [lt_cv_truncate_bin], [1], + [Command to truncate a binary pipe]) +])# _LT_CMD_TRUNCATE + + # _LT_CHECK_MAGIC_METHOD # ---------------------- # how to check for library dependencies @@ -3177,13 +3446,13 @@ lt_cv_deplibs_check_method='unknown' # Need to set the preceding variable on all platforms that support # interlibrary dependencies. # 'none' -- dependencies not supported. -# `unknown' -- same as none, but documents that we really don't know. +# 'unknown' -- same as none, but documents that we really don't know. # 'pass_all' -- all dependencies passed with no checks. # 'test_compile' -- check by making test program. # 'file_magic [[regex]]' -- check by looking for files in library path -# which responds to the $file_magic_cmd with a given extended regex. -# If you have `file' or equivalent on your system and you're not sure -# whether `pass_all' will *always* work, you probably want this one. +# that responds to the $file_magic_cmd with a given extended regex. +# If you have 'file' or equivalent on your system and you're not sure +# whether 'pass_all' will *always* work, you probably want this one. case $host_os in aix[[4-9]]*) @@ -3210,8 +3479,7 @@ mingw* | pw32*) # Base MSYS/MinGW do not provide the 'file' command needed by # func_win32_libid shell function, so use a weaker test based on 'objdump', # unless we find 'file', for example because we are cross-compiling. - # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. - if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then + if ( file / ) >/dev/null 2>&1; then lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' lt_cv_file_magic_cmd='func_win32_libid' else @@ -3247,10 +3515,6 @@ freebsd* | dragonfly*) fi ;; -gnu*) - lt_cv_deplibs_check_method=pass_all - ;; - haiku*) lt_cv_deplibs_check_method=pass_all ;; @@ -3289,11 +3553,11 @@ irix5* | irix6* | nonstopux*) ;; # This must be glibc/ELF. -linux* | k*bsd*-gnu | kopensolaris*-gnu) +linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) lt_cv_deplibs_check_method=pass_all ;; -netbsd*) +netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' else @@ -3311,8 +3575,8 @@ newos6*) lt_cv_deplibs_check_method=pass_all ;; -openbsd*) - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then +openbsd* | bitrig*) + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|\.so|_pic\.a)$' else lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so\.[[0-9]]+\.[[0-9]]+|_pic\.a)$' @@ -3365,6 +3629,9 @@ sysv4 | sysv4.3*) tpf*) lt_cv_deplibs_check_method=pass_all ;; +os2*) + lt_cv_deplibs_check_method=pass_all + ;; esac ]) @@ -3405,33 +3672,38 @@ AC_DEFUN([LT_PATH_NM], AC_CACHE_CHECK([for BSD- or MS-compatible name lister (nm)], lt_cv_path_NM, [if test -n "$NM"; then # Let the user override the test. - lt_cv_path_NM="$NM" + lt_cv_path_NM=$NM else - lt_nm_to_check="${ac_tool_prefix}nm" + lt_nm_to_check=${ac_tool_prefix}nm if test -n "$ac_tool_prefix" && test "$build" = "$host"; then lt_nm_to_check="$lt_nm_to_check nm" fi for lt_tmp_nm in $lt_nm_to_check; do - lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR + lt_save_ifs=$IFS; IFS=$PATH_SEPARATOR for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs test -z "$ac_dir" && ac_dir=. - tmp_nm="$ac_dir/$lt_tmp_nm" - if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then + tmp_nm=$ac_dir/$lt_tmp_nm + if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext"; then # Check to see if the nm accepts a BSD-compat flag. - # Adding the `sed 1q' prevents false positives on HP-UX, which says: + # Adding the 'sed 1q' prevents false positives on HP-UX, which says: # nm: unknown option "B" ignored # Tru64's nm complains that /dev/null is an invalid object file - case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in - */dev/null* | *'Invalid file or object type'*) + # MSYS converts /dev/null to NUL, MinGW nm treats NUL as empty + case $build_os in + mingw*) lt_bad_file=conftest.nm/nofile ;; + *) lt_bad_file=/dev/null ;; + esac + case `"$tmp_nm" -B $lt_bad_file 2>&1 | sed '1q'` in + *$lt_bad_file* | *'Invalid file or object type'*) lt_cv_path_NM="$tmp_nm -B" - break + break 2 ;; *) case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in */dev/null*) lt_cv_path_NM="$tmp_nm -p" - break + break 2 ;; *) lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but @@ -3442,21 +3714,21 @@ else esac fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs done : ${lt_cv_path_NM=no} fi]) -if test "$lt_cv_path_NM" != "no"; then - NM="$lt_cv_path_NM" +if test no != "$lt_cv_path_NM"; then + NM=$lt_cv_path_NM else # Didn't find any BSD compatible name lister, look for dumpbin. if test -n "$DUMPBIN"; then : # Let the user override the test. else AC_CHECK_TOOLS(DUMPBIN, [dumpbin "link -dump"], :) - case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in + case `$DUMPBIN -symbols -headers /dev/null 2>&1 | sed '1q'` in *COFF*) - DUMPBIN="$DUMPBIN -symbols" + DUMPBIN="$DUMPBIN -symbols -headers" ;; *) DUMPBIN=: @@ -3464,8 +3736,8 @@ else esac fi AC_SUBST([DUMPBIN]) - if test "$DUMPBIN" != ":"; then - NM="$DUMPBIN" + if test : != "$DUMPBIN"; then + NM=$DUMPBIN fi fi test -z "$NM" && NM=nm @@ -3511,8 +3783,8 @@ lt_cv_sharedlib_from_linklib_cmd, case $host_os in cygwin* | mingw* | pw32* | cegcc*) - # two different shell functions defined in ltmain.sh - # decide which to use based on capabilities of $DLLTOOL + # two different shell functions defined in ltmain.sh; + # decide which one to use based on capabilities of $DLLTOOL case `$DLLTOOL --help 2>&1` in *--identify-strict*) lt_cv_sharedlib_from_linklib_cmd=func_cygming_dll_for_implib @@ -3524,7 +3796,7 @@ cygwin* | mingw* | pw32* | cegcc*) ;; *) # fallback: assume linklib IS sharedlib - lt_cv_sharedlib_from_linklib_cmd="$ECHO" + lt_cv_sharedlib_from_linklib_cmd=$ECHO ;; esac ]) @@ -3551,13 +3823,28 @@ AC_CACHE_CHECK([if $MANIFEST_TOOL is a manifest tool], [lt_cv_path_mainfest_tool lt_cv_path_mainfest_tool=yes fi rm -f conftest*]) -if test "x$lt_cv_path_mainfest_tool" != xyes; then +if test yes != "$lt_cv_path_mainfest_tool"; then MANIFEST_TOOL=: fi _LT_DECL([], [MANIFEST_TOOL], [1], [Manifest tool])dnl ])# _LT_PATH_MANIFEST_TOOL +# _LT_DLL_DEF_P([FILE]) +# --------------------- +# True iff FILE is a Windows DLL '.def' file. +# Keep in sync with func_dll_def_p in the libtool script +AC_DEFUN([_LT_DLL_DEF_P], +[dnl + test DEF = "`$SED -n dnl + -e '\''s/^[[ ]]*//'\'' dnl Strip leading whitespace + -e '\''/^\(;.*\)*$/d'\'' dnl Delete empty lines and comments + -e '\''s/^\(EXPORTS\|LIBRARY\)\([[ ]].*\)*$/DEF/p'\'' dnl + -e q dnl Only consider the first "real" line + $1`" dnl +])# _LT_DLL_DEF_P + + # LT_LIB_M # -------- # check for math library @@ -3569,11 +3856,11 @@ case $host in # These system don't have libm, or don't need it ;; *-ncr-sysv4.3*) - AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM="-lmw") + AC_CHECK_LIB(mw, _mwvalidcheckl, LIBM=-lmw) AC_CHECK_LIB(m, cos, LIBM="$LIBM -lm") ;; *) - AC_CHECK_LIB(m, cos, LIBM="-lm") + AC_CHECK_LIB(m, cos, LIBM=-lm) ;; esac AC_SUBST([LIBM]) @@ -3592,7 +3879,7 @@ m4_defun([_LT_COMPILER_NO_RTTI], _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= -if test "$GCC" = yes; then +if test yes = "$GCC"; then case $cc_basename in nvcc*) _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -Xcompiler -fno-builtin' ;; @@ -3644,7 +3931,7 @@ cygwin* | mingw* | pw32* | cegcc*) symcode='[[ABCDGISTW]]' ;; hpux*) - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then symcode='[[ABCDEGRST]]' fi ;; @@ -3677,14 +3964,44 @@ case `$NM -V 2>&1` in symcode='[[ABCDGIRSTW]]' ;; esac +if test "$lt_cv_nm_interface" = "MS dumpbin"; then + # Gets list of data symbols to import. + lt_cv_sys_global_symbol_to_import="sed -n -e 's/^I .* \(.*\)$/\1/p'" + # Adjust the below global symbol transforms to fixup imported variables. + lt_cdecl_hook=" -e 's/^I .* \(.*\)$/extern __declspec(dllimport) char \1;/p'" + lt_c_name_hook=" -e 's/^I .* \(.*\)$/ {\"\1\", (void *) 0},/p'" + lt_c_name_lib_hook="\ + -e 's/^I .* \(lib.*\)$/ {\"\1\", (void *) 0},/p'\ + -e 's/^I .* \(.*\)$/ {\"lib\1\", (void *) 0},/p'" +else + # Disable hooks by default. + lt_cv_sys_global_symbol_to_import= + lt_cdecl_hook= + lt_c_name_hook= + lt_c_name_lib_hook= +fi + # Transform an extracted symbol line into a proper C declaration. # Some systems (esp. on ia64) link data and code symbols differently, # so use this general approach. -lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" +lt_cv_sys_global_symbol_to_cdecl="sed -n"\ +$lt_cdecl_hook\ +" -e 's/^T .* \(.*\)$/extern int \1();/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/extern char \1;/p'" # Transform an extracted symbol line into symbol name and symbol address -lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p'" -lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([[^ ]]*\)[[ ]]*$/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \(lib[[^ ]]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/ {\"lib\2\", (void *) \&\2},/p'" +lt_cv_sys_global_symbol_to_c_name_address="sed -n"\ +$lt_c_name_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/p'" + +# Transform an extracted symbol line into symbol name with lib prefix and +# symbol address. +lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n"\ +$lt_c_name_lib_hook\ +" -e 's/^: \(.*\) .*$/ {\"\1\", (void *) 0},/p'"\ +" -e 's/^$symcode$symcode* .* \(lib.*\)$/ {\"\1\", (void *) \&\1},/p'"\ +" -e 's/^$symcode$symcode* .* \(.*\)$/ {\"lib\1\", (void *) \&\1},/p'" # Handle CRLF in mingw tool chain opt_cr= @@ -3702,21 +4019,24 @@ for ac_symprfx in "" "_"; do # Write the raw and C identifiers. if test "$lt_cv_nm_interface" = "MS dumpbin"; then - # Fake it for dumpbin and say T for any non-static function - # and D for any global variable. + # Fake it for dumpbin and say T for any non-static function, + # D for any global variable and I for any imported variable. # Also find C++ and __fastcall symbols from MSVC++, # which start with @ or ?. lt_cv_sys_global_symbol_pipe="$AWK ['"\ " {last_section=section; section=\$ 3};"\ " /^COFF SYMBOL TABLE/{for(i in hide) delete hide[i]};"\ " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ +" /^ *Symbol name *: /{split(\$ 0,sn,\":\"); si=substr(sn[2],2)};"\ +" /^ *Type *: code/{print \"T\",si,substr(si,length(prfx))};"\ +" /^ *Type *: data/{print \"I\",si,substr(si,length(prfx))};"\ " \$ 0!~/External *\|/{next};"\ " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ " {if(hide[section]) next};"\ -" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ -" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ -" s[1]~/^[@?]/{print s[1], s[1]; next};"\ -" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ +" {f=\"D\"}; \$ 0~/\(\).*\|/{f=\"T\"};"\ +" {split(\$ 0,a,/\||\r/); split(a[2],s)};"\ +" s[1]~/^[@?]/{print f,s[1],s[1]; next};"\ +" s[1]~prfx {split(s[1],t,\"@\"); print f,t[1],substr(t[1],length(prfx))}"\ " ' prfx=^$ac_symprfx]" else lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[[ ]]\($symcode$symcode*\)[[ ]][[ ]]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" @@ -3743,7 +4063,8 @@ _LT_EOF if AC_TRY_EVAL(ac_compile); then # Now try to grab the symbols. nlist=conftest.nm - if AC_TRY_EVAL(NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) && test -s "$nlist"; then + $ECHO "$as_me:$LINENO: $NM conftest.$ac_objext | $lt_cv_sys_global_symbol_pipe > $nlist" >&AS_MESSAGE_LOG_FD + if eval "$NM" conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist 2>&AS_MESSAGE_LOG_FD && test -s "$nlist"; then # Try sorting and uniquifying the output. if sort "$nlist" | uniq > "$nlist"T; then mv -f "$nlist"T "$nlist" @@ -3756,11 +4077,11 @@ _LT_EOF if $GREP ' nm_test_func$' "$nlist" >/dev/null; then cat <<_LT_EOF > conftest.$ac_ext /* Keep this code in sync between libtool.m4, ltmain, lt_system.h, and tests. */ -#if defined(_WIN32) || defined(__CYGWIN__) || defined(_WIN32_WCE) -/* DATA imports from DLLs on WIN32 con't be const, because runtime +#if defined _WIN32 || defined __CYGWIN__ || defined _WIN32_WCE +/* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs. */ # define LT@&t@_DLSYM_CONST -#elif defined(__osf__) +#elif defined __osf__ /* This system does not cope well with relocations in const data. */ # define LT@&t@_DLSYM_CONST #else @@ -3786,7 +4107,7 @@ lt__PROGRAM__LTX_preloaded_symbols[[]] = { { "@PROGRAM@", (void *) 0 }, _LT_EOF - $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext + $SED "s/^$symcode$symcode* .* \(.*\)$/ {\"\1\", (void *) \&\1},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext cat <<\_LT_EOF >> conftest.$ac_ext {0, (void *) 0} }; @@ -3806,9 +4127,9 @@ _LT_EOF mv conftest.$ac_objext conftstm.$ac_objext lt_globsym_save_LIBS=$LIBS lt_globsym_save_CFLAGS=$CFLAGS - LIBS="conftstm.$ac_objext" + LIBS=conftstm.$ac_objext CFLAGS="$CFLAGS$_LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)" - if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then + if AC_TRY_EVAL(ac_link) && test -s conftest$ac_exeext; then pipe_works=yes fi LIBS=$lt_globsym_save_LIBS @@ -3829,7 +4150,7 @@ _LT_EOF rm -rf conftest* conftst* # Do not use the global_symbol_pipe unless it works. - if test "$pipe_works" = yes; then + if test yes = "$pipe_works"; then break else lt_cv_sys_global_symbol_pipe= @@ -3856,12 +4177,16 @@ _LT_DECL([global_symbol_pipe], [lt_cv_sys_global_symbol_pipe], [1], [Take the output of nm and produce a listing of raw symbols and C names]) _LT_DECL([global_symbol_to_cdecl], [lt_cv_sys_global_symbol_to_cdecl], [1], [Transform the output of nm in a proper C declaration]) +_LT_DECL([global_symbol_to_import], [lt_cv_sys_global_symbol_to_import], [1], + [Transform the output of nm into a list of symbols to manually relocate]) _LT_DECL([global_symbol_to_c_name_address], [lt_cv_sys_global_symbol_to_c_name_address], [1], [Transform the output of nm in a C name address pair]) _LT_DECL([global_symbol_to_c_name_address_lib_prefix], [lt_cv_sys_global_symbol_to_c_name_address_lib_prefix], [1], [Transform the output of nm in a C name address pair when lib prefix is needed]) +_LT_DECL([nm_interface], [lt_cv_nm_interface], [1], + [The name lister interface]) _LT_DECL([], [nm_file_list_spec], [1], [Specify filename containing input files for $NM]) ]) # _LT_CMD_GLOBAL_SYMBOLS @@ -3877,17 +4202,18 @@ _LT_TAGVAR(lt_prog_compiler_static, $1)= m4_if([$1], [CXX], [ # C++ specific cases for pic, static, wl, etc. - if test "$GXX" = yes; then + if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) @@ -3898,8 +4224,8 @@ m4_if([$1], [CXX], [ ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac @@ -3915,6 +4241,11 @@ m4_if([$1], [CXX], [ # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac ;; darwin* | rhapsody*) # PIC is the default on this platform @@ -3964,7 +4295,7 @@ m4_if([$1], [CXX], [ case $host_os in aix[[4-9]]*) # All AIX code is PIC. - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else @@ -4005,14 +4336,14 @@ m4_if([$1], [CXX], [ case $cc_basename in CC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' - if test "$host_cpu" != ia64; then + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' + if test ia64 != "$host_cpu"; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='+Z' fi ;; aCC*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' case $host_cpu in hppa*64*|ia64*) # +Z the default @@ -4041,7 +4372,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # KAI C++ Compiler @@ -4049,7 +4380,7 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; ecpc* ) - # old Intel C++ for x86_64 which still supported -KPIC. + # old Intel C++ for x86_64, which still supported -KPIC. _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' @@ -4105,7 +4436,7 @@ m4_if([$1], [CXX], [ ;; esac ;; - netbsd*) + netbsd* | netbsdelf*-gnu) ;; *qnx* | *nto*) # QNX uses GNU C++, but need to define -shared option too, otherwise @@ -4194,17 +4525,18 @@ m4_if([$1], [CXX], [ fi ], [ - if test "$GCC" = yes; then + if test yes = "$GCC"; then _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' case $host_os in aix*) # All AIX code is PIC. - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' ;; amigaos*) @@ -4215,8 +4547,8 @@ m4_if([$1], [CXX], [ ;; m68k) # FIXME: we need at least 68020 code to build shared libraries, but - # adding the `-m68020' flag to GCC prevents building anything better, - # like `-m68040'. + # adding the '-m68020' flag to GCC prevents building anything better, + # like '-m68040'. _LT_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4' ;; esac @@ -4233,6 +4565,11 @@ m4_if([$1], [CXX], [ # (--disable-auto-import) libraries m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac ;; darwin* | rhapsody*) @@ -4303,7 +4640,7 @@ m4_if([$1], [CXX], [ case $host_os in aix*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # AIX 5 now supports IA64 processor _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' else @@ -4311,11 +4648,30 @@ m4_if([$1], [CXX], [ fi ;; + darwin* | rhapsody*) + # PIC is the default on this platform + # Common symbols not allowed in MH_DYLIB files + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common' + case $cc_basename in + nagfor*) + # NAG Fortran compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,-Wl,,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' + ;; + esac + ;; + mingw* | cygwin* | pw32* | os2* | cegcc*) # This hack is so that the source file can tell whether it is being # built for inclusion in a dll (and should export symbols for example). m4_if([$1], [GCJ], [], [_LT_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT']) + case $host_os in + os2*) + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-static' + ;; + esac ;; hpux9* | hpux10* | hpux11*) @@ -4331,7 +4687,7 @@ m4_if([$1], [CXX], [ ;; esac # Is there a better lt_prog_compiler_static that works with the bundled CC? - _LT_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive' + _LT_TAGVAR(lt_prog_compiler_static, $1)='$wl-a ${wl}archive' ;; irix5* | irix6* | nonstopux*) @@ -4340,14 +4696,20 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_static, $1)='-non_shared' ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in - # old Intel for x86_64 which still supported -KPIC. + # old Intel for x86_64, which still supported -KPIC. ecc*) _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' _LT_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' ;; + # flang / f18. f95 an alias for gfortran or flang on Debian + flang* | f18* | f95*) + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; # icc used to be incompatible with GCC. # ICC 10 doesn't accept -KPIC any more. icc* | ifort*) @@ -4367,6 +4729,12 @@ m4_if([$1], [CXX], [ _LT_TAGVAR(lt_prog_compiler_pic, $1)='-PIC' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' ;; + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,' + _LT_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC' + _LT_TAGVAR(lt_prog_compiler_static, $1)='-static' + ;; pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group compilers (*not* the Pentium gcc compiler, # which looks to be a dead project) @@ -4464,7 +4832,7 @@ m4_if([$1], [CXX], [ ;; sysv4*MP*) - if test -d /usr/nec ;then + if test -d /usr/nec; then _LT_TAGVAR(lt_prog_compiler_pic, $1)='-Kconform_pic' _LT_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic' fi @@ -4493,7 +4861,7 @@ m4_if([$1], [CXX], [ fi ]) case $host_os in - # For platforms which do not support PIC, -DPIC is meaningless: + # For platforms that do not support PIC, -DPIC is meaningless: *djgpp*) _LT_TAGVAR(lt_prog_compiler_pic, $1)= ;; @@ -4559,17 +4927,21 @@ m4_if([$1], [CXX], [ case $host_os in aix[[4-9]]*) # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global defined - # symbols, whereas GNU nm marks them as "W". + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi ;; pw32*) - _LT_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds" + _LT_TAGVAR(export_symbols_cmds, $1)=$ltdll_cmds ;; cygwin* | mingw* | cegcc*) case $cc_basename in @@ -4582,6 +4954,9 @@ m4_if([$1], [CXX], [ ;; esac ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; *) _LT_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' ;; @@ -4615,9 +4990,9 @@ m4_if([$1], [CXX], [ # included in the symbol list _LT_TAGVAR(include_expsyms, $1)= # exclude_expsyms can be an extended regexp of symbols to exclude - # it will be wrapped by ` (' and `)$', so one must not match beginning or - # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', - # as well as any symbol that contains `d'. + # it will be wrapped by ' (' and ')$', so one must not match beginning or + # end of line. Example: 'a|bc|.*d.*' will exclude the symbols 'a' and 'bc', + # as well as any symbol that contains 'd'. _LT_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'] # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out # platforms (ab)use it in PIC code, but their linkers get confused if @@ -4633,7 +5008,7 @@ dnl Note also adjust exclude_expsyms for C++ above. # FIXME: the MSVC++ port hasn't been tested in a loooong time # When not using gcc, we currently assume that we are using # Microsoft Visual C++. - if test "$GCC" != yes; then + if test yes != "$GCC"; then with_gnu_ld=no fi ;; @@ -4641,9 +5016,12 @@ dnl Note also adjust exclude_expsyms for C++ above. # we just hope/assume this is gcc and not c89 (= MSVC++) with_gnu_ld=yes ;; - openbsd*) + openbsd* | bitrig*) with_gnu_ld=no ;; + linux* | k*bsd*-gnu | gnu*) + _LT_TAGVAR(link_all_deplibs, $1)=no + ;; esac _LT_TAGVAR(ld_shlibs, $1)=yes @@ -4651,7 +5029,7 @@ dnl Note also adjust exclude_expsyms for C++ above. # On some targets, GNU ld is compatible enough with the native linker # that we're better off using the native interface for both. lt_use_gnu_ld_interface=no - if test "$with_gnu_ld" = yes; then + if test yes = "$with_gnu_ld"; then case $host_os in aix*) # The AIX port of GNU ld has always aspired to compatibility @@ -4673,24 +5051,24 @@ dnl Note also adjust exclude_expsyms for C++ above. esac fi - if test "$lt_use_gnu_ld_interface" = yes; then + if test yes = "$lt_use_gnu_ld_interface"; then # If archive_cmds runs LD, not CC, wlarc should be empty - wlarc='${wl}' + wlarc='$wl' # Set some defaults for GNU ld with shared library support. These # are reset later if shared libraries are not supported. Putting them # here allows them to be overridden if necessary. runpath_var=LD_RUN_PATH - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # ancient GNU ld didn't support --whole-archive et. al. if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi supports_anon_versioning=no - case `$LD -v 2>&1` in + case `$LD -v | $SED -e 's/([^)]\+)\s\+//' 2>&1` in *GNU\ gold*) supports_anon_versioning=yes ;; *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.10.*) ;; # catch versions < 2.11 *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... @@ -4703,7 +5081,7 @@ dnl Note also adjust exclude_expsyms for C++ above. case $host_os in aix[[3-9]]*) # On AIX/PPC, the GNU linker is very broken - if test "$host_cpu" != ia64; then + if test ia64 != "$host_cpu"; then _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 @@ -4722,7 +5100,7 @@ _LT_EOF case $host_cpu in powerpc) # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) @@ -4738,7 +5116,7 @@ _LT_EOF _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -4748,7 +5126,7 @@ _LT_EOF # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes @@ -4756,61 +5134,89 @@ _LT_EOF _LT_TAGVAR(exclude_expsyms, $1)=['[_]+GLOBAL_OFFSET_TABLE_|[_]+GLOBAL__[FID]_.*|[_]+head_[A-Za-z0-9_]+_dll|[A-Za-z0-9_]+_dll_iname'] if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) tmp_diet=no - if test "$host_os" = linux-dietlibc; then + if test linux-dietlibc = "$host_os"; then case $cc_basename in diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) esac fi if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ - && test "$tmp_diet" = no + && test no = "$tmp_diet" then tmp_addflag=' $pic_flag' tmp_sharedflag='-shared' case $cc_basename,$host_cpu in pgcc*) # Portland Group C compiler - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag' ;; pgf77* | pgf90* | pgf95* | pgfortran*) # Portland Group f77 and f90 compilers - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' tmp_addflag=' $pic_flag -Mnomain' ;; ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 tmp_addflag=' -i_dynamic' ;; @@ -4821,42 +5227,47 @@ _LT_EOF lf95*) # Lahey Fortran 8.1 _LT_TAGVAR(whole_archive_flag_spec, $1)= tmp_sharedflag='--shared' ;; + nagfor*) # NAGFOR 5.3 + tmp_sharedflag='-Wl,-shared' ;; xl[[cC]]* | bgxl[[cC]]* | mpixl[[cC]]*) # IBM XL C 8.0 on PPC (deal with xlf below) tmp_sharedflag='-qmkshrobj' tmp_addflag= ;; nvcc*) # Cuda Compiler Driver 2.2 - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes ;; esac case `$CC -V 2>&1 | sed 5q` in *Sun\ C*) # Sun C 5.9 - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes tmp_sharedflag='-G' ;; *Sun\ F*) # Sun Fortran 8.3 tmp_sharedflag='-G' ;; esac - _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then + if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi case $cc_basename in + tcc*) + _LT_TAGVAR(export_dynamic_flag_spec, $1)='-rdynamic' + ;; xlf* | bgf* | bgxlf* | mpixlf*) # IBM XL Fortran 10.1 on PPC cannot create shared libs itself _LT_TAGVAR(whole_archive_flag_spec, $1)='--whole-archive$convenience --no-whole-archive' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(archive_cmds, $1)='$LD -shared $libobjs $deplibs $linker_flags -soname $soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then + if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $LD -shared $libobjs $deplibs $linker_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' fi ;; esac @@ -4865,13 +5276,13 @@ _LT_EOF fi ;; - netbsd*) + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' wlarc= else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' fi ;; @@ -4889,8 +5300,8 @@ _LT_EOF _LT_EOF elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -4902,7 +5313,7 @@ _LT_EOF _LT_TAGVAR(ld_shlibs, $1)=no cat <<_LT_EOF 1>&2 -*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not +*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 cannot *** reliably create shared libraries on SCO systems. Therefore, libtool *** is disabling shared libraries support. We urge you to upgrade GNU *** binutils to release 2.16.91.0.3 or newer. Another option is to modify @@ -4917,9 +5328,9 @@ _LT_EOF # DT_RUNPATH tag from executables and libraries. But doing so # requires that you compile everything twice, which is a pain. if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -4936,15 +5347,15 @@ _LT_EOF *) if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi ;; esac - if test "$_LT_TAGVAR(ld_shlibs, $1)" = no; then + if test no = "$_LT_TAGVAR(ld_shlibs, $1)"; then runpath_var= _LT_TAGVAR(hardcode_libdir_flag_spec, $1)= _LT_TAGVAR(export_dynamic_flag_spec, $1)= @@ -4960,7 +5371,7 @@ _LT_EOF # Note: this linker hardcodes the directories in LIBPATH if there # are no directories specified by -L. _LT_TAGVAR(hardcode_minus_L, $1)=yes - if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then + if test yes = "$GCC" && test -z "$lt_prog_compiler_static"; then # Neither direct hardcoding nor static linking is supported with a # broken collect2. _LT_TAGVAR(hardcode_direct, $1)=unsupported @@ -4968,34 +5379,57 @@ _LT_EOF ;; aix[[4-9]]*) - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' - no_entry_flag="" + no_entry_flag= else # If we're using GNU nm, then we don't want the "-C" option. - # -C means demangle to AIX nm, but means don't demangle with GNU nm - # Also, AIX nm treats weak defined symbols like other global - # defined symbols, whereas GNU nm marks them as "W". + # -C means demangle to GNU nm, but means don't demangle to AIX nm. + # Without the "-l" option, or with the "-B" option, AIX nm treats + # weak defined symbols like other global defined symbols, whereas + # GNU nm marks them as "W". + # While the 'weak' keyword is ignored in the Export File, we need + # it in the Import File for the 'aix-soname' feature, so we have + # to replace the "-B" option with "-P" for AIX nm. if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && ([substr](\$ 3,1,1) != ".")) { if (\$ 2 == "W") { print \$ 3 " weak" } else { print \$ 3 } } }'\'' | sort -u > $export_symbols' else - _LT_TAGVAR(export_symbols_cmds, $1)='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && ([substr](\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' + _LT_TAGVAR(export_symbols_cmds, $1)='`func_echo_all $NM | $SED -e '\''s/B\([[^B]]*\)$/P\1/'\''` -PCpgl $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) && ([substr](\$ 1,1,1) != ".")) { if ((\$ 2 == "W") || (\$ 2 == "V") || (\$ 2 == "Z")) { print \$ 1 " weak" } else { print \$ 1 } } }'\'' | sort -u > $export_symbols' fi aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do - if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then + if (test x-brtl = "x$ld_flag" || test x-Wl,-brtl = "x$ld_flag"); then aix_use_runtimelinking=yes break fi done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi ;; esac @@ -5014,13 +5448,21 @@ _LT_EOF _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # traditional, no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac - if test "$GCC" = yes; then + if test yes = "$GCC"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` + collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then @@ -5039,61 +5481,80 @@ _LT_EOF ;; esac shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag="$shared_flag "'$wl-G' fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' else # not using gcc - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' else - shared_flag='${wl}-bM:SRE' + shared_flag='$wl-bM:SRE' fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' fi fi - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to export. _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. _LT_TAGVAR(allow_undefined_flag, $1)='-berok' # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared libraries. - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared libraries. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; @@ -5102,7 +5563,7 @@ _LT_EOF case $host_cpu in powerpc) # see comment about AmigaOS4 .so support - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='' ;; m68k) @@ -5132,16 +5593,17 @@ _LT_EOF # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" + shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - sed -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - sed -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes @@ -5150,18 +5612,18 @@ _LT_EOF # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' ;; *) # Assume MSVC wrapper @@ -5170,7 +5632,7 @@ _LT_EOF # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" + shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. _LT_TAGVAR(archive_cmds, $1)='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' # The linker will automatically build a .lib file if we build a DLL. @@ -5220,33 +5682,33 @@ _LT_EOF ;; hpux9*) - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; hpux10*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + if test yes,no = "$GCC,$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. _LT_TAGVAR(hardcode_minus_L, $1)=yes @@ -5254,25 +5716,25 @@ _LT_EOF ;; hpux11*) - if test "$GCC" = yes && test "$with_gnu_ld" = no; then + if test yes,no = "$GCC,$with_gnu_ld"; then case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags' ;; esac else case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' ;; *) m4_if($1, [], [ @@ -5280,14 +5742,14 @@ _LT_EOF # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) _LT_LINKER_OPTION([if $CC understands -b], _LT_TAGVAR(lt_cv_prog_compiler__b, $1), [-b], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags'], [_LT_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'])], - [_LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) + [_LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $libobjs $deplibs $compiler_flags']) ;; esac fi - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in @@ -5298,7 +5760,7 @@ _LT_EOF *) _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # hardcode_minus_L: Not really in the search PATH, # but as the default location of the library. @@ -5309,16 +5771,16 @@ _LT_EOF ;; irix5* | irix6* | nonstopux*) - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' # Try to use the -exported_symbol ld option, if it does not # work, assume that -exports_file does not work either and # implicitly export all symbols. # This should be the same for all languages, so no per-tag cache variable. AC_CACHE_CHECK([whether the $host_os linker accepts -exported_symbol], [lt_cv_irix_exported_symbol], - [save_LDFLAGS="$LDFLAGS" - LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" + [save_LDFLAGS=$LDFLAGS + LDFLAGS="$LDFLAGS -shared $wl-exported_symbol ${wl}foo $wl-update_registry $wl/dev/null" AC_LINK_IFELSE( [AC_LANG_SOURCE( [AC_LANG_CASE([C], [[int foo (void) { return 0; }]], @@ -5331,22 +5793,33 @@ _LT_EOF end]])])], [lt_cv_irix_exported_symbol=yes], [lt_cv_irix_exported_symbol=no]) - LDFLAGS="$save_LDFLAGS"]) - if test "$lt_cv_irix_exported_symbol" = yes; then - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' + LDFLAGS=$save_LDFLAGS]) + if test yes = "$lt_cv_irix_exported_symbol"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations $wl-exports_file $wl$export_symbols -o $lib' fi + _LT_TAGVAR(link_all_deplibs, $1)=no else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -exports_file $export_symbols -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes _LT_TAGVAR(link_all_deplibs, $1)=yes ;; - netbsd*) + linux*) + case $cc_basename in + tcc*) + # Fabrice Bellard et al's Tiny C Compiler + _LT_TAGVAR(ld_shlibs, $1)=yes + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + ;; + esac + ;; + + netbsd* | netbsdelf*-gnu) if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out else @@ -5360,7 +5833,7 @@ _LT_EOF newsos6) _LT_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(hardcode_direct, $1)=yes - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(hardcode_shlibpath_var, $1)=no ;; @@ -5368,27 +5841,19 @@ _LT_EOF *nto* | *qnx*) ;; - openbsd*) + openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes - if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then + if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`"; then _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags $wl-retain-symbols-file,$export_symbols' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' else - case $host_os in - openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*) - _LT_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - ;; - *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - ;; - esac + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' fi else _LT_TAGVAR(ld_shlibs, $1)=no @@ -5399,33 +5864,53 @@ _LT_EOF _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' _LT_TAGVAR(hardcode_minus_L, $1)=yes _LT_TAGVAR(allow_undefined_flag, $1)=unsupported - _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' - _LT_TAGVAR(old_archive_from_new_cmds, $1)='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes ;; osf3*) - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' fi _LT_TAGVAR(archive_cmds_need_lc, $1)='no' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: ;; osf4* | osf5*) # as osf3* with the addition of -msym flag - if test "$GCC" = yes; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $pic_flag $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + if test yes = "$GCC"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $pic_flag $libobjs $deplibs $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' else _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ - $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' + $CC -shared$allow_undefined_flag $wl-input $wl$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~$RM $lib.exp' # Both c and cxx compiler support -rpath directly _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' @@ -5436,24 +5921,24 @@ _LT_EOF solaris*) _LT_TAGVAR(no_undefined_flag, $1)=' -z defs' - if test "$GCC" = yes; then - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' + if test yes = "$GCC"; then + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $wl-z ${wl}text $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + $CC -shared $pic_flag $wl-z ${wl}text $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' else case `$CC -V 2>&1` in *"Compilers 5.0"*) wlarc='' - _LT_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' + _LT_TAGVAR(archive_cmds, $1)='$LD -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $linker_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' + $LD -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' ;; *) - wlarc='${wl}' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' + wlarc='$wl' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h $soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' + $CC -G$allow_undefined_flag -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' ;; esac fi @@ -5463,11 +5948,11 @@ _LT_EOF solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. GCC discards it without `$wl', + # but understands '-z linker_flag'. GCC discards it without '$wl', # but is careful enough not to reorder. # Supported since Solaris 2.6 (maybe 2.5.1?) - if test "$GCC" = yes; then - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + if test yes = "$GCC"; then + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' else _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' fi @@ -5477,10 +5962,10 @@ _LT_EOF ;; sunos4*) - if test "x$host_vendor" = xsequent; then + if test sequent = "$host_vendor"; then # Use $CC to link under sequent, because it throws in some extra .o # files that make .init and .fini sections work. - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h $soname -o $lib $libobjs $deplibs $compiler_flags' else _LT_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' fi @@ -5529,43 +6014,43 @@ _LT_EOF ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not + # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' - if test "$GCC" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + if test yes = "$GCC"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' else - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' fi ;; @@ -5580,17 +6065,17 @@ _LT_EOF ;; esac - if test x$host_vendor = xsni; then + if test sni = "$host_vendor"; then case $host in sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Blargedynsym' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Blargedynsym' ;; esac fi fi ]) AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) -test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no +test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no _LT_TAGVAR(with_gnu_ld, $1)=$with_gnu_ld @@ -5607,7 +6092,7 @@ x|xyes) # Assume -lc should be added _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - if test "$enable_shared" = yes && test "$GCC" = yes; then + if test yes,yes = "$GCC,$enable_shared"; then case $_LT_TAGVAR(archive_cmds, $1) in *'~'*) # FIXME: we may have to deal with multi-command sequences. @@ -5687,12 +6172,12 @@ _LT_TAGDECL([], [hardcode_libdir_flag_spec], [1], _LT_TAGDECL([], [hardcode_libdir_separator], [1], [Whether we need a single "-rpath" flag with a separated argument]) _LT_TAGDECL([], [hardcode_direct], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary]) _LT_TAGDECL([], [hardcode_direct_absolute], [0], - [Set to "yes" if using DIR/libNAME${shared_ext} during linking hardcodes + [Set to "yes" if using DIR/libNAME$shared_ext during linking hardcodes DIR into the resulting binary and the resulting library dependency is - "absolute", i.e impossible to change by setting ${shlibpath_var} if the + "absolute", i.e impossible to change by setting $shlibpath_var if the library is relocated]) _LT_TAGDECL([], [hardcode_minus_L], [0], [Set to "yes" if using the -LDIR flag during linking hardcodes DIR @@ -5733,10 +6218,10 @@ dnl [Compiler flag to generate thread safe objects]) # ------------------------ # Ensure that the configuration variables for a C compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. +# the compiler configuration to 'libtool'. m4_defun([_LT_LANG_C_CONFIG], [m4_require([_LT_DECL_EGREP])dnl -lt_save_CC="$CC" +lt_save_CC=$CC AC_LANG_PUSH(C) # Source file extension for C test sources. @@ -5776,18 +6261,18 @@ if test -n "$compiler"; then LT_SYS_DLOPEN_SELF _LT_CMD_STRIPLIB - # Report which library types will actually be built + # Report what library types will actually be built AC_MSG_CHECKING([if libtool supports shared libraries]) AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no + test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) - test "$enable_shared" = yes && enable_static=no + test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' @@ -5795,8 +6280,12 @@ if test -n "$compiler"; then ;; aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac fi ;; esac @@ -5804,13 +6293,13 @@ if test -n "$compiler"; then AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes + test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) _LT_CONFIG($1) fi AC_LANG_POP -CC="$lt_save_CC" +CC=$lt_save_CC ])# _LT_LANG_C_CONFIG @@ -5818,14 +6307,14 @@ CC="$lt_save_CC" # -------------------------- # Ensure that the configuration variables for a C++ compiler are suitably # defined. These variables are subsequently used by _LT_CONFIG to write -# the compiler configuration to `libtool'. +# the compiler configuration to 'libtool'. m4_defun([_LT_LANG_CXX_CONFIG], [m4_require([_LT_FILEUTILS_DEFAULTS])dnl m4_require([_LT_DECL_EGREP])dnl m4_require([_LT_PATH_MANIFEST_TOOL])dnl -if test -n "$CXX" && ( test "X$CXX" != "Xno" && - ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || - (test "X$CXX" != "Xg++"))) ; then +if test -n "$CXX" && ( test no != "$CXX" && + ( (test g++ = "$CXX" && `g++ -v >/dev/null 2>&1` ) || + (test g++ != "$CXX"))); then AC_PROG_CXXCPP else _lt_caught_CXX_error=yes @@ -5867,7 +6356,7 @@ _LT_TAGVAR(objext, $1)=$objext # the CXX compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_caught_CXX_error" != yes; then +if test yes != "$_lt_caught_CXX_error"; then # Code to be used in simple compile tests lt_simple_compile_test_code="int some_variable = 0;" @@ -5909,35 +6398,35 @@ if test "$_lt_caught_CXX_error" != yes; then if test -n "$compiler"; then # We don't want -fno-exception when compiling C++ code, so set the # no_builtin_flag separately - if test "$GXX" = yes; then + if test yes = "$GXX"; then _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)=' -fno-builtin' else _LT_TAGVAR(lt_prog_compiler_no_builtin_flag, $1)= fi - if test "$GXX" = yes; then + if test yes = "$GXX"; then # Set up default GNU C++ configuration LT_PATH_LD # Check if GNU C++ uses GNU ld as the underlying linker, since the # archiving commands below assume that GNU ld is being used. - if test "$with_gnu_ld" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + if test yes = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # If archive_cmds runs LD, not CC, wlarc should be empty # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to # investigate it a little bit more. (MM) - wlarc='${wl}' + wlarc='$wl' # ancient GNU ld didn't support --whole-archive et. al. if eval "`$CC -print-prog-name=ld` --help 2>&1" | $GREP 'no-whole-archive' > /dev/null; then - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' else _LT_TAGVAR(whole_archive_flag_spec, $1)= fi @@ -5956,7 +6445,7 @@ if test "$_lt_caught_CXX_error" != yes; then # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else GXX=no @@ -5973,18 +6462,30 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=no ;; aix[[4-9]]*) - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # On IA64, the linker does run time linking by default, so we don't # have to do anything special. aix_use_runtimelinking=no exp_sym_flag='-Bexport' - no_entry_flag="" + no_entry_flag= else aix_use_runtimelinking=no # Test if we are trying to use run time linking or normal # AIX style linking. If -brtl is somewhere in LDFLAGS, we - # need to do runtime linking. + # have runtime linking enabled, and use it for executables. + # For shared libraries, we enable/disable runtime linking + # depending on the kind of the shared library created - + # when "with_aix_soname,aix_use_runtimelinking" is: + # "aix,no" lib.a(lib.so.V) shared, rtl:no, for executables + # "aix,yes" lib.so shared, rtl:yes, for executables + # lib.a static archive + # "both,no" lib.so.V(shr.o) shared, rtl:yes + # lib.a(lib.so.V) shared, rtl:no, for executables + # "both,yes" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a(lib.so.V) shared, rtl:no + # "svr4,*" lib.so.V(shr.o) shared, rtl:yes, for executables + # lib.a static archive case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*) for ld_flag in $LDFLAGS; do case $ld_flag in @@ -5994,6 +6495,13 @@ if test "$_lt_caught_CXX_error" != yes; then ;; esac done + if test svr4,no = "$with_aix_soname,$aix_use_runtimelinking"; then + # With aix-soname=svr4, we create the lib.so.V shared archives only, + # so we don't have lib.a shared libs to link our executables. + # We have to force runtime linking in this case. + aix_use_runtimelinking=yes + LDFLAGS="$LDFLAGS -Wl,-brtl" + fi ;; esac @@ -6012,13 +6520,21 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(file_list_spec, $1)='${wl}-f,' + _LT_TAGVAR(file_list_spec, $1)='$wl-f,' + case $with_aix_soname,$aix_use_runtimelinking in + aix,*) ;; # no import file + svr4,* | *,yes) # use import file + # The Import File defines what to hardcode. + _LT_TAGVAR(hardcode_direct, $1)=no + _LT_TAGVAR(hardcode_direct_absolute, $1)=no + ;; + esac - if test "$GXX" = yes; then + if test yes = "$GXX"; then case $host_os in aix4.[[012]]|aix4.[[012]].*) # We only want to do this on AIX 4.2 and lower, the check # below for broken collect2 doesn't work under 4.3+ - collect2name=`${CC} -print-prog-name=collect2` + collect2name=`$CC -print-prog-name=collect2` if test -f "$collect2name" && strings "$collect2name" | $GREP resolve_lib_name >/dev/null then @@ -6036,64 +6552,84 @@ if test "$_lt_caught_CXX_error" != yes; then fi esac shared_flag='-shared' - if test "$aix_use_runtimelinking" = yes; then - shared_flag="$shared_flag "'${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag=$shared_flag' $wl-G' fi + # Need to ensure runtime linking is disabled for the traditional + # shared library, or the linker may eventually find shared libraries + # /with/ Import File - we do not want to mix them. + shared_flag_aix='-shared' + shared_flag_svr4='-shared $wl-G' else # not using gcc - if test "$host_cpu" = ia64; then + if test ia64 = "$host_cpu"; then # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release # chokes on -Wl,-G. The following line is correct: shared_flag='-G' else - if test "$aix_use_runtimelinking" = yes; then - shared_flag='${wl}-G' + if test yes = "$aix_use_runtimelinking"; then + shared_flag='$wl-G' else - shared_flag='${wl}-bM:SRE' + shared_flag='$wl-bM:SRE' fi + shared_flag_aix='$wl-bM:SRE' + shared_flag_svr4='$wl-G' fi fi - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-bexpall' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-bexpall' # It seems that -bexpall does not export symbols beginning with # underscore (_), so it is better to generate a list of symbols to # export. _LT_TAGVAR(always_export_symbols, $1)=yes - if test "$aix_use_runtimelinking" = yes; then + if test aix,yes = "$with_aix_soname,$aix_use_runtimelinking"; then # Warning - without using the other runtime loading flags (-brtl), # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(allow_undefined_flag, $1)='-berok' + # The "-G" linker flag allows undefined symbols. + _LT_TAGVAR(no_undefined_flag, $1)='-bernotok' # Determine the default libpath from the value encoded in an empty # executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $deplibs $wl'$no_entry_flag' $compiler_flags `if test -n "$allow_undefined_flag"; then func_echo_all "$wl$allow_undefined_flag"; else :; fi` $wl'$exp_sym_flag:\$export_symbols' '$shared_flag else - if test "$host_cpu" = ia64; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib' + if test ia64 = "$host_cpu"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $libdir:/usr/lib:/lib' _LT_TAGVAR(allow_undefined_flag, $1)="-z nodefs" - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" + _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\$wl$no_entry_flag"' $compiler_flags $wl$allow_undefined_flag '"\$wl$exp_sym_flag:\$export_symbols" else # Determine the default libpath from the value encoded in an # empty executable. _LT_SYS_MODULE_PATH_AIX([$1]) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath" + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-blibpath:$libdir:'"$aix_libpath" # Warning - without using the other run time loading flags, # -berok will link without error, but may produce a broken library. - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok' - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok' - if test "$with_gnu_ld" = yes; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-bernotok' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-berok' + if test yes = "$with_gnu_ld"; then # We only use this code for GNU lds that support --whole-archive. - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' else # Exported symbols can be pulled into shared objects from archives _LT_TAGVAR(whole_archive_flag_spec, $1)='$convenience' fi _LT_TAGVAR(archive_cmds_need_lc, $1)=yes - # This is similar to how AIX traditionally builds its shared - # libraries. - _LT_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' + _LT_TAGVAR(archive_expsym_cmds, $1)='$RM -r $output_objdir/$realname.d~$MKDIR $output_objdir/$realname.d' + # -brtl affects multiple linker settings, -berok does not and is overridden later + compiler_flags_filtered='`func_echo_all "$compiler_flags " | $SED -e "s%-brtl\\([[, ]]\\)%-berok\\1%g"`' + if test svr4 != "$with_aix_soname"; then + # This is similar to how AIX traditionally builds its shared + # libraries. Need -bnortl late, we may have -brtl in LDFLAGS. + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_aix' -o $output_objdir/$realname.d/$soname $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$realname.d/$soname' + fi + if test aix != "$with_aix_soname"; then + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$CC '$shared_flag_svr4' -o $output_objdir/$realname.d/$shared_archive_member_spec.o $libobjs $deplibs $wl-bnoentry '$compiler_flags_filtered'$wl-bE:$export_symbols$allow_undefined_flag~$STRIP -e $output_objdir/$realname.d/$shared_archive_member_spec.o~( func_echo_all "#! $soname($shared_archive_member_spec.o)"; if test shr_64 = "$shared_archive_member_spec"; then func_echo_all "# 64"; else func_echo_all "# 32"; fi; cat $export_symbols ) > $output_objdir/$realname.d/$shared_archive_member_spec.imp~$AR $AR_FLAGS $output_objdir/$soname $output_objdir/$realname.d/$shared_archive_member_spec.o $output_objdir/$realname.d/$shared_archive_member_spec.imp' + else + # used by -dlpreopen to get the symbols + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$MV $output_objdir/$realname.d/$soname $output_objdir' + fi + _LT_TAGVAR(archive_expsym_cmds, $1)="$_LT_TAGVAR(archive_expsym_cmds, $1)"'~$RM -r $output_objdir/$realname.d' fi fi ;; @@ -6103,7 +6639,7 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(allow_undefined_flag, $1)=unsupported # Joseph Beckenbach <jrb3@best.com> says some releases of gcc # support --undefined. This deserves some investigation. FIXME - _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -6131,57 +6667,58 @@ if test "$_lt_caught_CXX_error" != yes; then # Tell ltmain to make .lib files, not .a files. libext=lib # Tell ltmain to make .dll files, not .so files. - shrext_cmds=".dll" + shrext_cmds=.dll # FIXME: Setting linknames here is a bad hack. - _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-dll~linknames=' - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - $SED -n -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' -e '1\\\!p' < $export_symbols > $output_objdir/$soname.exp; - else - $SED -e 's/\\\\\\\(.*\\\\\\\)/-link\\\ -EXPORT:\\\\\\\1/' < $export_symbols > $output_objdir/$soname.exp; - fi~ - $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ - linknames=' + _LT_TAGVAR(archive_cmds, $1)='$CC -o $output_objdir/$soname $libobjs $compiler_flags $deplibs -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~linknames=' + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp "$export_symbols" "$output_objdir/$soname.def"; + echo "$tool_output_objdir$soname.def" > "$output_objdir/$soname.exp"; + else + $SED -e '\''s/^/-link -EXPORT:/'\'' < $export_symbols > $output_objdir/$soname.exp; + fi~ + $CC -o $tool_output_objdir$soname $libobjs $compiler_flags $deplibs "@$tool_output_objdir$soname.exp" -Wl,-DLL,-IMPLIB:"$tool_output_objdir$libname.dll.lib"~ + linknames=' # The linker will not automatically build a static lib if we build a DLL. # _LT_TAGVAR(old_archive_from_new_cmds, $1)='true' _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes # Don't use ranlib _LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib' _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~ - lt_tool_outputfile="@TOOL_OUTPUT@"~ - case $lt_outputfile in - *.exe|*.EXE) ;; - *) - lt_outputfile="$lt_outputfile.exe" - lt_tool_outputfile="$lt_tool_outputfile.exe" - ;; - esac~ - func_to_tool_file "$lt_outputfile"~ - if test "$MANIFEST_TOOL" != ":" && test -f "$lt_outputfile.manifest"; then - $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; - $RM "$lt_outputfile.manifest"; - fi' + lt_tool_outputfile="@TOOL_OUTPUT@"~ + case $lt_outputfile in + *.exe|*.EXE) ;; + *) + lt_outputfile=$lt_outputfile.exe + lt_tool_outputfile=$lt_tool_outputfile.exe + ;; + esac~ + func_to_tool_file "$lt_outputfile"~ + if test : != "$MANIFEST_TOOL" && test -f "$lt_outputfile.manifest"; then + $MANIFEST_TOOL -manifest "$lt_tool_outputfile.manifest" -outputresource:"$lt_tool_outputfile" || exit 1; + $RM "$lt_outputfile.manifest"; + fi' ;; *) # g++ # _LT_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless, # as there is no search path for DLLs. _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-all-symbols' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-all-symbols' _LT_TAGVAR(allow_undefined_flag, $1)=unsupported _LT_TAGVAR(always_export_symbols, $1)=no _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' - # If the export-symbols file already is a .def file (1st line - # is EXPORTS), use it as is; otherwise, prepend... - _LT_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then - cp $export_symbols $output_objdir/$soname.def; - else - echo EXPORTS > $output_objdir/$soname.def; - cat $export_symbols >> $output_objdir/$soname.def; - fi~ - $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' + # If the export-symbols file already is a .def file, use it as + # is; otherwise, prepend EXPORTS... + _LT_TAGVAR(archive_expsym_cmds, $1)='if _LT_DLL_DEF_P([$export_symbols]); then + cp $export_symbols $output_objdir/$soname.def; + else + echo EXPORTS > $output_objdir/$soname.def; + cat $export_symbols >> $output_objdir/$soname.def; + fi~ + $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname $wl--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' else _LT_TAGVAR(ld_shlibs, $1)=no fi @@ -6192,6 +6729,34 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_DARWIN_LINKER_FEATURES($1) ;; + os2*) + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir' + _LT_TAGVAR(hardcode_minus_L, $1)=yes + _LT_TAGVAR(allow_undefined_flag, $1)=unsupported + shrext_cmds=.dll + _LT_TAGVAR(archive_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + emxexp $libobjs | $SED /"_DLL_InitTerm"/d >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(archive_expsym_cmds, $1)='$ECHO "LIBRARY ${soname%$shared_ext} INITINSTANCE TERMINSTANCE" > $output_objdir/$libname.def~ + $ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~ + $ECHO "DATA MULTIPLE NONSHARED" >> $output_objdir/$libname.def~ + $ECHO EXPORTS >> $output_objdir/$libname.def~ + prefix_cmds="$SED"~ + if test EXPORTS = "`$SED 1q $export_symbols`"; then + prefix_cmds="$prefix_cmds -e 1d"; + fi~ + prefix_cmds="$prefix_cmds -e \"s/^\(.*\)$/_\1/g\""~ + cat $export_symbols | $prefix_cmds >> $output_objdir/$libname.def~ + $CC -Zdll -Zcrtdll -o $output_objdir/$soname $libobjs $deplibs $compiler_flags $output_objdir/$libname.def~ + emximp -o $lib $output_objdir/$libname.def' + _LT_TAGVAR(old_archive_From_new_cmds, $1)='emximp -o $output_objdir/${libname}_dll.a $output_objdir/$libname.def' + _LT_TAGVAR(enable_shared_with_static_runtimes, $1)=yes + ;; + dgux*) case $cc_basename in ec++*) @@ -6226,18 +6791,15 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=yes ;; - gnu*) - ;; - haiku*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(link_all_deplibs, $1)=yes ;; hpux9*) - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH, # but as the default @@ -6249,7 +6811,7 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=no ;; aCC*) - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -b $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. @@ -6258,11 +6820,11 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) - if test "$GXX" = yes; then - _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' + if test yes = "$GXX"; then + _LT_TAGVAR(archive_cmds, $1)='$RM $output_objdir/$soname~$CC -shared -nostdlib $pic_flag $wl+b $wl$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test "x$output_objdir/$soname" = "x$lib" || mv $output_objdir/$soname $lib' else # FIXME: insert proper C++ library support _LT_TAGVAR(ld_shlibs, $1)=no @@ -6272,15 +6834,15 @@ if test "$_lt_caught_CXX_error" != yes; then ;; hpux10*|hpux11*) - if test $with_gnu_ld = no; then - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir' + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl+b $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: case $host_cpu in hppa*64*|ia64*) ;; *) - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' ;; esac fi @@ -6306,13 +6868,13 @@ if test "$_lt_caught_CXX_error" != yes; then aCC*) case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -b $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac # Commands to make compiler produce verbose output that lists @@ -6323,20 +6885,20 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP " \-L"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) - if test "$GXX" = yes; then - if test $with_gnu_ld = no; then + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then case $host_cpu in hppa*64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC $wl+h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; ia64*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $pic_flag $wl+h $wl$soname $wl+b $wl$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' ;; esac fi @@ -6351,22 +6913,22 @@ if test "$_lt_caught_CXX_error" != yes; then interix[[3-9]]*) _LT_TAGVAR(hardcode_direct, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. # Instead, shared libraries are loaded at an image base (0x10000000 by # default) and relocated if they conflict, which is a slow very memory # consuming and fragmenting process. To avoid this, we pick a random, # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link # time. Moving up from 0x10000000 also allows more sbrk(2) space. - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='sed "s|^|_|" $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags $wl-h,$soname $wl--retain-symbols-file,$output_objdir/$soname.expsym $wl--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' ;; irix5* | irix6*) case $cc_basename in CC*) # SGI C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' # Archives containing C++ object files must be created using # "CC -ar", where "CC" is the IRIX C++ compiler. This is @@ -6375,22 +6937,22 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(old_archive_cmds, $1)='$CC -ar -WR,-u -o $oldlib $oldobjs' ;; *) - if test "$GXX" = yes; then - if test "$with_gnu_ld" = no; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + if test yes = "$GXX"; then + if test no = "$with_gnu_ld"; then + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' else - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` -o $lib' fi fi _LT_TAGVAR(link_all_deplibs, $1)=yes ;; esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: _LT_TAGVAR(inherit_rpath, $1)=yes ;; - linux* | k*bsd*-gnu | kopensolaris*-gnu) + linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu*) case $cc_basename in KCC*) # Kuck and Associates, Inc. (KAI) C++ Compiler @@ -6398,8 +6960,8 @@ if test "$_lt_caught_CXX_error" != yes; then # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib $wl-retain-symbols-file,$export_symbols; mv \$templib $lib' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. @@ -6408,10 +6970,10 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' # Archives containing C++ object files must be created using # "CC -Bstatic", where "CC" is the KAI C++ compiler. @@ -6425,59 +6987,59 @@ if test "$_lt_caught_CXX_error" != yes; then # earlier do not add the objects themselves. case `$CC -V 2>&1` in *"Version 7."*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 8.0 or newer tmp_idyn= case $host_cpu in ia64*) tmp_idyn=' -i_dynamic';; esac - _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac _LT_TAGVAR(archive_cmds_need_lc, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive$convenience $wl--no-whole-archive' ;; pgCC* | pgcpp*) # Portland Group C++ compiler case `$CC -V` in *pgCC\ [[1-5]].* | *pgcpp\ [[1-5]].*) _LT_TAGVAR(prelink_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ - compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ + compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"' _LT_TAGVAR(old_archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ - $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ - $RANLIB $oldlib' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ + $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~ + $RANLIB $oldlib' _LT_TAGVAR(archive_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='tpldir=Template.dir~ - rm -rf $tpldir~ - $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ - $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + rm -rf $tpldir~ + $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ + $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; *) # Version 6 and above use weak symbols - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname $wl-retain-symbols-file $wl$export_symbols -o $lib' ;; esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}--rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl--rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' ;; cxx*) # Compaq C++ - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname -o $lib $wl-retain-symbols-file $wl$export_symbols' runpath_var=LD_RUN_PATH _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' @@ -6491,18 +7053,18 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' ;; xl* | mpixl* | bgxl*) # IBM XL 8.0 on PPC, with GNU ld - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic' - _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' - if test "x$supports_anon_versioning" = xyes; then + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl--export-dynamic' + _LT_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname -o $lib' + if test yes = "$supports_anon_versioning"; then _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $output_objdir/$libname.ver~ - cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ - echo "local: *; };" >> $output_objdir/$libname.ver~ - $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' + cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ + echo "local: *; };" >> $output_objdir/$libname.ver~ + $CC -qmkshrobj $libobjs $deplibs $compiler_flags $wl-soname $wl$soname $wl-version-script $wl$output_objdir/$libname.ver -o $lib' fi ;; *) @@ -6510,10 +7072,10 @@ if test "$_lt_caught_CXX_error" != yes; then *Sun\ C*) # Sun C++ 5.9 _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file $wl$export_symbols' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` $wl--no-whole-archive' _LT_TAGVAR(compiler_needs_object, $1)=yes # Not sure whether something based on @@ -6571,22 +7133,17 @@ if test "$_lt_caught_CXX_error" != yes; then _LT_TAGVAR(ld_shlibs, $1)=yes ;; - openbsd2*) - # C++ shared libraries are fairly broken - _LT_TAGVAR(ld_shlibs, $1)=no - ;; - - openbsd*) + openbsd* | bitrig*) if test -f /usr/libexec/ld.so; then _LT_TAGVAR(hardcode_direct, $1)=yes _LT_TAGVAR(hardcode_shlibpath_var, $1)=no _LT_TAGVAR(hardcode_direct_absolute, $1)=yes _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' - if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E' - _LT_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' + if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`"; then + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-retain-symbols-file,$export_symbols -o $lib' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-E' + _LT_TAGVAR(whole_archive_flag_spec, $1)=$wlarc'--whole-archive$convenience '$wlarc'--no-whole-archive' fi output_verbose_link_cmd=func_echo_all else @@ -6602,9 +7159,9 @@ if test "$_lt_caught_CXX_error" != yes; then # KCC will only create a shared library if the output file # ends with ".so" (or ".sl" for HP-UX), so rename the library # to its proper name (with version) after linking. - _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' + _LT_TAGVAR(archive_cmds, $1)='tempext=`echo $shared_ext | $SED -e '\''s/\([[^()0-9A-Za-z{}]]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\$tempext\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Archives containing C++ object files must be created using @@ -6622,17 +7179,17 @@ if test "$_lt_caught_CXX_error" != yes; then cxx*) case $host in osf3*) - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $soname `test -n "$verstring" && func_echo_all "$wl-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' ;; *) _LT_TAGVAR(allow_undefined_flag, $1)=' -expect_unresolved \*' - _LT_TAGVAR(archive_cmds, $1)='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ - echo "-hidden">> $lib.exp~ - $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ - $RM $lib.exp' + echo "-hidden">> $lib.exp~ + $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname $wl-input $wl$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry $output_objdir/so_locations -o $lib~ + $RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-rpath $libdir' ;; esac @@ -6647,27 +7204,27 @@ if test "$_lt_caught_CXX_error" != yes; then # explicitly linking system object files so we need to strip them # from the output so that they don't get included in the library # dependencies. - output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' + output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list= ; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' ;; *) - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(allow_undefined_flag, $1)=' ${wl}-expect_unresolved ${wl}\*' + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(allow_undefined_flag, $1)=' $wl-expect_unresolved $wl\*' case $host in osf3*) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-msym $wl-soname $wl$soname `test -n "$verstring" && func_echo_all "$wl-set_version $wl$verstring"` $wl-update_registry $wl$output_objdir/so_locations -o $lib' ;; esac - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-rpath $wl$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=: # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else # FIXME: insert proper C++ library support @@ -6707,9 +7264,9 @@ if test "$_lt_caught_CXX_error" != yes; then # Sun C++ 4.2, 5.x and Centerline C++ _LT_TAGVAR(archive_cmds_need_lc,$1)=yes _LT_TAGVAR(no_undefined_flag, $1)=' -zdefs' - _LT_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G$allow_undefined_flag -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + $CC -G$allow_undefined_flag $wl-M $wl$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir' _LT_TAGVAR(hardcode_shlibpath_var, $1)=no @@ -6717,7 +7274,7 @@ if test "$_lt_caught_CXX_error" != yes; then solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) # The compiler driver will combine and reorder linker options, - # but understands `-z linker_flag'. + # but understands '-z linker_flag'. # Supported since Solaris 2.6 (maybe 2.5.1?) _LT_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;; @@ -6734,42 +7291,42 @@ if test "$_lt_caught_CXX_error" != yes; then ;; gcx*) # Green Hills C++ Compiler - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' # The C++ compiler must be used to create the archive. _LT_TAGVAR(old_archive_cmds, $1)='$CC $LDFLAGS -archive -o $oldlib $oldobjs' ;; *) # GNU C++ compiler with Solaris linker - if test "$GXX" = yes && test "$with_gnu_ld" = no; then - _LT_TAGVAR(no_undefined_flag, $1)=' ${wl}-z ${wl}defs' + if test yes,no = "$GXX,$with_gnu_ld"; then + _LT_TAGVAR(no_undefined_flag, $1)=' $wl-z ${wl}defs' if $CC --version | $GREP -v '^2\.7' > /dev/null; then - _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -shared $pic_flag -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + $CC -shared $pic_flag -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' else - # g++ 2.7 appears to require `-G' NOT `-shared' on this + # g++ 2.7 appears to require '-G' NOT '-shared' on this # platform. - _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' + _LT_TAGVAR(archive_cmds, $1)='$CC -G -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags $wl-h $wl$soname -o $lib' _LT_TAGVAR(archive_expsym_cmds, $1)='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ - $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' + $CC -G -nostdlib $wl-M $wl$lib.exp $wl-h $wl$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' # Commands to make compiler produce verbose output that lists # what "hidden" libraries, object files and flags are used when # linking a shared library. - output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' + output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP " \-L"' fi - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R $wl$libdir' case $host_os in solaris2.[[0-5]] | solaris2.[[0-5]].*) ;; *) - _LT_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' + _LT_TAGVAR(whole_archive_flag_spec, $1)='$wl-z ${wl}allextract$convenience $wl-z ${wl}defaultextract' ;; esac fi @@ -6778,52 +7335,52 @@ if test "$_lt_caught_CXX_error" != yes; then ;; sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*) - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no runpath_var='LD_RUN_PATH' case $cc_basename in CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; sysv5* | sco3.2v5* | sco5v6*) - # Note: We can NOT use -z defs as we might desire, because we do not + # Note: We CANNOT use -z defs as we might desire, because we do not # link with -lc, and that would cause any symbols used from libc to # always be unresolved, which means just about no library would # ever link correctly. If we're not using GNU ld we use -z text # though, which does catch some bad symbols but isn't as heavy-handed # as -z defs. - _LT_TAGVAR(no_undefined_flag, $1)='${wl}-z,text' - _LT_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs' + _LT_TAGVAR(no_undefined_flag, $1)='$wl-z,text' + _LT_TAGVAR(allow_undefined_flag, $1)='$wl-z,nodefs' _LT_TAGVAR(archive_cmds_need_lc, $1)=no _LT_TAGVAR(hardcode_shlibpath_var, $1)=no - _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R,$libdir' + _LT_TAGVAR(hardcode_libdir_flag_spec, $1)='$wl-R,$libdir' _LT_TAGVAR(hardcode_libdir_separator, $1)=':' _LT_TAGVAR(link_all_deplibs, $1)=yes - _LT_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport' + _LT_TAGVAR(export_dynamic_flag_spec, $1)='$wl-Bexport' runpath_var='LD_RUN_PATH' case $cc_basename in CC*) - _LT_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -G $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -G $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' _LT_TAGVAR(old_archive_cmds, $1)='$CC -Tprelink_objects $oldobjs~ - '"$_LT_TAGVAR(old_archive_cmds, $1)" + '"$_LT_TAGVAR(old_archive_cmds, $1)" _LT_TAGVAR(reload_cmds, $1)='$CC -Tprelink_objects $reload_objs~ - '"$_LT_TAGVAR(reload_cmds, $1)" + '"$_LT_TAGVAR(reload_cmds, $1)" ;; *) - _LT_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' - _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_cmds, $1)='$CC -shared $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' + _LT_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $wl-Bexport:$export_symbols $wl-h,$soname -o $lib $libobjs $deplibs $compiler_flags' ;; esac ;; @@ -6854,10 +7411,10 @@ if test "$_lt_caught_CXX_error" != yes; then esac AC_MSG_RESULT([$_LT_TAGVAR(ld_shlibs, $1)]) - test "$_LT_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no + test no = "$_LT_TAGVAR(ld_shlibs, $1)" && can_build_shared=no - _LT_TAGVAR(GCC, $1)="$GXX" - _LT_TAGVAR(LD, $1)="$LD" + _LT_TAGVAR(GCC, $1)=$GXX + _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change @@ -6884,7 +7441,7 @@ if test "$_lt_caught_CXX_error" != yes; then lt_cv_path_LD=$lt_save_path_LD lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld -fi # test "$_lt_caught_CXX_error" != yes +fi # test yes != "$_lt_caught_CXX_error" AC_LANG_POP ])# _LT_LANG_CXX_CONFIG @@ -6906,13 +7463,14 @@ AC_REQUIRE([_LT_DECL_SED]) AC_REQUIRE([_LT_PROG_ECHO_BACKSLASH]) func_stripname_cnf () { - case ${2} in - .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;; - *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;; + case @S|@2 in + .*) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%\\\\@S|@2\$%%"`;; + *) func_stripname_result=`$ECHO "@S|@3" | $SED "s%^@S|@1%%; s%@S|@2\$%%"`;; esac } # func_stripname_cnf ])# _LT_FUNC_STRIPNAME_CNF + # _LT_SYS_HIDDEN_LIBDEPS([TAGNAME]) # --------------------------------- # Figure out "hidden" library dependencies from verbose @@ -6996,13 +7554,13 @@ if AC_TRY_EVAL(ac_compile); then pre_test_object_deps_done=no for p in `eval "$output_verbose_link_cmd"`; do - case ${prev}${p} in + case $prev$p in -L* | -R* | -l*) # Some compilers place space between "-{L,R}" and the path. # Remove the space. - if test $p = "-L" || - test $p = "-R"; then + if test x-L = "$p" || + test x-R = "$p"; then prev=$p continue fi @@ -7018,16 +7576,16 @@ if AC_TRY_EVAL(ac_compile); then case $p in =*) func_stripname_cnf '=' '' "$p"; p=$lt_sysroot$func_stripname_result ;; esac - if test "$pre_test_object_deps_done" = no; then - case ${prev} in + if test no = "$pre_test_object_deps_done"; then + case $prev in -L | -R) # Internal compiler library paths should come after those # provided the user. The postdeps already come after the # user supplied libs so there is no need to process them. if test -z "$_LT_TAGVAR(compiler_lib_search_path, $1)"; then - _LT_TAGVAR(compiler_lib_search_path, $1)="${prev}${p}" + _LT_TAGVAR(compiler_lib_search_path, $1)=$prev$p else - _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} ${prev}${p}" + _LT_TAGVAR(compiler_lib_search_path, $1)="${_LT_TAGVAR(compiler_lib_search_path, $1)} $prev$p" fi ;; # The "-l" case would never come before the object being @@ -7035,9 +7593,9 @@ if AC_TRY_EVAL(ac_compile); then esac else if test -z "$_LT_TAGVAR(postdeps, $1)"; then - _LT_TAGVAR(postdeps, $1)="${prev}${p}" + _LT_TAGVAR(postdeps, $1)=$prev$p else - _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} ${prev}${p}" + _LT_TAGVAR(postdeps, $1)="${_LT_TAGVAR(postdeps, $1)} $prev$p" fi fi prev= @@ -7052,15 +7610,15 @@ if AC_TRY_EVAL(ac_compile); then continue fi - if test "$pre_test_object_deps_done" = no; then + if test no = "$pre_test_object_deps_done"; then if test -z "$_LT_TAGVAR(predep_objects, $1)"; then - _LT_TAGVAR(predep_objects, $1)="$p" + _LT_TAGVAR(predep_objects, $1)=$p else _LT_TAGVAR(predep_objects, $1)="$_LT_TAGVAR(predep_objects, $1) $p" fi else if test -z "$_LT_TAGVAR(postdep_objects, $1)"; then - _LT_TAGVAR(postdep_objects, $1)="$p" + _LT_TAGVAR(postdep_objects, $1)=$p else _LT_TAGVAR(postdep_objects, $1)="$_LT_TAGVAR(postdep_objects, $1) $p" fi @@ -7091,51 +7649,6 @@ interix[[3-9]]*) _LT_TAGVAR(postdep_objects,$1)= _LT_TAGVAR(postdeps,$1)= ;; - -linux*) - case `$CC -V 2>&1 | sed 5q` in - *Sun\ C*) - # Sun C++ 5.9 - - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; - -solaris*) - case $cc_basename in - CC* | sunCC*) - # The more standards-conforming stlport4 library is - # incompatible with the Cstd library. Avoid specifying - # it if it's in CXXFLAGS. Ignore libCrun as - # -library=stlport4 depends on it. - case " $CXX $CXXFLAGS " in - *" -library=stlport4 "*) - solaris_use_stlport4=yes - ;; - esac - - # Adding this requires a known-good setup of shared libraries for - # Sun compiler versions before 5.6, else PIC objects from an old - # archive will be linked into the output, leading to subtle bugs. - if test "$solaris_use_stlport4" != yes; then - _LT_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun' - fi - ;; - esac - ;; esac ]) @@ -7144,7 +7657,7 @@ case " $_LT_TAGVAR(postdeps, $1) " in esac _LT_TAGVAR(compiler_lib_search_dirs, $1)= if test -n "${_LT_TAGVAR(compiler_lib_search_path, $1)}"; then - _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` + _LT_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_TAGVAR(compiler_lib_search_path, $1)}" | $SED -e 's! -L! !g' -e 's!^ !!'` fi _LT_TAGDECL([], [compiler_lib_search_dirs], [1], [The directories searched by this compiler when creating a shared library]) @@ -7164,10 +7677,10 @@ _LT_TAGDECL([], [compiler_lib_search_path], [1], # -------------------------- # Ensure that the configuration variables for a Fortran 77 compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_F77_CONFIG], [AC_LANG_PUSH(Fortran 77) -if test -z "$F77" || test "X$F77" = "Xno"; then +if test -z "$F77" || test no = "$F77"; then _lt_disable_F77=yes fi @@ -7204,7 +7717,7 @@ _LT_TAGVAR(objext, $1)=$objext # the F77 compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_F77" != yes; then +if test yes != "$_lt_disable_F77"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t @@ -7226,7 +7739,7 @@ if test "$_lt_disable_F77" != yes; then _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. - lt_save_CC="$CC" + lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${F77-"f77"} @@ -7240,21 +7753,25 @@ if test "$_lt_disable_F77" != yes; then AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no + test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) - test "$enable_shared" = yes && enable_static=no + test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac fi ;; esac @@ -7262,11 +7779,11 @@ if test "$_lt_disable_F77" != yes; then AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes + test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) - _LT_TAGVAR(GCC, $1)="$G77" - _LT_TAGVAR(LD, $1)="$LD" + _LT_TAGVAR(GCC, $1)=$G77 + _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change @@ -7283,9 +7800,9 @@ if test "$_lt_disable_F77" != yes; then fi # test -n "$compiler" GCC=$lt_save_GCC - CC="$lt_save_CC" - CFLAGS="$lt_save_CFLAGS" -fi # test "$_lt_disable_F77" != yes + CC=$lt_save_CC + CFLAGS=$lt_save_CFLAGS +fi # test yes != "$_lt_disable_F77" AC_LANG_POP ])# _LT_LANG_F77_CONFIG @@ -7295,11 +7812,11 @@ AC_LANG_POP # ------------------------- # Ensure that the configuration variables for a Fortran compiler are # suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_FC_CONFIG], [AC_LANG_PUSH(Fortran) -if test -z "$FC" || test "X$FC" = "Xno"; then +if test -z "$FC" || test no = "$FC"; then _lt_disable_FC=yes fi @@ -7336,7 +7853,7 @@ _LT_TAGVAR(objext, $1)=$objext # the FC compiler isn't working. Some variables (like enable_shared) # are currently assumed to apply to all compilers on this platform, # and will be corrupted by setting them based on a non-working compiler. -if test "$_lt_disable_FC" != yes; then +if test yes != "$_lt_disable_FC"; then # Code to be used in simple compile tests lt_simple_compile_test_code="\ subroutine t @@ -7358,7 +7875,7 @@ if test "$_lt_disable_FC" != yes; then _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. - lt_save_CC="$CC" + lt_save_CC=$CC lt_save_GCC=$GCC lt_save_CFLAGS=$CFLAGS CC=${FC-"f95"} @@ -7374,21 +7891,25 @@ if test "$_lt_disable_FC" != yes; then AC_MSG_RESULT([$can_build_shared]) AC_MSG_CHECKING([whether to build shared libraries]) - test "$can_build_shared" = "no" && enable_shared=no + test no = "$can_build_shared" && enable_shared=no # On AIX, shared libraries and static libraries use the same namespace, and # are all built from PIC. case $host_os in aix3*) - test "$enable_shared" = yes && enable_static=no + test yes = "$enable_shared" && enable_static=no if test -n "$RANLIB"; then archive_cmds="$archive_cmds~\$RANLIB \$lib" postinstall_cmds='$RANLIB $lib' fi ;; aix[[4-9]]*) - if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then - test "$enable_shared" = yes && enable_static=no + if test ia64 != "$host_cpu"; then + case $enable_shared,$with_aix_soname,$aix_use_runtimelinking in + yes,aix,yes) ;; # shared object as lib.so file only + yes,svr4,*) ;; # shared object as lib.so archive member only + yes,*) enable_static=no ;; # shared object in lib.a archive as well + esac fi ;; esac @@ -7396,11 +7917,11 @@ if test "$_lt_disable_FC" != yes; then AC_MSG_CHECKING([whether to build static libraries]) # Make sure either enable_shared or enable_static is yes. - test "$enable_shared" = yes || enable_static=yes + test yes = "$enable_shared" || enable_static=yes AC_MSG_RESULT([$enable_static]) - _LT_TAGVAR(GCC, $1)="$ac_cv_fc_compiler_gnu" - _LT_TAGVAR(LD, $1)="$LD" + _LT_TAGVAR(GCC, $1)=$ac_cv_fc_compiler_gnu + _LT_TAGVAR(LD, $1)=$LD ## CAVEAT EMPTOR: ## There is no encapsulation within the following macros, do not change @@ -7420,7 +7941,7 @@ if test "$_lt_disable_FC" != yes; then GCC=$lt_save_GCC CC=$lt_save_CC CFLAGS=$lt_save_CFLAGS -fi # test "$_lt_disable_FC" != yes +fi # test yes != "$_lt_disable_FC" AC_LANG_POP ])# _LT_LANG_FC_CONFIG @@ -7430,7 +7951,7 @@ AC_LANG_POP # -------------------------- # Ensure that the configuration variables for the GNU Java Compiler compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GCJ_CONFIG], [AC_REQUIRE([LT_PROG_GCJ])dnl AC_LANG_SAVE @@ -7464,7 +7985,7 @@ CC=${GCJ-"gcj"} CFLAGS=$GCJFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" +_LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # GCJ did not exist at the time GCC didn't implicitly link libc in. @@ -7501,7 +8022,7 @@ CFLAGS=$lt_save_CFLAGS # -------------------------- # Ensure that the configuration variables for the GNU Go compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_GO_CONFIG], [AC_REQUIRE([LT_PROG_GO])dnl AC_LANG_SAVE @@ -7535,7 +8056,7 @@ CC=${GOC-"gccgo"} CFLAGS=$GOFLAGS compiler=$CC _LT_TAGVAR(compiler, $1)=$CC -_LT_TAGVAR(LD, $1)="$LD" +_LT_TAGVAR(LD, $1)=$LD _LT_CC_BASENAME([$compiler]) # Go did not exist at the time GCC didn't implicitly link libc in. @@ -7572,7 +8093,7 @@ CFLAGS=$lt_save_CFLAGS # ------------------------- # Ensure that the configuration variables for the Windows resource compiler # are suitably defined. These variables are subsequently used by _LT_CONFIG -# to write the compiler configuration to `libtool'. +# to write the compiler configuration to 'libtool'. m4_defun([_LT_LANG_RC_CONFIG], [AC_REQUIRE([LT_PROG_RC])dnl AC_LANG_SAVE @@ -7588,7 +8109,7 @@ _LT_TAGVAR(objext, $1)=$objext lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }' # Code to be used in simple link tests -lt_simple_link_test_code="$lt_simple_compile_test_code" +lt_simple_link_test_code=$lt_simple_compile_test_code # ltmain only uses $CC for tagged configurations so make sure $CC is set. _LT_TAG_COMPILER @@ -7598,7 +8119,7 @@ _LT_COMPILER_BOILERPLATE _LT_LINKER_BOILERPLATE # Allow CC to be a program name with arguments. -lt_save_CC="$CC" +lt_save_CC=$CC lt_save_CFLAGS=$CFLAGS lt_save_GCC=$GCC GCC= @@ -7627,7 +8148,7 @@ AC_DEFUN([LT_PROG_GCJ], [m4_ifdef([AC_PROG_GCJ], [AC_PROG_GCJ], [m4_ifdef([A][M_PROG_GCJ], [A][M_PROG_GCJ], [AC_CHECK_TOOL(GCJ, gcj,) - test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2" + test set = "${GCJFLAGS+set}" || GCJFLAGS="-g -O2" AC_SUBST(GCJFLAGS)])])[]dnl ]) @@ -7738,7 +8259,7 @@ lt_ac_count=0 # Add /usr/xpg4/bin/sed as it is typically found on Solaris # along with /bin/sed that truncates output. for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do - test ! -f $lt_ac_sed && continue + test ! -f "$lt_ac_sed" && continue cat /dev/null > conftest.in lt_ac_count=0 echo $ECHO_N "0123456789$ECHO_C" >conftest.in @@ -7755,9 +8276,9 @@ for lt_ac_sed in $lt_ac_sed_list /usr/xpg4/bin/sed; do $lt_ac_sed -e 's/a$//' < conftest.nl >conftest.out || break cmp -s conftest.out conftest.nl || break # 10000 chars as input seems more than enough - test $lt_ac_count -gt 10 && break + test 10 -lt "$lt_ac_count" && break lt_ac_count=`expr $lt_ac_count + 1` - if test $lt_ac_count -gt $lt_ac_max; then + if test "$lt_ac_count" -gt "$lt_ac_max"; then lt_ac_max=$lt_ac_count lt_cv_path_SED=$lt_ac_sed fi @@ -7781,27 +8302,7 @@ dnl AC_DEFUN([LT_AC_PROG_SED], []) # Find out whether the shell is Bourne or XSI compatible, # or has some other useful features. m4_defun([_LT_CHECK_SHELL_FEATURES], -[AC_MSG_CHECKING([whether the shell understands some XSI constructs]) -# Try some XSI features -xsi_shell=no -( _lt_dummy="a/b/c" - test "${_lt_dummy##*/},${_lt_dummy%/*},${_lt_dummy#??}"${_lt_dummy%"$_lt_dummy"}, \ - = c,a/b,b/c, \ - && eval 'test $(( 1 + 1 )) -eq 2 \ - && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ - && xsi_shell=yes -AC_MSG_RESULT([$xsi_shell]) -_LT_CONFIG_LIBTOOL_INIT([xsi_shell='$xsi_shell']) - -AC_MSG_CHECKING([whether the shell understands "+="]) -lt_shell_append=no -( foo=bar; set foo baz; eval "$[1]+=\$[2]" && test "$foo" = barbaz ) \ - >/dev/null 2>&1 \ - && lt_shell_append=yes -AC_MSG_RESULT([$lt_shell_append]) -_LT_CONFIG_LIBTOOL_INIT([lt_shell_append='$lt_shell_append']) - -if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then +[if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then lt_unset=unset else lt_unset=false @@ -7825,102 +8326,9 @@ _LT_DECL([NL2SP], [lt_NL2SP], [1], [turn newlines into spaces])dnl ])# _LT_CHECK_SHELL_FEATURES -# _LT_PROG_FUNCTION_REPLACE (FUNCNAME, REPLACEMENT-BODY) -# ------------------------------------------------------ -# In `$cfgfile', look for function FUNCNAME delimited by `^FUNCNAME ()$' and -# '^} FUNCNAME ', and replace its body with REPLACEMENT-BODY. -m4_defun([_LT_PROG_FUNCTION_REPLACE], -[dnl { -sed -e '/^$1 ()$/,/^} # $1 /c\ -$1 ()\ -{\ -m4_bpatsubsts([$2], [$], [\\], [^\([ ]\)], [\\\1]) -} # Extended-shell $1 implementation' "$cfgfile" > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") -test 0 -eq $? || _lt_function_replace_fail=: -]) - - -# _LT_PROG_REPLACE_SHELLFNS -# ------------------------- -# Replace existing portable implementations of several shell functions with -# equivalent extended shell implementations where those features are available.. -m4_defun([_LT_PROG_REPLACE_SHELLFNS], -[if test x"$xsi_shell" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_dirname], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_basename], [dnl - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_dirname_and_basename], [dnl - case ${1} in - */*) func_dirname_result="${1%/*}${2}" ;; - * ) func_dirname_result="${3}" ;; - esac - func_basename_result="${1##*/}"]) - - _LT_PROG_FUNCTION_REPLACE([func_stripname], [dnl - # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are - # positional parameters, so assign one to ordinary parameter first. - func_stripname_result=${3} - func_stripname_result=${func_stripname_result#"${1}"} - func_stripname_result=${func_stripname_result%"${2}"}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_long_opt], [dnl - func_split_long_opt_name=${1%%=*} - func_split_long_opt_arg=${1#*=}]) - - _LT_PROG_FUNCTION_REPLACE([func_split_short_opt], [dnl - func_split_short_opt_arg=${1#??} - func_split_short_opt_name=${1%"$func_split_short_opt_arg"}]) - - _LT_PROG_FUNCTION_REPLACE([func_lo2o], [dnl - case ${1} in - *.lo) func_lo2o_result=${1%.lo}.${objext} ;; - *) func_lo2o_result=${1} ;; - esac]) - - _LT_PROG_FUNCTION_REPLACE([func_xform], [ func_xform_result=${1%.*}.lo]) - - _LT_PROG_FUNCTION_REPLACE([func_arith], [ func_arith_result=$(( $[*] ))]) - - _LT_PROG_FUNCTION_REPLACE([func_len], [ func_len_result=${#1}]) -fi - -if test x"$lt_shell_append" = xyes; then - _LT_PROG_FUNCTION_REPLACE([func_append], [ eval "${1}+=\\${2}"]) - - _LT_PROG_FUNCTION_REPLACE([func_append_quoted], [dnl - func_quote_for_eval "${2}" -dnl m4 expansion turns \\\\ into \\, and then the shell eval turns that into \ - eval "${1}+=\\\\ \\$func_quote_for_eval_result"]) - - # Save a `func_append' function call where possible by direct use of '+=' - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1+="%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -else - # Save a `func_append' function call even when '+=' is not available - sed -e 's%func_append \([[a-zA-Z_]]\{1,\}\) "%\1="$\1%g' $cfgfile > $cfgfile.tmp \ - && mv -f "$cfgfile.tmp" "$cfgfile" \ - || (rm -f "$cfgfile" && cp "$cfgfile.tmp" "$cfgfile" && rm -f "$cfgfile.tmp") - test 0 -eq $? || _lt_function_replace_fail=: -fi - -if test x"$_lt_function_replace_fail" = x":"; then - AC_MSG_WARN([Unable to substitute extended shell functions in $ofile]) -fi -]) - # _LT_PATH_CONVERSION_FUNCTIONS # ----------------------------- -# Determine which file name conversion functions should be used by +# Determine what file name conversion functions should be used by # func_to_host_file (and, implicitly, by func_to_host_path). These are needed # for certain cross-compile configurations and native mingw. m4_defun([_LT_PATH_CONVERSION_FUNCTIONS], diff --git a/v2.5/toolkit/m4/ltoptions.m4 b/v2.5/toolkit/m4/ltoptions.m4 index 5d9acd8e23bcfd20d353804aff13666ecbed54f4..94b082976667c0c9edf2e9ff7a668c1fd7d997bf 100644 --- a/v2.5/toolkit/m4/ltoptions.m4 +++ b/v2.5/toolkit/m4/ltoptions.m4 @@ -1,14 +1,14 @@ # Helper functions for option handling. -*- Autoconf -*- # -# Copyright (C) 2004, 2005, 2007, 2008, 2009 Free Software Foundation, -# Inc. +# Copyright (C) 2004-2005, 2007-2009, 2011-2015 Free Software +# Foundation, Inc. # Written by Gary V. Vaughan, 2004 # # This file is free software; the Free Software Foundation gives # unlimited permission to copy and/or distribute it, with or without # modifications, as long as this notice is preserved. -# serial 7 ltoptions.m4 +# serial 8 ltoptions.m4 # This is to help aclocal find these macros, as it can't see m4_define. AC_DEFUN([LTOPTIONS_VERSION], [m4_if([1])]) @@ -29,7 +29,7 @@ m4_define([_LT_SET_OPTION], [m4_define(_LT_MANGLE_OPTION([$1], [$2]))dnl m4_ifdef(_LT_MANGLE_DEFUN([$1], [$2]), _LT_MANGLE_DEFUN([$1], [$2]), - [m4_warning([Unknown $1 option `$2'])])[]dnl + [m4_warning([Unknown $1 option '$2'])])[]dnl ]) @@ -75,13 +75,15 @@ m4_if([$1],[LT_INIT],[ dnl dnl If no reference was made to various pairs of opposing options, then dnl we run the default mode handler for the pair. For example, if neither - dnl `shared' nor `disable-shared' was passed, we enable building of shared + dnl 'shared' nor 'disable-shared' was passed, we enable building of shared dnl archives by default: _LT_UNLESS_OPTIONS([LT_INIT], [shared disable-shared], [_LT_ENABLE_SHARED]) _LT_UNLESS_OPTIONS([LT_INIT], [static disable-static], [_LT_ENABLE_STATIC]) _LT_UNLESS_OPTIONS([LT_INIT], [pic-only no-pic], [_LT_WITH_PIC]) _LT_UNLESS_OPTIONS([LT_INIT], [fast-install disable-fast-install], - [_LT_ENABLE_FAST_INSTALL]) + [_LT_ENABLE_FAST_INSTALL]) + _LT_UNLESS_OPTIONS([LT_INIT], [aix-soname=aix aix-soname=both aix-soname=svr4], + [_LT_WITH_AIX_SONAME([aix])]) ]) ])# _LT_SET_OPTIONS @@ -112,7 +114,7 @@ AU_DEFUN([AC_LIBTOOL_DLOPEN], [_LT_SET_OPTION([LT_INIT], [dlopen]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `dlopen' option into LT_INIT's first parameter.]) +put the 'dlopen' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: @@ -148,7 +150,7 @@ AU_DEFUN([AC_LIBTOOL_WIN32_DLL], _LT_SET_OPTION([LT_INIT], [win32-dll]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `win32-dll' option into LT_INIT's first parameter.]) +put the 'win32-dll' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: @@ -157,9 +159,9 @@ dnl AC_DEFUN([AC_LIBTOOL_WIN32_DLL], []) # _LT_ENABLE_SHARED([DEFAULT]) # ---------------------------- -# implement the --enable-shared flag, and supports the `shared' and -# `disable-shared' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +# implement the --enable-shared flag, and supports the 'shared' and +# 'disable-shared' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_SHARED], [m4_define([_LT_ENABLE_SHARED_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([shared], @@ -172,14 +174,14 @@ AC_ARG_ENABLE([shared], *) enable_shared=no # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_shared=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], [enable_shared=]_LT_ENABLE_SHARED_DEFAULT) @@ -211,9 +213,9 @@ dnl AC_DEFUN([AM_DISABLE_SHARED], []) # _LT_ENABLE_STATIC([DEFAULT]) # ---------------------------- -# implement the --enable-static flag, and support the `static' and -# `disable-static' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +# implement the --enable-static flag, and support the 'static' and +# 'disable-static' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_STATIC], [m4_define([_LT_ENABLE_STATIC_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([static], @@ -226,14 +228,14 @@ AC_ARG_ENABLE([static], *) enable_static=no # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_static=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], [enable_static=]_LT_ENABLE_STATIC_DEFAULT) @@ -265,9 +267,9 @@ dnl AC_DEFUN([AM_DISABLE_STATIC], []) # _LT_ENABLE_FAST_INSTALL([DEFAULT]) # ---------------------------------- -# implement the --enable-fast-install flag, and support the `fast-install' -# and `disable-fast-install' LT_INIT options. -# DEFAULT is either `yes' or `no'. If omitted, it defaults to `yes'. +# implement the --enable-fast-install flag, and support the 'fast-install' +# and 'disable-fast-install' LT_INIT options. +# DEFAULT is either 'yes' or 'no'. If omitted, it defaults to 'yes'. m4_define([_LT_ENABLE_FAST_INSTALL], [m4_define([_LT_ENABLE_FAST_INSTALL_DEFAULT], [m4_if($1, no, no, yes)])dnl AC_ARG_ENABLE([fast-install], @@ -280,14 +282,14 @@ AC_ARG_ENABLE([fast-install], *) enable_fast_install=no # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for pkg in $enableval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$pkg" = "X$p"; then enable_fast_install=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], [enable_fast_install=]_LT_ENABLE_FAST_INSTALL_DEFAULT) @@ -304,14 +306,14 @@ AU_DEFUN([AC_ENABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], m4_if([$1], [no], [disable-])[fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `fast-install' option into LT_INIT's first parameter.]) +the 'fast-install' option into LT_INIT's first parameter.]) ]) AU_DEFUN([AC_DISABLE_FAST_INSTALL], [_LT_SET_OPTION([LT_INIT], [disable-fast-install]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you put -the `disable-fast-install' option into LT_INIT's first parameter.]) +the 'disable-fast-install' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: @@ -319,11 +321,64 @@ dnl AC_DEFUN([AC_ENABLE_FAST_INSTALL], []) dnl AC_DEFUN([AM_DISABLE_FAST_INSTALL], []) +# _LT_WITH_AIX_SONAME([DEFAULT]) +# ---------------------------------- +# implement the --with-aix-soname flag, and support the `aix-soname=aix' +# and `aix-soname=both' and `aix-soname=svr4' LT_INIT options. DEFAULT +# is either `aix', `both' or `svr4'. If omitted, it defaults to `aix'. +m4_define([_LT_WITH_AIX_SONAME], +[m4_define([_LT_WITH_AIX_SONAME_DEFAULT], [m4_if($1, svr4, svr4, m4_if($1, both, both, aix))])dnl +shared_archive_member_spec= +case $host,$enable_shared in +power*-*-aix[[5-9]]*,yes) + AC_MSG_CHECKING([which variant of shared library versioning to provide]) + AC_ARG_WITH([aix-soname], + [AS_HELP_STRING([--with-aix-soname=aix|svr4|both], + [shared library versioning (aka "SONAME") variant to provide on AIX, @<:@default=]_LT_WITH_AIX_SONAME_DEFAULT[@:>@.])], + [case $withval in + aix|svr4|both) + ;; + *) + AC_MSG_ERROR([Unknown argument to --with-aix-soname]) + ;; + esac + lt_cv_with_aix_soname=$with_aix_soname], + [AC_CACHE_VAL([lt_cv_with_aix_soname], + [lt_cv_with_aix_soname=]_LT_WITH_AIX_SONAME_DEFAULT) + with_aix_soname=$lt_cv_with_aix_soname]) + AC_MSG_RESULT([$with_aix_soname]) + if test aix != "$with_aix_soname"; then + # For the AIX way of multilib, we name the shared archive member + # based on the bitwidth used, traditionally 'shr.o' or 'shr_64.o', + # and 'shr.imp' or 'shr_64.imp', respectively, for the Import File. + # Even when GNU compilers ignore OBJECT_MODE but need '-maix64' flag, + # the AIX toolchain works better with OBJECT_MODE set (default 32). + if test 64 = "${OBJECT_MODE-32}"; then + shared_archive_member_spec=shr_64 + else + shared_archive_member_spec=shr + fi + fi + ;; +*) + with_aix_soname=aix + ;; +esac + +_LT_DECL([], [shared_archive_member_spec], [0], + [Shared archive member basename, for filename based shared library versioning on AIX])dnl +])# _LT_WITH_AIX_SONAME + +LT_OPTION_DEFINE([LT_INIT], [aix-soname=aix], [_LT_WITH_AIX_SONAME([aix])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=both], [_LT_WITH_AIX_SONAME([both])]) +LT_OPTION_DEFINE([LT_INIT], [aix-soname=svr4], [_LT_WITH_AIX_SONAME([svr4])]) + + # _LT_WITH_PIC([MODE]) # -------------------- -# implement the --with-pic flag, and support the `pic-only' and `no-pic' +# implement the --with-pic flag, and support the 'pic-only' and 'no-pic' # LT_INIT options. -# MODE is either `yes' or `no'. If omitted, it defaults to `both'. +# MODE is either 'yes' or 'no'. If omitted, it defaults to 'both'. m4_define([_LT_WITH_PIC], [AC_ARG_WITH([pic], [AS_HELP_STRING([--with-pic@<:@=PKGS@:>@], @@ -334,19 +389,17 @@ m4_define([_LT_WITH_PIC], *) pic_mode=default # Look at the argument we got. We use all the common list separators. - lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," + lt_save_ifs=$IFS; IFS=$IFS$PATH_SEPARATOR, for lt_pkg in $withval; do - IFS="$lt_save_ifs" + IFS=$lt_save_ifs if test "X$lt_pkg" = "X$lt_p"; then pic_mode=yes fi done - IFS="$lt_save_ifs" + IFS=$lt_save_ifs ;; esac], - [pic_mode=default]) - -test -z "$pic_mode" && pic_mode=m4_default([$1], [default]) + [pic_mode=m4_default([$1], [default])]) _LT_DECL([], [pic_mode], [0], [What type of objects to build])dnl ])# _LT_WITH_PIC @@ -359,7 +412,7 @@ AU_DEFUN([AC_LIBTOOL_PICMODE], [_LT_SET_OPTION([LT_INIT], [pic-only]) AC_DIAGNOSE([obsolete], [$0: Remove this warning and the call to _LT_SET_OPTION when you -put the `pic-only' option into LT_INIT's first parameter.]) +put the 'pic-only' option into LT_INIT's first parameter.]) ]) dnl aclocal-1.4 backwards compatibility: diff --git a/v2.5/toolkit/m4/ltversion.m4 b/v2.5/toolkit/m4/ltversion.m4 index 07a8602d48d615a65800b14446d8c8c8694f2818..fa04b52a3bf868bd57e7ba796d64385a51e7ec5a 100644 --- a/v2.5/toolkit/m4/ltversion.m4 +++ b/v2.5/toolkit/m4/ltversion.m4 @@ -1,6 +1,6 @@ # ltversion.m4 -- version numbers -*- Autoconf -*- # -# Copyright (C) 2004 Free Software Foundation, Inc. +# Copyright (C) 2004, 2011-2015 Free Software Foundation, Inc. # Written by Scott James Remnant, 2004 # # This file is free software; the Free Software Foundation gives @@ -9,15 +9,15 @@ # @configure_input@ -# serial 3337 ltversion.m4 +# serial 4179 ltversion.m4 # This file is part of GNU Libtool -m4_define([LT_PACKAGE_VERSION], [2.4.2]) -m4_define([LT_PACKAGE_REVISION], [1.3337]) +m4_define([LT_PACKAGE_VERSION], [2.4.6]) +m4_define([LT_PACKAGE_REVISION], [2.4.6]) AC_DEFUN([LTVERSION_VERSION], -[macro_version='2.4.2' -macro_revision='1.3337' +[macro_version='2.4.6' +macro_revision='2.4.6' _LT_DECL(, macro_version, 0, [Which release of libtool.m4 was used?]) _LT_DECL(, macro_revision, 0) ]) diff --git a/v2.5/toolkit/mygitcl b/v2.5/toolkit/mygitcl new file mode 100755 index 0000000000000000000000000000000000000000..b14d7563a397e6b4177e1cceeee07cf3d1d4f76d --- /dev/null +++ b/v2.5/toolkit/mygitcl @@ -0,0 +1 @@ +git log --pretty --numstat --summary -p . | git2cl > ChangeLog.new diff --git a/v2.5/toolkit/src/fnlo-tk-config.in b/v2.5/toolkit/src/fnlo-tk-config.in index 3e52ddfbb95aaadad352ec4b940af4a3fdc08360..6bd30540b3caa28dcb116ad62696d6848bb30614 100644 --- a/v2.5/toolkit/src/fnlo-tk-config.in +++ b/v2.5/toolkit/src/fnlo-tk-config.in @@ -21,6 +21,7 @@ if [[ $# -eq 0 || -n $( echo $* | egrep -- "--help|-h" ) ]]; then echo " --prefix : Show the installation prefix." echo " --incdir : Show the path to the include directory for fastNLO Toolkit header files." echo " --libdir : Show the path to the directory for the fastNLO Toolkit libraries." + echo " --pythondir : Show the path to the directory with the python extension if any" echo echo " --cppflags : Get compiler flags to use with the C preprocessor stage of C++ compilation" echo " --ldflags : Get compiler flags to use with the linker stage of any compilation" @@ -45,6 +46,9 @@ test -n "$tmp" && OUT="$OUT @libdir@" tmp=$( echo "$*" | egrep -- '--\<ldflags\>') test -n "$tmp" && OUT="$OUT -L@libdir@ -lfastnlotoolkit" +tmp=$( echo "$*" | egrep -- '--\<pythondir\>') +test -n "$tmp" && test -n "@pythondir@" && OUT="$OUT @prefix@@pythondir@" + ## Version& revision number tmp=$( echo "$*" | egrep -- '--\<version\>') test -n "$tmp" && OUT="$OUT @PACKAGE_VERSION@_@GITREV@" diff --git a/v2.5/toolkit/src/fnlo-tk-cppread.cc b/v2.5/toolkit/src/fnlo-tk-cppread.cc index 6483b1d2aa855065c7a122f448c9c4aabc5da0ac..1207e263e91bec9757feb969eb572252f0a560ff 100644 --- a/v2.5/toolkit/src/fnlo-tk-cppread.cc +++ b/v2.5/toolkit/src/fnlo-tk-cppread.cc @@ -108,7 +108,6 @@ int main(int argc, char** argv) { man << " Specification: <> mandatory; [] optional." << endl; man << "<fastNLOtable.tab>: Table input file, e.g. fnl2342b.tab" << endl; man << "[PDF]: PDF set, def. = CT10nlo" << endl; - man << " For LHAPDF5: Specify set names WITH filename extension, e.g. \".LHgrid\"." << endl; man << " For LHAPDF6: Specify set names WITHOUT filename extension." << endl; man << " If the PDF set still is not found, then:" << endl; man << " - Check, whether the LHAPDF environment variable is set correctly." << endl; @@ -166,11 +165,7 @@ int main(int argc, char** argv) { PDFFile = (const char*) argv[2]; } if (argc <= 2 || PDFFile == "_") { -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 PDFFile = "CT10nlo"; -#else - PDFFile = "CT10nlo.LHgrid"; -#endif shout["fnlo-tk-cppread"] << "No PDF set given, taking " << PDFFile << " instead!" << endl; } else { shout["fnlo-tk-cppread"] << "Using PDF set : " << PDFFile << endl; @@ -928,7 +923,6 @@ int main(int argc, char** argv) { //! cout << "Read from LHAPDF: Number of loops = " << nloop << endl; if ( AsEvolCode != "LHAPDF" ) fnlo->SetNLoop(NLoop);//! Default = 2, else from command line; does not work with LHAPDF. - //! Unfortunately, LHAPDF5 neither has a function to access alphas(M_Z) directly! //! double asmz = fnlo->GetAlphasMz(Mz); //! cout << "Read from LHAPDF: alpha_s at M_Z = " << asmz << endl; if ( AsEvolCode != "LHAPDF" ) { @@ -942,7 +936,6 @@ int main(int argc, char** argv) { //! fnlo->SetAlphasMz(0.1190);//! NNPDF21-NLO } - //! Nor does LHAPDF5 has a function to access M_Z! if ( AsEvolCode != "LHAPDF" ) { fnlo->SetMz(Mz);//! Default = 91.1876 (PDG), else from command line; does not work with LHAPDF. //! double Mz = 91.174; //! ABM11 diff --git a/v2.5/toolkit/src/fnlo-tk-example.cc b/v2.5/toolkit/src/fnlo-tk-example.cc index ffa9144462aa506d42f5339740a0192968cd2fe2..073416df3fddd0cc29fb072bfe8ca5e7ac9b4a73 100644 --- a/v2.5/toolkit/src/fnlo-tk-example.cc +++ b/v2.5/toolkit/src/fnlo-tk-example.cc @@ -61,11 +61,7 @@ int main(int argc, char** argv) { shout["fnlo-tk-example"] << "fastNLO Example Evaluator" << endl; yell << _SSEPSC << endl; string tablename; -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 string PDFFile = "CT10nlo"; -#else - string PDFFile = "CT10nlo.LHgrid"; -#endif if (argc <= 1) { error["fnlo-tk-example"] << "No fastNLO table specified!" << endl; shout["fnlo-tk-example"] << "For an explanation of command line arguments type:" << endl; @@ -85,7 +81,6 @@ int main(int argc, char** argv) { man << " Arguments: <> mandatory; [] optional." << endl; man << "<fastNLOtable.tab>: Table input file fnl2342b.tab" << endl; man << "[PDF]: PDF set, def. = CT10nlo" << endl; - man << " For LHAPDF5: Specify set names WITH filename extension, e.g. \".LHgrid\"." << endl; man << " For LHAPDF6: Specify set names WITHOUT filename extension." << endl; man << " If the PDF set still is not found, then:" << endl; man << " - Check, whether the LHAPDF environment variable is set correctly." << endl; @@ -172,7 +167,6 @@ int main(int argc, char** argv) { //! --- Example calculation of cross section including PDF uncertainty using LHAPDF6 specifically //! -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 vector<LHAPDF::PDFUncertainty> PDFUnc = fnlo.GetPDFUncertaintyLHAPDF(); //! Using the following call the CL can be changed and the alternativ asymmetric NNPDF uncertainty //! around the median as implemented in LHAPDF6 can be switched on. @@ -194,7 +188,6 @@ int main(int argc, char** argv) { //! Finish? return 0; -#endif //! --- Example filling of ROOT histogram with previously calculated cross section and uncertainty diff --git a/v2.5/toolkit/src/fnlo-tk-rootout.cc b/v2.5/toolkit/src/fnlo-tk-rootout.cc index 06e70cfc269af06fa6fa43f12297f1375c21a3bb..75f6d3abf263cb639c3e7aed4ffa637004e10ece 100644 --- a/v2.5/toolkit/src/fnlo-tk-rootout.cc +++ b/v2.5/toolkit/src/fnlo-tk-rootout.cc @@ -92,7 +92,6 @@ int main(int argc, char** argv) { man << " Arguments: <> mandatory; [] optional." << endl; man << "<fastNLOtable.tab>: Table input file, e.g. fnl2342b.tab" << endl; man << "[PDF]: PDF set, def. = series of CT14nlo, MMHT2014nlo68cl, NNPDF30_nlo_as_0118, PDF4LHC15_nlo_mc" << endl; - man << " For LHAPDF5: Specify set names WITH filename extension, e.g. \".LHgrid\"." << endl; man << " For LHAPDF6: Specify set names WITHOUT filename extension." << endl; man << " If the PDF set still is not found, then:" << endl; man << " - Check, whether the LHAPDF environment variable is set correctly." << endl; @@ -105,9 +104,7 @@ int main(int argc, char** argv) { man << " HP (pairwise asymmetric Hessian PDF uncertainty --> CTEQ|MSTW PDFs)" << endl; man << " HC (pairwise asymmetric Hessian PDF uncertainty rescaled to CL68 --> CTEQ PDFs)" << endl; man << " MC (MC sampling PDF uncertainty --> NNPDF PDFs)" << endl; -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 man << " L6 (LHAPDF6 PDF uncertainty --> LHAPDF6 PDFs)" << endl; -#endif man << "[order]: Fixed-order precision to use, def. = series up to highest fixed-order available" << endl; man << " Alternatives: LO, NLO, NNLO (if available)" << endl; man << "[norm]: Normalize if applicable, def. = no." << endl; @@ -171,11 +168,9 @@ int main(int argc, char** argv) { } else if ( chunc == "MC" ) { ePDFUnc = kMCSampling; shout["fnlo-tk-rootout"] << "Showing MC sampling PDF uncertainty (--> NNPDF PDFs)." << endl; -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 } else if ( chunc == "L6" ) { ePDFUnc = kLHAPDF6; shout["fnlo-tk-rootout"] << "Showing LHAPDF6 PDF uncertainty (--> LHAPDF6 PDFs)." << endl; -#endif } else { error["fnlo-tk-rootout"] << "Illegal choice of uncertainty, " << chunc << ", aborted!" << endl; exit(1); @@ -255,11 +250,7 @@ int main(int argc, char** argv) { //! --- Prepare loop over PDF sets const int nsets = 4; -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 string StandardPDFSets[nsets] = {"CT14nlo", "MMHT2014nlo68cl", "NNPDF30_nlo_as_0118", "PDF4LHC15_nlo_mc"}; -#else - string StandardPDFSets[nsets] = {"CT10nlo.LHgrid", "MSTW2008nlo68cl.LHgrid", "NNPDF21_100.LHgrid", "NNPDF10_100.lHpdf"}; -#endif EPDFUncertaintyStyle ePDFUncs[nsets] = {kHessianCTEQCL68, kHessianAsymmetricMax, kMCSampling, kMCSampling}; vector < string > PDFFiles; diff --git a/v2.5/toolkit/src/fnlo-tk-statunc.cc b/v2.5/toolkit/src/fnlo-tk-statunc.cc index d4a7d26448cb28d7e39207ee24b12daecc7c46c5..751fb5a71904271df0a2e44cac0d6dbac54eccda 100644 --- a/v2.5/toolkit/src/fnlo-tk-statunc.cc +++ b/v2.5/toolkit/src/fnlo-tk-statunc.cc @@ -101,7 +101,6 @@ int main(int argc, char** argv) { man << "<fastNLOsample>: Basename of table input files, e.g. fnl2452_I1082936_v23_flex-hhc-born-2jet_," << endl; man << " that will be complemented by 'nnnn.tab'" << endl; man << "[PDF]: PDF set, def. = CT10nlo" << endl; - man << " For LHAPDF5: Specify set names WITH filename extension, e.g. \".LHgrid\"." << endl; man << " For LHAPDF6: Specify set names WITHOUT filename extension." << endl; man << " If the PDF set still is not found, then:" << endl; man << " - Check, whether the LHAPDF environment variable is set correctly." << endl; @@ -128,11 +127,7 @@ int main(int argc, char** argv) { PDFFile = (const char*) argv[2]; } if (argc <= 2 || PDFFile == "_") { -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 PDFFile = "CT10nlo"; -#else - PDFFile = "CT10nlo.LHgrid"; -#endif shout["fnlo-tk-statunc"] << "No PDF set given, taking " << PDFFile << " instead!" << endl; } else { shout["fnlo-tk-statunc"] << "Using PDF set : " << PDFFile << endl; diff --git a/v2.5/toolkit/src/fnlo-tk-yodaout.cc b/v2.5/toolkit/src/fnlo-tk-yodaout.cc index bb8c8a121066c7b7cc011b2ca68c134e820ebf60..5ad715bf03b07cd1a8979456e965c80a13013791 100644 --- a/v2.5/toolkit/src/fnlo-tk-yodaout.cc +++ b/v2.5/toolkit/src/fnlo-tk-yodaout.cc @@ -92,7 +92,6 @@ int main(int argc, char** argv) { man << " Arguments: <> mandatory; [] optional." << endl; man << "<fastNLOtable.tab>: Table input file, e.g. fnl2342b.tab" << endl; man << "[PDF]: PDF set, def. = CT10nlo" << endl; - man << " For LHAPDF5: Specify set names WITH filename extension, e.g. \".LHgrid\"." << endl; man << " For LHAPDF6: Specify set names WITHOUT filename extension." << endl; man << " If the PDF set still is not found, then:" << endl; man << " - Check, whether the LHAPDF environment variable is set correctly." << endl; @@ -107,9 +106,7 @@ int main(int argc, char** argv) { man << " HP (pairwise asymmetric Hessian PDF uncertainty --> CTEQ|MSTW PDFs)" << endl; man << " HC (pairwise asymmetric Hessian PDF uncertainty rescaled to CL68 --> CTEQ PDFs)" << endl; man << " MC (MC sampling PDF uncertainty --> NNPDF PDFs)" << endl; -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 man << " L6 (LHAPDF6 PDF uncertainty --> LHAPDF6 PDFs)" << endl; -#endif man << " AS (a_s(M_Z) variation uncertainty with GRV evolution)" << endl; man << " ST (statistical uncertainty of x section calculation, if available)" << endl; man << "[order]: Fixed-order precision to use, def. = NLO" << endl; @@ -145,11 +142,7 @@ int main(int argc, char** argv) { PDFFile = (const char*) argv[2]; } if (argc <= 2 || PDFFile == "_") { -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 PDFFile = "CT10nlo"; -#else - PDFFile = "CT10nlo.LHgrid"; -#endif shout["fnlo-tk-yodaout"] << "No PDF set given, taking " << PDFFile << " instead!" << endl; } else { shout["fnlo-tk-yodaout"] << "Using PDF set : " << PDFFile << endl; @@ -191,11 +184,9 @@ int main(int argc, char** argv) { } else if ( chunc == "MC" ) { ePDFUnc = kMCSampling; shout["fnlo-tk-yodaout"] << "Showing MC sampling PDF uncertainty (--> NNPDF PDFs)." << endl; -#if defined LHAPDF_MAJOR_VERSION && LHAPDF_MAJOR_VERSION == 6 } else if ( chunc == "L6" ) { ePDFUnc = kLHAPDF6; shout["fnlo-tk-yodaout"] << "Showing LHAPDF6 PDF uncertainty (--> LHAPDF6 PDFs)." << endl; -#endif } else if ( chunc == "AS" ) { eAsUnc = kAsGRV; shout["fnlo-tk-yodaout"] << "Showing a_s(M_Z) uncertainty with GRV evolution." << endl;