NM = @NM@
all: @DEFAULT_MAKECMDGOALS@
-all-mingwrt-stage-1: all-mingwrt-objects all-mingwrt-libs
-all-mingwrt-stage-1-and-2: all-mingwrt-stage-1 all-mingwrt-dll
+all-mingwrt-stage-1-only: all-mingwrt-objects all-mingwrt-libs
+all-mingwrt-stage-1-and-2: all-mingwrt-stage-1-only all-mingwrt-dll
all-mingwrt: all-mingwrt-stage-1-and-2
+all-gcc: all-mingwrt-stage-1-only
-include_deprecated = @include_deprecated@
-active_goals = $1-$2 $(if $(include_deprecated),$1-deprecated-$2)
+active_goals = $1-$2 $(if @include_deprecated@,$1-deprecated-$2)
+all-deprecated-mingwrt-stage-1-only: all-deprecated-mingwrt
-all-stage-1: $(call active_goals,all,mingwrt-stage-1)
+all-stage-1-only: $(call active_goals,all,mingwrt-stage-1-only)
all-stage-1-and-2: $(call active_goals,all,mingwrt)
# Installation paths and macros.
# "inttypes" conversion routines, provided in libmingwex.a
#
libmingwex.a: $(addsuffix .$(OBJEXT), \
- imaxabs imaxdiv strtoimax strtoumax wcstoimax wcstoumax)
+ imaxdiv strtoimax strtoumax wcstoimax wcstoumax)
# Additional math functions, augmenting Microsoft's paltry
# selection, also delivered in libmingwex.a, (FIXME: and yet
# compatibility than their Microsoft equivalents.
#
vpath %.c ${mingwrt_srcdir}/mingwex/stdio
-libmingwex.a: $(addsuffix .$(OBJEXT), btowc fopen64 fprintf fseeko64 ftello64 \
- lseek64 pformat printf snprintf snwprintf sprintf vfprintf vfscanf vfwscanf \
- vprintf vscanf vsnprintf vsnwprintf vsprintf vsscanf vswscanf vwscanf)
+libmingwex.a: $(addsuffix .$(OBJEXT), btowc fprintf fseeko64 pformat \
+ printf snprintf snwprintf sprintf vfprintf vfscanf vfwscanf vprintf \
+ vscanf vsnprintf vsnwprintf vsprintf vsscanf vswscanf vwscanf)
# pformat.$(OBJEXT) needs an explicit build rule, since we need to
# specify an additional header file path.
# Some additional miscellaneous functions, in libmingwex.a
#
#libmingwex.a: $(addsuffix .$(OBJEXT), glob membarrier)
-libmingwex.a: $(addsuffix .$(OBJEXT), mingw-aligned-malloc mingw-fseek glob)
-libmingwex.a: $(addsuffix .$(OBJEXT), getopt basename dirname ftruncate usleep)
+libmingwex.a: $(addsuffix .$(OBJEXT), mingw-aligned-malloc mingw-fseek)
+libmingwex.a: $(addsuffix .$(OBJEXT), glob getopt basename dirname nsleep)
+libmingwex.a: $(addsuffix .$(OBJEXT), mkstemp mkdtemp cryptnam)
libmingwex.a: $(addsuffix .$(OBJEXT), tdelete tfind tsearch twalk)
# which identifies the originating file as a system header).
#
libimpl_sed_script = sed \
- -e '/__CRT_ALIAS *__LIBIMPL.*FUNCTION *= *$1[ ,)].*)/d' \
+ -e '/pragma .* system_header/d' \
-e '/__CRT_INLINE *__LIBIMPL.*FUNCTION *= *$1[ ,)].*)/d' \
- -e '/pragma .* system_header/d'
+ -e 's/__LIBIMPL.*ALIAS *= *$1[ ,)].*)/__attribute__((__alias__("$1")))/' \
+ -e '/__CRT_ALIAS *__LIBIMPL.*FUNCTION *= *$1[ ,)].*)/d'
-LIBIMPL_CFLAGS = $(CFLAGS) $(INCLUDES) -fno-align-functions
+LIBIMPL_CFLAGS = $(CFLAGS) $(INCLUDES) $(LIBIMPL_EXTRA_CFLAGS)
+LIBIMPL_EXTRA_CFLAGS = -fno-align-functions -Wno-deprecated-declarations
# LIBIMPL dependencies are tracked using zero sized name.libimpl
# files; the intermediate C files are generated as a side effect
# Install everything.
#
-install: install-mingwrt
+install: inst@DEFAULT_MAKECMDGOALS@
install-stage-1-only: install-headers install-libdir-objects install-libs
install-stage-1-and-2: install-stage-1-only install-bin
install-gcc: install-stage-1-only
includedirs: mingwrt-includedirs
install-headers install-mingwrt: install-mingwrt-headers
-${includedir}/sys: includedir
-mingwrt-includedirs: ${includedir}/sys
+${includedir}/sys ${includedir}/parts: includedir
+mingwrt-includedirs: ${includedir}/sys ${includedir}/parts
$(mkinstalldirs) $^
install-mingwrt-headers: mingwrt-includedirs
$(INSTALL_DATA) ${mingwrt_srcdir}/include/*.h ${includedir}
$(INSTALL_DATA) ${mingwrt_srcdir}/include/sys/*.h ${includedir}/sys
+ $(INSTALL_DATA) ${mingwrt_srcdir}/include/parts/*.h ${includedir}/parts
$(INSTALL_DATA) ${mingwrt_srcdir}/profile/*.h ${includedir}
# Install libraries, and supporting free standing object files.