libtool
[Top][All Lists]
Advanced

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

Re: Error messages


From: Gabriel de Perthuis
Subject: Re: Error messages
Date: Wed, 14 Jul 2004 19:03:15 +0200
User-agent: Mozilla Thunderbird 0.7 (X11/20040615)

Gabriel de Perthuis wrote:

When libtool encouters an error about a missing library (for example, if a .la refers to a file which is not found), it would be good to give more explicit errors. In my case, it was a problem of nested dependencies; the error was not due to $lib (the dependency of the dependency) but too $name (the dependency) which had been compiled when $lib was in another directory; so the solution was to rebuild $name not $lib.
Here is a patch giving a message with $name and $laname:
--- /usr/bin/libtool    2004-02-11 10:35:02.000000000 +0100
+++ libtool     2004-07-14 17:18:53.992827152 +0200
@@ -1838,6 +1838,7 @@
       if test "$found" = yes || test -f "$lib"; then :
       else
         $echo "$modename: cannot find the library \`$lib'" 1>&2
+ $echo "It was referenced from library \`$name' 's libtool archive, \`$laname'" 1>&2
         exit 1
       fi



_______________________________________________
Libtool mailing list
address@hidden
http://lists.gnu.org/mailman/listinfo/libtool

Here is a patch that also updates the 'not a libtool archive' messages. It has proved rather useful and helped me debugging dependencies of dependencies problems.
--- /usr/bin/libtool    2004-02-11 10:35:02.000000000 +0100
+++ libtool     2004-07-14 18:54:36.747795696 +0200
@@ -1838,6 +1838,7 @@
        if test "$found" = yes || test -f "$lib"; then :
        else
          $echo "$modename: cannot find the library \`$lib'" 1>&2
+         $echo "It was referenced from library \`$name' 's libtool archive, 
\`$laname'" 1>&2
          exit 1
        fi
 
@@ -1845,6 +1846,7 @@
        if (${SED} -e '2q' $lib | egrep "^# Generated by .*$PACKAGE") 
>/dev/null 2>&1; then :
        else
          $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2
+         $echo "It was referenced from library \`$name' 's libtool archive, 
\`$laname'" 1>&2
          exit 1
        fi
 
@@ -2369,6 +2371,8 @@
                  eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
                  if test -z "$libdir"; then
                    $echo "$modename: \`$deplib' is not a valid libtool 
archive" 1>&2
+                   $echo "It was referenced from library \`$name' 's libtool 
archive, \`$laname'" 1>&2
+
                    exit 1
                  fi
                  if test "$absdir" != "$libdir"; then
@@ -4304,6 +4308,7 @@
                eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
                if test -z "$libdir"; then
                  $echo "$modename: \`$deplib' is not a valid libtool archive" 
1>&2
+                 $echo "It was referenced from library \`$name' 's libtool 
archive, \`$laname'" 1>&2
                  exit 1
                fi
                newdependency_libs="$newdependency_libs $libdir/$name"
@@ -4318,6 +4323,7 @@
              eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
              if test -z "$libdir"; then
                $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2
+               $echo "It was referenced from library \`$name' 's libtool 
archive, \`$laname'" 1>&2
                exit 1
              fi
              newdlfiles="$newdlfiles $libdir/$name"
@@ -4329,6 +4335,7 @@
              eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib`
              if test -z "$libdir"; then
                $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2
+               $echo "It was referenced from library \`$name' 's libtool 
archive, \`$laname'" 1>&2
                exit 1
              fi
              newdlprefiles="$newdlprefiles $libdir/$name"
@@ -4553,6 +4560,7 @@
        if (${SED} -e '2q' $file | egrep "^# Generated by .*$PACKAGE") 
>/dev/null 2>&1; then :
        else
          $echo "$modename: \`$file' is not a valid libtool archive" 1>&2
+         $echo "It was referenced from library \`$name' 's libtool archive, 
\`$laname'" 1>&2
          $echo "$help" 1>&2
          exit 1
        fi
@@ -4966,6 +4974,7 @@
        if (${SED} -e '2q' $file | egrep "^# Generated by .*$PACKAGE") 
>/dev/null 2>&1; then :
        else
          $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2
+         $echo "It was referenced from library \`$name' 's libtool archive, 
\`$laname'" 1>&2
          $echo "$help" 1>&2
          exit 1
        fi

reply via email to

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