Comments (5)
zcc is going to be passing a mass of files not usually one at a time and quite often as a list of files in a single .lst file to avoid command line limitations. So I don't think there is any way to add a command line parameter sensibly.
Actually that's not right. I couldn't remember if zcc passes files at the .asm stage or the .o stage to z80asm for building a library but it is the .o stage. So that means zcc individually assembles each .asm file and it would be possible to pass the original filename as command line parameter to z80asm.
Right now that parameter would become the module name.
from z88dk.
z80asm MODULE directive does just that. It replaces the source file name by the name given as argument in the linked file. zcc just has to add "MODULE original_file" to every temporary file before assembling.
In my plan for z80asm2 the linked module will be named <source_file>_<module_directive_name>
from z88dk.
Will z80asm be okay with receiving two module directives?
If zcc inserts one in the front and the user has specified one which would appear second, will z80asm be able to use the last one declared?
In my plan for z80asm2 the linked module will be named <source_file>_<module_directive_name>
Yes this is what I was thinking about. In the future, it's the source_file name that zcc should be tweaking and not the module.
from z88dk.
If zcc inserts one in the front and the user has specified one which would appear second, will z80asm be able to use the last one declared?
Today there's an error message on the second module directive. But this can be easily changed, as the module name is not used except for the name in the .o file.
from z88dk.
zcc now inserts a module directive at the start of every file at the .asm stage.
- We've moved away from shell invokes of copy and cp to shell invokes of type and cat for appending
- CRTs must have module directives at the top since they are processed outside zcc's loop
To form the module string, the basename is taken and non-alnum chars are replaced with '_'. So a file "clisp.c" will get module name "clisp_c" and a file "clisp.asm" will get module name "clisp_asm".
Tested on windows and this change fixes the zcc lib issue as well as makes the map file clearer.
from z88dk.
Related Issues (20)
- (z80asm) new feature: add m4 macros to z80asm
- (classic) Create 6x8 fonts labels
- z80asm equate definition that is similar to asm z80 opcode instruction causes assembler error message HOT 3
- z88dk build script fails with error message on macOS Apple Silicon "ld: warning: ignoring file '/usr/local/Cellar/gmp/6.2.1_1/lib/libgmp.10.dylib': found architecture 'x86_64', required architecture 'arm64'" HOT 7
- z80asm using $ from incorrect section when computing using defc constant HOT 2
- /libsrc/_DEVELOPMENT/Makefile incorrectly fixed to build libraries HOT 1
- zcc with sdcc fails frequently on msys2
- (help wanted-macosx) m4 error in macosx HOT 3
- z88dk-win32-2.3.zip is flagged by multiple anti-virus systems HOT 7
- make compatible with casio 8080 CPU HOT 4
- (ci) msys2 build failing HOT 5
- (sccz80) Compilation issue
- Request: Please update the AgonLight wiki re: ADL=1 (24 bit mode)
- How to have random #asm as a beginning of a banked file? HOT 2
- def.asm.m4 missing from lib/target/zx/def HOT 1
- Windows zcc binary doesn't work on wine HOT 6
- CMake: Detecting C compiler ABI info - failed
- Contributing with fixes in header files HOT 3
- typo error in src/ticks/disassembler_main.c
- Linux: error compiling test program HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from z88dk.