On Tue, 6 Mar 2001, Andris Pavenis wrote:
It was already discussed that we cannot distribute Borland BGI fonts with GRX. Anyway my script to get them linked into library (if one have them) was added in 2.3.4. Script was really for DJGPP only. Here is patch which adds related support to makefiles. However I moved directory where to put .chr files to src/chr. It's easy to move it back to top directory if needed
Sorry for errors in patch
+$(subst .o,.c,$(CHR_1)) : ../bin/bin2c
- ../bin/bin2c $*.chr _$(subst .chr,.o,$(shell basename $*))_font $*.c
^^^^^^^^^^^^^^^^ I only noticed this stupid, wrong but harmless $(subst ...) when saw message in my inbox. I didn't notice it immediatelly as substitution is never done and as result all worked Ok. Below is fixed patch
Andris
--- grx-2.3.4/src/stdobjs.mak~5 Mon Mar 5 13:12:12 2001 +++ grx-2.3.4/src/stdobjs.mak Mon Mar 5 13:13:10 2001 @@ -324,3 +324,4 @@ $(OP)../addons/print/prndata$(OX) \ $(OP)bgi/bgiprint$(OX)
+CHR_1 = $(subst .chr,.o,$(wildcard chr/*.chr)) --- grx-2.3.4/src/makefile.x11~5 Mon Mar 5 13:20:34 2001 +++ grx-2.3.4/src/makefile.x11 Tue Mar 6 10:56:03 2001 @@ -38,7 +38,7 @@ $(STD_9) $(STD_10) $(STD_11) $(STD_12)\
BGI_O= $(BGI_1) $(BGI_2) $(BGI_3) $(BGI_4) \ - $(BGI_5) $(BGI_6) + $(BGI_5) $(BGI_6) $(CHR_1)
ADDON_O= ifdef DEBUG @@ -124,5 +124,11 @@
$(O) : %.o : %.c $(CC) -c $(CCOPT) -D__XWIN__ $(INCDIR) $*.c -o $*.o + +$(subst .o,.c,$(CHR_1)) : ../bin/bin2c + ../bin/bin2c $*.chr _$(shell basename $*)_font $*.c + +../bin/bin2c: + $(CC) -O2 bgi/bin2c.c -o ../bin/bin2c
include depend.x11 --- grx-2.3.4/src/makefile.w32~5 Fri Feb 2 18:54:28 2001 +++ grx-2.3.4/src/makefile.w32 Tue Mar 6 10:56:17 2001 @@ -29,7 +29,7 @@ STD_Oa= $(STD_1) $(STD_2) $(STD_3) $(STD_4) $(STD_5) $(STD_6) STD_Ob= $(STD_7) $(STD_8) $(STD_9) $(STD_10) $(STD_11) $(STD_12) BGI_Oa= $(BGI_1) $(BGI_2) $(BGI_3) -BGI_Ob= $(BGI_4) $(BGI_5) $(BGI_6) +BGI_Ob= $(BGI_4) $(BGI_5) $(BGI_6) $(CHR_1)
ADDON_O= ifdef DEBUG @@ -127,5 +127,11 @@
.c.o: $(CC) -c $(CCOPT) $(INCDIR) $*.c -o $*.o + +$(subst .o,.c,$(CHR_1)) : ../bin/bin2c.exe + ../bin/bin2c.exe $*.chr _$(shell basename $*)_font $*.c + +../bin/bin2c.exe: + $(CC) -O2 bgi/bin2c.c -o ../bin/bin2c.exe
#include depend.w32 --- grx-2.3.4/src/makefile.lnx~5 Sat Feb 3 01:47:38 2001 +++ grx-2.3.4/src/makefile.lnx Tue Mar 6 10:56:27 2001 @@ -36,7 +36,7 @@ $(STD_9) $(STD_10) $(STD_11) $(STD_12)
BGI_O= $(BGI_1) $(BGI_2) $(BGI_3) $(BGI_4) \ - $(BGI_5) $(BGI_6) + $(BGI_5) $(BGI_6) $(CHR_1)
ADDON_O= ifdef DEBUG @@ -129,6 +129,12 @@
.c.o: $(CC) -c $(CCOPT) $(INCDIR) $*.c -o $*.o + +$(subst .o,.c,$(CHR_1)) : ../bin/bin2c + ../bin/bin2c $*.chr _$(shell basename $*)_font $*.c + +../bin/bin2c: + $(CC) -O2 bgi/bin2c.c -o ../bin/bin2c
include depend.lnx
--- grx-2.3.4/src/makebase.dj~5 Sat Feb 3 01:29:30 2001 +++ grx-2.3.4/src/makebase.dj Tue Mar 6 10:56:42 2001 @@ -19,7 +19,7 @@ STD_Oa= $(STD_1) $(STD_2) $(STD_3) $(STD_4) $(STD_5) $(STD_6) STD_Ob= $(STD_7) $(STD_8) $(STD_9) $(STD_10) $(STD_11) $(STD_12) BGI_Oa= $(BGI_1) $(BGI_2) $(BGI_3) -BGI_Ob= $(BGI_4) $(BGI_5) $(BGI_6) +BGI_Ob= $(BGI_4) $(BGI_5) $(BGI_6) $(CHR_1)
ADDON_O= ifdef DEBUG @@ -163,5 +163,11 @@
.c.o: $(CC) -c $(CCOPT) $(INCDIR) $*.c -o $*.o + +$(subst .o,.c,$(CHR_1)) : ../bin/bin2c.exe + ../bin/bin2c.exe $*.chr _$(shell basename $*)_font $*.c + +../bin/bin2c.exe: + $(CC) -O2 bgi/bin2c.c -o ../bin/bin2c.exe
include depend.dj2