1
0
mirror of https://github.com/php/php-src.git synced 2026-04-28 18:53:33 +02:00

- Move stuff that belongs in Makefile into Makefile.frag

This commit is contained in:
foobar
2005-03-14 01:09:49 +00:00
parent 7c4cd04229
commit bde0661ef6
2 changed files with 25 additions and 11 deletions
+21
View File
@@ -0,0 +1,21 @@
$(builddir)/sqlite/tool/lemon: $(srcdir)/sqlite/tool/lemon.c
$(CC) $(srcdir)/sqlite/tool/lemon.c -o $@
cp $(srcdir)/sqlite/tool/lempar.c $(builddir)/sqlite/tool/
$(builddir)/sqlite/tool/mkkeywordhash: $(srcdir)/sqlite/tool/mkkeywordhash.c
$(CC) $(srcdir)/sqlite/tool/mkkeywordhash.c -o $@
$(srcdir)/sqlite/src/parse.c: $(srcdir)/sqlite/src/parse.y $(builddir)/sqlite/tool/lemon
$(builddir)/sqlite/tool/lemon $(srcdir)/sqlite/src/parse.y
$(srcdir)/sqlite/src/parse.h: $(srcdir)/sqlite/src/parse.c
$(srcdir)/sqlite/src/opcodes.h: $(srcdir)/sqlite/src/parse.h
cat $(srcdir)/sqlite/src/parse.h $(srcdir)/sqlite/src/vdbe.c | $(AWK) -f $(srcdir)/sqlite/mkopcodeh.awk > $@
$(srcdir)/sqlite/src/opcodes.c: $(srcdir)/sqlite/src/opcodes.h
sort -n +2 $(srcdir)/sqlite/src/opcodes.h | $(AWK) -f $(srcdir)/sqlite/mkopcodec.awk > $@
$(srcdir)/sqlite/src/keywordhash.h: $(builddir)/sqlite/tool/mkkeywordhash
$(srcdir)/sqlite/tool/mkkeywordhash > $(srcdir)/sqlite/src/keywordhash.h
+4 -11
View File
@@ -5,7 +5,7 @@ dnl vim:et:sw=2:ts=2:
if test "$PHP_PDO" != "no"; then
PHP_ARG_WITH(pdo-sqlite, for sqlite 3 driver for PDO,
[ --with-pdo-sqlite Include PDO sqlite 3 support],yes)
[ --with-pdo-sqlite[=DIR] Include PDO sqlite 3 support.],yes)
if test "$PHP_PDO_SQLITE" != "no"; then
@@ -83,21 +83,14 @@ if test "$PHP_PDO_SQLITE" != "no"; then
PHP_ADD_BUILD_DIR($ext_builddir/sqlite)
PHP_ADD_BUILD_DIR($ext_builddir/sqlite/src)
PHP_ADD_BUILD_DIR($ext_builddir/sqlite/tool)
PHP_ADD_MAKEFILE_FRAGMENT
AC_CHECK_SIZEOF(char *,4)
AC_DEFINE(SQLITE_PTR_SZ, SIZEOF_CHAR_P, [Size of a pointer])
PDO_SQLITE_VERSION=`cat $ext_srcdir/sqlite/VERSION`
PDO_SQLITE_VERSION_NUMBER=`echo $PDO_SQLITE_VERSION | awk -F. '{printf("%d%03d%03d", $1, $2, $3)}'`
sed -e s/--VERS--/$PDO_SQLITE_VERSION/ -e s/--VERSION-NUMBER--/$PDO_SQLITE_VERSION_NUMBER/ $ext_srcdir/sqlite/src/sqlite.h.in > $ext_srcdir/sqlite3.h
if ! test -f $ext_srcdir/sqlite/src/parse.h ; then
$CC -o $ext_srcdir/sqlite/tool/lemon $ext_srcdir/sqlite/tool/lemon.c
$ext_srcdir/sqlite/tool/lemon $ext_srcdir/sqlite/src/parse.y
cat $ext_srcdir/sqlite/src/parse.h $ext_srcdir/sqlite/src/vdbe.c | awk -f $ext_srcdir/sqlite/mkopcodeh.awk > $ext_srcdir/sqlite/src/opcodes.h
sort -n +2 $ext_srcdir/sqlite/src/opcodes.h | awk -f $ext_srcdir/sqlite/mkopcodec.awk > $ext_srcdir/sqlite/src/opcodes.c
$CC -o $ext_srcdir/sqlite/tool/mkkeywordhash $ext_srcdir/sqlite/tool/mkkeywordhash.c
$ext_srcdir/sqlite/tool/mkkeywordhash > $ext_srcdir/sqlite/src/keywordhash.h
else
touch $ext_srcdir/sqlite/src/parse.c $ext_srcdir/sqlite/src/parse.y
fi
if test "$ext_shared" = "no" -o "$ext_srcdir" != "$abs_srcdir"; then
echo '#include "php_config.h"' > $ext_srcdir/sqlite/src/config.h