--- /dev/null
+#Generic rules and options for building with Borland C++
+
+OFLAGS = -6 -O2 -g0 -w-proto
+
+.c.obj:
+ BCC32 -c $(OFLAGS) $(CFLAGS) $(CPPFLAGS) $<
PRJDIR = ../..
-CPPFLAGS = -I. -I$(PRJDIR)
-CFLAGS = -6 -O -g0
+!include ..\..\Bcc.inc
+
+CFLAGS = -I. -I$(PRJDIR)
M_OR_MM = -MM
LDFLAGS =
-.c.obj:
- BCC32 -c $(CFLAGS) $(CPPFLAGS) $<
-
ASOBJECTS = asmain.obj aslex.obj assym.obj assubr.obj asnoice.obj \
asexpr.obj asdata.obj aslist.obj asout.obj asstore.obj \
i51ext.obj i51pst.obj i51mch.obj i51adr.obj
&flush_pending_data;
$pendingDataStart = 0;
$nextOffset = 0;
- print;
+ print;
}
else
{
--- /dev/null
+Building SDCC with Borland C++ under Windows
+
+1: Build SDCC under Cygwin as documented in cygwininst.txt (this is
+necessary in order to run all the necessary configuration steps).
+
+2: If necessary, modify support\gc\BCC_Makefile to point to your Borland
+C++ installation.
+
+3: From the sdcc directory, run the command "make -f Makefile.bcc". This
+should regenerate all the .exe files in the bin directory except for
+sdcdb.exe (which currently doesn't build under Borland C++).
+
+4: If you modify any source files and need to rebuild, be aware that the
+dependancies may not be correctly calculated. The safest option is to
+delete all .obj files and run the build again. From a Cygwin BASH
+prompt, this can easily be done with the commmand:
+
+ 'find . -name "*.obj" -print | xargs rm'
+
+from the sdcc directory.
$(TARGET): $(OBJECTS) $(PORT_LIBS)
bcc32 -e$(TARGET) $(OBJECTS) $(PORT_LIBS) $(LIBGC)
-CFLAGS = -6 -O -g0 -I. -I.. -I..\support
-
-.c.obj:
- BCC32 -c $(CFLAGS) $(CPPFLAGS) $<
+!include ..\Bcc.inc
+CFLAGS = -I. -I.. -I..\support
SDCCy.h: SDCCy.c
OBJ = gen.obj ralloc.obj main.obj
LIB = port.lib
-CFLAGS = -6 -O -g0 -I.. -I. -I..\.. -I..\..\support
-
-.c.obj:
- BCC32 -c $(CFLAGS) $(CPPFLAGS) $<
+!include ..\..\Bcc.inc
+CFLAGS = -I.. -I. -I..\.. -I..\..\support
all: $(LIB)
OBJ = gen.obj ralloc.obj main.obj gbz80.obj
LIB = port.lib
-CFLAGS = -6 -O -g0 -I.. -I. -I..\.. -I..\..\support
-
-.c.obj:
- BCC32 -c $(CFLAGS) $(CPPFLAGS) $<
+!include ..\..\Bcc.inc
+CFLAGS = -I.. -I. -I..\.. -I..\..\support
all: $(LIB)
infodir = ${prefix}/info
STD_INC = @sdcc_include_dir@
-#CPPFLAGS = -I. -I$(PRJDIR) -D_FORASXXXX_
-#CFLAGS = -ggdb -O2 -pipe
-CFLAGS = -6 -O -g0 -I. -I$(PRJDIR) -D_FORASXXXX_
+!include ..\..\bcc.inc
+CFLAGS = -I. -I$(PRJDIR) -D_FORASXXXX_
M_OR_MM = -MM
LDFLAGS =
!include Makefile.dep
-# My rules
-# --------
-.c.obj:
- BCC32 -c $(CFLAGS) $(CPPFLAGS) $<
-
# End of cpp/Makefile