File:  [gforth] / gforth / configure.cmd
Revision 1.7: download - view: text, annotated - select for diffs
Wed May 21 20:39:20 1997 UTC (20 years, 6 months ago) by anton
Branches: MAIN
CVS tags: HEAD
jwilke's changes:
Moved many files to other directories
renamed many files
other changes unknown to me.

/*
Copyright 1996-1997 Free Software Foundation, Inc.

This file is part of Gforth.

Gforth is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
say "*** Configuring for OS/2 with EMX 3.0 GNU C ***"

parse arg args

THREAD="i"
FREGS="n"

do while args \== ""
   parse var args arg args

   select
      when arg="--enable-direct-threaded" then THREAD="d"
      when arg="--enable-indirect-threaded" then THREAD="i"
      when arg="--enable-force-reg" then FREGS="y"
      when arg="--help" then do
        say "--enable and --with options recognized:"
        say "  --enable-force-reg      Use explicit register declarations if they appear in"
        say "                          the machine.h file. This can cause a good speedup,"
        say "                          but also incorrect code with some gcc versions on"
        say "                          some processors (default disabled)."
        say "  --enable-direct-threaded      Force direct threading. This may not work on"
        say "                                some machines and may cause slowdown on others."
        say "                                (default processor-dependent)"
        say "  --enable-indirect-threaded    Force indirect threading. This can cause a"
        say "                                slowdown on some machines."
        say "                                (default processor-dependent)"
      end
    otherwise
      do
        say "*** Unknown option:" arg
        call Usage
      end
  end

end

copy makefile.os2 makefile
copy kernl32l.fi kernel.fi
copy 386.h machine.h
copy os2conf.h csrc\config.h
copy startup.fs startup.unx
copy startup.dos startup.fs
copy history.dos history.fs
if THREAD="i" THEN DO
	call lineout csrc\config.h, "#ifndef INDIRECT_THREADED"
	call lineout csrc\config.h, "#define INDIRECT_THREADED 1"
	call lineout csrc\config.h, "#endif"
end
IF THREAD="d" THEN do
	call lineout csrc\config.h, "#ifndef DIRECT_THREADED"
	call lineout csrc\config.h, "#define DIRECT_THREADED 1" 
	call lineout csrc\config.h, "#endif"
end
IF FREGS="y" THEN do
	call lineout csrc\config.h, "#ifndef FORCE_REG"
	call lineout csrc\config.h, "#define FORCE_REG 1"
	call lineout csrc\config.h, "#endif"
end
call lineout version.h1, 'static char gforth_version[]="0.3.0";'
call lineout version.fs1, ': version-string s" 0.3.0" ;'
call lineout 'version-stamp', '0.3.0'

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>