view buildsys/nmake/prolog.nmake @ 632:ed19b429a152

- added explicit arm64 target, and clang tool options to Windows' configure.bat - configure.{bat,rc} now writing Makefile.config, for consistency/compatibility (e.g. configure.bat can now be used to set up env flags for a non-nmake toolchain) - simplified/decluttered Windows and Plan9 configure scripts (removal of unused/stale options, ...) - removed stale test/makepkg.sh helper
author Tassilo Philipp
date Sat, 19 Nov 2022 15:45:41 +0100
parents 3e629dc19168
children
line wrap: on
line source

#//////////////////////////////////////////////////////////////////////////////
#
# Copyright (c) 2007,2009      Daniel Adler <dadler@uni-goettingen.de>, 
#               2007,2009,2022 Tassilo Philipp <tphilipp@potion-studios.com>
#
# Permission to use, copy, modify, and distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
#
# THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
# WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
# MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
# ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
# ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#
#//////////////////////////////////////////////////////////////////////////////

#///////////////////////////////////////////////////
#
#	nmake rules
#	prolog.nmake
#
#///////////////////////////////////////////////////


.SILENT:

# Default "build all" target.
all: configure build


# Check if library has been 'configured' properly. If not, tell the user and abort.
!IF !DEFINED(CONFIG_OS) || !DEFINED(CONFIG_ARCH)
configure: $(TOP)\Makefile.config
$(TOP)\Makefile.config:
	echo "Library not configured properly! Run configure.bat from the library's root directory first!"
!ELSE
configure:
!ENDIF


# Include config rules.
!IF EXISTS($(TOP)\Makefile.config)
!  INCLUDE $(TOP)\Makefile.config
!ENDIF


# set BUILD_* from CONFIG_* variables
!IF !DEFINED(BUILD_HOST)
BUILD_HOST = $(CONFIG_HOST)
!ENDIF
!IF !DEFINED(BUILD_OS)
BUILD_OS = $(CONFIG_OS)
!ENDIF
!IF !DEFINED(BUILD_ARCH)
BUILD_ARCH = $(CONFIG_ARCH)
!ENDIF
!IF !DEFINED(BUILD_TOOL)
BUILD_TOOL = $(CONFIG_TOOL)
!ENDIF
!IF !DEFINED(BUILD_ASM)
BUILD_ASM = $(CONFIG_ASM)
!ENDIF

!IF "$(BUILD_TOOL)" != ""
!  INCLUDE tool_$(BUILD_TOOL).nmake
!ENDIF