Command line tools¶
This section describes the usage the commandline tools installed with ppci.
Take for example the stm32f4 blinky project. To build this project, run ppci-build.py in the project folder:
$ cd examples/blinky
$ ppci-build.py
This command is used to construct build files.
Or specify the buildfile a the command line:
$ ppci-build.py -f examples/blinky/build.xml
Instead of relying on a build system, the c3 compiler can also be activated stand alone.
$ ppci-c3c.py --machine arm examples/snake/game.c3
ppci-c3c.py¶
C3 compiler. Use this compiler to produce object files from c3 sources and c3 includes. C3 includes have the same format as c3 source files, but do not result in any code.
usage: ppci-c3c.py [-h] [–log log-level] [–report report-file] [–verbose] [–version] –machine {6500,arm,avr,msp430,thumb,x86_64} –output output-file [-i include] source [source ...]
-
source
¶
source file
-
-h
,
--help
¶
show this help message and exit
-
--log
<log-level>
¶ Log level (info,debug,warn)
-
--report
<report-file>
¶ Specify a file to write the compile report to
-
--verbose
,
-v
¶
Increase verbosity of the output
-
--version
,
-V
¶
Display version and exit
-
--machine
{6500,arm,avr,msp430,thumb,x86_64}
,
-m
{6500,arm,avr,msp430,thumb,x86_64}
¶ target machine
-
--output
<output-file>
,
-o
<output-file>
¶ output file
-
-i
<include>
,
--include
<include>
¶ include file
ppci-build.py¶
Build utility. Use this to execute build files.
usage: ppci-build.py [-h] [–log log-level] [–report report-file] [–verbose] [–version] [-f build-file] [target [target ...]]
-
target
¶
-
-h
,
--help
¶
show this help message and exit
-
--log
<log-level>
¶ Log level (info,debug,warn)
-
--report
<report-file>
¶ Specify a file to write the compile report to
-
--verbose
,
-v
¶
Increase verbosity of the output
-
--version
,
-V
¶
Display version and exit
-
-f
<build-file>
,
--buildfile
<build-file>
¶ use buildfile, otherwise build.xml is the default
ppci-asm.py¶
Assembler utility.
usage: ppci-asm.py [-h] [–log log-level] [–report report-file] [–verbose] [–version] –machine {6500,arm,avr,msp430,thumb,x86_64} –output output-file sourcefile
-
sourcefile
¶
the source file to assemble
-
-h
,
--help
¶
show this help message and exit
-
--log
<log-level>
¶ Log level (info,debug,warn)
-
--report
<report-file>
¶ Specify a file to write the compile report to
-
--verbose
,
-v
¶
Increase verbosity of the output
-
--version
,
-V
¶
Display version and exit
-
--machine
{6500,arm,avr,msp430,thumb,x86_64}
,
-m
{6500,arm,avr,msp430,thumb,x86_64}
¶ target machine
-
--output
<output-file>
,
-o
<output-file>
¶ output file
ppci-ld.py¶
Linker. Use the linker to combine several object files and a memory layout to produce another resulting object file with images.
usage: ppci-ld.py [-h] [–log log-level] [–report report-file] [–verbose] [–version] –machine {6500,arm,avr,msp430,thumb,x86_64} –output output-file –layout layout-file obj [obj ...]
-
obj
¶
the object to link
-
-h
,
--help
¶
show this help message and exit
-
--log
<log-level>
¶ Log level (info,debug,warn)
-
--report
<report-file>
¶ Specify a file to write the compile report to
-
--verbose
,
-v
¶
Increase verbosity of the output
-
--version
,
-V
¶
Display version and exit
-
--machine
{6500,arm,avr,msp430,thumb,x86_64}
,
-m
{6500,arm,avr,msp430,thumb,x86_64}
¶ target machine
-
--output
<output-file>
,
-o
<output-file>
¶ output file
-
--layout
<layout-file>
,
-L
<layout-file>
¶ memory layout
ppci-objcopy.py¶
Objcopy utility to manipulate object files.
usage: ppci-objcopy.py [-h] [–log log-level] [–report report-file] [–verbose] [–version] –segment SEGMENT [–output-format OUTPUT_FORMAT] input output
-
input
¶
input file
-
output
¶
output file
-
-h
,
--help
¶
show this help message and exit
-
--log
<log-level>
¶ Log level (info,debug,warn)
-
--report
<report-file>
¶ Specify a file to write the compile report to
-
--verbose
,
-v
¶
Increase verbosity of the output
-
--version
,
-V
¶
Display version and exit
-
--segment
<segment>
,
-S
<segment>
¶ segment to copy
-
--output-format
<output_format>
,
-O
<output_format>
¶ output file format
ppci-objdump.py¶
Objdump utility to display the contents of object files.
usage: ppci-objdump.py [-h] [–log log-level] [–report report-file] [–verbose] [–version] obj
-
obj
¶
object file
-
-h
,
--help
¶
show this help message and exit
-
--log
<log-level>
¶ Log level (info,debug,warn)
-
--report
<report-file>
¶ Specify a file to write the compile report to
-
--verbose
,
-v
¶
Increase verbosity of the output
-
--version
,
-V
¶
Display version and exit
ppci-hexutil.py¶
hexfile manipulation tool by Windel Bouwman
usage: ppci-hexutil.py [-h] {info,new,merge} ...
-
-h
,
--help
¶
show this help message and exit
ppci-hexutil.py info¶
usage: ppci-hexutil.py [-h] {info,new,merge} ...
-
hexfile
¶
-
-h
,
--help
¶
show this help message and exit