1
0
mirror of https://github.com/cc65/cc65.git synced 2024-10-31 20:06:11 +00:00
Commit Graph

4536 Commits

Author SHA1 Message Date
uz
4786caf496 For modules, the ZP memory area must be written to the output file. This is
required by the logic in the linker.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4854 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-13 10:20:28 +00:00
uz
c797be4767 Add an additional file = "" to memory areas that contain only bss or zp type
segments and aren't written to the output file. Before that, the "not going to
output file" was implicit because of the bss type of the segments contained.
The new attribute makes this explicit.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4853 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-12 19:59:02 +00:00
uz
de14990fbb Define the __XX_START__ symbol for a memory area earlier, so it may be used in
the expression for the size of the same area.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4852 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-12 18:01:31 +00:00
uz
5e8252fa36 Reworked and improved the SYMBOLS section. The old syntax (using symbol =
value) is now gone, attributes are used instead. The SYMBOLS section does now
support imports, so the linker config can be used to force symbols (and
therefore module) imports. Evaluation of start address and size for memory
areas has been delayed even further, so it is now possible to use the values
from one memory area in the definition of the next one.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4851 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-12 14:17:35 +00:00
uz
a0a0347ecc Make the Name and Col fields unsigned instead of short.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4850 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-12 14:14:27 +00:00
uz
c59eeb3110 make.sgml has been renamed to using-make.sgml.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4849 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-11 07:06:41 +00:00
ol.sc
9c341fbccb Avoid name conflict with 'make.info'.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4848 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-10 21:38:07 +00:00
uz
7c1094c086 Keep the config file position in a FilePos structure.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4847 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-10 19:52:40 +00:00
uz
c695829813 Added a static initializer for struct FilePos.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4846 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-10 19:16:29 +00:00
uz
3f24c88355 SegNum has been renamed to SecNum.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4845 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-10 10:22:55 +00:00
uz
7bd19b737a One more place where OutputNameUsed must be flagged.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4844 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-09 22:07:45 +00:00
uz
fa1b5047dd Fixed order of options in call to ld65, which became important after the
latest changes.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4843 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-09 21:33:14 +00:00
uz
a2b7ef2b08 Merge CfgProcess and CfgAssignSegments because both do some sort of
postprocessing. Print a warning if %O was used in the config file and the
output file name is changed later using -o.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4842 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-09 21:01:27 +00:00
uz
c9b9069208 Better handling of imports in the ExprNode structure.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4841 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-09 20:34:08 +00:00
uz
da792b3fd0 Separate processing the linker config file into two phases: The config file is
read when the -t or -C switch is encountered and parts of it are processed.
The remaining parts are processed when all object files and libraries have
been read. To make this work, the expression evaluation in cfgexpr has been
rewritten to generate true expression trees. This means that expressions in
the linker config may use exports from the object files. 

Separation of config file processing is the base for several enhancements, for
example forced imports by linker config.

