On Wed, 30 Jan 2013, Jan Nijtmans wrote: > 2013/1/29 Stephan Beal: > > On Tue, Jan 29, 2013 at 9:00 AM, K. Fossil user wrote: > >> Latest stable release or dev release does not compile with option: > >> --static > > ... > > Like networking libs, it will produce warnings like: > > > > warning: Using 'dlopen' in statically linked applications requires > > at runtime the shared libraries from the glibc version used for > > linking > > Those are only warnings, the executable should work fine. I tried it, > and encountered 2 minor problems on Linux: > - "strcmp" from the static C library cannot be used, it should be > replaced by "fossil_strcmp" everywhere. (that's a good idea anyway, as > strcmp is locale-dependant) > >Fossil's TCL support also appears to use dlopen()
[snip] > The first problem is fixed now on trunk, the second one should be easy > to fix (for someone who understands the build system better than I > do). [FYI] An optimized (-O2) default build with entered substitution -Dstrcmp=fossil_strcmp fails (SIGSEG) on i686 GNU/Linux Reading symbols from /home/sg/fossil/build/fossil...done. (gdb) set args clean --force (gdb) run Starting program: /home/sg/fossil/build/fossil clean --force Program received signal SIGSEGV, Segmentation fault. fossil_strcmp (zA=0xbffff452 "force", zB=0x0) at ../src/printf.c:908 908 b = *zB++; (gdb) bt #0 fossil_strcmp (zA=0xbffff452 "force", zB=0x0) at ../src/printf.c:908 #1 0x0808d73c in find_option (zLong=0x815454b "quiet", zShort=0x0, hasArg=0) at ../src/main.c:865 #2 0x080902ca in main (argc=3, argv=0xbffff294) at ../src/main.c:510 (gdb) detach Detaching from program: /home/sg/fossil/build/fossil, process 18084 (gdb) q % ./fossil version This is fossil version 1.25 [7ac0fd9d11] 2013-01-30 10:03:19 UTC The -O0 build does parse the same option without the issue. Sergei _______________________________________________ fossil-users mailing list fossil-users@lists.fossil-scm.org http://lists.fossil-scm.org:8080/cgi-bin/mailman/listinfo/fossil-users