From: Peter Johnson Date: Sat, 20 Oct 2001 23:37:13 +0000 (-0000) Subject: Add "very flat" (based on Makefile.flat) makefiles and config.h files for X-Git-Tag: v0.1.0~240 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d9ea939762911ebce2bab5dbd3575b38c2f6923a;p=yasm Add "very flat" (based on Makefile.flat) makefiles and config.h files for DJGPP and Visual C++. These are build-only (not development). svn path=/trunk/yasm/; revision=290 --- diff --git a/Mkfiles/Makefile.dj b/Mkfiles/Makefile.dj new file mode 100644 index 00000000..ba96818d --- /dev/null +++ b/Mkfiles/Makefile.dj @@ -0,0 +1,78 @@ +# $IdPath$ +# +# Ultra-flat Makefile for DJGPP. +# Does NOT depend on or use configure. +# +# Works for simple build but *not* for development (no clean, dist, etc). +# Also, WARNING, no header dependencies are included! +# +# How to compile: +# copy Mkfiles/config.h.dj config.h +# make -fMkfiles/Makefile.dj + +CFLAGS=-DHAVE_CONFIG_H -I. -Isrc -Inointl +CC=gcc + +all: src/yasm + +SRC_OBJS= \ + src/bytecode.o \ + src/errwarn.o \ + src/expr.o \ + src/symrec.o \ + src/globals.o \ + src/file.o \ + src/section.o \ + src/options.o \ + src/parser.o \ + src/intnum.o \ + src/floatnum.o \ + src/ternary.o \ + src/bitvect.o \ + src/xmalloc.o \ + src/xstrdup.o \ + src/strcasecmp.o + +SRC_PREPROCS_RAW_OBJS= \ + src/preprocs/raw/preproc.o + +SRC_PREPROCS_OBJS= \ + $(SRC_PREPROCS_RAW_OBJS) + +SRC_PARSERS_NASM_OBJS= \ + src/parsers/nasm/parser.o \ + src/parsers/nasm/bison.o \ + src/parsers/nasm/token.o + +SRC_PARSERS_OBJS= \ + $(SRC_PARSERS_NASM_OBJS) + +SRC_OPTIMIZERS_DBG_OBJS= \ + src/optimizers/dbg/optimizer.o + +SRC_OPTIMIZERS_OBJS= \ + $(SRC_OPTIMIZERS_DBG_OBJS) + +SRC_OBJFMTS_DBG_OBJS= \ + src/objfmts/dbg/objfmt.o + +SRC_OBJFMTS_OBJS= \ + $(SRC_OBJFMTS_DBG_OBJS) + +YASM_OBJS= \ + src/main.o \ + $(SRC_OBJS) \ + $(SRC_PREPROCS_OBJS) \ + $(SRC_PARSERS_OBJS) \ + $(SRC_OPTIMIZERS_OBJS) \ + $(SRC_OBJFMTS_OBJS) + +src/yasm: $(YASM_OBJS) + $(CC) -o src/yasm $(YASM_OBJS) + +src/parsers/nasm/token.o: src/parsers/nasm/token.c + $(CC) -c $(CFLAGS) -Isrc/parsers/nasm -o $@ $< + +.c.o: + $(CC) -c $(CFLAGS) -o $@ $< + diff --git a/Mkfiles/Makefile.vc b/Mkfiles/Makefile.vc new file mode 100644 index 00000000..0f8650ba --- /dev/null +++ b/Mkfiles/Makefile.vc @@ -0,0 +1,78 @@ +# $IdPath$ +# +# Ultra-flat Makefile for Visual C++. +# Does NOT depend on or use configure. +# +# Works for simple build but *not* for development (no clean, dist, etc). +# Also, WARNING, no header dependencies are included! +# +# How to compile: +# copy Mkfiles/config.h.vc config.h +# nmake -fMkfiles/Makefile.vc + +CFLAGS=/DHAVE_CONFIG_H /I. /Isrc /Inointl +CC=cl + +all: src\yasm.exe + +SRC_OBJS= \ + src\bytecode.obj \ + src\errwarn.obj \ + src\expr.obj \ + src\symrec.obj \ + src\globals.obj \ + src\file.obj \ + src\section.obj \ + src\options.obj \ + src\parser.obj \ + src\intnum.obj \ + src\floatnum.obj \ + src\ternary.obj \ + src\bitvect.obj \ + src\xmalloc.obj \ + src\xstrdup.obj \ + src\strcasecmp.obj + +SRC_PREPROCS_RAW_OBJS= \ + src\preprocs\raw\preproc.obj + +SRC_PREPROCS_OBJS= \ + $(SRC_PREPROCS_RAW_OBJS) + +SRC_PARSERS_NASM_OBJS= \ + src\parsers\nasm\parser.obj \ + src\parsers\nasm\bison.obj \ + src\parsers\nasm\token.obj + +SRC_PARSERS_OBJS= \ + $(SRC_PARSERS_NASM_OBJS) + +SRC_OPTIMIZERS_DBG_OBJS= \ + src\optimizers\dbg\optimizer.obj + +SRC_OPTIMIZERS_OBJS= \ + $(SRC_OPTIMIZERS_DBG_OBJS) + +SRC_OBJFMTS_DBG_OBJS= \ + src\objfmts\dbg\objfmt.obj + +SRC_OBJFMTS_OBJS= \ + $(SRC_OBJFMTS_DBG_OBJS) + +YASM_OBJS= \ + src\main.obj \ + $(SRC_OBJS) \ + $(SRC_PREPROCS_OBJS) \ + $(SRC_PARSERS_OBJS) \ + $(SRC_OPTIMIZERS_OBJS) \ + $(SRC_OBJFMTS_OBJS) + +src\yasm.exe: $(YASM_OBJS) + $(CC) /Fesrc\yasm.exe $(YASM_OBJS) + +src\parsers\nasm\token.o: src\parsers\nasm\token.c + $(CC) /c $(CFLAGS) /Isrc/parsers/nasm /Fo$@ $< + +.c.obj: + $(CC) /c $(CFLAGS) /Fo$@ $< + diff --git a/Mkfiles/config.h.dj b/Mkfiles/config.h.dj new file mode 100644 index 00000000..f0c1a877 --- /dev/null +++ b/Mkfiles/config.h.dj @@ -0,0 +1,210 @@ +/* $IdPath$ */ + +#ifndef YASM_CONFIG_H +#define YASM_CONFIG_H + +/* Define if using alloca.c. */ +/* #undef C_ALLOCA */ + +/* 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 if you have alloca, as a function or macro. */ +#define HAVE_ALLOCA + +/* Define if you have and it should be used (not on Ultrix). */ +/* #undef HAVE_ALLOCA_H */ + +/* Define if you don't have vprintf but do have _doprnt. */ +/* #undef HAVE_DOPRNT */ + +/* Define if you have a working `mmap' system call. */ +/* #undef HAVE_MMAP */ + +/* Define if you have that is POSIX.1 compatible. */ +#define HAVE_SYS_WAIT_H + +/* Define if you have the vprintf function. */ +#define HAVE_VPRINTF + +/* Define as __inline if that's what the C compiler calls it. */ +/* #undef inline */ + +/* Define to `long' if doesn't define. */ +/* #undef off_t */ + +/* Define to `int' if doesn't define. */ +/* #undef pid_t */ + +/* Define to `unsigned' if doesn't define. */ +/* #undef size_t */ + +/* 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 run-time. + 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 if you have the ANSI C header files. */ +#define STDC_HEADERS + +/* Define if lex declares yytext as a char * by default, not a char[]. */ +#define YYTEXT_POINTER + +/* Workaround for bad implementations. */ +#define HAVE_BOGUS_SYS_QUEUE_H + +/* gettext tests */ +/* #undef ENABLE_NLS */ +/* #undef HAVE_CATGETS */ +/* #undef HAVE_GETTEXT */ +/* #undef HAVE_LC_MESSAGES */ +/* #undef HAVE_STPCPY */ + +/* combined test for fork/way/msg* */ +/* #undef USE_FORKWAITMSG */ + +/* Check for GNU C Library */ +/* #undef HAVE_GNU_C_LIBRARY */ + +/* Define if you have the __argz_count function. */ +/* #undef HAVE___ARGZ_COUNT */ + +/* Define if you have the __argz_next function. */ +/* #undef HAVE___ARGZ_NEXT */ + +/* Define if you have the __argz_stringify function. */ +/* #undef HAVE___ARGZ_STRINGIFY */ + +/* Define if you have the abort function. */ +#define HAVE_ABORT + +/* Define if you have the dcgettext function. */ +/* #undef HAVE_DCGETTEXT */ + +/* Define if you have the fork function. */ +/* #undef HAVE_FORK */ + +/* Define if you have the getcwd function. */ +#define HAVE_GETCWD + +/* Define if you have the getpagesize function. */ +#define HAVE_GETPAGESIZE + +/* Define if you have the memcpy function. */ +#define HAVE_MEMCPY + +/* Define if you have the msgctl function. */ +/* #undef HAVE_MSGCTL */ + +/* Define if you have the msgget function. */ +/* #undef HAVE_MSGGET */ + +/* Define if you have the msgrcv function. */ +/* #undef HAVE_MSGRCV */ + +/* Define if you have the msgsnd function. */ +/* #undef HAVE_MSGSND */ + +/* Define if you have the munmap function. */ +/* #undef HAVE_MUNMAP */ + +/* Define if you have the putenv function. */ +#define HAVE_PUTENV + +/* Define if you have the setenv function. */ +#define HAVE_SETENV + +/* Define if you have the setlocale function. */ +#define HAVE_SETLOCALE + +/* Define if you have the snprintf function. */ +/* #undef HAVE_SNPRINTF */ + +/* Define if you have the stpcpy function. */ +#define HAVE_STPCPY + +/* Define if you have the strcasecmp function. */ +#define HAVE_STRCASECMP + +/* Define if you have the strchr function. */ +#define HAVE_STRCHR + +/* Define if you have the strcmpi function. */ +/* #undef HAVE_STRCMPI */ + +/* Define if you have the strdup function. */ +#define HAVE_STRDUP + +/* Define if you have the strerror function. */ +#define HAVE_STRERROR + +/* Define if you have the stricmp function. */ +/* #undef HAVE_STRICMP */ + +/* Define if you have the strsep function. */ +#define HAVE_STRSEP + +/* Define if you have the toascii function. */ +#define HAVE_TOASCII + +/* Define if you have the wait function. */ +#define HAVE_WAIT + +/* Define if you have the header file. */ +/* #undef HAVE_ARGZ_H */ + +/* Define if you have the header file. */ +#define HAVE_LIMITS_H + +/* Define if you have the header file. */ +#define HAVE_LOCALE_H + +/* Define if you have the header file. */ +#define HAVE_MALLOC_H + +/* Define if you have the header file. */ +/* #undef HAVE_NL_TYPES_H */ + +/* Define if you have the header file. */ +#define HAVE_STRING_H + +/* Define if you have the header file. */ +#define HAVE_SYS_CDEFS_H + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_IPC_H */ + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_MSG_H */ + +/* Define if you have the header file. */ +#define HAVE_SYS_PARAM_H + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_QUEUE_H */ + +/* Define if you have the header file. */ +#define HAVE_SYS_TYPES_H + +/* Define if you have the header file. */ +#define HAVE_UNISTD_H + +/* Define if you have the i library (-li). */ +/* #undef HAVE_LIBI */ + +/* Name of package */ +#define PACKAGE "yasm" + +/* Version number of package */ +#define VERSION "0.0.1" + + +#endif /* YASM_CONFIG_H */ diff --git a/Mkfiles/config.h.vc b/Mkfiles/config.h.vc new file mode 100644 index 00000000..1af0e941 --- /dev/null +++ b/Mkfiles/config.h.vc @@ -0,0 +1,215 @@ +/* $IdPath$ */ + +#ifndef YASM_CONFIG_H +#define YASM_CONFIG_H + +/* Define if using alloca.c. */ +/* #undef C_ALLOCA */ + +/* 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 if you have alloca, as a function or macro. */ +/* #undef HAVE_ALLOCA */ + +/* Define if you have and it should be used (not on Ultrix). */ +/* #undef HAVE_ALLOCA_H */ + +/* Define if you don't have vprintf but do have _doprnt. */ +/* #undef HAVE_DOPRNT */ + +/* Define if you have a working `mmap' system call. */ +/* #undef HAVE_MMAP */ + +/* Define if you have that is POSIX.1 compatible. */ +/* #undef HAVE_SYS_WAIT_H */ + +/* Define if you have the vprintf function. */ +#define HAVE_VPRINTF + +/* Define as __inline if that's what the C compiler calls it. */ +/* #undef inline */ + +/* Define to `long' if doesn't define. */ +/* #undef off_t */ + +/* Define to `int' if doesn't define. */ +#define pid_t int + +/* Define to `unsigned' if doesn't define. */ +/* #undef size_t */ + +/* 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 run-time. + 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 if you have the ANSI C header files. */ +#define STDC_HEADERS + +/* Define if lex declares yytext as a char * by default, not a char[]. */ +#define YYTEXT_POINTER + +/* Workaround for bad implementations. */ +#define HAVE_BOGUS_SYS_QUEUE_H + +/* gettext tests */ +/* #undef ENABLE_NLS */ +/* #undef HAVE_CATGETS */ +/* #undef HAVE_GETTEXT */ +/* #undef HAVE_LC_MESSAGES */ +/* #undef HAVE_STPCPY */ + +/* combined test for fork/way/msg* */ +/* #undef USE_FORKWAITMSG */ + +/* Check for GNU C Library */ +/* #undef HAVE_GNU_C_LIBRARY */ + +/* Define if you have the __argz_count function. */ +/* #undef HAVE___ARGZ_COUNT */ + +/* Define if you have the __argz_next function. */ +/* #undef HAVE___ARGZ_NEXT */ + +/* Define if you have the __argz_stringify function. */ +/* #undef HAVE___ARGZ_STRINGIFY */ + +/* Define if you have the abort function. */ +#define HAVE_ABORT + +/* Define if you have the dcgettext function. */ +/* #undef HAVE_DCGETTEXT */ + +/* Define if you have the fork function. */ +/* #undef HAVE_FORK */ + +/* Define if you have the getcwd function. */ +/* #undef HAVE_GETCWD */ + +/* Define if you have the getpagesize function. */ +/* #undef HAVE_GETPAGESIZE */ + +/* Define if you have the memcpy function. */ +#define HAVE_MEMCPY + +/* Define if you have the msgctl function. */ +/* #undef HAVE_MSGCTL */ + +/* Define if you have the msgget function. */ +/* #undef HAVE_MSGGET */ + +/* Define if you have the msgrcv function. */ +/* #undef HAVE_MSGRCV */ + +/* Define if you have the msgsnd function. */ +/* #undef HAVE_MSGSND */ + +/* Define if you have the munmap function. */ +/* #undef HAVE_MUNMAP */ + +/* Define if you have the putenv function. */ +/* #undef HAVE_PUTENV */ + +/* Define if you have the setenv function. */ +/* #undef HAVE_SETENV */ + +/* Define if you have the setlocale function. */ +/* #undef HAVE_SETLOCALE */ + +/* Define if you have the snprintf function. */ +#define HAVE_SNPRINTF +#define snprintf _snprintf + +/* Define if you have the stpcpy function. */ +/* #undef HAVE_STPCPY */ + +/* Define if you have the strcasecmp function. */ +/* #undef HAVE_STRCASECMP */ + +/* Define if you have the strchr function. */ +#define HAVE_STRCHR + +/* Define if you have the strcmpi function. */ +#define HAVE_STRCMPI +#define strcmpi _strcmpi + +/* Define if you have the strdup function. */ +#define HAVE_STRDUP +#define strdup _strdup + +/* Define if you have the strerror function. */ +#define HAVE_STRERROR + +/* Define if you have the stricmp function. */ +#define HAVE_STRICMP +#define stricmp _stricmp + +/* Define if you have the strsep function. */ +/* #undef HAVE_STRSEP */ + +/* Define if you have the toascii function. */ +#define HAVE_TOASCII +#define toascii __toascii + +/* Define if you have the wait function. */ +/* #undef HAVE_WAIT */ + +/* Define if you have the header file. */ +/* #undef HAVE_ARGZ_H */ + +/* Define if you have the header file. */ +#define HAVE_LIMITS_H + +/* Define if you have the header file. */ +#define HAVE_LOCALE_H + +/* Define if you have the header file. */ +#define HAVE_MALLOC_H + +/* Define if you have the header file. */ +/* #undef HAVE_NL_TYPES_H */ + +/* Define if you have the header file. */ +#define HAVE_STRING_H + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_CDEFS_H */ + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_IPC_H */ + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_MSG_H */ + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_PARAM_H */ + +/* Define if you have the header file. */ +/* #undef HAVE_SYS_QUEUE_H */ + +/* Define if you have the header file. */ +#define HAVE_SYS_TYPES_H + +/* Define if you have the header file. */ +/* #undef HAVE_UNISTD_H */ + +/* Define if you have the i library (-li). */ +/* #undef HAVE_LIBI */ + +/* Name of package */ +#define PACKAGE "yasm" + +/* Version number of package */ +#define VERSION "0.0.1" + + +#endif /* YASM_CONFIG_H */