Import Cardgame 0.1.15 upstream source snapshot
Original author: Pierre Sarrazin. Public-domain library and demo. Source: http://sarrazip.com/dev/cardgame-0.1.15.tar.gz Archive SHA-256: ca706dddd96fec63b829f8958c2e47485b0e1166129d45fda0b6369404c1bb54
This commit is contained in:
commit
d3a54e24ee
39 files changed
+2603
No files matched your search
@@ -0,0 +1,130 @@
|
||||
# By Pierre Sarrazin <http://sarrazip.com/>
|
||||
# This file is in the public domain.
|
||||
|
||||
PACKAGE = cardgame
|
||||
VERSION = 0.1.15
|
||||
TARGET = coco
|
||||
|
||||
ifneq "$(TARGET)" "os9"
|
||||
EXEEXT = .bin
|
||||
endif
|
||||
|
||||
LIBSRC = \
|
||||
$(PACKAGE).c \
|
||||
pmode4game.c \
|
||||
8-bit-wide-font.c \
|
||||
compiled-cards.c \
|
||||
initSound.c \
|
||||
beep.c \
|
||||
whiteNoise.c \
|
||||
OS9Timer.c \
|
||||
invertCharAtCursor.c \
|
||||
waitForKeyWithAnimatedCursor.c \
|
||||
moveCursorLeft.c \
|
||||
drawCharWithoutMovingCursor.c \
|
||||
readLineFromKeyboard.c \
|
||||
concat.c \
|
||||
enableInvertedColorText.c \
|
||||
setColorInversionMask.c \
|
||||
printCentered.c \
|
||||
setScreenBuffer.c \
|
||||
setScreenBuffer2.c \
|
||||
moveCursor.c \
|
||||
getCursor.c \
|
||||
hiResTextConsoleOutHook.c \
|
||||
drawChar.c \
|
||||
setTextAreaScrollCallback.c \
|
||||
getCurrentCharPos.c \
|
||||
pmode4game_vars.c \
|
||||
setInvertedColorsParameters.c \
|
||||
makeSpacesTransparent.c
|
||||
|
||||
LIBHEADERS = \
|
||||
$(PACKAGE).h \
|
||||
pmode4game.h \
|
||||
pmode4game_private.h \
|
||||
8-bit-wide-font.h \
|
||||
compiled-cards.h \
|
||||
OS9Timer.h
|
||||
|
||||
STATICLIB = lib$(PACKAGE).a
|
||||
|
||||
CARDGAMEDEMOSRC = $(PACKAGE)-demo.c
|
||||
CARDGAMEDEMOBIN = $(PACKAGE)$(EXEEXT)
|
||||
|
||||
BEEPDEMOSRC = beep-demo.c
|
||||
ifneq "$(TARGET)" "os9"
|
||||
BEEPDEMOBIN = beep$(EXEEXT)
|
||||
endif
|
||||
|
||||
OS9TIMERDEMOSRC = os9timer-demo.c
|
||||
ifeq "$(TARGET)" "os9"
|
||||
OS9TIMERDEMOBIN = os9timer
|
||||
endif
|
||||
|
||||
DISTFILES = README.md Makefile $(LIBHEADERS) $(LIBSRC) $(CARDGAMEDEMOSRC) $(BEEPDEMOSRC) $(OS9TIMERDEMOSRC)
|
||||
|
||||
ORG = #--org=2800
|
||||
INTERMEDIATE = #--intermediate
|
||||
NDEBUG = -DNDEBUG
|
||||
WARNINGS = -Wfor-condition-sizes
|
||||
WERROR = -Werror
|
||||
CFLAGS = --$(TARGET) $(WARNINGS) $(WERROR) $(NDEBUG) $(INTERMEDIATE)
|
||||
LDFLAGS = --$(TARGET) $(ORG) $(INTERMEDIATE)
|
||||
|
||||
CARDGAMEDEMOOBJ = $(CARDGAMEDEMOSRC:.c=.o)
|
||||
BEEPDEMOOBJ = $(BEEPDEMOSRC:.c=.o)
|
||||
OS9TIMERDEMOOBJ = $(OS9TIMERDEMOSRC:.c=.o)
|
||||
LIBOBJ = $(LIBSRC:.c=.o)
|
||||
|
||||
CMOC = cmoc
|
||||
LWAR = lwar
|
||||
TAR = tar
|
||||
|
||||
all: $(CARDGAMEDEMOBIN) $(BEEPDEMOBIN) $(OS9TIMERDEMOBIN)
|
||||
|
||||
$(CARDGAMEDEMOBIN): $(CARDGAMEDEMOOBJ) $(STATICLIB)
|
||||
$(CMOC) -o $(CARDGAMEDEMOBIN) $(LDFLAGS) $(CARDGAMEDEMOOBJ) -L. -l$(PACKAGE)
|
||||
|
||||
ifneq "$(TARGET)" "os9"
|
||||
$(BEEPDEMOBIN): $(BEEPDEMOOBJ) $(STATICLIB)
|
||||
$(CMOC) -o $(BEEPDEMOBIN) $(LDFLAGS) $(BEEPDEMOOBJ) -L. -l$(PACKAGE)
|
||||
endif
|
||||
|
||||
ifeq "$(TARGET)" "os9"
|
||||
$(OS9TIMERDEMOBIN): $(OS9TIMERDEMOOBJ) $(STATICLIB)
|
||||
$(CMOC) -o $(OS9TIMERDEMOBIN) $(LDFLAGS) $(OS9TIMERDEMOOBJ) -L. -l$(PACKAGE)
|
||||
endif
|
||||
|
||||
$(STATICLIB): $(LIBOBJ)
|
||||
$(LWAR) --create $(STATICLIB) $(LIBOBJ)
|
||||
|
||||
%.o: %.c
|
||||
$(CMOC) -c $(CFLAGS) -o $@ $<
|
||||
|
||||
clean:
|
||||
rm -f $(CARDGAMEDEMOBIN) $(CARDGAMEDEMOOBJ) $(BEEPDEMOBIN) $(BEEPDEMOOBJ) $(OS9TIMERDEMOBIN) $(OS9TIMERDEMOOBJ) $(STATICLIB) $(LIBOBJ)
|
||||
|
||||
.PHONY: dist
|
||||
dist:
|
||||
$(TAR) -czf $(PACKAGE)-$(VERSION).tar.gz --transform 's,^,$(PACKAGE)-$(VERSION)/,' $(DISTFILES)
|
||||
|
||||
distcheck: dist
|
||||
mkdir ,distcheck
|
||||
$(TAR) -C ,distcheck -xzf $(PACKAGE)-$(VERSION).tar.gz
|
||||
$(MAKE) -C ,distcheck/$(PACKAGE)-$(VERSION) all
|
||||
rm -fr ,distcheck
|
||||
@echo "SUCCESS: $(PACKAGE)-$(VERSION).tar.gz ready for distribution"
|
||||
|
||||
# Automatic prerequisite generation.
|
||||
%.d: %.c
|
||||
$(CMOC) --deps-only $(CFLAGS) $<
|
||||
|
||||
.PHONY: cleandeps
|
||||
cleandeps:
|
||||
rm -f $(CARDGAMEDEMOSRC:.c=.d) $(BEEPDEMOSRC:.c=.d) $(OS9TIMERDEMOSRC:.c=.d) $(LIBSRC:.c=.d)
|
||||
|
||||
include $(CARDGAMEDEMOSRC:.c=.d)
|
||||
include $(BEEPDEMOSRC:.c=.d)
|
||||
include $(OS9TIMERDEMOSRC:.c=.d)
|
||||
include $(LIBSRC:.c=.d)
|
||||
Reference in new issue
Block a user