Renamed common-post-process to xa-pre-process.

This commit is contained in:
Russell-S-Harper 2018-08-07 07:03:21 -04:00
parent b1b9970b0d
commit b96f42daaa
9 changed files with 18 additions and 17 deletions

View File

@ -1,5 +1,5 @@
all: all:
cd common-post-process ; make ; cd .. cd xa-pre-process ; make ; cd ..
cd common ; make ; cd .. cd common ; make ; cd ..
cd emulator ; make ; cd .. cd emulator ; make ; cd ..
@ -7,6 +7,6 @@ run:
./emulator/emulator < common/system.obj ./emulator/emulator < common/system.obj
clean: clean:
cd common-post-process ; make clean ; cd .. cd xa-pre-process ; make clean ; cd ..
cd common ; make clean ; cd .. cd common ; make clean ; cd ..
cd emulator ; make clean ; cd .. cd emulator ; make clean ; cd ..

View File

@ -1,4 +1,5 @@
# COMMON # COMMON
Advances some ideas using Steve Wozniak's SWEET16 interpreted byte-code language as inspiration. While the goal of SWEET16 was brevity, the goal of COMMON is functionality. The intent is to make a platform suitable for many commercial, scientific, and engineering applications. Advances some ideas using Steve Wozniak's SWEET16 interpreted byte-code language as inspiration. While the goal of SWEET16 was brevity, the goal of COMMON is functionality. The intent is to make a platform suitable for many commercial, scientific, and engineering applications.
For example: For example:
@ -33,11 +34,11 @@ The meat of the project:
Auxiliary: Auxiliary:
* `emulator/*`: 6502 emulator (borrowed Mike Chambers' Fake6502 CPU emulator v1.1 ©2011) * `emulator/*`: 6502 emulator (borrowed Mike Chambers' Fake6502 CPU emulator v1.1 ©2011)
* `common-post-process/*`: this utility converts 32-bit fixed decimal quantities so that `xa` can use them * `xa-pre-process/*`: utility `xapp` to convert 32-bit fixed decimal quantities so that `xa` can use them
Right now, for testing purposes, the code builds everything into one file `system.obj` and runs the code in the last block loaded, in this case, the code corresponding to `page6.src`. Eventually will support decoupling of system and application files. Right now, for testing purposes, the code builds everything into one file `system.obj` and runs the code in the last block loaded, in this case, the code corresponding to `page6.src`. Eventually will support decoupling of system and application files.
*To build and run:* To build and run:
make make
make run make run

View File

@ -1,4 +1,4 @@
POPR=../common-post-process/common-post-process XAPP=../xa-pre-process/xapp
system.obj: common.obj page6.obj system.obj: common.obj page6.obj
cat common.obj page6.obj > system.obj cat common.obj page6.obj > system.obj
@ -7,7 +7,7 @@ common.obj: rom.h common.h common.asm
xa -M common.asm -l common.lbl -o common.obj xa -M common.asm -l common.lbl -o common.obj
page6.obj: rom.h macros.h page6.src page6.obj: rom.h macros.h page6.src
cpp -P page6.src | $(POPR) > page6.asm cpp -P page6.src | $(XAPP) > page6.asm
xa -M page6.asm -l page6.lbl -o page6.obj xa -M page6.asm -l page6.lbl -o page6.obj
clean: clean:

View File

@ -1,4 +1,4 @@
TGT=common-post-process TGT=xapp
$(TGT): main.c $(TGT).h $(TGT).re $(TGT).l $(TGT).y $(TGT): main.c $(TGT).h $(TGT).re $(TGT).l $(TGT).y
re2c -is $(TGT).re -o $(TGT).c re2c -is $(TGT).re -o $(TGT).c

View File

@ -2,8 +2,8 @@
#include <limits.h> #include <limits.h>
#include <string.h> #include <string.h>
#include "common-post-process.h" #include "xapp.h"
#include "common-post-process.yy.h" #include "xapp.yy.h"
long long result; long long result;

View File

@ -1,5 +1,5 @@
#ifndef __COMMON_POST_PROCESS_H #ifndef __XAPP_H
#define __COMMON_POST_PROCESS_H #define __XAPP_H
/* How many bits for ... */ /* How many bits for ... */
@ -68,4 +68,4 @@ int tokenizeInput(const char *cursor, TOKEN *tokens);
long long parseCommon(const char *input); long long parseCommon(const char *input);
long long shiftCommon(long long base, long long amount); long long shiftCommon(long long base, long long amount);
#endif /* __COMMON_POST_PROCESS_H */ #endif /* __XAPP_H */

View File

@ -3,7 +3,7 @@
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>
#include "common-post-process.tab.h" #include "xapp.tab.h"
%} %}

View File

@ -1,7 +1,7 @@
#include <stdio.h> #include <stdio.h>
#include <string.h> #include <string.h>
#include "common-post-process.h" #include "xapp.h"
static int copyToken(TOKEN *tokens, int index, TOKEN_TYPE type, const char *text, int length); static int copyToken(TOKEN *tokens, int index, TOKEN_TYPE type, const char *text, int length);

View File

@ -1,7 +1,7 @@
%error-verbose %error-verbose
%code requires { %code requires {
#include "common-post-process.h" #include "xapp.h"
} }
%{ %{
@ -10,8 +10,8 @@
#include <limits.h> #include <limits.h>
#include <math.h> #include <math.h>
#include "common-post-process.h" #include "xapp.h"
#include "common-post-process.yy.h" #include "xapp.yy.h"
%} %}
%union { %union {