[FriBidi-commit] fribidi Makefile.am, 1.6, 1.7 TODO, 1.8, 1.9 bootstrap, 1.2, 1.3 configure.ac, 1.11, 1.12

Behdad Esfahbod behdad at pdx.freedesktop.org
Fri Jun 4 02:41:13 PDT 2004


Update of /cvs/fribidi/fribidi
In directory pdx:/tmp/cvs-serv367

Modified Files:
	Makefile.am TODO bootstrap configure.ac 
Log Message:
Cleaning up here and there.  Last lingers before adding joining.


Index: Makefile.am
===================================================================
RCS file: /cvs/fribidi/fribidi/Makefile.am,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- a/Makefile.am	31 May 2004 18:43:26 -0000	1.6
+++ b/Makefile.am	4 Jun 2004 09:41:11 -0000	1.7
@@ -11,6 +11,8 @@
 ## The order of subdirs is important, don't change without a reason.
 SUBDIRS = gen.tab charset lib bin doc test
 
+EXTRA_DIST = bootstrap ChangeLog.old
+
 pkgconfigdir = $(libdir)/pkgconfig
 pkgconfig_DATA = @PACKAGE at .pc
 
@@ -22,37 +24,52 @@
 		$(srcdir)/config.guess \
 		$(srcdir)/config.h.in \
 		$(srcdir)/config.sub \
-		$(srcdir)/configure \
 		$(srcdir)/configure.scan \
 		$(srcdir)/depcomp \
 		$(srcdir)/install-sh \
 		$(srcdir)/ltmain.sh \
 		$(srcdir)/missing \
 		`find "$(srcdir)" -type f -name Makefile.in -print` \
-		`find "$(srcdir)" -type f -name "*~" -print`
+		`find "$(srcdir)" -type f -name "*~" -print` \
+		`$(srcdir)/bootstrap --write-configure`
+# The last line above is a horrible hack.
+# GNU Coding Standards recommends that `make maintainer-clean' should not 
+# remove the configure script.
+# We instead make configure call bootstrap.
 
 BUILT_SOURCES = lib/fribidi-unicode-version.h
 lib/fribidi-unicode-version.h:
 	(cd lib && $(MAKE) $(AM_MAKEFLAGS) fribidi-unicode-version.h)
 
-# Indent all C source and header files
-
-.PHONY: indent
+# Indent all C source and header files, using indent(1):
 
 indent: $(srcdir)/.indent.pro
 	cd "$(srcdir)" && \
 	find . -type f -mindepth 2 -name "*.[ch]" -print | \
-		xargs ./missing --run indent
+	  xargs ./missing --run indent
 
+.PHONY: indent
 
-# Creating ChangeLog from CVS log, with cvs2cl:
+# Creating ChangeLog from CVS log, using cvs2cl(1):
 
 MAINTAINERCLEANFILES += ChangeLog ChangeLog.bak
 
-EXTRA_DIST = ChangeLog
+EXTRA_DIST += ChangeLog
 
-ChangeLog:
-	if test -d "$(srcdir)/CVS"; then \
-		cd "$(srcdir)" && \
-		./missing --run cvs2cl --stdout --utc --FSF -U AUTHORS; \
-	fi > $@
+ChangeLog: $(srcdir)/ChangeLog
+
+$(srcdir)/ChangeLog:
+	@if test -d "$(srcdir)/CVS"; then \
+	  (cd "$(srcdir)" && \
+	  ./missing --run cvs2cl --stdout --utc --FSF -U AUTHORS) > $@.tmp \
+	  && echo "For older changes see ChangeLog.old" >> $@.tmp && mv $@.tmp $@ \
+	  || ($(RM) $@.tmp; \
+	      echo Failed to generate ChangeLog, your ChangeLog may be outdated >&2; \
+	      (test -f $@ || echo cvs2cl is required to generate this file >> $@)); \
+	else \
+	  test -f $@ || \
+	  (echo A CVS checkout and cvs2cl is required to generate ChangeLog >&2 && \
+	  echo A CVS checkout and cvs2cl is required to generate this file >> $@); \
+	fi
+
+.PHONY: ChangeLog $(srcdir)/ChangeLog

