]> asedeno.scripts.mit.edu Git - PuTTY.git/commitdiff
Merge from trunk up to r8020.
authorSimon Tatham <anakin@pobox.com>
Wed, 28 May 2008 19:28:17 +0000 (19:28 +0000)
committerSimon Tatham <anakin@pobox.com>
Wed, 28 May 2008 19:28:17 +0000 (19:28 +0000)
[originally from svn r8021]
[r8020 == 14d825d42fb4d36f671ea4d05c6d254f7796c7e5]

1  2 
mkauto.sh

diff --cc mkauto.sh
index 5e394f8db139accc5681ff4b45d9c205adc5a0b3,334a110b794689802b21ecf01356dc1fecfcc687..078669430159c747c3fc0ac206b142eda02c7288
+++ b/mkauto.sh
@@@ -3,10 -3,41 +3,45 @@@
  # It's separate from mkfiles.pl because it won't work (and isn't needed)
  # on a non-Unix system.
  
- # Track down automake's copy of install-sh
- cp `aclocal --print-ac-dir | sed 's/aclocal$/automake/'`/install-sh unix/.
- (cd unix && autoreconf  && rm -rf aclocal.m4 autom4te.cache)
 +# It's nice to be able to run this from inside the unix subdir as
 +# well as from outside.
 +test -f unix.h && cd ..
 +
+ # Persuade automake to give us a copy of its install-sh. This is a
+ # pain because I don't actually want to have to _use_ automake.
+ # Instead, I construct a trivial unrelated automake project in a
+ # temporary subdirectory, run automake so that it'll copy
+ # install-sh into that directory, then copy it back out again.
+ # Hideous, but it should work.
+ mkdir automake-grievous-hack
+ cat > automake-grievous-hack/hello.c << EOF
+ #include <stdio.h>
+ int main(int argc, char **argv)
+ {
+     printf("hello, world\n");
+     return 0;
+ }
+ EOF
+ cat > automake-grievous-hack/Makefile.am << EOF
+ bin_PROGRAMS = hello
+ hello_SOURCES = hello.c
+ EOF
+ cat > automake-grievous-hack/configure.ac << EOF
+ AC_INIT
+ AM_INIT_AUTOMAKE(hello, 1.0)
+ AC_CONFIG_FILES([Makefile])
+ AC_PROG_CC
+ AC_OUTPUT
+ EOF
+ echo Some news > automake-grievous-hack/NEWS
+ echo Some text > automake-grievous-hack/README
+ echo Some people > automake-grievous-hack/AUTHORS
+ echo Some changes > automake-grievous-hack/ChangeLog
+ rm -f install-sh # this won't work if we accidentally have one _here_
+ (cd automake-grievous-hack && autoreconf -i && \
+   cp install-sh ../unix/install-sh)
+ rm -rf automake-grievous-hack
+ # That was the hard bit. Now run autoconf on our real configure.in.
+ (cd unix && autoreconf && rm -rf aclocal.m4 autom4te.cache)