The build system now accepts a single C file as a target and compiles that
file only. For example:
$ lua build_elua.lua board=ek-lm3s8962 src/main.c
Two other switches were added to the build sysem (both of which work only
with the single file target shown above):
"-E": preprocess file instead of compiling it
"-S": generate assembler source for the file instead of compiling it
Get rid of the "reserved" byte in the TString data type. Might actually
save more than one byte, depdending on the compiler structure alignment
rules (and the architecture). Tested with the Lua 5.1 test suite.
1. Respect the value of build_dir
2. Added romfs_dir (specify ROMFS directory location)
3. Added output_dir (specify the location of the final executable and
associated (bin, hex) files)
There is a new command in the shell ('mv' - move/rename files).
Also, the shell code was refactored into its own directory (src/shell).
The 'help' command in the shell was updated and supports 'help <command>'.
There is a new BUILD_ADVANCED_SHELL build time macro that enables the
advanced shell features (currently 'cp' with recursion (and other improvements),
'mv' and 'rm').
- For now only supported for MMCFS
- 'dir' function in shell augmented to show directories and
to traverse a path recursively if requested
- new command 'mkdir' in shell
Newer Newlib versions use different functions to implement integer-only versions
of printf/scanf. Our stubs were modified to take advantage of these changes and
keep the code size low in integer-only versions of eLua.
- AVR32 platform converted to use the new build system
- new section in configuration: 'build'. Used to set predefined
build parameters (such as allocator, target, boot mode...)
- LPC288x platform converted to the new build system
- changed generation for the 'extmem' attribute
- added combined attributes (validated against two or more possible types)
Fixed bug reported by Tim Van der Hulst:
-------------------------------------------------------------------------------
dofile('/mmc/test.lua') -- OK
require('test') -- Fail!!
-------------
/mmc
test.txt 5 bytes
gprs.lua 2910 bytes
util.lua 385 bytes
test.lua 385 bytes
Total on /mmc: 3685 bytes
-------------
Error: [string "xmodem"]:23: module 'test' not found:
no field package.preload['test']
no file '/mmc/test.lua;/mmc/test.lc;/rom/test.lua;/rom/test.lc'
no file '/mmc/test.lc;/rom/test.lua;/rom/test.lc'
no file '/rom/test.lua;/rom/test.lc'
no file '/rom/test.lc'
-------------------------------------------------------------------------------
The problem was actually in the way read-only strings were created. If a read-only
string creation call specified a size which was different than the actual (C) size
of the string, the string didn't get null-terminated, which in turn led to some
interesting errors (like the one above).
- more build configuration attributes (allocator, target)
- more sanity checks
- more color in the builder
- 'romfs' is now a separate builder target, not a function being called separately
- added mappings for the configurator attributes