Index: TODO
===================================================================
RCS file: /cvs/fribidi/fribidi/TODO,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- a/TODO	31 May 2004 18:43:26 -0000	1.8
+++ b/TODO	4 Jun 2004 09:41:11 -0000	1.9
@@ -7,7 +7,7 @@
 * Update all files headers/footers.  For c/h files, lib/fribidi-mirroring.[ch]
   is always the reference.
 
-* Show BidiTypes enum in manual.
+* Show BidiTypes enum in manual and gdb.
 
 * Update CapRTL with new Unicode reference code.
 
@@ -40,7 +40,8 @@
 * Use gengetopt.
 
 * Add FriBidiEnv functionality at compile time.  Also, ifdef out the memory
-  cleanup stuff if asked to fail on memory allocation failure (xmalloc).
+  cleanup stuff if asked to fail on memory allocation failure (xmalloc).  When
+  this is done, FRIBIDI_GNUC_WARN_UNUSEDS can be turned off conditionally.
 
 * Fix cvs2cl bug with spacing around author names read with -U option.  Then
   fix spacing in AUTHORS.
@@ -48,8 +49,6 @@
 * Use `-' before any command for installing a man page, so that make will
   ignore any errors.
 
-* Should fail if cannot build ChangeLog, right?
-
 * Clean up README and NEWS, and check all files' headers.  Write
   gen.tab/README.
 
@@ -66,8 +65,6 @@
 
 From GNU Coding Standards:
 
-* make maintainer-clean should not clean configure system.
-
 * The distribution should contain a file named `README' which gives the name
   of the package, and a general description of what it does. It is also good
   to explain the purpose of each of the first-level subdirectories in the

Index: bootstrap
===================================================================
RCS file: /cvs/fribidi/fribidi/bootstrap,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- a/bootstrap	12 May 2004 07:06:21 -0000	1.2
+++ b/bootstrap	4 Jun 2004 09:41:11 -0000	1.3
@@ -9,52 +9,90 @@
 #                                               -*- Bootstrap -*-
 # Run this file to produce a configure script.
 
-DEFAULTARGS="--force --install --autoreconf=auto"
+DEFAULT_BOOTSTRAPFLAGS="--force --install --autoreconf=auto"
+DEFAULT_CONFIGUREFLAGS="--enable-maintainer-mode --enable-compile-warnings"
 
-for arg in $DEFAULTARGS $*
+OLDDIR=`pwd`
+
+# move to source dir
+DIR=`echo $0 | sed 's,[^/]*$,,'`
+test -n "$DIR" && cd "$DIR"
+
+if test "$1" = --write-configure; then
+	test -f configure && \
+	((echo '#! /bin/sh
+	        DIR=`echo $0 | sed "s,[^/]*\$,,"`
+	        exec ${DIR}bootstrap --configure -- "$@"' > configure \
+	  && chmod a+x configure) || \
+	 echo Failed writing to configure >&2)
+
+	exit $?
+fi
+
+# check if we are invoked as configure, or bootstrap
+BASE=`echo $0 | sed 's,.*/,,'`
+if test "$BASE" = "configure"; then
+	CONFIG=--config
+	EXTRA_CONFIGUREFLAGS=$@
+else # bootstrap
+	EXTRA_BOOTSTRAPFLAGS=$*
+fi
+
+for arg in $DEFAULT_BOOTSTRAPFLAGS $BOOTSTRAPFLAGS $EXTRA_BOOTSTRAPFLAGS
 do
+if test -n "$DASHDASHFLAGS"; then
+	DASHDASHFLAGS="$DASHDASHFLAGS $arg"
+else
 	case $arg in
-		-h | --help)
+		-h|--h|--he|--hel|--help)
 			HELP=--help ;;
