Well, it looks like the error is not in my sources at all...
Here is my current OSDK_config.bat:
Code: Select all
@ECHO OFF
:: Set the build paremeters
SET OSDKADDR=$600
SET OSDKNAME=XS
SET OSDKFILE=main
And a test main.c I just created:
And here is the result of running OSKD_build.bat after removing all files except the OSDK_*.bat files and main.c in that folder:
Code: Select all
C:\Users\laurent\Desktop\Dropbox\Oric\_xs>osdk_build.bat
Building the program XS at adress $600
"Handling main"
Compiling main.C
- preprocess
C:\Users\laurent\Desktop\Dropbox\Oric\_xs>C:\Users\laurent\Desktop\Dropbox\Oric\OSDK\Osdk\_final_\BIN\cpp.exe -lang-c++ -I C:\Users\laurent\Desktop\Dropbox\Oric\OSDK\Osdk\_final_\include -D__16BIT__ -D__NOFLOAT__ -DATMOS -DOSDKNAME_XS -nostdinc main.c C:\Users\laurent\Desktop\Dropbox\Oric\OSDK\Osdk\
_final_\TMP\main.c
- compile
C:\Users\laurent\Desktop\Dropbox\Oric\_xs>C:\Users\laurent\Desktop\Dropbox\Oric\OSDK\Osdk\_final_\BIN\compiler.exe -Nmain -O2 C:\Users\laurent\Desktop\Dropbox\Oric\OSDK\Osdk\_final_\TMP\main.c 1>C:\Users\laurent\Desktop\Dropbox\Oric\OSDK\Osdk\_final_\TMP\main.c2
- convert C to assembly code
- cleanup output
Linking
C:\Users\laurent\Desktop\Dropbox\Oric\_xs
Assembling
# 1 "C:\\Users\\laurent\\Desktop\\Dropbox\\Oric\\OSDK\\Osdk\\_final_\\TMP\\main.s"
C:\Users\laurent\Desktop\Dropbox\Oric\_xs\main.s(1): 06bb:Syntax error
Break after 1 errors
ERROR : Build failed.
And here is the 06bb line in Build/symbols:
Code: Select all
0611 retstack
06bb _main
0612 enter
So it definitely always complains about the first symbol defined in the C source.
Either there is something wrong with my setup, I have noticed that the git version I am using (from Cygwin) tends to give weird permission to files on Windows so I kinda wonder if that could have side effects on some of the tools in the build chain.
Or this version of the OSDK is funky.
I will have to try with a fresh installation from the OSDK .zip file.
Are there others who use the latest OSDK? Could you guys try to reproduce this error?
I will post a .zip with the sources I am trying to compile soon.
Update:
I have been able to compile my stuff normally using the OSDK and found what the issue was!
Here is how to reproduce the issue:
- Obtain the OSDK from the SVN folder (same as http://miniserve.defence-force.org/svn/ ... osdk/main/).
- let's assume you put the content of that "main" folder in C:\KITTY
- Open a CMD window, type "cd C:\KITTY"
- type "set OSDK=C:\KITTY\Osdk\_final_" so that it points directly to the compiled version stored in _final_
- go to the c simple example: "cd C:\KITTY\sample\c\hello_world_simple"
- type "osdk_build.bat"
- notice that this completely fails to compile with weird errors
The error is clearly that I set the OSDK environment variable to
the Osdk/_final_ folder contained in the SVN repository.
I assumed that the version which was present in SVN in that folder would be valid but apparently it is not.
Setting OSDK to C:\KITTY solves the issue, stuff compiles fine. (My empty main.c compiles too.
)
I naively assumed that since DBug used _final_ as his tests bed that the version of that folder from the SVN repository would be valid.
But it clearly seems that it is not valid.
So, I assume that having _final_ in SVN is some kind of mistake, like a .gitignore/.svnignore missing a "-Osdk/_final_/*" or something of that nature.
I guess it would be probably safer to "kitten proof" it by removing it from the SVN repo since after all:
- it is supposed to be generated by "make"-ing the OSDK
- it is not present in the OSDK zip file
In any case... phew... I CAN FINALLY CODE AGAIN. Yeah!