automake-patches
[Top][All Lists]
Advanced

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

37-fyi-rm-dead-require-conf-files.patch


From: Akim Demaille
Subject: 37-fyi-rm-dead-require-conf-files.patch
Date: Sun, 21 Oct 2001 20:12:34 +0200

Index: ChangeLog
from  Akim Demaille  <address@hidden>
        * automake.in ($libtool_line, $seen_pythondir): Replace with...
        ($libtool_location, $pythondir_location): these.
        (&require_conf_file_with_line, &require_conf_file_with_line):
        Remove, unused.
        (&require_file): Don't forget $where.
        (&require_conf_file): Ahem...  Fix the name.
        (&require_config_file): Invoke &require_conf_file, not yourself.
        (&am_line_error): Fix the default am_file_error invocation.
        
        
Index: automake.in
--- automake.in Sun, 21 Oct 2001 17:50:34 +0200 akim
+++ automake.in Sun, 21 Oct 2001 17:59:15 +0200 akim
@@ -400,7 +400,7 @@ sub target_hook ($$$$)
 
 # TRUE if we've seen AC_PROG_LIBTOOL.
 my $seen_libtool = 0;
-my $libtool_line = 0;
+my $libtool_location;
 
 # TRUE if we've seen AM_MAINTAINER_MODE.
 my $seen_maint_mode = 0;
@@ -414,8 +414,8 @@ sub target_hook ($$$$)
 # Where AM_PATH_LISPDIR appears.
 my $am_lispdir_location;
 
-# TRUE if we've seen AM_PATH_PYTHON.
-my $seen_pythondir = 0;
+# Where AM_PATH_PYTHON appears.
+my $pythondir_location;
 
 # TRUE if we've seen AC_ENABLE_MULTILIB.
 my $seen_multilib = 0;
@@ -2494,8 +2494,7 @@ sub handle_libtool
     return unless $seen_libtool;
 
     # libtool requires some files, but only at top level.
-    &require_conf_file_with_conf_line ($libtool_line, $FOREIGN,
-                                      @libtoolize_files)
+    require_conf_file ($libtool_location, $FOREIGN, @libtoolize_files)
        if $relative_dir eq '.';
 
     # Output the libtool compilation rules.
@@ -4328,10 +4327,9 @@ sub handle_python
 
     # Found some python.
     &am_error ("`python_PYTHON' defined but `AM_PATH_PYTHON' not in 
`$configure_ac'")
-       if ! $seen_pythondir && &variable_defined ('python_PYTHON');
+       if ! $pythondir_location && &variable_defined ('python_PYTHON');
 
-    &require_conf_file_with_conf_line ('AM_PATH_PYTHON',
-                                      $FOREIGN, 'py-compile');
+    require_conf_file ($pythondir_location, $FOREIGN, 'py-compile');
     &define_variable ('py_compile', $config_aux_dir . '/py-compile');
 }
 
@@ -4511,7 +4509,7 @@ sub scan_autoconf_traces ($)
       elsif ($macro =~ /A(C|M)_PROG_LIBTOOL/)
        {
          $seen_libtool = $here;
-         $libtool_line = $line;
+         $libtool_location = $line;
        }
       elsif ($macro =~ /AC_PROG_LEX/)
        {
@@ -4571,7 +4569,7 @@ sub scan_autoconf_traces ($)
        }
       elsif ($macro eq 'AM_PATH_PYTHON')
        {
-         $seen_pythondir = $here;
+         $pythondir_location = $here;
        }
       elsif ($macro eq 'AM_PROG_CC_C_O')
        {
@@ -4860,7 +4858,7 @@ sub scan_one_autoconf_file
 
         if (/AM_PATH_PYTHON/)
          {
-           $seen_pythondir = $here;
+           $pythondir_location = $here;
            $configure_vars{'pythondir'} = $here;
            $configure_vars{'PYTHON'} = $here;
          }
@@ -4878,7 +4876,7 @@ sub scan_one_autoconf_file
            #   &am_file_warning ($here, "`AM_PROG_LIBTOOL' is obsolete, use 
`AC_PROG_LIBTOOL' instead");
            # }
            $seen_libtool = $here;
-           $libtool_line = $.;
+           $libtool_location = $here;
            $configure_vars{'LIBTOOL'} = $here;
            $configure_vars{'RANLIB'} = $here;
            $configure_vars{'CC'} = $here;
@@ -4959,7 +4957,7 @@ sub scan_autoconf_files
         if -f $config_aux_path[0] . '/install.sh';
 
     &require_config_file ($FOREIGN, 'py-compile')
-       if $seen_pythondir;
+       if $pythondir_location;
 
     # Preserve dist_common for later.
     $configure_dist_common = variable_value ('DIST_COMMON', 'TRUE') || '';
@@ -7836,7 +7834,7 @@ sub require_file_internal
 # -----------------------------------------
 sub require_file ($$@)
 {
-    my ($mystrict, @files) = @_;
+    my ($where, $mystrict, @files) = @_;
     @require_file_paths = $relative_dir;
     require_file_internal ($where, $mystrict, @files);
 }
@@ -7853,7 +7851,7 @@ sub require_file_with_macro ($$@)
 
 # &require_conf_file ($WHERE, $MYSTRICT, @FILES)
 # ----------------------------------------------
-sub require_config_file ($$@)
+sub require_conf_file ($$@)
 {
     my ($where, $mystrict, @files) = @_;
     @require_file_paths = @config_aux_path;
@@ -7872,35 +7870,17 @@ sub require_config_file ($$@)
 sub require_config_file ($@)
 {
     my ($mystrict, @files) = @_;
-    require_config_file ($configure_ac, $mystrict, @files);
-}
-
-# &require_conf_file_with_line ($LINE, $MYSTRICT, @FILES)
-# -------------------------------------------------------
-# $LINE is wrt $AM_FILE.am.
-sub require_conf_file_with_line ($$@)
-{
-    my ($line, $mystrict, @files) = @_;
-    require_conf_file ("$am_file.am:$line", $mystrict, @files);
+    require_conf_file ($configure_ac, $mystrict, @files);
 }
 
 # &require_conf_file_with_macro ($MACRO, $MYSTRICT, @FILES)
 # -------------------------------------------------------
-sub require_conf_file_with_line ($$@)
+sub require_conf_file_with_macro ($$@)
 {
     my ($macro, $mystrict, @files) = @_;
     require_conf_file ($var_location{$macro}, $mystrict, @files);
 }
 
-# &require_conf_file_with_line ($LINE, $MYSTRICT, @FILES)
-# -------------------------------------------------------
-# $LINE is wrt $AM_FILE.am
-sub require_conf_file_with_conf_line ($$@)
-{
-    my ($line, $mystrict, @files) = @_;
-    require_conf_file ("$configure_ac:$line", $mystrict, @files);
-}
-
 ################################################################
 
 # &require_build_directory ($DIRECTORY)
@@ -8117,10 +8097,8 @@ sub am_line_error ($@)
        else
        {
            # Couldn't find the line number.
-           $where = "${am_file}.am";
+           am_file_error ("${am_file}.am", @args);
        }
-
-       am_file_error ($where, @args);
     }
     else
     {



reply via email to

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