cmake_minimum_required(VERSION 3.2) include(${CMAKE_ROOT}/Modules/Platform/AT89S5x.cmake) project(Hello_World C) ADD_EXECUTABLE(hello main.c)
sdcc.exe is included in the %path% in Windows, and is recognized as the following output shows:
Error:The C compiler "C:/Programs_Dev/sdcc_x86/bin/sdcc.exe" is not able to compile a simple test program. It fails with the following output: Change Dir: C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/__default__/CMakeFiles/CMakeTmp Run Build Command:"C:/Programs_Dev/mingw/bin/mingw32-make.exe" "cmTC_1564c/fast" C:/Programs_Dev/mingw/bin/mingw32-make.exe -f CMakeFiles\cmTC_1564c.dir\build.make CMakeFiles/cmTC_1564c.dir/build mingw32-make.exe[1]: Entering directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/__default__/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_1564c.dir/testCCompiler.c.o C:\Programs_Dev\sdcc_x86\bin\sdcc.exe -o CMakeFiles\cmTC_1564c.dir\testCCompiler.c.o -c C:\Users\Tahiro\.CLion2016.1\system\cmake\generated\Hello_World-e4cf0ec9\e4cf0ec9\__default__\CMakeFiles\CMakeTmp\testCCompiler.c Linking C executable cmTC_1564c.exe C:\Programs_Dev\CMake\bin\cmake.exe -E cmake_link_script CMakeFiles\cmTC_1564c.dir\link.txt --verbose=1 C:\Programs_Dev\sdcc_x86\bin\sdcc.exe CMakeFiles/cmTC_1564c.dir/testCCompiler.c.o -o cmTC_1564c.exe at 1: error 119: don't know what to do with file 'CMakeFiles/cmTC_1564c.dir/testCCompiler.c.o'. file extension unsupported SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc08/s08/stm8 3.6.0 #9615 (MINGW32) published under GNU General Public License (GPL) Usage : sdcc [options] filename Options :- General options: --help Display this help -v --version Display sdcc's version --verbose Trace calls to the preprocessor, assembler, and linker -V Execute verbosely. Show sub commands as they are run -d -D Define macro as in -Dmacro -I Add to the include (*.h) path, as in -Ipath -A -U -M Preprocessor option -W Pass through options to the pre-processor (p), assembler (a) or linker (l) -S Compile only; do not assemble or link -c --compile-only Compile and assemble, but do not link -E --preprocessonly Preprocess only, do not compile --c1mode Act in c1 mode. The standard input is preprocessed code, the output is assembly code. -o Place the output into the given path resp. file --print-search-dirs display the directories in the compiler's search path --vc messages are compatible with Micro$oft visual studio --use-stdout send errors to stdout instead of stderr --nostdlib Do not include the standard library directory in the search path --nostdinc Do not include the standard include directory in the search path --less-pedantic Disable some of the more pedantic warnings --disable-warning <nnnn> Disable specific warning --Werror Treat the warnings as errors --debug Enable debugging symbol output --cyclomatic Display complexity of compiled functions --std-c89 Use ISO C90 (aka ANSI C89) standard (slightly incomplete) --std-sdcc89 Use ISO C90 (aka ANSI C89) standard with SDCC extensions (default) --std-c95 Use ISO C95 (aka ISO C94) standard (slightly incomplete) --std-c99 Use ISO C99 standard (incomplete) --std-sdcc99 Use ISO C99 standard with SDCC extensions --std-c11 Use ISO C11 standard (incomplete) --std-sdcc11 Use ISO C11 standard with SDCC extensions --fdollars-in-identifiers Permit '$' as an identifier character --fsigned-char Make "char" signed by default --use-non-free Search / include non-free licensed libraries and header files Code generation options: -m Set the port to use e.g. -mz80. -p Select port specific processor e.g. -mpic14 -p16f84 --model-small internal data space is used (default) --model-medium external paged data space is used --model-large external data space is used --model-huge functions are banked, data in external space --stack-auto Stack automatic variables --xstack Use external stack --int-long-reent Use reentrant calls on the int and long support functions --float-reent Use reentrant calls on the float support functions --xram-movc Use movc instead of movx to read xram (xdata) --callee-saves <func[,func,...]> Cause the called function to save registers instead of the caller --profile On supported ports, generate extra profiling information --fomit-frame-pointer Leave out the frame pointer. --all-callee-saves callee will always save registers used --stack-probe insert call to function __stack_probe at each function prologue --no-xinit-opt don't memcpy initialized xram from code --no-c-code-in-asm don't include c-code as comments in the asm file --no-peep-comments don't include peephole optimizer comments --short-is-8bits Make short 8 bits (for old times sake) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment Optimization options: --nooverlay Disable overlaying leaf function auto variables --nogcse Disable the GCSE optimisation --nolabelopt Disable label optimisation --noinvariant Disable optimisation of invariants --noinduction Disable loop variable induction --nojtbound Don't generate boundary check for jump tables --noloopreverse Disable the loop reverse optimisation --no-peep Disable the peephole assembly file optimisation --no-reg-params On some ports, disable passing some parameters in registers --peep-asm Enable peephole optimization on inline assembly --peep-return Enable peephole optimization for return instructions --no-peep-return Disable peephole optimization for return instructions --peep-file <file> use this extra peephole file --opt-code-speed Optimize for code speed rather than size --opt-code-size Optimize for code size rather than speed --max-allocs-per-node Maximum number of register assignments considered at each node of the tree decomposition --nolospre Disable lospre --allow-unsafe-read Allow optimizations to read any memory location anytime Internal debugging options: --dump-ast Dump front-end AST before generating i-code --dump-i-code Dump the i-code structure at all stages --dump-graphs Dump graphs (control-flow, conflict, etc) --i-code-in-asm Include i-code as comments in the asm file --fverbose-asm Include code generator comments in the asm output Linker options: -l Include the given library in the link -L Add the next field to the library search path --lib-path <path> use this path to search for libraries --out-fmt-ihx Output in Intel hex format --out-fmt-s19 Output in S19 hex format --xram-loc <nnnn> External Ram start location --xram-size <nnnn> External Ram size --iram-size <nnnn> Internal Ram size --xstack-loc <nnnn> External Stack start location --code-loc <nnnn> Code Segment Location --code-size <nnnn> Code Segment size --stack-loc <nnnn> Stack pointer initial value --data-loc <nnnn> Direct data start location --idata-loc --no-optsdcc-in-asm Do not emit .optsdcc in asm Special options for the mcs51 port: --stack-size Tells the linker to allocate this space for stack --parms-in-bank1 use Bank1 for parameter passing --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --acall-ajmp Use acall/ajmp instead of lcall/ljmp --no-ret-without-call Do not use ret independent of acall/lcall Special options for the z80 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the z180 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r2k port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r3ka port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the gbz80 port: -bo <num> use code bank <num> -ba <num> use data bank <num> --callee-saves-bc Force a called function to always save BC --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel Special options for the tlcs90 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the ds390 port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the pic16 port: --pstack-model= use stack model 'small' (default) or 'large' -y --extended enable Extended Instruction Set/Literal Offset Addressing mode --pno-banksel do not generate BANKSEL assembler directives --obanksel= set banksel optimization level (default=0 no) --denable-peeps explicit enable of peepholes --no-optimize-goto do NOT use (conditional) BRA instead of GOTO --optimize-cmp try to optimize some compares --optimize-df thoroughly analyze data flow (memory and time intensive!) --asm= Use alternative assembler --mplab-comp enable compatibility mode for MPLAB utilities (MPASM/MPLINK) --link= Use alternative linker --preplace-udata-with= Place udata variables at another section: udata_acs, udata_ovr, udata_shr --ivt-loc= Set address of interrupt vector table. --nodefaultlibs do not link default libraries when linking --use-crt= use <crt-o> run-time initialization module --no-crt do not link any default run-time initialization module --debug-xtra show more debug info in assembly output --debug-ralloc dump register allocator debug file *.d --pcode-verbose dump pcode related info --calltree dump call tree in .calltree file --gstack trace stack pointer push/pop to overflow --no-warn-non-free suppress warning on absent --use-non-free option Special options for the pic14 port: --debug-xtra show more debug info in assembly output --no-pcode-opt disable (slightly faulty) optimization on pCode --stack-size sets the size if the argument passing stack (default: 16, minimum: 4) --no-extended-instructions forbid use of the extended instruction set (e.g., ADDFSR) --no-warn-non-free suppress warning on absent --use-non-free option Special options for the TININative port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing --tini-libid <nnnn> LibraryID used in -mTININative Special options for the ds400 port: --model-flat24 use the flat24 model for the ds400 (default) --stack-8bit use the 8bit stack for the ds400 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds400 (default) --use-accelerator generate code for ds400 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the hc08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the s08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the stm8 port: --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --out-fmt-elf Output executable in ELF format CMakeFiles\cmTC_1564c.dir\build.make:96: recipe for target 'cmTC_1564c.exe' failed mingw32-make.exe[1]: *** [cmTC_1564c.exe] Error 1 mingw32-make.exe[1]: Leaving directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/__default__/CMakeFiles/CMakeTmp' Makefile:125: recipe for target 'cmTC_1564c/fast' failed mingw32-make.exe: *** [cmTC_1564c/fast] Error 2 CMake will not be able to correctly generate this project. Error:Configuration Debug The C compiler "C:/Programs_Dev/sdcc_x86/bin/sdcc.exe" is not able to compile a simple test program. It fails with the following output: Change Dir: C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/Debug/CMakeFiles/CMakeTmp Run Build Command:"C:/Programs_Dev/mingw/bin/mingw32-make.exe" "cmTC_bb662/fast" C:/Programs_Dev/mingw/bin/mingw32-make.exe -f CMakeFiles\cmTC_bb662.dir\build.make CMakeFiles/cmTC_bb662.dir/build mingw32-make.exe[1]: Entering directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/Debug/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_bb662.dir/testCCompiler.c.o C:\Programs_Dev\sdcc_x86\bin\sdcc.exe -o CMakeFiles\cmTC_bb662.dir\testCCompiler.c.o -c C:\Users\Tahiro\.CLion2016.1\system\cmake\generated\Hello_World-e4cf0ec9\e4cf0ec9\Debug\CMakeFiles\CMakeTmp\testCCompiler.c Linking C executable cmTC_bb662.exe C:\Programs_Dev\CMake\bin\cmake.exe -E cmake_link_script CMakeFiles\cmTC_bb662.dir\link.txt --verbose=1 C:\Programs_Dev\sdcc_x86\bin\sdcc.exe CMakeFiles/cmTC_bb662.dir/testCCompiler.c.o -o cmTC_bb662.exe at 1: error 119: don't know what to do with file 'CMakeFiles/cmTC_bb662.dir/testCCompiler.c.o'. file extension unsupported SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc08/s08/stm8 3.6.0 #9615 (MINGW32) published under GNU General Public License (GPL) Usage : sdcc [options] filename Options :- General options: --help Display this help -v --version Display sdcc's version --verbose Trace calls to the preprocessor, assembler, and linker -V Execute verbosely. Show sub commands as they are run -d -D Define macro as in -Dmacro -I Add to the include (*.h) path, as in -Ipath -A -U -M Preprocessor option -W Pass through options to the pre-processor (p), assembler (a) or linker (l) -S Compile only; do not assemble or link -c --compile-only Compile and assemble, but do not link -E --preprocessonly Preprocess only, do not compile --c1mode Act in c1 mode. The standard input is preprocessed code, the output is assembly code. -o Place the output into the given path resp. file --print-search-dirs display the directories in the compiler's search path --vc messages are compatible with Micro$oft visual studio --use-stdout send errors to stdout instead of stderr --nostdlib Do not include the standard library directory in the search path --nostdinc Do not include the standard include directory in the search path --less-pedantic Disable some of the more pedantic warnings --disable-warning <nnnn> Disable specific warning --Werror Treat the warnings as errors --debug Enable debugging symbol output --cyclomatic Display complexity of compiled functions --std-c89 Use ISO C90 (aka ANSI C89) standard (slightly incomplete) --std-sdcc89 Use ISO C90 (aka ANSI C89) standard with SDCC extensions (default) --std-c95 Use ISO C95 (aka ISO C94) standard (slightly incomplete) --std-c99 Use ISO C99 standard (incomplete) --std-sdcc99 Use ISO C99 standard with SDCC extensions --std-c11 Use ISO C11 standard (incomplete) --std-sdcc11 Use ISO C11 standard with SDCC extensions --fdollars-in-identifiers Permit '$' as an identifier character --fsigned-char Make "char" signed by default --use-non-free Search / include non-free licensed libraries and header files Code generation options: -m Set the port to use e.g. -mz80. -p Select port specific processor e.g. -mpic14 -p16f84 --model-small internal data space is used (default) --model-medium external paged data space is used --model-large external data space is used --model-huge functions are banked, data in external space --stack-auto Stack automatic variables --xstack Use external stack --int-long-reent Use reentrant calls on the int and long support functions --float-reent Use reentrant calls on the float support functions --xram-movc Use movc instead of movx to read xram (xdata) --callee-saves <func[,func,...]> Cause the called function to save registers instead of the caller --profile On supported ports, generate extra profiling information --fomit-frame-pointer Leave out the frame pointer. --all-callee-saves callee will always save registers used --stack-probe insert call to function __stack_probe at each function prologue --no-xinit-opt don't memcpy initialized xram from code --no-c-code-in-asm don't include c-code as comments in the asm file --no-peep-comments don't include peephole optimizer comments --short-is-8bits Make short 8 bits (for old times sake) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment Optimization options: --nooverlay Disable overlaying leaf function auto variables --nogcse Disable the GCSE optimisation --nolabelopt Disable label optimisation --noinvariant Disable optimisation of invariants --noinduction Disable loop variable induction --nojtbound Don't generate boundary check for jump tables --noloopreverse Disable the loop reverse optimisation --no-peep Disable the peephole assembly file optimisation --no-reg-params On some ports, disable passing some parameters in registers --peep-asm Enable peephole optimization on inline assembly --peep-return Enable peephole optimization for return instructions --no-peep-return Disable peephole optimization for return instructions --peep-file <file> use this extra peephole file --opt-code-speed Optimize for code speed rather than size --opt-code-size Optimize for code size rather than speed --max-allocs-per-node Maximum number of register assignments considered at each node of the tree decomposition --nolospre Disable lospre --allow-unsafe-read Allow optimizations to read any memory location anytime Internal debugging options: --dump-ast Dump front-end AST before generating i-code --dump-i-code Dump the i-code structure at all stages --dump-graphs Dump graphs (control-flow, conflict, etc) --i-code-in-asm Include i-code as comments in the asm file --fverbose-asm Include code generator comments in the asm output Linker options: -l Include the given library in the link -L Add the next field to the library search path --lib-path <path> use this path to search for libraries --out-fmt-ihx Output in Intel hex format --out-fmt-s19 Output in S19 hex format --xram-loc <nnnn> External Ram start location --xram-size <nnnn> External Ram size --iram-size <nnnn> Internal Ram size --xstack-loc <nnnn> External Stack start location --code-loc <nnnn> Code Segment Location --code-size <nnnn> Code Segment size --stack-loc <nnnn> Stack pointer initial value --data-loc <nnnn> Direct data start location --idata-loc --no-optsdcc-in-asm Do not emit .optsdcc in asm Special options for the mcs51 port: --stack-size Tells the linker to allocate this space for stack --parms-in-bank1 use Bank1 for parameter passing --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --acall-ajmp Use acall/ajmp instead of lcall/ljmp --no-ret-without-call Do not use ret independent of acall/lcall Special options for the z80 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the z180 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r2k port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r3ka port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the gbz80 port: -bo <num> use code bank <num> -ba <num> use data bank <num> --callee-saves-bc Force a called function to always save BC --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel Special options for the tlcs90 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the ds390 port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the pic16 port: --pstack-model= use stack model 'small' (default) or 'large' -y --extended enable Extended Instruction Set/Literal Offset Addressing mode --pno-banksel do not generate BANKSEL assembler directives --obanksel= set banksel optimization level (default=0 no) --denable-peeps explicit enable of peepholes --no-optimize-goto do NOT use (conditional) BRA instead of GOTO --optimize-cmp try to optimize some compares --optimize-df thoroughly analyze data flow (memory and time intensive!) --asm= Use alternative assembler --mplab-comp enable compatibility mode for MPLAB utilities (MPASM/MPLINK) --link= Use alternative linker --preplace-udata-with= Place udata variables at another section: udata_acs, udata_ovr, udata_shr --ivt-loc= Set address of interrupt vector table. --nodefaultlibs do not link default libraries when linking --use-crt= use <crt-o> run-time initialization module --no-crt do not link any default run-time initialization module --debug-xtra show more debug info in assembly output --debug-ralloc dump register allocator debug file *.d --pcode-verbose dump pcode related info --calltree dump call tree in .calltree file --gstack trace stack pointer push/pop to overflow --no-warn-non-free suppress warning on absent --use-non-free option Special options for the pic14 port: --debug-xtra show more debug info in assembly output --no-pcode-opt disable (slightly faulty) optimization on pCode --stack-size sets the size if the argument passing stack (default: 16, minimum: 4) --no-extended-instructions forbid use of the extended instruction set (e.g., ADDFSR) --no-warn-non-free suppress warning on absent --use-non-free option Special options for the TININative port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing --tini-libid <nnnn> LibraryID used in -mTININative Special options for the ds400 port: --model-flat24 use the flat24 model for the ds400 (default) --stack-8bit use the 8bit stack for the ds400 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds400 (default) --use-accelerator generate code for ds400 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the hc08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the s08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the stm8 port: --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --out-fmt-elf Output executable in ELF format CMakeFiles\cmTC_bb662.dir\build.make:96: recipe for target 'cmTC_bb662.exe' failed mingw32-make.exe[1]: *** [cmTC_bb662.exe] Error 1 mingw32-make.exe[1]: Leaving directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/Debug/CMakeFiles/CMakeTmp' Makefile:125: recipe for target 'cmTC_bb662/fast' failed mingw32-make.exe: *** [cmTC_bb662/fast] Error 2 CMake will not be able to correctly generate this project. Error:Configuration Release The C compiler "C:/Programs_Dev/sdcc_x86/bin/sdcc.exe" is not able to compile a simple test program. It fails with the following output: Change Dir: C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/Release/CMakeFiles/CMakeTmp Run Build Command:"C:/Programs_Dev/mingw/bin/mingw32-make.exe" "cmTC_1bf28/fast" C:/Programs_Dev/mingw/bin/mingw32-make.exe -f CMakeFiles\cmTC_1bf28.dir\build.make CMakeFiles/cmTC_1bf28.dir/build mingw32-make.exe[1]: Entering directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/Release/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_1bf28.dir/testCCompiler.c.o C:\Programs_Dev\sdcc_x86\bin\sdcc.exe -o CMakeFiles\cmTC_1bf28.dir\testCCompiler.c.o -c C:\Users\Tahiro\.CLion2016.1\system\cmake\generated\Hello_World-e4cf0ec9\e4cf0ec9\Release\CMakeFiles\CMakeTmp\testCCompiler.c Linking C executable cmTC_1bf28.exe C:\Programs_Dev\CMake\bin\cmake.exe -E cmake_link_script CMakeFiles\cmTC_1bf28.dir\link.txt --verbose=1 C:\Programs_Dev\sdcc_x86\bin\sdcc.exe CMakeFiles/cmTC_1bf28.dir/testCCompiler.c.o -o cmTC_1bf28.exe at 1: error 119: don't know what to do with file 'CMakeFiles/cmTC_1bf28.dir/testCCompiler.c.o'. file extension unsupported SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc08/s08/stm8 3.6.0 #9615 (MINGW32) published under GNU General Public License (GPL) Usage : sdcc [options] filename Options :- General options: --help Display this help -v --version Display sdcc's version --verbose Trace calls to the preprocessor, assembler, and linker -V Execute verbosely. Show sub commands as they are run -d -D Define macro as in -Dmacro -I Add to the include (*.h) path, as in -Ipath -A -U -M Preprocessor option -W Pass through options to the pre-processor (p), assembler (a) or linker (l) -S Compile only; do not assemble or link -c --compile-only Compile and assemble, but do not link -E --preprocessonly Preprocess only, do not compile --c1mode Act in c1 mode. The standard input is preprocessed code, the output is assembly code. -o Place the output into the given path resp. file --print-search-dirs display the directories in the compiler's search path --vc messages are compatible with Micro$oft visual studio --use-stdout send errors to stdout instead of stderr --nostdlib Do not include the standard library directory in the search path --nostdinc Do not include the standard include directory in the search path --less-pedantic Disable some of the more pedantic warnings --disable-warning <nnnn> Disable specific warning --Werror Treat the warnings as errors --debug Enable debugging symbol output --cyclomatic Display complexity of compiled functions --std-c89 Use ISO C90 (aka ANSI C89) standard (slightly incomplete) --std-sdcc89 Use ISO C90 (aka ANSI C89) standard with SDCC extensions (default) --std-c95 Use ISO C95 (aka ISO C94) standard (slightly incomplete) --std-c99 Use ISO C99 standard (incomplete) --std-sdcc99 Use ISO C99 standard with SDCC extensions --std-c11 Use ISO C11 standard (incomplete) --std-sdcc11 Use ISO C11 standard with SDCC extensions --fdollars-in-identifiers Permit '$' as an identifier character --fsigned-char Make "char" signed by default --use-non-free Search / include non-free licensed libraries and header files Code generation options: -m Set the port to use e.g. -mz80. -p Select port specific processor e.g. -mpic14 -p16f84 --model-small internal data space is used (default) --model-medium external paged data space is used --model-large external data space is used --model-huge functions are banked, data in external space --stack-auto Stack automatic variables --xstack Use external stack --int-long-reent Use reentrant calls on the int and long support functions --float-reent Use reentrant calls on the float support functions --xram-movc Use movc instead of movx to read xram (xdata) --callee-saves <func[,func,...]> Cause the called function to save registers instead of the caller --profile On supported ports, generate extra profiling information --fomit-frame-pointer Leave out the frame pointer. --all-callee-saves callee will always save registers used --stack-probe insert call to function __stack_probe at each function prologue --no-xinit-opt don't memcpy initialized xram from code --no-c-code-in-asm don't include c-code as comments in the asm file --no-peep-comments don't include peephole optimizer comments --short-is-8bits Make short 8 bits (for old times sake) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment Optimization options: --nooverlay Disable overlaying leaf function auto variables --nogcse Disable the GCSE optimisation --nolabelopt Disable label optimisation --noinvariant Disable optimisation of invariants --noinduction Disable loop variable induction --nojtbound Don't generate boundary check for jump tables --noloopreverse Disable the loop reverse optimisation --no-peep Disable the peephole assembly file optimisation --no-reg-params On some ports, disable passing some parameters in registers --peep-asm Enable peephole optimization on inline assembly --peep-return Enable peephole optimization for return instructions --no-peep-return Disable peephole optimization for return instructions --peep-file <file> use this extra peephole file --opt-code-speed Optimize for code speed rather than size --opt-code-size Optimize for code size rather than speed --max-allocs-per-node Maximum number of register assignments considered at each node of the tree decomposition --nolospre Disable lospre --allow-unsafe-read Allow optimizations to read any memory location anytime Internal debugging options: --dump-ast Dump front-end AST before generating i-code --dump-i-code Dump the i-code structure at all stages --dump-graphs Dump graphs (control-flow, conflict, etc) --i-code-in-asm Include i-code as comments in the asm file --fverbose-asm Include code generator comments in the asm output Linker options: -l Include the given library in the link -L Add the next field to the library search path --lib-path <path> use this path to search for libraries --out-fmt-ihx Output in Intel hex format --out-fmt-s19 Output in S19 hex format --xram-loc <nnnn> External Ram start location --xram-size <nnnn> External Ram size --iram-size <nnnn> Internal Ram size --xstack-loc <nnnn> External Stack start location --code-loc <nnnn> Code Segment Location --code-size <nnnn> Code Segment size --stack-loc <nnnn> Stack pointer initial value --data-loc <nnnn> Direct data start location --idata-loc --no-optsdcc-in-asm Do not emit .optsdcc in asm Special options for the mcs51 port: --stack-size Tells the linker to allocate this space for stack --parms-in-bank1 use Bank1 for parameter passing --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --acall-ajmp Use acall/ajmp instead of lcall/ljmp --no-ret-without-call Do not use ret independent of acall/lcall Special options for the z80 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the z180 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r2k port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r3ka port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the gbz80 port: -bo <num> use code bank <num> -ba <num> use data bank <num> --callee-saves-bc Force a called function to always save BC --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel Special options for the tlcs90 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the ds390 port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the pic16 port: --pstack-model= use stack model 'small' (default) or 'large' -y --extended enable Extended Instruction Set/Literal Offset Addressing mode --pno-banksel do not generate BANKSEL assembler directives --obanksel= set banksel optimization level (default=0 no) --denable-peeps explicit enable of peepholes --no-optimize-goto do NOT use (conditional) BRA instead of GOTO --optimize-cmp try to optimize some compares --optimize-df thoroughly analyze data flow (memory and time intensive!) --asm= Use alternative assembler --mplab-comp enable compatibility mode for MPLAB utilities (MPASM/MPLINK) --link= Use alternative linker --preplace-udata-with= Place udata variables at another section: udata_acs, udata_ovr, udata_shr --ivt-loc= Set address of interrupt vector table. --nodefaultlibs do not link default libraries when linking --use-crt= use <crt-o> run-time initialization module --no-crt do not link any default run-time initialization module --debug-xtra show more debug info in assembly output --debug-ralloc dump register allocator debug file *.d --pcode-verbose dump pcode related info --calltree dump call tree in .calltree file --gstack trace stack pointer push/pop to overflow --no-warn-non-free suppress warning on absent --use-non-free option Special options for the pic14 port: --debug-xtra show more debug info in assembly output --no-pcode-opt disable (slightly faulty) optimization on pCode --stack-size sets the size if the argument passing stack (default: 16, minimum: 4) --no-extended-instructions forbid use of the extended instruction set (e.g., ADDFSR) --no-warn-non-free suppress warning on absent --use-non-free option Special options for the TININative port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing --tini-libid <nnnn> LibraryID used in -mTININative Special options for the ds400 port: --model-flat24 use the flat24 model for the ds400 (default) --stack-8bit use the 8bit stack for the ds400 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds400 (default) --use-accelerator generate code for ds400 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the hc08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the s08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the stm8 port: --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --out-fmt-elf Output executable in ELF format CMakeFiles\cmTC_1bf28.dir\build.make:96: recipe for target 'cmTC_1bf28.exe' failed mingw32-make.exe[1]: *** [cmTC_1bf28.exe] Error 1 mingw32-make.exe[1]: Leaving directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/Release/CMakeFiles/CMakeTmp' Makefile:125: recipe for target 'cmTC_1bf28/fast' failed mingw32-make.exe: *** [cmTC_1bf28/fast] Error 2 CMake will not be able to correctly generate this project. Error:Configuration RelWithDebInfo The C compiler "C:/Programs_Dev/sdcc_x86/bin/sdcc.exe" is not able to compile a simple test program. It fails with the following output: Change Dir: C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/RelWithDebInfo/CMakeFiles/CMakeTmp Run Build Command:"C:/Programs_Dev/mingw/bin/mingw32-make.exe" "cmTC_91cd8/fast" C:/Programs_Dev/mingw/bin/mingw32-make.exe -f CMakeFiles\cmTC_91cd8.dir\build.make CMakeFiles/cmTC_91cd8.dir/build mingw32-make.exe[1]: Entering directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/RelWithDebInfo/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_91cd8.dir/testCCompiler.c.o C:\Programs_Dev\sdcc_x86\bin\sdcc.exe -o CMakeFiles\cmTC_91cd8.dir\testCCompiler.c.o -c C:\Users\Tahiro\.CLion2016.1\system\cmake\generated\Hello_World-e4cf0ec9\e4cf0ec9\RelWithDebInfo\CMakeFiles\CMakeTmp\testCCompiler.c Linking C executable cmTC_91cd8.exe C:\Programs_Dev\CMake\bin\cmake.exe -E cmake_link_script CMakeFiles\cmTC_91cd8.dir\link.txt --verbose=1 C:\Programs_Dev\sdcc_x86\bin\sdcc.exe CMakeFiles/cmTC_91cd8.dir/testCCompiler.c.o -o cmTC_91cd8.exe at 1: error 119: don't know what to do with file 'CMakeFiles/cmTC_91cd8.dir/testCCompiler.c.o'. file extension unsupported SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc08/s08/stm8 3.6.0 #9615 (MINGW32) published under GNU General Public License (GPL) Usage : sdcc [options] filename Options :- General options: --help Display this help -v --version Display sdcc's version --verbose Trace calls to the preprocessor, assembler, and linker -V Execute verbosely. Show sub commands as they are run -d -D Define macro as in -Dmacro -I Add to the include (*.h) path, as in -Ipath -A -U -M Preprocessor option -W Pass through options to the pre-processor (p), assembler (a) or linker (l) -S Compile only; do not assemble or link -c --compile-only Compile and assemble, but do not link -E --preprocessonly Preprocess only, do not compile --c1mode Act in c1 mode. The standard input is preprocessed code, the output is assembly code. -o Place the output into the given path resp. file --print-search-dirs display the directories in the compiler's search path --vc messages are compatible with Micro$oft visual studio --use-stdout send errors to stdout instead of stderr --nostdlib Do not include the standard library directory in the search path --nostdinc Do not include the standard include directory in the search path --less-pedantic Disable some of the more pedantic warnings --disable-warning <nnnn> Disable specific warning --Werror Treat the warnings as errors --debug Enable debugging symbol output --cyclomatic Display complexity of compiled functions --std-c89 Use ISO C90 (aka ANSI C89) standard (slightly incomplete) --std-sdcc89 Use ISO C90 (aka ANSI C89) standard with SDCC extensions (default) --std-c95 Use ISO C95 (aka ISO C94) standard (slightly incomplete) --std-c99 Use ISO C99 standard (incomplete) --std-sdcc99 Use ISO C99 standard with SDCC extensions --std-c11 Use ISO C11 standard (incomplete) --std-sdcc11 Use ISO C11 standard with SDCC extensions --fdollars-in-identifiers Permit '$' as an identifier character --fsigned-char Make "char" signed by default --use-non-free Search / include non-free licensed libraries and header files Code generation options: -m Set the port to use e.g. -mz80. -p Select port specific processor e.g. -mpic14 -p16f84 --model-small internal data space is used (default) --model-medium external paged data space is used --model-large external data space is used --model-huge functions are banked, data in external space --stack-auto Stack automatic variables --xstack Use external stack --int-long-reent Use reentrant calls on the int and long support functions --float-reent Use reentrant calls on the float support functions --xram-movc Use movc instead of movx to read xram (xdata) --callee-saves <func[,func,...]> Cause the called function to save registers instead of the caller --profile On supported ports, generate extra profiling information --fomit-frame-pointer Leave out the frame pointer. --all-callee-saves callee will always save registers used --stack-probe insert call to function __stack_probe at each function prologue --no-xinit-opt don't memcpy initialized xram from code --no-c-code-in-asm don't include c-code as comments in the asm file --no-peep-comments don't include peephole optimizer comments --short-is-8bits Make short 8 bits (for old times sake) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment Optimization options: --nooverlay Disable overlaying leaf function auto variables --nogcse Disable the GCSE optimisation --nolabelopt Disable label optimisation --noinvariant Disable optimisation of invariants --noinduction Disable loop variable induction --nojtbound Don't generate boundary check for jump tables --noloopreverse Disable the loop reverse optimisation --no-peep Disable the peephole assembly file optimisation --no-reg-params On some ports, disable passing some parameters in registers --peep-asm Enable peephole optimization on inline assembly --peep-return Enable peephole optimization for return instructions --no-peep-return Disable peephole optimization for return instructions --peep-file <file> use this extra peephole file --opt-code-speed Optimize for code speed rather than size --opt-code-size Optimize for code size rather than speed --max-allocs-per-node Maximum number of register assignments considered at each node of the tree decomposition --nolospre Disable lospre --allow-unsafe-read Allow optimizations to read any memory location anytime Internal debugging options: --dump-ast Dump front-end AST before generating i-code --dump-i-code Dump the i-code structure at all stages --dump-graphs Dump graphs (control-flow, conflict, etc) --i-code-in-asm Include i-code as comments in the asm file --fverbose-asm Include code generator comments in the asm output Linker options: -l Include the given library in the link -L Add the next field to the library search path --lib-path <path> use this path to search for libraries --out-fmt-ihx Output in Intel hex format --out-fmt-s19 Output in S19 hex format --xram-loc <nnnn> External Ram start location --xram-size <nnnn> External Ram size --iram-size <nnnn> Internal Ram size --xstack-loc <nnnn> External Stack start location --code-loc <nnnn> Code Segment Location --code-size <nnnn> Code Segment size --stack-loc <nnnn> Stack pointer initial value --data-loc <nnnn> Direct data start location --idata-loc --no-optsdcc-in-asm Do not emit .optsdcc in asm Special options for the mcs51 port: --stack-size Tells the linker to allocate this space for stack --parms-in-bank1 use Bank1 for parameter passing --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --acall-ajmp Use acall/ajmp instead of lcall/ljmp --no-ret-without-call Do not use ret independent of acall/lcall Special options for the z80 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the z180 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r2k port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r3ka port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the gbz80 port: -bo <num> use code bank <num> -ba <num> use data bank <num> --callee-saves-bc Force a called function to always save BC --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel Special options for the tlcs90 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the ds390 port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the pic16 port: --pstack-model= use stack model 'small' (default) or 'large' -y --extended enable Extended Instruction Set/Literal Offset Addressing mode --pno-banksel do not generate BANKSEL assembler directives --obanksel= set banksel optimization level (default=0 no) --denable-peeps explicit enable of peepholes --no-optimize-goto do NOT use (conditional) BRA instead of GOTO --optimize-cmp try to optimize some compares --optimize-df thoroughly analyze data flow (memory and time intensive!) --asm= Use alternative assembler --mplab-comp enable compatibility mode for MPLAB utilities (MPASM/MPLINK) --link= Use alternative linker --preplace-udata-with= Place udata variables at another section: udata_acs, udata_ovr, udata_shr --ivt-loc= Set address of interrupt vector table. --nodefaultlibs do not link default libraries when linking --use-crt= use <crt-o> run-time initialization module --no-crt do not link any default run-time initialization module --debug-xtra show more debug info in assembly output --debug-ralloc dump register allocator debug file *.d --pcode-verbose dump pcode related info --calltree dump call tree in .calltree file --gstack trace stack pointer push/pop to overflow --no-warn-non-free suppress warning on absent --use-non-free option Special options for the pic14 port: --debug-xtra show more debug info in assembly output --no-pcode-opt disable (slightly faulty) optimization on pCode --stack-size sets the size if the argument passing stack (default: 16, minimum: 4) --no-extended-instructions forbid use of the extended instruction set (e.g., ADDFSR) --no-warn-non-free suppress warning on absent --use-non-free option Special options for the TININative port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --stack-10bit use the 10bit stack for ds400 (default) --use-accelerator generate code for ds400 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the hc08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the s08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the stm8 port: --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --out-fmt-elf Output executable in ELF format CMakeFiles\cmTC_91cd8.dir\build.make:96: recipe for target 'cmTC_91cd8.exe' failed mingw32-make.exe[1]: *** [cmTC_91cd8.exe] Error 1 mingw32-make.exe[1]: Leaving directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/RelWithDebInfo/CMakeFiles/CMakeTmp' Makefile:125: recipe for target 'cmTC_91cd8/fast' failed mingw32-make.exe: *** [cmTC_91cd8/fast] Error 2 CMake will not be able to correctly generate this project. Error:Configuration MinSizeRel The C compiler "C:/Programs_Dev/sdcc_x86/bin/sdcc.exe" is not able to compile a simple test program. It fails with the following output: Change Dir: C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/MinSizeRel/CMakeFiles/CMakeTmp mingw32-make.exe[1]: Entering directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/MinSizeRel/CMakeFiles/CMakeTmp' Building C object CMakeFiles/cmTC_0741d.dir/testCCompiler.c.o C:\Programs_Dev\sdcc_x86\bin\sdcc.exe -o CMakeFiles\cmTC_0741d.dir\testCCompiler.c.o -c C:\Users\Tahiro\.CLion2016.1\system\cmake\generated\Hello_World-e4cf0ec9\e4cf0ec9\MinSizeRel\CMakeFiles\CMakeTmp\testCCompiler.c Linking C executable cmTC_0741d.exe C:\Programs_Dev\CMake\bin\cmake.exe -E cmake_link_script CMakeFiles\cmTC_0741d.dir\link.txt --verbose=1 C:\Programs_Dev\sdcc_x86\bin\sdcc.exe CMakeFiles/cmTC_0741d.dir/testCCompiler.c.o -o cmTC_0741d.exe at 1: error 119: don't know what to do with file 'CMakeFiles/cmTC_0741d.dir/testCCompiler.c.o'. file extension unsupported SDCC : mcs51/z80/z180/r2k/r3ka/gbz80/tlcs90/ds390/pic16/pic14/TININative/ds400/hc08/s08/stm8 3.6.0 #9615 (MINGW32) published under GNU General Public License (GPL) Usage : sdcc [options] filename Options :- General options: --help Display this help -v --version Display sdcc's version --verbose Trace calls to the preprocessor, assembler, and linker -V Execute verbosely. Show sub commands as they are run -d -D Define macro as in -Dmacro -I Add to the include (*.h) path, as in -Ipath -A -U -M Preprocessor option -W Pass through options to the pre-processor (p), assembler (a) or linker (l) -S Compile only; do not assemble or link -c --compile-only Compile and assemble, but do not link -E --preprocessonly Preprocess only, do not compile --c1mode Act in c1 mode. The standard input is preprocessed code, the output is assembly code. -o Place the output into the given path resp. file --print-search-dirs display the directories in the compiler's search path --vc messages are compatible with Micro$oft visual studio --use-stdout send errors to stdout instead of stderr --nostdlib Do not include the standard library directory in the search path --nostdinc Do not include the standard include directory in the search path --less-pedantic Disable some of the more pedantic warnings --disable-warning <nnnn> Disable specific warning --Werror Treat the warnings as errors --debug Enable debugging symbol output --cyclomatic Display complexity of compiled functions --std-c89 Use ISO C90 (aka ANSI C89) standard (slightly incomplete) --std-sdcc89 Use ISO C90 (aka ANSI C89) standard with SDCC extensions (default) --std-c95 Use ISO C95 (aka ISO C94) standard (slightly incomplete) --std-c99 Use ISO C99 standard (incomplete) --std-sdcc99 Use ISO C99 standard with SDCC extensions --std-c11 Use ISO C11 standard (incomplete) --std-sdcc11 Use ISO C11 standard with SDCC extensions --fdollars-in-identifiers Permit '$' as an identifier character --fsigned-char Make "char" signed by default --use-non-free Search / include non-free licensed libraries and header files Code generation options: -m Set the port to use e.g. -mz80. -p Select port specific processor e.g. -mpic14 -p16f84 --model-small internal data space is used (default) --model-medium external paged data space is used --model-large external data space is used --model-huge functions are banked, data in external space --stack-auto Stack automatic variables --xstack Use external stack --int-long-reent Use reentrant calls on the int and long support functions --float-reent Use reentrant calls on the float support functions --xram-movc Use movc instead of movx to read xram (xdata) --callee-saves <func[,func,...]> Cause the called function to save registers instead of the caller --profile On supported ports, generate extra profiling information --fomit-frame-pointer Leave out the frame pointer. --all-callee-saves callee will always save registers used --stack-probe insert call to function __stack_probe at each function prologue --no-xinit-opt don't memcpy initialized xram from code --no-c-code-in-asm don't include c-code as comments in the asm file --no-peep-comments don't include peephole optimizer comments --short-is-8bits Make short 8 bits (for old times sake) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment Optimization options: --nooverlay Disable overlaying leaf function auto variables --nogcse Disable the GCSE optimisation --nolabelopt Disable label optimisation --noinvariant Disable optimisation of invariants --noinduction Disable loop variable induction --nojtbound Don't generate boundary check for jump tables --noloopreverse Disable the loop reverse optimisation --no-peep Disable the peephole assembly file optimisation --no-reg-params On some ports, disable passing some parameters in registers --peep-asm Enable peephole optimization on inline assembly --peep-return Enable peephole optimization for return instructions --no-peep-return Disable peephole optimization for return instructions --peep-file <file> use this extra peephole file --opt-code-speed Optimize for code speed rather than size --opt-code-size Optimize for code size rather than speed --max-allocs-per-node Maximum number of register assignments considered at each node of the tree decomposition --nolospre Disable lospre --allow-unsafe-read Allow optimizations to read any memory location anytime Internal debugging options: --dump-ast Dump front-end AST before generating i-code --dump-i-code Dump the i-code structure at all stages --dump-graphs Dump graphs (control-flow, conflict, etc) --i-code-in-asm Include i-code as comments in the asm file --fverbose-asm Include code generator comments in the asm output Linker options: -l Include the given library in the link -L Add the next field to the library search path --lib-path <path> use this path to search for libraries --out-fmt-ihx Output in Intel hex format --out-fmt-s19 Output in S19 hex format --xram-loc <nnnn> External Ram start location --xram-size <nnnn> External Ram size --iram-size <nnnn> Internal Ram size --xstack-loc <nnnn> External Stack start location --code-loc <nnnn> Code Segment Location --code-size <nnnn> Code Segment size --stack-loc <nnnn> Stack pointer initial value --data-loc <nnnn> Direct data start location --idata-loc --no-optsdcc-in-asm Do not emit .optsdcc in asm Special options for the mcs51 port: --stack-size Tells the linker to allocate this space for stack --parms-in-bank1 use Bank1 for parameter passing --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --acall-ajmp Use acall/ajmp instead of lcall/ljmp --no-ret-without-call Do not use ret independent of acall/lcall Special options for the z80 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the z180 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r2k port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the r3ka port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the gbz80 port: -bo <num> use code bank <num> -ba <num> use data bank <num> --callee-saves-bc Force a called function to always save BC --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel Special options for the tlcs90 port: --callee-saves-bc Force a called function to always save BC --portmode= Determine PORT I/O mode (z80/z180) --asm= Define assembler name (rgbds/asxxxx/isas/z80asm) --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --no-std-crt0 For the z80/gbz80 do not link default crt0.rel --reserve-regs-iy Do not use IY (incompatible with --fomit-frame-pointer) --oldralloc Use old register allocator --fno-omit-frame-pointer Do not omit frame pointer --emit-externs Emit externs list in generated asm Special options for the ds390 port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the pic16 port: --pstack-model= use stack model 'small' (default) or 'large' -y --extended enable Extended Instruction Set/Literal Offset Addressing mode --pno-banksel do not generate BANKSEL assembler directives --obanksel= set banksel optimization level (default=0 no) --denable-peeps explicit enable of peepholes --no-optimize-goto do NOT use (conditional) BRA instead of GOTO --optimize-cmp try to optimize some compares --optimize-df thoroughly analyze data flow (memory and time intensive!) --asm= Use alternative assembler --mplab-comp enable compatibility mode for MPLAB utilities (MPASM/MPLINK) --link= Use alternative linker --preplace-udata-with= Place udata variables at another section: udata_acs, udata_ovr, udata_shr --ivt-loc= Set address of interrupt vector table. --nodefaultlibs do not link default libraries when linking --use-crt= use <crt-o> run-time initialization module --no-crt do not link any default run-time initialization module --debug-xtra show more debug info in assembly output --debug-ralloc dump register allocator debug file *.d --pcode-verbose dump pcode related info --calltree dump call tree in .calltree file --gstack trace stack pointer push/pop to overflow --no-warn-non-free suppress warning on absent --use-non-free option Special options for the pic14 port: --debug-xtra show more debug info in assembly output --no-pcode-opt disable (slightly faulty) optimization on pCode --stack-size sets the size if the argument passing stack (default: 16, minimum: 4) --no-extended-instructions forbid use of the extended instruction set (e.g., ADDFSR) --no-warn-non-free suppress warning on absent --use-non-free option Special options for the TININative port: --model-flat24 use the flat24 model for the ds390 (default) --stack-8bit use the 8bit stack for the ds390 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds390 (default) --use-accelerator generate code for ds390 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing --tini-libid <nnnn> LibraryID used in -mTININative Special options for the ds400 port: --model-flat24 use the flat24 model for the ds400 (default) --stack-8bit use the 8bit stack for the ds400 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram --stack-10bit use the 10bit stack for ds400 (default) --use-accelerator generate code for ds400 arithmetic accelerator --protect-sp-update will disable interrupts during ESP:SP updates --parms-in-bank1 use Bank1 for parameter passing Special options for the hc08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the s08 port: --out-fmt-elf Output executable in ELF format --oldralloc Use old register allocator Special options for the stm8 port: --codeseg <name> use this name for the code segment --constseg <name> use this name for the const segment --out-fmt-elf Output executable in ELF format CMakeFiles\cmTC_0741d.dir\build.make:96: recipe for target 'cmTC_0741d.exe' failed mingw32-make.exe[1]: *** [cmTC_0741d.exe] Error 1 mingw32-make.exe[1]: Leaving directory 'C:/Users/Tahiro/.CLion2016.1/system/cmake/generated/Hello_World-e4cf0ec9/e4cf0ec9/MinSizeRel/CMakeFiles/CMakeTmp' Makefile:125: recipe for target 'cmTC_0741d/fast' failed mingw32-make.exe: *** [cmTC_0741d/fast] Error 2 CMake will not be able to correctly generate this project. --parms-in-bank1 use Bank1 for parameter passing --tini-libid <nnnn> LibraryID used in -mTININative Special options for the ds400 port: --model-flat24 use the flat24 model for the ds400 (default) --stack-8bit use the 8bit stack for the ds400 (not supported yet) --stack-size Tells the linker to allocate this space for stack --pack-iram Tells the linker to pack variables in internal ram (default) --no-pack-iram Deprecated: Tells the linker not to pack variables in internal ram Run Build Command:"C:/Programs_Dev/mingw/bin/mingw32-make.exe" "cmTC_0741d/fast" C:/Programs_Dev/mingw/bin/mingw32-make.exe -f CMakeFiles\cmTC_0741d.dir\build.make CMakeFiles/cmTC_0741d.dir/build
The issue seems to be the handling of extensions of files used in respective stages of he building process. Anyone with tips?
Using CMake 3.6 with CLion.
Written in Platform/AT89S5x.cmake is
and in CMakeList.txt
sdcc.exe is included in the %path% in Windows, and is recognized as the following output shows:
The issue seems to be the handling of extensions of files used in respective stages of he building process. Anyone with tips?
Were you able to get this working?
JetBrains blog wrote about this in September 2022: https://blog.jetbrains.com/clion/2022/09/custom-compilers/