teTeX-2.0-rc1: make vs. $(MAKE)

Harald Koenig <[email protected]>
Newsgroups gmane.comp.tex.tetex.beta
Message-ID <[email protected]>
On Jan 19, Thomas Esser wrote:

>   ftp://ftp.dante.de/tex-archive/systems/unix/teTeX/2.0/distrib/teTeX-src-2.0-rc1.tar.gz

this version does not compile cleanly at least on HP-UX, AIX, AXP OSF1 and FreeBSD
because sometimes the native "make" will fail for sophisticated makefiles.
they all break with messages similar to this one

-------------------------------------------------------------------------------
cd pdftexdir && make pdftosrc.o
Make: Unknown flag argument  .  Stop.
gmake[2]: *** [pdftexdir/pdftosrc.o] Error 1
gmake[2]: Leaving directory `teTeX-bin-2.0-rc1/ARENA/texk/web2c'
gmake[1]: *** [all] Error 1
gmake[1]: Leaving directory `teTeX-bin-2.0-rc1/ARENA/texk'
gmake: *** [all] Error 1
-------------------------------------------------------------------------------

because it's calling make instead of $(MAKE) (which is gmake).

that specific bug comes from web2c/pdftexdir/pdftex.mk (see diff below).
I've grepped around a bit and found a few more locations where
make is used instead of $(MAKE) -- maybe there are even more ?!

here is my patch which seems to work fine for me:



-------------------------------------------------------------------------------
--- ./teTeX-src-2.0-rc1/texk/web2c/pdftexdir/pdftex.mk~	Sun Jun  2 10:10:33 2002
+++ ./teTeX-src-2.0-rc1/texk/web2c/pdftexdir/pdftex.mk	Fri Jan 31 17:42:00 2003
@@ -43,25 +43,25 @@
 pdftosrc: pdftexdir/pdftosrc.o
 	$(kpathsea_cxx_link) pdftexdir/pdftosrc.o $(LDLIBXPDF) -lm
 pdftexdir/pdftosrc.o:$(srcdir)/pdftexdir/pdftosrc.cc
-	cd pdftexdir && make pdftosrc.o
+	cd pdftexdir && $(MAKE) pdftosrc.o
 
 # pdftex binaries archive
 pdftexbin:
 	rm -f pdtex*.zip $(pdftex_bin)
-	XLDFLAGS=-static make $(pdftex_bin)
+	XLDFLAGS=-static $(MAKE) $(pdftex_bin)
 	if test "x$(CC)" = "xdos-gcc"; then \
-	    make pdftexbin-djgpp; \
+	    $(MAKE) pdftexbin-djgpp; \
 	elif test "x$(CC)" = "xi386-mingw32-gcc"; then \
-	    make pdftexbin-mingw32; \
+	    $(MAKE) pdftexbin-mingw32; \
 	elif test "x$(CC)" = "xgnuwin32gcc"; then \
-	    make pdftexbin-gnuwin32; \
+	    $(MAKE) pdftexbin-gnuwin32; \
 	else \
-	    make pdftexbin-native; \
+	    $(MAKE) pdftexbin-native; \
 	fi
 
 pdftex-cross:
-	make web2c-cross
-	make pdftexbin
+	$(MAKE) web2c-cross
+	$(MAKE) pdftexbin
 
 web2c-cross: $(web2c_programs)
 	@if test ! -x $(linux_build_dir)/tangle; then echo Error: linux_build_dir not ready; exit -1; fi
@@ -70,15 +70,15 @@
 	cp -f $(linux_build_dir)/web2c/splitup web2c
 	cp -f $(linux_build_dir)/web2c/web2c web2c
 	touch web2c/fixwrites web2c/splitup web2c/web2c
-	make tie
+	$(MAKE) tie
 	rm -f tie
 	cp -f $(linux_build_dir)/tie .
 	touch tie
-	make tangleboot
+	$(MAKE) tangleboot
 	rm -f tangleboot
 	cp -f $(linux_build_dir)/tangleboot .
 	touch tangleboot
-	make tangle
+	$(MAKE) tangle
 	rm -f tangle
 	cp -f $(linux_build_dir)/tangle .
 	touch tangle
--- ./teTeX-src-2.0-rc1/libs/ncurses/dist.mk~	Sun Oct 13 01:27:36 2002
+++ ./teTeX-src-2.0-rc1/libs/ncurses/dist.mk	Fri Jan 31 17:42:58 2003
@@ -107,7 +107,7 @@
 # .ali files contain cross referencing information required by gnathtml.
 adahtml: MANIFEST
 	if [ ! -z "$(GNATHTML)" ]; then \
-	  (cd ./Ada95/gen ; make html) ;\
+	  (cd ./Ada95/gen ; $(MAKE) html) ;\
 	  sed -e "\%./doc/html/ada/%d" < MANIFEST > MANIFEST.tmp ;\
 	  find ./doc/html/ada -type f -print >> MANIFEST.tmp ;\
 	  sort -u < MANIFEST.tmp > MANIFEST ;\
--- ./teTeX-src-2.0-rc1/texk/make/dist.mk~	Wed Nov 13 15:55:42 2002
+++ ./teTeX-src-2.0-rc1/texk/make/dist.mk	Fri Jan 31 17:44:15 2003
@@ -24,7 +24,7 @@
 @MAINT@	libs_files="$(libs_files)"; \
 @MAINT@	  for f in $$libs_files; do \
 @MAINT@	    ln $(top_srcdir)/../../libs/$$f $(libs_distdir); done
-@MAINT@	cd .. && make Makefile ./configure
+@MAINT@	cd .. && ($MAKE) Makefile ./configure
 @MAINT@	cd .. && ln $(texk_files) $(distname)/$(texk_distdir)
 @MAINT@	cp -p $(top_srcdir)/../dir $(texk_distdir)
 @MAINT@	-ln $(ln_files) $(distdir)
-------------------------------------------------------------------------------

Harald Koenig
-- 
"I hope to die                                      ___       _____
before I *have* to use Microsoft Word.",           0--,|    /OOOOOOO\
Donald E. Knuth, 02-Oct-2001 in Tuebingen.        <_/  /  /OOOOOOOOOOO\
                                                    \  \/OOOOOOOOOOOOOOO\
                                                      \ OOOOOOOOOOOOOOOOO|//
Harald Koenig                                          \/\/\/\/\/\/\/\/\/
science+computing ag                                    //  /     \\  \
[email protected]                            ^^^^^       ^^^^^
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.