$! We do not use the configure script, since we do not have /bin/sh
$! to execute it.
$!
-$! Written by Klaus K"ampf (kkaempf@progis.de)
+$! Written by Klaus K"ampf (kkaempf@rmi.de)
$!
$arch_indx = 1 + ((f$getsyi("CPU").ge.128).and.1) ! vax==1, alpha==2
$arch = f$element(arch_indx,"|","|VAX|Alpha|")
-$if arch .eqs. "VAX"
-$then
-$ write sys$output "Target VAX not supported."
-$ exit 2
-$endif
$!
$!
$! Generate config.h
/* Do we need to use the b modifier when opening binary files? */
/* #undef USE_BINARY_FOPEN */
/* Define if you have the sbrk function. */
-#define HAVE_SBRK 1
+/* #undef HAVE_SBRK 1 */
/* Define if you have the utimes function. */
#define HAVE_UTIMES 1
/* Define if you have the <fcntl.h> header file. */
$ write sys$output "Generated `config.h'"
$!
$!
-$! Edit VERSION in makefile.vms
+$! Edit VERSION in makefile.vms-in
$!
$ edit/tpu/nojournal/nosection/nodisplay/command=sys$input -
- []makefile.vms /output=[]makefile.vms
+ []makefile.vms-in /output=[]makefile.vms
$DECK
!
-! Get VERSION from Makefile.in
+! Get VERSION from configure.in
!
- mfile := CREATE_BUFFER("mfile", "Makefile.in");
+ mfile := CREATE_BUFFER("mfile", "[-.bfd]CONFIGURE.IN");
rang := CREATE_RANGE(BEGINNING_OF(mfile), END_OF(mfile));
- v_pos := SEARCH_QUIETLY('VERSION=', FORWARD, EXACT, rang);
- POSITION(BEGINNING_OF(v_pos));
- vers := CURRENT_LINE;
+ match_pos := SEARCH_QUIETLY('AM_INIT_AUTOMAKE(bfd, ', FORWARD, EXACT, rang);
IF match_pos <> 0 THEN;
- file := CREATE_BUFFER("file", GET_INFO(COMMAND_LINE, "file_name"));
- rang := CREATE_RANGE(BEGINNING_OF(file), END_OF(file));
- match_pos := SEARCH_QUIETLY('VERSION=', FORWARD, EXACT, rang);
- POSITION(BEGINNING_OF(match_pos));
- ERASE_LINE;
- COPY_TEXT(vers);
- SPLIT_LINE;
+ POSITION(BEGINNING_OF(match_pos));
+ ERASE(match_pos);
+ vers := CURRENT_LINE-")";
+ ELSE;
+ vers := "unknown";
ENDIF;
+
+ file := CREATE_BUFFER("file", GET_INFO(COMMAND_LINE, "file_name"));
+ rang := CREATE_RANGE(BEGINNING_OF(file), END_OF(file));
+ match_pos := SEARCH_QUIETLY('@VERSION@', FORWARD, EXACT, rang);
+ POSITION(BEGINNING_OF(match_pos));
+ ERASE(match_pos);
+ COPY_TEXT(vers);
WRITE_FILE(file, GET_INFO(COMMAND_LINE, "output_file"));
QUIT
$ EOD
-$ write sys$output "Patched `makefile.vms'"
+$ write sys$output "Created `makefile.vms'"