This code needs more work and is only very, very, very roughly tested.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4840 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-08 21:52:24 +00:00
uz
6c0a9c0438 Patch to correct the linkorder in the make files to make the --as-needed
ldflag work. By Mario Fetka.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4838 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-07 11:34:51 +00:00
uz
f1ce44edfe Fixed register info for several runtime functions. Info for the Y register was
wrong, so the optimizer assumed it wouldn't change across a call.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4836 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-11-02 18:05:19 +00:00
uz
60e5c885e8 Ignore some automatically generated files.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4835 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-30 20:13:26 +00:00
cpg
f0d0e4e543 really use default drive
git-svn-id: svn://svn.cc65.org/cc65/trunk@4834 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-29 19:53:45 +00:00
cpg
3386876fd3 __defdev is not dependent on DYNAMIC_DD
git-svn-id: svn://svn.cc65.org/cc65/trunk@4833 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-29 19:52:31 +00:00
cpg
50becf541b fix for files with no extension
git-svn-id: svn://svn.cc65.org/cc65/trunk@4832 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-29 19:25:01 +00:00
cpg
c345e8fc46 add Atari version
git-svn-id: svn://svn.cc65.org/cc65/trunk@4831 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-28 21:13:52 +00:00
cpg
5f006333bf add posixdirent.s by Stefan Haubenthal
git-svn-id: svn://svn.cc65.org/cc65/trunk@4830 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-28 21:03:05 +00:00
cpg
03ed1b3a6a some fixes
git-svn-id: svn://svn.cc65.org/cc65/trunk@4829 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-28 21:02:09 +00:00
cpg
1aeb5651f5 initial version by Stefan A. Haubenthal
git-svn-id: svn://svn.cc65.org/cc65/trunk@4828 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-28 20:55:18 +00:00
uz
ef5f3970e5 Added missing drivers.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4827 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-10 13:43:41 +00:00
ol.sc
e14435685f Added CH_ENTER define.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4826 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 21:34:49 +00:00
ol.sc
8c0c1e1ed9 According to a recent discussion CH_ENTER should generally *not* be defined based on '\n'.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4825 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 21:20:25 +00:00
uz
d08ff2b6df Fix parsing of push/pop so that #pragma warn works without.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4824 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 19:43:18 +00:00
uz
e048d2aeba Make the warning "statement has no effect" switchable.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4823 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 19:32:11 +00:00
ol.sc
d1f5b74f01 Now that we reduce the size of the RAM memory area by the stacksize in the linker configuration we need to add the stacksize to end of the RAM area when setting the initial stack pointer in the startup code.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4822 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 10:37:20 +00:00
ol.sc
eef8ecc74d User linker generated symbols for stack placement (like most other targets) instead of a hardcoded constant in order to allow control of stack placement via linker configuration.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4821 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 10:32:26 +00:00
ol.sc
aaf90c1252 Exclude (small) stack from RAM memory area (like on most other targets) to make explicit that the linker may not use all RAM. If the cc65 parameter stack isn't used at all the __STACKSIZE__ symbol may be overridden on the linker command line with -D __STACKSIZE__=0.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4820 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-10-02 10:20:00 +00:00
uz
172d33e584 Fixed problem with last change: Static declaration do also set the SC_EXTERN
flag (have to check why).


git-svn-id: svn://svn.cc65.org/cc65/trunk@4818 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-24 07:28:08 +00:00
uz
5aff0764a1 Allow initialization of variables declared with "extern".
git-svn-id: svn://svn.cc65.org/cc65/trunk@4816 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-23 18:18:53 +00:00
uz
1708ec318b Updated GEOS TGI driver by Maciej Witkowiak.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4815 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 21:14:30 +00:00
uz
674289e471 use ReadVar to read the type. This doesn't make a difference for now but will
come handy later. Add output for all of the symbol flags from symdefs.h.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4814 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 21:04:28 +00:00
uz
017bdf970a Include information about the type of the symbol in the flags written to the
object file.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4813 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 20:54:02 +00:00
uz
112ae0e3db Renamed the defines in symdefs.h to something more meaningful. They were named
EXP_xxx for historic reasons, but SYM_ does make much more sense now.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4812 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 20:47:27 +00:00
uz
d62af9de80 Debug symbolid for each symbol that goes into the debug symbol output.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4811 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 20:11:27 +00:00
uz
b2b2a05a46 SF_INDEXED is no longer needed.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4810 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 20:02:30 +00:00
uz
c921c409e8 Rename symbol index => import id because that's what it really is.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4809 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 20:01:54 +00:00
uz
e55b19fa8b Maintain some additional information for scopes. Write a dummy scope section
into the object file.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4808 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-17 16:58:41 +00:00
uz
41c119deca Bumped the year in the copyright notice. It hasn't changed for five years:-)
git-svn-id: svn://svn.cc65.org/cc65/trunk@4807 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-11 19:43:48 +00:00
uz
1a4a02821e New function cc65_symbol_inrange. Fixed an error in cc65_symbol_byname.
Restructured the dbgtest.c source.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4806 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-11 19:31:30 +00:00
uz
d627b1ac83 First support for symbols - mostly untested.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4805 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-09 22:05:44 +00:00
uz
03d3868d45 Start adding (limited) support for symbols.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4804 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-09 21:29:15 +00:00
uz
7e72e7d46b Change output for symbols in the debug info file to match that of the other
lines. The name is now preceeded by "name=".


git-svn-id: svn://svn.cc65.org/cc65/trunk@4803 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-09 21:28:47 +00:00
uz
8f03c4e9cf Move the collection containing all line infos into the DbgInfo struct and keep
it there. It will be used to search for line info by address in some future
version, which is faster than searching through all the source files in a
linear fashion.


git-svn-id: svn://svn.cc65.org/cc65/trunk@4802 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-09 20:54:12 +00:00
uz
5625977188 Add 'extern "C"' so the module may be used from C++ sources.
git-svn-id: svn://svn.cc65.org/cc65/trunk@4801 b7a2c559-68d2-44c3-8de9-860c34a00d81
2010-08-09 15:55:49 +00:00