diff options
author | Tom Tromey <tromey@redhat.com> | 1999-04-11 13:02:43 +0000 |
---|---|---|
committer | Tom Tromey <tromey@redhat.com> | 1999-04-11 13:02:43 +0000 |
commit | 88b595974744cad79fa4bc2492a796c6037eea49 (patch) | |
tree | 8e9ad1c5fa002f0293b9bea17139bb1be3bf5db3 /m4/minuso.m4 | |
parent | 62fef9141ba3762d716da47b068733750d6a1fbc (diff) | |
download | automake-88b595974744cad79fa4bc2492a796c6037eea49.tar.gz |
First cut at allowing objects in subdirectories:
* m4/Makefile.am (m4data_DATA): Added minuso.m4.
* Makefile.am (dist_script_DATA): Added compile.
* m4/minuso.m4: New file.
* automake.in (initialize_global_constants): Added compile to
common_files.
(seen_cc_c_o): New global.
(scan_one_configure_file): Set it when AM_PROG_CC_C_O seen.
(handle_options): Recognize `subdir-objects' option.
(lang_c_rewrite): Added directory argument.
(lang_yacc_rewrite): Likewise.
(lang_yaccxx_rewrite): Likewise.
(lang_lex_rewrite): Likewise.
(lang_lexxx_rewrite): Likewise.
(handle_single_transform_list): Pass directory to _rewrite
function. Generate dependencies for dirstamp files for each .o;
it is just the rules we want to create once.
(lang_c_rewrite): Handle `subdir-objects' option.
(lang_c_rewrite): Require `compile' program.
* compile: New file.
Diffstat (limited to 'm4/minuso.m4')
-rw-r--r-- | m4/minuso.m4 | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/m4/minuso.m4 b/m4/minuso.m4 new file mode 100644 index 000000000..a28db55c9 --- /dev/null +++ b/m4/minuso.m4 @@ -0,0 +1,15 @@ +dnl Like AC_PROG_CC_C_O, but changed for automake. + +AC_DEFUN([AM_PROG_CC_C_O],[ +AC_REQUIRE([AC_PROG_CC_C_O]) +dnl FIXME: we rely on the cache variable name because +dnl there is no other way. +set dummy $CC; ac_cc="`echo [$]2 | +changequote(, )dnl + sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`" +changequote([, ])dnl +if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" != yes"; then + # Losing compiler, so override with the script. + CC="\$(top_srcdir)/compile $CC" +fi +]) |