summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>1999-08-30 15:37:30 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>1999-08-30 15:37:30 +0000
commit473741bb07868c035ec2e05025acfdefdd0cd6f9 (patch)
tree766d5bb2a9828ab684cf3f8ab97f68a9bca630fe
parentRemoved definition of NO_IMPLICIT_EXTERN_C since it is supposed to be (diff)
downloadrtems-473741bb07868c035ec2e05025acfdefdd0cd6f9.tar.bz2
Patch from Ralf Corsepius <corsepiu@faw.uni-ulm.de>:
1. Addition of maintainer-mode dependencies on config.status and aclocal.m4 for autoconf toplevel Makefile.ins. These rules are taken over from automake generated Makefile.ins, i.e. they are contained in any automake generated toplevel Makefile.in. Having this patch in is at least a great releaf for me when working on RTEMS configuration :) 2. Automated support for #1 in acpolish 3. Some minor "beautifications" on Makefile.ins resulting from running acpolish. FYI: This patch has been generated by running tools/update/rtems-polish.sh -ac on the source tree and manually editing the resulting patch afterwards to work around a problem with acpolish, which still corrupts one Makefile.in - WARNING: Be careful with running acpolish!
-rw-r--r--c/src/lib/Makefile.in13
-rwxr-xr-xtools/update/acpolish51
2 files changed, 53 insertions, 11 deletions
diff --git a/c/src/lib/Makefile.in b/c/src/lib/Makefile.in
index 638185babc..9d86472f0c 100644
--- a/c/src/lib/Makefile.in
+++ b/c/src/lib/Makefile.in
@@ -7,6 +7,11 @@ srcdir = @srcdir@
top_srcdir = @top_srcdir@
top_builddir = .
+ACLOCAL = aclocal
+AUTOCONF = autoconf
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+ACLOCAL_AMFLAGS = -I @RTEMS_TOPdir@/aclocal
+
RTEMS_ROOT = @RTEMS_ROOT@
PROJECT_ROOT = @PROJECT_ROOT@
@@ -46,3 +51,11 @@ CLOBBER_ADDITIONS += config.log config.cache
Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
cd $(top_builddir) \
&& CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
+
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ configure.in
+ cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
+
+config.status: $(srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ $(SHELL) ./config.status --recheck
+$(srcdir)/configure: @MAINTAINER_MODE_TRUE@$(srcdir)/configure.in $(ACLOCAL_M4)
+ cd $(srcdir) && $(AUTOCONF)
diff --git a/tools/update/acpolish b/tools/update/acpolish
index 9b1fc59edd..1fe933cfec 100755
--- a/tools/update/acpolish
+++ b/tools/update/acpolish
@@ -370,29 +370,33 @@ sub subst_line
}
}
elsif ( /^[\s]*([^\s+=]+)[\s]*\=[\s]*(.*)$/o )
- { # makefile variable
+ { # makefile variables
if ( ( "$1" eq "subdir" )
- or ( "$1" eq "top_srcdir" )
+ or ( "$1" eq "top_srcdir" )
or ( "$1" eq "top_builddir" )
or ( "$1" eq "RTEMS_ROOT" )
- or ( "$1" eq "PROJECT_ROOT" )
+ or ( "$1" eq "PROJECT_ROOT" )
or ( "$1" eq "INSTALL" )
or ( "$1" eq "PACKHEX" )
- or ( "$1" eq "INSTALL_CHANGE" )
+ or ( "$1" eq "INSTALL_CHANGE" )
or ( "$1" eq "mkinstalldirs" )
+ or ( "$1" eq "ACLOCAL" )
+ or ( "$1" eq "AUTOCONF" )
+ or ( "$1" eq "ACLOCAL_M4" )
+ or ( "$1" eq "ACLOCAL_AMFLAGS" )
)
{
- print STDERR "REMOVE: $1\n" if $verbose ;
+ print STDERR "REMOVE: $1\n" if $verbose ;
}
elsif ( "$1" eq "srcdir" )
{ # place marker
- push @tbuf, "§0\n";
+ push @tbuf, "§0\n";
}
elsif ( "$1" eq "INSTALLDIRS" )
{ # process the block
my $input = $2 ;
$input =~ s/\\\\/ /g ;
- my @l = split(' ',$input);
+ my @l = split(' ',$input);
foreach (@l)
{
if ( /[\s]*([^\s]+)[\s]*$/o )
@@ -467,7 +471,11 @@ sub subst_line
}
if ( ( "$1" eq "Makefile" )
- or ( "$1" eq "\$\(INSTALLDIRS\)" ) )
+ or ( "$1" eq "\$\(INSTALLDIRS\)" )
+ or ( "$1" eq "\$\(ACLOCAL_M4\)" )
+ or ( "$1" eq "config\.status" )
+ or ( "$1" eq "\$\(srcdir\)/configure" )
+ )
{ # delete entry
shift @buffer ;
}
@@ -578,7 +586,17 @@ if ( $experimental > 1 )
print "srcdir = \@srcdir\@\n" ;
print "top_srcdir = \@top_srcdir\@\n" ;
print "top_builddir = $top_builddir\n" ;
- print "subdir = $subdir\n" if "$subdir" ;
+ if ( "$subdir" )
+ {
+ print "subdir = $subdir\n";
+ }
+ else
+ {
+ print "\nACLOCAL = aclocal\n" ;
+ print "AUTOCONF = autoconf\n" ;
+ print "ACLOCAL_M4 = \$(top_srcdir)/aclocal.m4\n" ;
+ print "ACLOCAL_AMFLAGS = -I \@RTEMS_TOPdir\@/aclocal\n" ;
+ }
print "\nRTEMS_ROOT = \@RTEMS_ROOT\@\n" ;
print "PROJECT_ROOT = \@PROJECT_ROOT\@\n\n" ;
$nl_seen = 1 ;
@@ -639,10 +657,21 @@ print "\$@ CONFIG_HEADERS= \$(SHELL) ./config.status\n";
else
{
print "Makefile: \$(srcdir)/Makefile.in \$(top_builddir)/config.status\n" ;
-print " cd \$(top_builddir) \\\n" ;
-print " && CONFIG_FILES=" ;
+print "\tcd \$(top_builddir) \\\n" ;
+print "\t && CONFIG_FILES=" ;
print "\$(subdir)/" if ( "$subdir" );
print "\$@ CONFIG_HEADERS= \$(SHELL) ./config.status\n";
}
+if ( ! "$subdir" )
+{
+print "\n\$(ACLOCAL_M4): \@MAINTAINER_MODE_TRUE\@ configure.in\n" ;
+print "\tcd \$(srcdir) && \$(ACLOCAL) \$(ACLOCAL_AMFLAGS)\n" ;
+print "\nconfig.status: \$(srcdir)/configure \$(CONFIG_STATUS_DEPENDENCIES)\n" ;
+print "\t\$(SHELL) ./config.status --recheck\n" ;
+print "\$(srcdir)/configure: \@MAINTAINER_MODE_TRUE\@\$(srcdir)/configure.in";
+print " \$(ACLOCAL_M4)\n" ;
+print "\tcd \$(srcdir) && \$(AUTOCONF)\n"
+}
+
;1