* configure.ac (gl_PREFIXED_LIBOBJS): Don't rename it, rather,
change the value of...
(gl_LIBOBJS): this.
Adjust more variables.
* etc/prefix-gnulib-mk (prefix_assignment): Don't rename
gl_LIBOBJS.
(prefix): Also transform rules whose targets have slashes.
Use $prefix liberally.
Map @MKDIR_P@ to $(MKDIR_P).
Prefix directories that are mkdir'd.
+2009-08-12 Akim Demaille <demaille@gostai.com>
+
+ gnulib: improve prefixing.
+ * configure.ac (gl_PREFIXED_LIBOBJS): Don't rename it, rather,
+ change the value of...
+ (gl_LIBOBJS): this.
+ Adjust more variables.
+ * etc/prefix-gnulib-mk (prefix_assignment): Don't rename
+ gl_LIBOBJS.
+ (prefix): Also transform rules whose targets have slashes.
+ Use $prefix liberally.
+ Map @MKDIR_P@ to $(MKDIR_P).
+ Prefix directories that are mkdir'd.
+
2009-08-12 Akim Demaille <demaille@gostai.com>
build: fix paths.
2009-08-12 Akim Demaille <demaille@gostai.com>
build: fix paths.
gt_JAVACOMP([1.3], [1.4])
gt_JAVAEXEC
gt_JAVACOMP([1.3], [1.4])
gt_JAVAEXEC
-AC_SUBST([gl_PREFIXED_LIBOBJS],
- [$(echo "$gl_LIBOBJS" | sed -e 's, , lib/,g')])
-for ac_var in ERRNO_H GETOPT_H INTTYPES_H STDBOOL_H STDINT_H WCHAR_H WCTYPE_H
+# We use gnulib, but from lib/local.mk instead of lib/Makefile.am.
+# So prefix paths with lib/. See also etc/prefix-gnulib-mk.
+gl_LIBOBJS=`echo "$gl_LIBOBJS" | sed -e 's, , lib/,g'`
+for ac_var in ALLOCA_H ERRNO_H FCNTL_H GETOPT_H INTTYPES_H \
+ STDBOOL_H STDINT_H SYS_WAIT_H WCHAR_H WCTYPE_H
- eval "$ac_var=lib/\$$ac_var"
+ eval "test 'x$ac_var' = x || $ac_var=lib/\$$ac_var"
done
AC_CONFIG_FILES([Makefile
po/Makefile.in
done
AC_CONFIG_FILES([Makefile
po/Makefile.in
# lib_libbison_a_SOURCES.
$lhs_and_assign_op =~ s/(libbison)/lib_$1/g;
# lib_libbison_a_SOURCES.
$lhs_and_assign_op =~ s/(libbison)/lib_$1/g;
- # Do not use gl_LIBOBJS, but its prefixed version.
- $rhs =~ s/gl_LIBOBJS/gl_PREFIXED_LIBOBJS/g;
-
return $lhs_and_assign_op . $rhs;
}
return $lhs_and_assign_op . $rhs;
}
# Prefix all the occurrence of files in rules. If there is nothing
# after in the :, it's probably a phony target, or a suffix rule.
# Don't touch it.
# Prefix all the occurrence of files in rules. If there is nothing
# after in the :, it's probably a phony target, or a suffix rule.
# Don't touch it.
+ s{^([\w./]+ *: *\w.*)$}
{prefix_words($1)}gem;
# Prefix files in variables.
{prefix_words($1)}gem;
# Prefix files in variables.
# These three guys escape all the other regular rules.
s{(charset\.alias|ref-add\.sed|ref-del\.sed)}{$prefix$1}g;
# Unfortunately, as a result we sometimes have lib/lib.
# These three guys escape all the other regular rules.
s{(charset\.alias|ref-add\.sed|ref-del\.sed)}{$prefix$1}g;
# Unfortunately, as a result we sometimes have lib/lib.
# $(srcdir) is actually $(top_srcdir)/lib.
s{\$\(srcdir\)}{\$(top_srcdir)/lib}g;
# $(srcdir) is actually $(top_srcdir)/lib.
s{\$\(srcdir\)}{\$(top_srcdir)/lib}g;
# not work when we have a $@ with a directory in it.
s{t-\$\@}{\$\@-t}g;
# not work when we have a $@ with a directory in it.
s{t-\$\@}{\$\@-t}g;
+ # Some AC_SUBST patterns remain and would better be Make macros.
+ s{\@(MKDIR_P)\@}{\$($1)}g;
+
+ # Adjust paths in mkdir.
+ s{(\$\(MKDIR_P\))\s*(\w+)}{$1 $prefix$2}g;
+
-process ("lib/gnulib.mk")
+process ("${prefix}gnulib.mk")
### Setup "GNU" style for perl-mode and cperl-mode.
### Setup "GNU" style for perl-mode and cperl-mode.