Date: Fri, 10 May 2013 19:29:30 +0000 (UTC) From: Jung-uk Kim <jkim@FreeBSD.org> To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r250475 - in projects/flex-sf: . usr.bin/lex usr.bin/lex/lib Message-ID: <201305101929.r4AJTU2t015917@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jkim Date: Fri May 10 19:29:30 2013 New Revision: 250475 URL: http://svnweb.freebsd.org/changeset/base/250475 Log: Connect the new flex to build. Note this flex requires m4(1) to run. Deleted: projects/flex-sf/usr.bin/lex/COPYING projects/flex-sf/usr.bin/lex/FlexLexer.h projects/flex-sf/usr.bin/lex/NEWS projects/flex-sf/usr.bin/lex/README projects/flex-sf/usr.bin/lex/ccl.c projects/flex-sf/usr.bin/lex/dfa.c projects/flex-sf/usr.bin/lex/ecs.c projects/flex-sf/usr.bin/lex/flex.skl projects/flex-sf/usr.bin/lex/flexdef.h projects/flex-sf/usr.bin/lex/gen.c projects/flex-sf/usr.bin/lex/initscan.c projects/flex-sf/usr.bin/lex/lib/libmain.c projects/flex-sf/usr.bin/lex/lib/libyywrap.c projects/flex-sf/usr.bin/lex/main.c projects/flex-sf/usr.bin/lex/misc.c projects/flex-sf/usr.bin/lex/mkskel.sh projects/flex-sf/usr.bin/lex/nfa.c projects/flex-sf/usr.bin/lex/parse.y projects/flex-sf/usr.bin/lex/scan.l projects/flex-sf/usr.bin/lex/sym.c projects/flex-sf/usr.bin/lex/tblcmp.c projects/flex-sf/usr.bin/lex/version.h projects/flex-sf/usr.bin/lex/yylex.c Modified: projects/flex-sf/Makefile.inc1 projects/flex-sf/usr.bin/lex/Makefile projects/flex-sf/usr.bin/lex/config.h projects/flex-sf/usr.bin/lex/lib/Makefile Modified: projects/flex-sf/Makefile.inc1 ============================================================================== --- projects/flex-sf/Makefile.inc1 Fri May 10 19:22:43 2013 (r250474) +++ projects/flex-sf/Makefile.inc1 Fri May 10 19:29:30 2013 (r250475) @@ -1138,6 +1138,10 @@ _nmtree= lib/libnetbsd \ _cat= bin/cat .endif +.if ${BOOTSTRAPPING} < 1000033 +_m4= usr.bin/m4 +.endif + .if ${BOOTSTRAPPING} >= 900040 && ${BOOTSTRAPPING} < 900041 _awk= usr.bin/awk .endif @@ -1200,6 +1204,7 @@ bootstrap-tools: usr.bin/rpcgen \ ${_sed} \ ${_yacc} \ + ${_m4} \ ${_lex} \ lib/libmd \ usr.bin/xinstall \ Modified: projects/flex-sf/usr.bin/lex/Makefile ============================================================================== --- projects/flex-sf/usr.bin/lex/Makefile Fri May 10 19:22:43 2013 (r250474) +++ projects/flex-sf/usr.bin/lex/Makefile Fri May 10 19:29:30 2013 (r250475) @@ -14,37 +14,57 @@ LINKS+= ${BINDIR}/lex ${BINDIR}/lex++ LINKS+= ${BINDIR}/lex ${BINDIR}/flex LINKS+= ${BINDIR}/lex ${BINDIR}/flex++ -SRCS= scan.c ccl.c dfa.c ecs.c gen.c main.c misc.c nfa.c parse.y \ - skel.c sym.c tblcmp.c yylex.c +FLEXDIR= ${.CURDIR}/../../contrib/flex + +.PATH: ${FLEXDIR} + +SRCS= buf.c ccl.c dfa.c ecs.c filter.c gen.c main.c misc.c \ + nfa.c options.c parse.y regex.c scan.c scanflags.c \ + scanopt.c skel.c sym.c tables.c tables_shared.c \ + tblcmp.c yylex.c LFLAGS+= -is -CFLAGS+= -I. -I${.CURDIR} +CFLAGS+= -I. -I${.CURDIR} -I${FLEXDIR} -DHAVE_CONFIG_H INCS= FlexLexer.h INCSDIR= ${INCLUDEDIR} MLINKS+= lex.1 flex.1 MLINKS+= lex.1 flex++.1 MLINKS+= lex.1 lex++.1 -WARNS?= 2 +WARNS?= 3 CLEANFILES= scan.c skel.c SUBDIR= lib +MAJOR_VERSION= 2 +MINOR_VERSION= 5 +SUBMINOR_VERSION= 37 + skel.c: mkskel.sh flex.skl - sh ${.CURDIR}/mkskel.sh ${.CURDIR}/flex.skl > skel.c + sed 's/m4_/m4postproc_/g; s/m4preproc_/m4_/g' \ + ${FLEXDIR}/flex.skl | \ + m4 -I${FLEXDIR} -P \ + -DFLEX_MAJOR_VERSION=${MAJOR_VERSION} \ + -DFLEX_MINOR_VERSION=${MINOR_VERSION} \ + -DFLEX_SUBMINOR_VERSION=${SUBMINOR_VERSION} | \ + sed 's/m4postproc_/m4_/g' | \ + sh ${FLEXDIR}/mkskel.sh > ${.TARGET} -bootstrap: initscan.c - @cmp -s ${.CURDIR}/initscan.c scan.c || { \ - echo "Bootstrapping flex" ; \ +bootstrap: scan.c skel.c + cmp -s ${FLEXDIR}/scan.c scan.c || { \ rm -f scan.c ; \ - cp -f ${.CURDIR}/initscan.c scan.c ; \ + cp -f ${FLEXDIR}/scan.c scan.c ; \ + } + cmp -s ${FLEXDIR}/skel.c skel.c || { \ + rm -f skel.c ; \ + cp -f ${FLEXDIR}/skel.c skel.c ; \ } test: check check: $(PROG) - ./$(PROG) $(LFLAGS) -t $(COMPRESSION) $(.CURDIR)/scan.l \ - | sed s,\"$(.CURDIR)/scan.l",\"scan.l", \ - | diff -I '\$$FreeBS[D]:.*\$$' $(.CURDIR)/initscan.c - + ./$(PROG) $(LFLAGS) -t $(COMPRESSION) $(FLEXDIR)/scan.l \ + | sed s,\"$(FLEXDIR)/scan.l",\"scan.l", \ + | diff -I '\$$FreeBS[D]:.*\$$' $(FLEXDIR)/scan.c - @echo "Check successful" .include <bsd.prog.mk> Modified: projects/flex-sf/usr.bin/lex/config.h ============================================================================== --- projects/flex-sf/usr.bin/lex/config.h Fri May 10 19:22:43 2013 (r250474) +++ projects/flex-sf/usr.bin/lex/config.h Fri May 10 19:29:30 2013 (r250475) @@ -1,26 +1,208 @@ -/* config.h. Generated automatically by configure. */ +/* config.h. Generated from conf.in by configure. */ +/* conf.in. Generated from configure.in by autoheader. */ /* $FreeBSD$ */ -/* Define to empty if the keyword does not work. */ -/* #undef const */ +/* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP + systems. This function is required for `alloca.c' support on those systems. + */ +/* #undef CRAY_STACKSEG_END */ + +/* Define to 1 if using `alloca.c'. */ +/* #undef C_ALLOCA */ + +/* Define to 1 if translation of program messages to the user's native + language is requested. */ +/* #undef ENABLE_NLS */ -/* Define to `unsigned' if <sys/types.h> doesn't define. */ -/* #undef size_t */ +/* Define to 1 if you have `alloca', as a function or macro. */ +#define HAVE_ALLOCA 1 -/* Define if you have the ANSI C header files. */ -#define STDC_HEADERS 1 +/* Define to 1 if you have <alloca.h> and it should be used (not on Ultrix). + */ +/* #undef HAVE_ALLOCA_H */ + +/* Define if the GNU dcgettext() function is already present or preinstalled. + */ +/* #undef HAVE_DCGETTEXT */ + +/* Define to 1 if you have the `dup2' function. */ +#define HAVE_DUP2 1 + +/* Define to 1 if you have the `fork' function. */ +#define HAVE_FORK 1 + +/* Define if the GNU gettext() function is already present or preinstalled. */ +/* #undef HAVE_GETTEXT */ + +/* Define if you have the iconv() function. */ +/* #undef HAVE_ICONV */ + +/* Define to 1 if you have the <inttypes.h> header file. */ +#define HAVE_INTTYPES_H 1 + +/* Define to 1 if you have the `isascii' function. */ +#define HAVE_ISASCII 1 + +/* Define to 1 if you have the <libintl.h> header file. */ +/* #undef HAVE_LIBINTL_H */ + +/* Define to 1 if you have the `m' library (-lm). */ +#define HAVE_LIBM 1 + +/* pthread library */ +#define HAVE_LIBPTHREAD 1 + +/* Define to 1 if you have the <limits.h> header file. */ +#define HAVE_LIMITS_H 1 + +/* Define to 1 if you have the <locale.h> header file. */ +#define HAVE_LOCALE_H 1 -/* Define if you have the <malloc.h> header file. */ +/* Define to 1 if your system has a GNU libc compatible `malloc' function, and + to 0 otherwise. */ +#define HAVE_MALLOC 1 + +/* Define to 1 if you have the <malloc.h> header file. */ /* #undef HAVE_MALLOC_H */ -/* Define if you have the <string.h> header file. */ +/* Define to 1 if you have the <memory.h> header file. */ +#define HAVE_MEMORY_H 1 + +/* Define to 1 if you have the `memset' function. */ +#define HAVE_MEMSET 1 + +/* Define to 1 if you have the <netinet/in.h> header file. */ +#define HAVE_NETINET_IN_H 1 + +/* Define to 1 if you have the `pow' function. */ +#define HAVE_POW 1 + +/* Define to 1 if you have the <pthread.h> header file. */ +#define HAVE_PTHREAD_H 1 + +/* Define to 1 if your system has a GNU libc compatible `realloc' function, + and to 0 otherwise. */ +#define HAVE_REALLOC 1 + +/* Define to 1 if you have the `regcomp' function. */ +#define HAVE_REGCOMP 1 + +/* Define to 1 if you have the <regex.h> header file. */ +#define HAVE_REGEX_H 1 + +/* Define to 1 if you have the `setlocale' function. */ +#define HAVE_SETLOCALE 1 + +/* Define to 1 if stdbool.h conforms to C99. */ +#define HAVE_STDBOOL_H 1 + +/* Define to 1 if you have the <stddef.h> header file. */ +#define HAVE_STDDEF_H 1 + +/* Define to 1 if you have the <stdint.h> header file. */ +#define HAVE_STDINT_H 1 + +/* Define to 1 if you have the <stdlib.h> header file. */ +#define HAVE_STDLIB_H 1 + +/* Define to 1 if you have the `strchr' function. */ +#define HAVE_STRCHR 1 + +/* Define to 1 if you have the <strings.h> header file. */ +#define HAVE_STRINGS_H 1 + +/* Define to 1 if you have the <string.h> header file. */ #define HAVE_STRING_H 1 -/* Define if you have the <sys/types.h> header file. */ +/* Define to 1 if you have the `strtol' function. */ +#define HAVE_STRTOL 1 + +/* Define to 1 if you have the <sys/stat.h> header file. */ +#define HAVE_SYS_STAT_H 1 + +/* Define to 1 if you have the <sys/types.h> header file. */ #define HAVE_SYS_TYPES_H 1 -/* Define if you have <alloca.h> and it should be used (not on Ultrix). */ -/* #undef HAVE_ALLOCA_H */ +/* Define to 1 if you have <sys/wait.h> that is POSIX.1 compatible. */ +#define HAVE_SYS_WAIT_H 1 + +/* Define to 1 if you have the <unistd.h> header file. */ +#define HAVE_UNISTD_H 1 + +/* Define to 1 if you have the `vfork' function. */ +#define HAVE_VFORK 1 + +/* Define to 1 if you have the <vfork.h> header file. */ +/* #undef HAVE_VFORK_H */ + +/* Define to 1 if `fork' works. */ +#define HAVE_WORKING_FORK 1 + +/* Define to 1 if `vfork' works. */ +#define HAVE_WORKING_VFORK 1 + +/* Define to 1 if the system has the type `_Bool'. */ +#define HAVE__BOOL 1 + +/* Define to the m4 executable name. */ +#define M4 "/usr/bin/m4" + +/* Define to 1 if your C compiler doesn't accept -c and -o together. */ +/* #undef NO_MINUS_C_MINUS_O */ + +/* Name of package */ +#define PACKAGE "flex" + +/* Define to the address where bug reports for this package should be sent. */ +#define PACKAGE_BUGREPORT "flex-help@lists.sourceforge.net" + +/* Define to the full name of this package. */ +#define PACKAGE_NAME "the fast lexical analyser generator" + +/* Define to the full name and version of this package. */ +#define PACKAGE_STRING "the fast lexical analyser generator 2.5.37" + +/* Define to the one symbol short name of this package. */ +#define PACKAGE_TARNAME "flex" + +/* Define to the home page for this package. */ +#define PACKAGE_URL "" + +/* Define to the version of this package. */ +#define PACKAGE_VERSION "2.5.37" + +/* If using the C implementation of alloca, define if you know the + direction of stack growth for your system; otherwise it will be + automatically deduced at runtime. + STACK_DIRECTION > 0 => grows toward higher addresses + STACK_DIRECTION < 0 => grows toward lower addresses + STACK_DIRECTION = 0 => direction of growth unknown */ +/* #undef STACK_DIRECTION */ + +/* Define to 1 if you have the ANSI C header files. */ +#define STDC_HEADERS 1 + +/* Version number of package */ +#define VERSION "2.5.37" + +/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a + `char[]'. */ +#define YYTEXT_POINTER 1 + +/* Define to empty if `const' does not conform to ANSI C. */ +/* #undef const */ + +/* Define to rpl_malloc if the replacement function should be used. */ +/* #undef malloc */ + +/* Define to `int' if <sys/types.h> does not define. */ +/* #undef pid_t */ + +/* Define to rpl_realloc if the replacement function should be used. */ +/* #undef realloc */ + +/* Define to `unsigned int' if <sys/types.h> does not define. */ +/* #undef size_t */ -/* Define if platform-specific command line handling is necessary. */ -/* #undef NEED_ARGV_FIXUP */ +/* Define as `fork' if `vfork' does not work. */ +/* #undef vfork */ Modified: projects/flex-sf/usr.bin/lex/lib/Makefile ============================================================================== --- projects/flex-sf/usr.bin/lex/lib/Makefile Fri May 10 19:22:43 2013 (r250474) +++ projects/flex-sf/usr.bin/lex/lib/Makefile Fri May 10 19:29:30 2013 (r250475) @@ -2,6 +2,8 @@ .include <bsd.own.mk> +.PATH: ${.CURDIR}/../../../contrib/flex + LIB= ln SRCS= libmain.c libyywrap.c NO_PIC=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201305101929.r4AJTU2t015917>