On Tue, Mar 4, 2014 at 5:35 PM, Chet Ramey <[email protected]> wrote: > > On 3/4/14 10:56 AM, Natanael Copa wrote: > > > Ok. I figured it out now. What actually happened is that I only added > > SHLIB_LIBS=-lncurses during 'make' phase but not during 'make install'. > > Adding SHLIB_LIBS to 'make install' or adding ./configure --disable-static > > solved it. I guess that building static makes the shared lib relink during > > make install phase. possibly due to a gnu make race condition on multicores > > but I havent investigated that. > > I can see a possibility of a race condition. However, when I first run
... > I'm not running parallel makes in these examples, but a quick test using > gmake -j 4 duplicates the results. I'm using RHEL5. I don't know what > else to tell you. I suppose that 12 cores with hyper threading, make -j24 and ccache makes the difference. I think I have found it. from: http://git.savannah.gnu.org/cgit/readline.git/commit/shlib/Makefile.in?id=7628b745a813aac53586b640da056a975f1c443e @@ -350,9 +377,12 @@ terminal.so: $(topdir)/rlprivate.h text.so: $(topdir)/rlprivate.h undo.so: $(topdir)/rlprivate.h util.so: $(topdir)/rlprivate.h -vi_mode.so: $(topdir)/rlprivate.h +vi_mode.so: $(topdir)/ +colors.so: $(topdir)/rlprivate.h +parse-colors.so: $(topdir)/rlprivate.h bind.so: $(topdir)/xmalloc.h +callback.so: $(topdir)/xmalloc.h complete.so: $(topdir)/xmalloc.h display.so: $(topdir)/xmalloc.h funmap.so: $(topdir)/xmalloc.h I think it is the vi_mode.so: $(topdir)/ that does it. when building with --disable-static it does not reproduce because nothing in $(topdir)/ changes. Without the --disable-static anything in $(topdir)/ will update the timestamp which will force a rebuild of shlib/vi_mode.so which again will force a relink of the library. I found it out because during make install i see this: make[1]: Entering directory '/home/ncopa/aports/main/readline/src/readline-6.3/shlib' rm -f vi_mode.so ccache gcc -c -DHAVE_CONFIG_H -Os -fomit-frame-pointer -I. -I.. -I.. -DRL_LIBRARY_VERSION='"6.3"' -Os -fomit-frame-pointer -fPIC -o vi_mode.o ../vi_mode.c mv vi_mode.o vi_mode.so rm -f libreadline.so.6.3 ccache gcc -shared -Wl,-soname,libreadline.so.6.3 -Wl,--as-needed -Wl,-rpath,/usr/lib -Wl,-soname,`basename libreadline.so.6.3 .3` -o libreadline.so.6.3 readline.so vi_mode.so funmap.so keymaps.so parens.so search.so rltty.so complete.so bind.so isearch.so display.so signals.so util.so kill.so undo.so macro.so input.so callback.so terminal.so text.so nls.so misc.so history.so histexpand.so histfile.so histsearch.so shell.so mbutil.so tilde.so colors.so parse-colors.so xmalloc.so xfree.so compat.so make[1]: Leaving directory '/home/ncopa/aports/main/readline/src/readline-6.3/shlib' So something makes vi_mode.so rebuild. Simply removing the rule 'vi_mode.so: $(topdir)/' makes things work as expected: --- a/shlib/Makefile.in +++ b/shlib/Makefile.in @@ -375,7 +375,6 @@ text.so: $(topdir)/rlprivate.h undo.so: $(topdir)/rlprivate.h util.so: $(topdir)/rlprivate.h -vi_mode.so: $(topdir)/ colors.so: $(topdir)/rlprivate.h parse-colors.so: $(topdir)/rlprivate.h -- Natanael Copa
_______________________________________________ Bug-readline mailing list [email protected] https://lists.gnu.org/mailman/listinfo/bug-readline
