bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

ncurses 5.6 runs ld directly on file in /usr/lib/, killing system


From: Adam J. Richter
Subject: ncurses 5.6 runs ld directly on file in /usr/lib/, killing system
Date: Fri, 16 Feb 2007 09:29:44 +0800

        If one configures ncurses-5.6 with the "--with-shared" option
and then does a "make install" (after doing a "make"), the following
command is executed:

gcc -O2 -shared -Wl,-soname,`basename /usr/lib/libncurses.so.5.6 
.5.6`.5,-stats,-lc -o /usr/lib/libncurses.so.5.6 ../obj_s/hardscroll.o [...etc, 
etc...]

        Notice the "-o /usr/lib/libncurses.so.5.6".  If "make install"
is being used to install the same version (5.6) of ncurses, it means
that while ld is in the midst of linking the new libncurses.so.5.6,
attempts by any other process on the system to execute any binary on
the system that dynamically links ncurses will fail.  Among the many
programs that link ncurses on my system is bash.

        This is particularly bad when tracking the install with
trackfs, as trackfs then errors out, causing the install to abort,
leaving a non-functional ncurses shared library.  Of course, I think
trackfs I should analyze and probably fix whatever dependence causes
trackfs to break when ncurses is non-functional, but it still seems
like a terrible practice to me for any software package to run ld
directly on a shared library in /usr/lib, as ld can fail for numerous
reasons, and programs that might be used to clean up after ld failure
might have unexpected shared library dependencies.  Therefore, the
link should be done in the build directory, and the shared library
should be installed by the "install" command or something similar.

Adam Richter
address@hidden

P.S. I apologize if this is a known bug.  I checked the INSTALL file,
     per the instructions in the README file.  I made a cursory effort to
     find such a the mailing list archive by grepping for "archive" in the
     doc/ subdirectory and INSTALL and README files, and also checked a
     search engine.  By the way, if there is an archive of the bug-ncurses
     mailing list and I did not overlook its mention somewhere, it would
     be helpful to mention it in the README file or somewhere similar.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]