-		-V | --version)
+		-V|--vers|--versi|--versio|--version)
 			VERSION=--version ;;
-		-v | --verbose)
+		-v|--verb|--verbo|--verbos|--verbose)
 			VERBOSE=--verbose ;;
-		-d | --debug)
+		-d|--de|--deb|--debu|--debug)
 			DEBUG=--debug ;;
-		-W | --warning | --warnings=yes)
-			WARNINGS=--warnings=all ;;
-		--no-warning | --warnings=no)
-			WARNINGS= ;;
-		--warning=*)
-			WARNINGS=$arg ;;
-		-f | --force | --force=yes | --force-missing)
+		-W|--w|--wa|--war|--warn|--warni|--warnin|--warning|--warnings|--warnings=yes|--warnings=all)
+			WARNS=--warnings=all ;;
+		--no-w|--no-wa|--no-war|--no-warn|--no-warni|--no-warnin|--no-warning|--no-warnings|--warn=no|--warning=no|--warnings=no)
+			WARNS=--warnings=none ;;
+		--w=*|--wa=*|--war=*|--warn=*|--warni=*|--warnin=*|--warning=*|--warnings=*)
+			WARNS=$arg ;;
+		-f|--f|--fo|--for|--forc|--force|--forced|--force=yes|--force-missing)
 			FORCE=--force ;;
-		--no-force | --force=no)
+		--no-f|--no-fo|--no-for|--no-forc|--no-force|--no-forced|--force=no)
 			FORCE=--no-force ;;
-		-i | --install | --install=yes | -a | --add-missing)
+		-i|--i|--in|--ins|--inst|--insta|--instal|--install|--install=yes|-a|--add-missing)
 			INSTALL=--install ;;
-		--no-install | --install=no)
+		--no-i|--no-in|--no-ins|--no-inst|--no-insta|--no-instal|--no-install|--install=no)
 			INSTALL= ;;
-		-s | --symlink | --symlink=yes | --no-copy | --copy=no)
+		-s|--s|--sy|--sym|--syml|--symli|--symlin|--symlink|--symlink=yes|--no-copy|--copy=no)
 			SYMLINK=--symlink ;;
-		--no-symlink | --symlink=no | --copy | --copy=yes)
+		--no-s|--no-sy|--no-sym|--no-syml|--no-symli|--no-symlin|--no-symlink|--symlink=no|--copy|--copy=yes)
 			SYMLINK= ;;
-		-m | --make | --make=yes)
-			MAKE=--make ;;
-		--no-make | --make=no)
+		-m|--m|--ma|--mak|--make|--make=yes)
+			MAKE=--make
+			CONFIG=--configure ;;
+		--no-m|--no-ma|--no-mak|--no-make|--make=no)
 			MAKE= ;;
-		-n | --dry-run)
+		-c|--c|--co|--con|--conf|--confi|--config|--configu|--configur|--configure|--configure=yes)
+			CONFIG=--configure ;;
+		--no-c|--no-co|--no-con|--no-conf|--no-confi|--no-config|--no-configu|--no-configur|--no-configure|--configure=no)
+			CONFIG= ;;
+		-n|--dr|--dry|--dry-|--dry-r|--dry-ru|--dry-run)
 			DRYRUN=echo ;;
-		--autoreconf=auto)
+		--auto|--autoreconf=auto)
 			AUTORECONF=auto ;;
-		--autoreconf | --autoreconf=yes)
+		--autoreconf|--autoreconf=yes)
 			AUTORECONF=yes ;;
-		--no-autoreconf | --autoreconf=no)
+		--no-autoreconf|--autoreconf=no)
 			AUTORECONF= ;;
+		--)
+			DASHDASHFLAGS=" " ;;
 		*)
 			echo Ignoring unknown parameter $arg
 	esac
+fi
 done
 
 test -z "$SYMLINK" && COPY=--copy
@@ -73,39 +111,49 @@
 fi
 
 if test -n "$AUTORECONF";  then
