From: nhmall Date: Fri, 9 Oct 2020 12:52:46 +0000 (-0400) Subject: cross-compile fix-up X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=de80dd2437abcbf3bd8c890e8acf4ed49bf23494;p=nethack cross-compile fix-up --- diff --git a/sys/unix/Makefile.src b/sys/unix/Makefile.src index 2e4be5114..51b7e06c8 100644 --- a/sys/unix/Makefile.src +++ b/sys/unix/Makefile.src @@ -572,7 +572,8 @@ HACKINCL = align.h artifact.h artilist.h attrib.h botl.h \ HSOURCES = $(HACKINCL) date.h onames.h pm.h vis_tab.h dgn_file.h # the following .o's _must_ be made before any others (for makedefs) -HOSTOBJ = monst.o objects.o alloc.o drawing.o +FIRSTOBJ = monst.o objects.o +HOSTOBJ = $(FIRSTOBJ) alloc.o drawing.o HOBJ = $(TARGETPFX)allmain.o $(TARGETPFX)alloc.o \ $(TARGETPFX)apply.o $(TARGETPFX)artifact.o $(TARGETPFX)attrib.o \ diff --git a/util/makedefs.c b/util/makedefs.c index 24c45d676..f8636c893 100644 --- a/util/makedefs.c +++ b/util/makedefs.c @@ -1296,7 +1296,9 @@ do_date() Fprintf(ofp, "#define NETHACK_%sGIT_BRANCH \"%s\"\n", xpref, gitbranch); } +#if !defined(CROSSCOMPILE) || !defined(CROSSCOMPILE_TARGET) Fprintf(ofp, "#endif /* !CROSSCOMPILE || !CROSSCOMPILE_TARGET */\n"); +#endif Fprintf(ofp, "\n"); #ifdef AMIGA {