|
From: <sv...@va...> - 2009-06-15 05:56:23
|
Author: njn Date: 2009-06-15 06:54:37 +0100 (Mon, 15 Jun 2009) New Revision: 10329 Log: Fold Makefile.core-tools.am into Makefile.all.am, because they're both needed almost everywhere. Removed: branches/BUILD_TWEAKS/Makefile.core-tool.am Modified: branches/BUILD_TWEAKS/Makefile.all.am branches/BUILD_TWEAKS/Makefile.tool-tests.am branches/BUILD_TWEAKS/Makefile.tool.am branches/BUILD_TWEAKS/auxprogs/Makefile.am branches/BUILD_TWEAKS/coregrind/Makefile.am branches/BUILD_TWEAKS/mpi/Makefile.am Modified: branches/BUILD_TWEAKS/Makefile.all.am =================================================================== --- branches/BUILD_TWEAKS/Makefile.all.am 2009-06-15 05:30:05 UTC (rev 10328) +++ branches/BUILD_TWEAKS/Makefile.all.am 2009-06-15 05:54:37 UTC (rev 10329) @@ -1,7 +1,11 @@ -## This file should be included by *every* Makefile.am, except those for docs/ -## and tests/ subdirectories. +# This file should be included (directly or indirectly) by every +# Makefile.am that builds programs. And also the top-level Makefile.am. +#---------------------------------------------------------------------------- +# Global stuff +#---------------------------------------------------------------------------- + valdir = $(libdir)/valgrind inplacedir = $(top_builddir)/.in_place @@ -11,3 +15,73 @@ # (this is equivalent to enforcing "make -j 1". .NOTPARALLEL: +#---------------------------------------------------------------------------- +# noinst_PROGRAMS and noinst_DSYMS targets +#---------------------------------------------------------------------------- + +# On Darwin, for a program 'p', the DWARF debug info is stored in the +# directory 'p.dSYM'. This must be generated after the executable is +# created, with 'dsymutil p'. We could redefine LINK with a script that +# executes 'dsymutil' after linking, but that's a pain. Instead we use this +# hook so that every time "make check" is run, we subsequently invoke +# 'dsymutil' on all the executables that lack a .dSYM directory, or that are +# newer than their corresponding .dSYM directory. +build-noinst_DSYMS: + for f in $(noinst_DSYMS); do \ + if [ ! -e $$f.dSYM -o $$f -nt $$f.dSYM ] ; then \ + echo "dsymutil $$f"; \ + dsymutil $$f; \ + fi; \ + done + +# This is used by coregrind/Makefile.am and Makefile.tool.am for doing +# "in-place" installs. It copies $(noinst_PROGRAMS) into $inplacedir. +# It needs to be depended on by an 'all-local' rule. +inplace-noinst_PROGRAMS: + if [ -n "$(noinst_PROGRAMS)" ] ; then \ + mkdir -p $(inplacedir); \ + for f in $(noinst_PROGRAMS) ; do \ + rm -f $(inplacedir)/$$f; \ + ln -f -s ../$(subdir)/$$f $(inplacedir); \ + done ; \ + fi + +# Similar to inplace-noinst_PROGRAMS +inplace-noinst_DSYMS: build-noinst_DSYMS + if [ -n "$(noinst_DSYMS)" ] ; then \ + mkdir -p $(inplacedir); \ + for f in $(noinst_DSYMS); do \ + rm -f $(inplacedir)/$$f.dSYM; \ + ln -f -s ../$(subdir)/$$f.dSYM $(inplacedir); \ + done ; \ + fi + +# This is used by coregrind/Makefile.am and by <tool>/Makefile.am for doing +# "make install". It copies $(noinst_PROGRAMS) into $prefix/lib/valgrind/. +# It needs to be depended on by an 'install-exec-local' rule. +install-noinst_PROGRAMS: + if [ -n "$(noinst_PROGRAMS)" ] ; then \ + $(mkinstalldirs) $(DESTDIR)$(valdir); \ + for f in $(noinst_PROGRAMS); do \ + $(INSTALL_PROGRAM) $$f $(DESTDIR)$(valdir); \ + done ; \ + fi + +# Similar to install-noinst_PROGRAMS. +# Nb: we don't use $(INSTALL_PROGRAM) here because it doesn't work with +# directories. XXX: not sure whether the resulting permissions will be +# correct when using 'cp -R'... +install-noinst_DSYMS: build-noinst_DSYMS + if [ -n "$(noinst_DSYMS)" ] ; then \ + $(mkinstalldirs) $(DESTDIR)$(valdir); \ + for f in $(noinst_DSYMS); do \ + cp -R $$f.dSYM $(DESTDIR)$(valdir); \ + done ; \ + fi + +# This needs to be depended on by a 'clean-local' rule. +clean-noinst_DSYMS: + for f in $(noinst_DSYMS); do \ + rm -rf $$f.dSYM; \ + done + Deleted: branches/BUILD_TWEAKS/Makefile.core-tool.am =================================================================== --- branches/BUILD_TWEAKS/Makefile.core-tool.am 2009-06-15 05:30:05 UTC (rev 10328) +++ branches/BUILD_TWEAKS/Makefile.core-tool.am 2009-06-15 05:54:37 UTC (rev 10329) @@ -1,71 +0,0 @@ -# This file contains things shared by coregrind/Makefile.am and tool -# Makefile.am and test/Makefile.am files. Also auxprogs/Makefile.am. - -# On Darwin, for a program 'p', the DWARF debug info is stored in the -# directory 'p.dSYM'. This must be generated after the executable is -# created, with 'dsymutil p'. We could redefine LINK with a script that -# executes 'dsymutil' after linking, but that's a pain. Instead we use this -# hook so that every time "make check" is run, we subsequently invoke -# 'dsymutil' on all the executables that lack a .dSYM directory, or that are -# newer than their corresponding .dSYM directory. -build-noinst_DSYMS: - for f in $(noinst_DSYMS); do \ - if [ ! -e $$f.dSYM -o $$f -nt $$f.dSYM ] ; then \ - echo "dsymutil $$f"; \ - dsymutil $$f; \ - fi; \ - done - -# This is used by coregrind/Makefile.am and Makefile.tool.am for doing -# "in-place" installs. It copies $(noinst_PROGRAMS) into $inplacedir. -# It needs to be depended on by an 'all-local' rule. -inplace-noinst_PROGRAMS: - if [ -n "$(noinst_PROGRAMS)" ] ; then \ - mkdir -p $(inplacedir); \ - for f in $(noinst_PROGRAMS) ; do \ - rm -f $(inplacedir)/$$f; \ - ln -f -s ../$(subdir)/$$f $(inplacedir); \ - done ; \ - fi - -# Similar to inplace-noinst_PROGRAMS -inplace-noinst_DSYMS: build-noinst_DSYMS - if [ -n "$(noinst_DSYMS)" ] ; then \ - mkdir -p $(inplacedir); \ - for f in $(noinst_DSYMS); do \ - rm -f $(inplacedir)/$$f.dSYM; \ - ln -f -s ../$(subdir)/$$f.dSYM $(inplacedir); \ - done ; \ - fi - -# This is used by coregrind/Makefile.am and by <tool>/Makefile.am for doing -# "make install". It copies $(noinst_PROGRAMS) into $prefix/lib/valgrind/. -# It needs to be depended on by an 'install-exec-local' rule. -install-noinst_PROGRAMS: - if [ -n "$(noinst_PROGRAMS)" ] ; then \ - $(mkinstalldirs) $(DESTDIR)$(valdir); \ - for f in $(noinst_PROGRAMS); do \ - $(INSTALL_PROGRAM) $$f $(DESTDIR)$(valdir); \ - done ; \ - fi - -# Similar to install-noinst_PROGRAMS. -# Nb: we don't use $(INSTALL_PROGRAM) here because it doesn't work with -# directories. XXX: not sure whether the resulting permissions will be -# correct when using 'cp -R'... -install-noinst_DSYMS: build-noinst_DSYMS - if [ -n "$(noinst_DSYMS)" ] ; then \ - $(mkinstalldirs) $(DESTDIR)$(valdir); \ - for f in $(noinst_DSYMS); do \ - cp -R $$f.dSYM $(DESTDIR)$(valdir); \ - done ; \ - fi - -# This needs to be depended on by a 'clean-local' rule. -clean-noinst_DSYMS: - for f in $(noinst_DSYMS); do \ - rm -rf $$f.dSYM; \ - done - - - Modified: branches/BUILD_TWEAKS/Makefile.tool-tests.am =================================================================== --- branches/BUILD_TWEAKS/Makefile.tool-tests.am 2009-06-15 05:30:05 UTC (rev 10328) +++ branches/BUILD_TWEAKS/Makefile.tool-tests.am 2009-06-15 05:54:37 UTC (rev 10329) @@ -1,7 +1,7 @@ # This file is used for tool tests, and also in perf/Makefile.am. -include $(top_srcdir)/Makefile.flags.am # For AM_FLAG_M3264_PRI -include $(top_srcdir)/Makefile.core-tool.am # For *-noinst_DSYM targets +include $(top_srcdir)/Makefile.all.am +include $(top_srcdir)/Makefile.flags.am # For AM_FLAG_M3264_PRI AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/include \ -I$(top_srcdir)/coregrind -I$(top_builddir)/include \ @@ -17,7 +17,6 @@ # automake; see comments in Makefile.flags.am for more detail. AM_CCASFLAGS = $(AM_CPPFLAGS) -# This sets if VGCONF_OS_IS_DARWIN noinst_DSYMS = $(check_PROGRAMS) endif Modified: branches/BUILD_TWEAKS/Makefile.tool.am =================================================================== --- branches/BUILD_TWEAKS/Makefile.tool.am 2009-06-15 05:30:05 UTC (rev 10328) +++ branches/BUILD_TWEAKS/Makefile.tool.am 2009-06-15 05:54:37 UTC (rev 10329) @@ -3,7 +3,6 @@ include $(top_srcdir)/Makefile.all.am include $(top_srcdir)/Makefile.flags.am -include $(top_srcdir)/Makefile.core-tool.am #---------------------------------------------------------------------------- # <tool>-<platform> stuff Modified: branches/BUILD_TWEAKS/auxprogs/Makefile.am =================================================================== --- branches/BUILD_TWEAKS/auxprogs/Makefile.am 2009-06-15 05:30:05 UTC (rev 10328) +++ branches/BUILD_TWEAKS/auxprogs/Makefile.am 2009-06-15 05:54:37 UTC (rev 10329) @@ -1,6 +1,5 @@ include $(top_srcdir)/Makefile.all.am include $(top_srcdir)/Makefile.flags.am -include $(top_srcdir)/Makefile.core-tool.am noinst_SCRIPTS = \ gen-mdg \ Modified: branches/BUILD_TWEAKS/coregrind/Makefile.am =================================================================== --- branches/BUILD_TWEAKS/coregrind/Makefile.am 2009-06-15 05:30:05 UTC (rev 10328) +++ branches/BUILD_TWEAKS/coregrind/Makefile.am 2009-06-15 05:54:37 UTC (rev 10329) @@ -5,7 +5,6 @@ include $(top_srcdir)/Makefile.all.am include $(top_srcdir)/Makefile.flags.am -include $(top_srcdir)/Makefile.core-tool.am #---------------------------------------------------------------------------- # Basics, flags Modified: branches/BUILD_TWEAKS/mpi/Makefile.am =================================================================== --- branches/BUILD_TWEAKS/mpi/Makefile.am 2009-06-15 05:30:05 UTC (rev 10328) +++ branches/BUILD_TWEAKS/mpi/Makefile.am 2009-06-15 05:54:37 UTC (rev 10329) @@ -1,6 +1,5 @@ include $(top_srcdir)/Makefile.all.am include $(top_srcdir)/Makefile.flags.am -include $(top_srcdir)/Makefile.core-tool.am # HACK WARNING: automake isn't good at supporting non-$(CC) compilers. # But we need to use $(MPI_CC) for the MPI stuff. So we have this mpi stuff |