-	$DRYRUN autoreconf $HELP $VERSION $VERBOSE $DEBUG $FORCE $INSTALL $SYMLINK $MAKE $WARNINGS
-	exit $?
-fi
+	$DRYRUN autoreconf $HELP $VERSION $VERBOSE $DEBUG $FORCE $INSTALL $SYMLINK $MAKE $WARNS $AUTORECONFFLAGS || exit $?
+else
 
 # add files 'config.guess', 'config.sub', 'ltconfig', 'ltmain.sh'
-$DRYRUN libtoolize $HELP $VERSION --automake $COPY $DEBUG $FORCE || exit 1
+test -f Makefile.am && MY_LIBTOOLIZEFLAGS=--automake
+
+$DRYRUN libtoolize $HELP $VERSION $COPY $DEBUG $FORCE $MY_LIBTOOLIZEFLAGS $LIBTOOLIZEFLAGS || exit $?
 
 # generate 'aclocal.m4'
 if test -f configure.ac -o configure.in; then
-	$DRYRUN aclocal $HELP $VERSION $VERBOSE $FORCE || exit 1
+	$DRYRUN aclocal $HELP $VERSION $VERBOSE $FORCE $ACLOCALFLAGS || exit $?
 fi
 
 # generate 'config.h.in'
 if test -f configure.ac -o configure.in; then
-	$DRYRUN autoheader $HELP $VERSION $VERBOSE $DEBUG $FORCE $WARNINGS || exit 1
+	$DRYRUN autoheader $HELP $VERSION $VERBOSE $DEBUG $FORCE $WARNS $AUTOHEADERFLAGS || exit $?
 fi
 
 #  generate Makefile.in's from Makefile.am's
 if test -f Makefile.am; then
-	$DRYRUN automake $HELP $VERSION $VERBOSE $ADDMISSING $COPY $FORCE $WARNINGS || exit 1
+	$DRYRUN automake $HELP $VERSION $VERBOSE $ADDMISSING $COPY $FORCE $WARNS $AUTOMAKEFLAGS || exit $?
 fi
 
 # generate configure from configure.ac
 if test -f configure.ac -o -f configure.in; then
-	$DRYRUN autoconf $HELP $VERSION $VERBOSE $DEBUG $FORCE $WARNINGS || exit 1
+	$DRYRUN autoconf $HELP $VERSION $VERBOSE $DEBUG $FORCE $WARNS $AUTOCONFFLAGS || exit $?
 fi
 
-if test -n "$MAKE"; then
-	if test -f ./configure; then
-		$DRYRUN ./configure $HELP $VERSION \
-		--enable-maintainer-mode --enable-compile-warnings || exit 1
+fi # !AUTOCONF
+
+# move to build dir
+cd $OLDDIR
+
+# configure
+if test -n "$CONFIG"; then
+	if test -f ${DIR}configure; then
+		$DRYRUN ${DIR}configure $HELP $VERSION $DEFAULT_CONFIGUREFLAGS $CONFIGUREFLAGS $DASHDASHFLAGS $EXTRA_CONFIGUREFLAGS || exit $?
 	fi
+fi
+
+# make
+if test -n "$MAKE"; then
 	if test -f Makefile; then
-		$DRYRUN make || exit 1
+		$DRYRUN make $MAKEFLAGS || exit $?
 	fi
 fi

Index: configure.ac
===================================================================
RCS file: /cvs/fribidi/fribidi/configure.ac,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- a/configure.ac	31 May 2004 18:43:26 -0000	1.11
+++ b/configure.ac	4 Jun 2004 09:41:11 -0000	1.12
@@ -110,6 +110,7 @@
 AC_C_INLINE
 AC_C_STRINGIZE
 AC_CHECK_SIZEOF(int)
+AC_SUBST(SIZEOF_INT)
 AC_CHECK_SIZEOF(short)
 AC_CHECK_SIZEOF(void *)
 AC_CHECK_SIZEOF(wchar_t)




More information about the FriBidi-Commit mailing list