Re: [fossil-users] autosetup build issues
On 20/02/2012, at 11:16 AM, Jan Danielsson wrote: > On 02/20/12 01:24, Richard Hipp wrote: > [---] >>> The dynamic linking works, but unfortunately on these particular >>> [Solaris] >>> systems I want static linking. :) >> >> I agree that static linking is nice. Unfortunately, the Solaris developers >> of Sun and now Oracle disagree. > [---] > > It seems I'm in an uphill struggle; even more so than I initially > thought. I won't put any more work into the static linking then, as I > suspect I'm a corner case. > > Anywho, my primary concern was getting OpenSSL statically linked into > fossil -- and using a slightly modified version of the final link > command line I got what I wanted. And if anyone else needs/wants it, the > information is easily found via a web search. That works for me. I don't think it is worth it to try to make this work out of the box. Cheers, Steve -- µWeb: Embedded Web Framework - http://uweb.workware.net.au/ WorkWare Systems Pty Ltd W: www.workware.net.au P: +61 434 921 300 E: ste...@workware.net.au F: +61 7 3391 6002 ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] autosetup build issues
On 02/20/12 01:24, Richard Hipp wrote: [---] >>The dynamic linking works, but unfortunately on these particular >> [Solaris] >> systems I want static linking. :) > > I agree that static linking is nice. Unfortunately, the Solaris developers > of Sun and now Oracle disagree. [---] It seems I'm in an uphill struggle; even more so than I initially thought. I won't put any more work into the static linking then, as I suspect I'm a corner case. Anywho, my primary concern was getting OpenSSL statically linked into fossil -- and using a slightly modified version of the final link command line I got what I wanted. And if anyone else needs/wants it, the information is easily found via a web search. -- Kind regards, Jan Danielsson ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] autosetup build issues
On Sun, Feb 19, 2012 at 7:11 PM, Jan Danielsson wrote: > > > Can we address the dynamic configure/build issues, and then possibly > > revisit static linking? > >The dynamic linking works, but unfortunately on these particular > [Solaris] > systems I want static linking. :) > I agree that static linking is nice. Unfortunately, the Solaris developers of Sun and now Oracle disagree. Hal Pomeranz at http://www.deer-run.com/~hal/sol-static.txt writes that "Solaris has historically made it difficult to statically compile "interesting" binaries." Beginning with Solaris 10, static linking is not just difficult, it has become impossible. See https://blogs.oracle.com/rie/entry/static_linking_where_did_it for details. -- D. Richard Hipp d...@sqlite.org ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] autosetup build issues
On 02/19/12 23:28, Steve Bennett wrote: >> For the record (in case someone finds this via a web search): I think >> there's something odd about the openssl detection. I had built openssl >> without the "shared" option (so I only had the shared libraries). But > > Building without "shared" meant you only had the shared libraries?? Oops; I meant I only had "static" libraries. Sorry for the confusion. >> even with "configure --static" (in fossil), I ran into linking problems. >> Building openssl with the "shared" option made those problems go away. I >> haven't looked into it more closely, as the workaround is trivial, and I >> think most people will have the shared libraries laying around anyway. > With the fix I sent earlier, does openssl detection work properly? It started working once I had built the dynamic OpenSSL libraries. That's what I thought felt odd -- the detection seemed to fail to find the OpenSSL static libs, even though "--static" was passed. [---] > How about forget about static linking and just use dynamic linking? Oh, I got dynamic linking working yesterday; that's not a problem -- but as I wrote in my other mail, I'm specifically looking to dynamically link (more specifically: with OpenSSL). (I stress that this is not something I'm doing to torture myself, I'm using a network of several Solaris systems, and I want to be able to build one fossil binary and move it around; so there's a practical reason for my battle with static builds on Solaris). > Can we address the dynamic configure/build issues, and then possibly > revisit static linking? The dynamic linking works, but unfortunately on these particular systems I want static linking. :) -- Kind regards, Jan Danielsson ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users
Re: [fossil-users] autosetup build issues
On 19/02/2012, at 1:44 PM, Jan Danielsson wrote: > Hello, > > I've been trying to get fossil to build using the auto-configurator > on Solaris/sparc 9, and have encountered some minor bumps in the road. > > For the record (in case someone finds this via a web search): I think > there's something odd about the openssl detection. I had built openssl > without the "shared" option (so I only had the shared libraries). But Building without "shared" meant you only had the shared libraries?? > even with "configure --static" (in fossil), I ran into linking problems. > Building openssl with the "shared" option made those problems go away. I > haven't looked into it more closely, as the workaround is trivial, and I > think most people will have the shared libraries laying around anyway. With the fix I sent earlier, does openssl detection work properly? > > Now there are just two issues remaining, and unfortunately I'm not > quite sure what to do about them. > > 1) The SunStudio compiler doesn't support -static; it uses -Bstatic > and -Bdynamic. > > 2) While zlib is a system library on Solaris 9, it doesn't appear to > have libz.a (only libz.so). This means that the final link line needs to > look something like this: > > [...] -Bdynamic -L/opt/openssl-1.0.0g/lib -lz -ldl -Bstatic -lssl > -lcrypto -lnsl -lsocket > > > My Tcl-Fu is painfully limited and hence I understand near-zero of > autosetup, but as far as I can gather the current autosetup/auto.def > isn't really designed to handle compiler differences and mix static and > dynamic linking? > > What I would like to do: > > 1) Add compiler detection (In this case: find sunstudio, default to > whatever gcc does) > > 2) Set dynamic/static link flags (-static vs -Bstatic, etc) depending > on compiler > > 3) Introduce a DLIBS which will unconditionally be dynamically > linked, regardless of whether --static is used or not. How about forget about static linking and just use dynamic linking? Even on Linux, static linking is a bit of a minefield. Can we address the dynamic configure/build issues, and then possibly revisit static linking? Cheers, Steve > > I realize there's something conceptually very wrong about dynamically > linking when it was explicitly requested by the users that static > linking be used. At the same time, the way I look at it, the project > should build and run on standard OS installations, with as few separate > dependencies as possible. > > Input is welcome. > > -- > Kind regards, > Jan Danielsson > > ___ > fossil-users mailing list > fossil-users@lists.fossil-scm.org > http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users -- µWeb: Embedded Web Framework - http://uweb.workware.net.au/ WorkWare Systems Pty Ltd W: www.workware.net.au P: +61 434 921 300 E: ste...@workware.net.au F: +61 7 3391 6002 ___ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users