Changeset 1676

Show
Ignore:
Timestamp:
12/19/02 16:04:15 (11 years ago)
Author:
mds
Message:

always generate warnings about libraries in /usr/lib since we can't

assume that ld.so puts /usr/lib last.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lm-sensors/trunk/lib/Module.mk

    r1675 r1676  
    8888# Generate warnings if the install directory isn't in /etc/ld.so.conf 
    8989# or if the library wasn't there before (which means ldconfig must be run). 
    90 # Don't generate warning about old versions in /usr/lib unless the new version 
    91 # won't be picked up, since ld.so looks at the directories in ld.so.conf 
    92 # before it looks at /usr/lib. 
     90# Note that some ld.so's put /usr/lib and /lib first, others put them last, 
     91# so we can't make any assumptions. 
    9392install-lib: all-lib 
    9493        $(MKDIR) $(DESTDIR)$(LIBDIR) $(DESTDIR)$(LIBINCLUDEDIR) $(DESTDIR)$(LIBMAN3DIR) $(DESTDIR)$(LIBMAN5DIR) 
     
    105104        $(LN) $(LIBSHSONAME) $(DESTDIR)$(LIBDIR)/$(LIBSHBASENAME) 
    106105        @if [ "$(DESTDIR)$(LIBDIR)" != "/usr/lib" -a "$(DESTDIR)$(LIBDIR)" != "/lib" ] ; then \ 
     106           if [ -e "/usr/lib/$(LIBSHSONAME)" ] ; then \ 
     107             echo '******************************************************************************' ;  \ 
     108             echo 'Warning: You have old $(LIBSHBASENAME)* library files in /usr/lib' ;  \ 
     109             echo '         and the new library files are in $(DESTDIR)$(LIBDIR) !!!' ; \ 
     110             echo '         These old files must be removed or the userspace tools' ; \ 
     111             echo '         will have unpredictable results !!!' ; \ 
     112             echo '         Run the following command: rm /usr/lib/$(LIBSHBASENAME)*' ; \ 
     113             echo '******************************************************************************' ;  \ 
     114           fi ; \ 
    107115           grep -q '^$(DESTDIR)$(LIBDIR)$$' /etc/ld.so.conf || \ 
    108116           grep -q '^$(DESTDIR)$(LIBDIR)[[:space:]:,=]' /etc/ld.so.conf || \ 
     
    112120                  echo 'Warning: Library directory $(DESTDIR)$(LIBDIR) not in /etc/ld.so.conf !!!' ;  \ 
    113121                  echo '         Add it and run /sbin/ldconfig for the userspace tools to work !!!' ; \ 
    114                   if [ -e "/usr/lib/$(LIBSHSONAME)" ] ; then \ 
    115                      echo '         Even worse, you have old $(LIBSHBASENAME)* library files in /usr/lib !!!' ;  \ 
    116                      echo '         These will be used instead which will cause unpredictable results !!!' ; \ 
    117                   fi ; \ 
    118122                  echo '******************************************************************************' ) ;  \ 
    119123        fi