com gtk/php-gtk: Add gen-sources target.: config.m4 main/Makefile.frag php_gtk.m4
[email protected] (David Soria Parra)
| Newsgroups | php.gtk.cvs |
|---|---|
| Message-ID | <[email protected]> |
Commit: bf166e44d9762a33c62675d70f7608e823d00d29 Author: Andrei Zmievski <[email protected]> Sat, 10 Jun 2006 19:53:12 +0000 Parents: 67404b672e9476c331508895f0d04056a9119f93 Branches: master Link: http://git.php.net/?p=gtk/php-gtk.git;a=commitdiff;h=bf166e44d9762a33c62675d70f7608e823d00d29 Log: Add gen-sources target. Changed paths: M config.m4 M main/Makefile.frag M php_gtk.m4 Diff: bf166e44d9762a33c62675d70f7608e823d00d29 diff --git a/config.m4 b/config.m4 index 3fca9a6..954866a 100644 --- a/config.m4 +++ b/config.m4 @@ -65,6 +65,7 @@ dnl reading config stubs esyscmd(./build2/config-stubs ext) PHP_SUBST(PHP_GTK_EXTENSIONS) +PHP_SUBST(PHP_GTK_GEN_SOURCES) PHP_NEW_EXTENSION(php_gtk2, main/php_gtk.c main/phpg_support.c main/phpg_gtype.c \ main/phpg_exceptions.c main/php_gtk_util.c main/phpg_gvalue.c \ diff --git a/main/Makefile.frag b/main/Makefile.frag index 45b8f43..b904e17 100644 --- a/main/Makefile.frag +++ b/main/Makefile.frag @@ -3,6 +3,8 @@ $(builddir)/php_gtk_ext.c: $(srcdir)/php_gtk_ext.c.in @echo "creating main/php_gtk_ext.c" sh $(top_srcdir)/build2/genext.sh $(srcdir)/php_gtk_ext.c.in $(top_srcdir) "" $(AWK) $(PHP_GTK_EXTENSIONS) > $@ +gen-sources: $(PHP_GTK_GEN_SOURCES) + cvsclean: @for i in `find . -name .cvsignore`; do \ (cd `dirname $$i` 2>/dev/null && rm -rf `cat .cvsignore` *.o *.a || true); \ @@ -15,4 +17,4 @@ clean-caches: clean-gen: find ext -name gen\*.[ch] | xargs rm -f -.PHONY: clean-caches clean-gen +.PHONY: gen-sources clean-caches clean-gen diff --git a/php_gtk.m4 b/php_gtk.m4 index 023ed2a..31aee61 100644 --- a/php_gtk.m4 +++ b/php_gtk.m4 @@ -498,6 +498,9 @@ dnl ---------------------------------------------- Shared module AC_DEFINE_UNQUOTED([PHP_GTK_COMPILE_DL_]translit($1,a-z-+,A-Z__), 1, Whether to build $1 as dynamic module) fi + for f in $4; do + PHP_GTK_GEN_SOURCES="$PHP_GTK_GEN_SOURCES ext/$1/$f" + done PHP_ADD_MAKEFILE_FRAGMENT($abs_srcdir/ext/$1/Makefile.frag, $abs_srcdir/ext/$1, ext/$1) PHP_ADD_BUILD_DIR($ext_builddir/ext/$1) ])