Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,12 @@
# Set the TARGETS and PROGRAM values as required.
# See makefiles/build.mk for details on directory structure for src files and how to add custom extensions to the build.

TARGETS = adam apple2 apple2enh atari c64 coco msdos
# Require GNU Make 4.0 or later for $(file ...) function
ifeq ($(filter 4.%,$(MAKE_VERSION)),)
$(error This Makefile requires GNU Make 4.0 or later. You are using $(MAKE_VERSION). Please use 'gmake' instead of 'make' on macOS.)
endif

TARGETS = apple2 apple2enh atari c64 coco
PROGRAM := fujinet.lib

SUB_TASKS := clean disk test release unit-test
Expand Down
2 changes: 1 addition & 1 deletion apple2/apple2-6502/bus/sp_init.s
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@

.include "macros.inc"
.include "zp.inc"
.macpack cpu
.include "cpu.inc"

; Find the SmartPort device that has a FujiNet NETWORK adapter on it.
; Really we should search for the FUJI device on it, but historically that was
Expand Down
7 changes: 7 additions & 0 deletions common/inc/cpu.inc
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
; Guard to prevent multiple inclusion of cpu macros
; Check if CPU_ISET_NONE is already defined (from cpu.mac)
.ifndef CPU_ISET_NONE

.macpack cpu

.endif
31 changes: 18 additions & 13 deletions fujinet-fuji.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,20 +6,25 @@
// In general, bools return the "success" status, so true is good, false is bad.

#ifdef _CMOC_VERSION_
#include <cmoc.h>
#include <coco.h>

#ifndef bool
#define bool _FNBool
typedef unsigned char _FNBool;
#endif /* bool */

#define true 1
#define false 0
// CMOC-specific types and definitions
#ifndef bool
#define bool unsigned char
#endif /* bool */

#define true 1
#define false 0

// Define standard integer types for CMOC
#define uint8_t unsigned char
#define int8_t signed char
#define uint16_t unsigned short
#define int16_t signed short
#define uint32_t unsigned long
#define int32_t signed long
#else
#include <stddef.h>
#include <stdbool.h>
#include <stdint.h>
#include <stddef.h>
#include <stdbool.h>
#include <stdint.h>
#endif /* _CMOC_VERSION_ */

#ifdef __CBM__
Expand Down
2 changes: 1 addition & 1 deletion makefiles/compiler-cmoc.mk
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
CC := cmoc
AR := lwar
CFLAGS := -O2
CFLAGS := -O2 -D_CMOC_VERSION_=1

INCC_ARG := -I
INCS_ARG := -I