From 2bf9cd2ee14050db34a03829cf8623d6a6034b77 Mon Sep 17 00:00:00 2001
From: "ol.sc"
Date: Sat, 4 Feb 2012 13:47:31 +0000
Subject: [PATCH] Moved the first couple of files from 'geos-cbm' to
'geos-common' which are believed to work as-is on Apple GEOS too.
git-svn-id: svn://svn.cc65.org/cc65/trunk@5435 b7a2c559-68d2-44c3-8de9-860c34a00d81
---
libsrc/Makefile | 3 +-
libsrc/geos-cbm/Makefile | 1 -
libsrc/geos-common/Makefile | 51 +++++++++++++++++++
.../{geos-cbm => geos-common}/dlgbox/Makefile | 0
.../dlgbox/dbget2lines.s | 0
.../dlgbox/dlgboxfileselect.s | 0
.../dlgbox/dlgboxgetstring.s | 0
.../dlgbox/dlgboxok.s | 0
.../dlgbox/dlgboxokcancel.s | 0
.../dlgbox/dlgboxyesno.s | 0
.../dlgbox/dodlgbox.s | 0
.../dlgbox/messagebox.c | 0
.../dlgbox/rstrfrmdialogue.s | 0
13 files changed, 53 insertions(+), 2 deletions(-)
create mode 100644 libsrc/geos-common/Makefile
rename libsrc/{geos-cbm => geos-common}/dlgbox/Makefile (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/dbget2lines.s (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/dlgboxfileselect.s (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/dlgboxgetstring.s (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/dlgboxok.s (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/dlgboxokcancel.s (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/dlgboxyesno.s (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/dodlgbox.s (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/messagebox.c (100%)
rename libsrc/{geos-cbm => geos-common}/dlgbox/rstrfrmdialogue.s (100%)
diff --git a/libsrc/Makefile b/libsrc/Makefile
index a3dbc684d..79f720eec 100644
--- a/libsrc/Makefile
+++ b/libsrc/Makefile
@@ -16,6 +16,7 @@ LD = ../../src/ld65/ld65
# List of shared directories
SHAREDDIRS = cbm \
common \
+ geos-common \
conio \
dbg \
em \
@@ -250,7 +251,7 @@ cbm610lib:
.PHONY: geos-cbmlib
geos-cbmlib:
- for i in runtime geos-cbm common conio em joystick tgi zlib; do \
+ for i in runtime geos-cbm geos-common common conio em joystick tgi zlib; do \
$(MAKE) SYS=geos-cbm -C $$i || exit 1; \
$(AR) a geos-cbm.lib $$i/*.o || exit 1; \
done
diff --git a/libsrc/geos-cbm/Makefile b/libsrc/geos-cbm/Makefile
index 5218045a1..787b55cf7 100644
--- a/libsrc/geos-cbm/Makefile
+++ b/libsrc/geos-cbm/Makefile
@@ -48,7 +48,6 @@ DIRS = common \
conio \
devel \
disk \
- dlgbox \
file \
graph \
menuicon \
diff --git a/libsrc/geos-common/Makefile b/libsrc/geos-common/Makefile
new file mode 100644
index 000000000..e884c1bd5
--- /dev/null
+++ b/libsrc/geos-common/Makefile
@@ -0,0 +1,51 @@
+#
+# makefile for CC65 runtime library
+#
+
+.SUFFIXES: .o .s .c
+
+#--------------------------------------------------------------------------
+# Programs and flags
+
+SYS = geos-cbm
+
+AS = ../../src/ca65/ca65
+CC = ../../src/cc65/cc65
+LD = ../../src/ld65/ld65
+
+AFLAGS = -t $(SYS) --forget-inc-paths -I../$(SYS) -I../../asminc
+CFLAGS = -Osir -g -T -t $(SYS) --forget-inc-paths -I . -I ../../include
+
+#--------------------------------------------------------------------------
+# Rules
+
+%.o: %.c
+ @$(CC) -o $(notdir $(*).s) $(CFLAGS) $<
+ @$(AS) -o $@ $(AFLAGS) $(*).s
+
+%.o: %.s
+ @$(AS) -g -o $@ $(AFLAGS) $<
+
+#--------------------------------------------------------------------------
+# Directories
+
+DIRS = dlgbox
+
+#--------------------------------------------------------------------------
+# Directives
+
+include $(addsuffix /Makefile, $(DIRS))
+vpath %.c $(DIRS)
+vpath %.s $(DIRS)
+
+#--------------------------------------------------------------------------
+# Targets
+
+.PHONY: all clean zap
+
+all: $(C_OBJS) $(S_OBJS)
+
+clean:
+ @$(RM) $(C_OBJS:.o=.s) $(C_OBJS) $(S_OBJS)
+
+zap: clean
diff --git a/libsrc/geos-cbm/dlgbox/Makefile b/libsrc/geos-common/dlgbox/Makefile
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/Makefile
rename to libsrc/geos-common/dlgbox/Makefile
diff --git a/libsrc/geos-cbm/dlgbox/dbget2lines.s b/libsrc/geos-common/dlgbox/dbget2lines.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/dbget2lines.s
rename to libsrc/geos-common/dlgbox/dbget2lines.s
diff --git a/libsrc/geos-cbm/dlgbox/dlgboxfileselect.s b/libsrc/geos-common/dlgbox/dlgboxfileselect.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/dlgboxfileselect.s
rename to libsrc/geos-common/dlgbox/dlgboxfileselect.s
diff --git a/libsrc/geos-cbm/dlgbox/dlgboxgetstring.s b/libsrc/geos-common/dlgbox/dlgboxgetstring.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/dlgboxgetstring.s
rename to libsrc/geos-common/dlgbox/dlgboxgetstring.s
diff --git a/libsrc/geos-cbm/dlgbox/dlgboxok.s b/libsrc/geos-common/dlgbox/dlgboxok.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/dlgboxok.s
rename to libsrc/geos-common/dlgbox/dlgboxok.s
diff --git a/libsrc/geos-cbm/dlgbox/dlgboxokcancel.s b/libsrc/geos-common/dlgbox/dlgboxokcancel.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/dlgboxokcancel.s
rename to libsrc/geos-common/dlgbox/dlgboxokcancel.s
diff --git a/libsrc/geos-cbm/dlgbox/dlgboxyesno.s b/libsrc/geos-common/dlgbox/dlgboxyesno.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/dlgboxyesno.s
rename to libsrc/geos-common/dlgbox/dlgboxyesno.s
diff --git a/libsrc/geos-cbm/dlgbox/dodlgbox.s b/libsrc/geos-common/dlgbox/dodlgbox.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/dodlgbox.s
rename to libsrc/geos-common/dlgbox/dodlgbox.s
diff --git a/libsrc/geos-cbm/dlgbox/messagebox.c b/libsrc/geos-common/dlgbox/messagebox.c
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/messagebox.c
rename to libsrc/geos-common/dlgbox/messagebox.c
diff --git a/libsrc/geos-cbm/dlgbox/rstrfrmdialogue.s b/libsrc/geos-common/dlgbox/rstrfrmdialogue.s
similarity index 100%
rename from libsrc/geos-cbm/dlgbox/rstrfrmdialogue.s
rename to libsrc/geos-common/dlgbox/rstrfrmdialogue.s
--
2.39.5