Sega Genesis Dev Kit (SGDK)
Moderator: Stef
My build file:
What is wrong? How it is correct?
Code: Select all
path = ..\..\bin;
make -f makefile clean
make -f makefile
pause
-
- Very interested
- Posts: 3131
- Joined: Thu Nov 30, 2006 9:46 pm
- Location: France - Sevres
- Contact:
Did you actually read the tutorial i pointed ?
The PATH variable is an environment variable and you shouldn't modify it this way. I guess you're using windows XP or windows 7 OS so you should look here to understand how set / modify environment variables.
Then your batch should contains :
You have to use absolute path informations.
The PATH variable is an environment variable and you shouldn't modify it this way. I guess you're using windows XP or windows 7 OS so you should look here to understand how set / modify environment variables.
Then your batch should contains :
Code: Select all
%GDK_WIN%\bin\make -f %GDK_WIN%\makefile.gen
I'm having trouble getting this to work. I get an error on winxp when I try to build the library:
"gcc: installation problem, cannot exec cc1: no such file or directory"
I have my path variables declared as "user variables" should I make them "system variables" instead?
edit: no that isn't it. The tutorial says there may be problems if other versions of gcc are installed, and I do have copies of cygwin and mingw, but they are in entirely different folders and neither have environment variables defined for them. So, I don't see how there could be conflicts.

"gcc: installation problem, cannot exec cc1: no such file or directory"
I have my path variables declared as "user variables" should I make them "system variables" instead?
edit: no that isn't it. The tutorial says there may be problems if other versions of gcc are installed, and I do have copies of cygwin and mingw, but they are in entirely different folders and neither have environment variables defined for them. So, I don't see how there could be conflicts.

-
- Very interested
- Posts: 3131
- Joined: Thu Nov 30, 2006 9:46 pm
- Location: France - Sevres
- Contact:
Are you sure your PATH variable is not pointing to your others GCC installation bin directory ? and did you set the SGDK bin directory in your PATH ?old man wrote:I'm having trouble getting this to work. I get an error on winxp when I try to build the library:
"gcc: installation problem, cannot exec cc1: no such file or directory"
...
So, I don't see how there could be conflicts.
...
OK I got it. I was using a colon instead of a semi colon to separate my path variables. :p (hard to see that little dot) Also, I setup the variables in both the system and user variable dialogues. I don't know if this made any difference though. Does anyone know if this matters or if I should only use one field to set the up in?
edit: now I'm getting undefined reference to 'main' errors. I basically cut and pasted c code from the wiki into a text file and save it as 'helloworld.c'. Then I ran the devkit from that files directory the way the tutorial shows. It didn't work.
I tried the same thing with the sample download from the wiki and it works fine. I also noticed that the downloaded sample had .project and .cproject files included with it. Can I just copy these to my own folders and things work correctly or do I need to custom make these for my projects somehow?
edit: now I'm getting undefined reference to 'main' errors. I basically cut and pasted c code from the wiki into a text file and save it as 'helloworld.c'. Then I ran the devkit from that files directory the way the tutorial shows. It didn't work.
I tried the same thing with the sample download from the wiki and it works fine. I also noticed that the downloaded sample had .project and .cproject files included with it. Can I just copy these to my own folders and things work correctly or do I need to custom make these for my projects somehow?
-
- Very interested
- Posts: 3131
- Joined: Thu Nov 30, 2006 9:46 pm
- Location: France - Sevres
- Contact:
It does not matters if you define the GDK env vars in both user and system entries but only one should suffice.old man wrote:OK I got it. I was using a colon instead of a semi colon to separate my path variables. :p (hard to see that little dot) Also, I setup the variables in both the system and user variable dialogues. I don't know if this made any difference though. Does anyone know if this matters or if I should only use one field to set the up in?
edit: now I'm getting undefined reference to 'main' errors. I basically cut and pasted c code from the wiki into a text file and save it as 'helloworld.c'. Then I ran the devkit from that files directory the way the tutorial shows. It didn't work.
I tried the same thing with the sample download from the wiki and it works fine. I also noticed that the downloaded sample had .project and .cproject files included with it. Can I just copy these to my own folders and things work correctly or do I need to custom make these for my projects somehow?
The .project and .cproject files are used by Code::Blocks but there are useless for command lines compilation.
If the downloaded sample does compile then SGDK is ok and you can work with... maybe there is a problem in piece of code in wiki.
What error you obtained ?
OK I figured this one out too. It was my own stupid mistake. I saved my file using notepad and saved it as a txt file on accident so it was saved as helloworld.c.txt. It's annoying that my windows version won't show file extensions. I only found it when I loaded into a code editor. Thanks for the help.
my But files:
Build.bat
and
Build2.bat
Everywhere gives out an identical error (always gives the same error).
Build.bat
Code: Select all
set path=J:\smd_ccp_9\bin
%GDK_WIN%make -f %GDK_WIN%makelib.gen
pause
Build2.bat
Code: Select all
set path=J:\smd_ccp_9\bin
make -f makelib.gen
pause
-
- Very interested
- Posts: 3131
- Joined: Thu Nov 30, 2006 9:46 pm
- Location: France - Sevres
- Contact:
The makelib.gen file is used to rebuild the library.
To compile your own project you have to use the makefile.gen file.
Anyway your files are outdated and/or modified... i can't help you this way.
Just download the last SGDK version here :
http://code.google.com/p/sgdk/downloads/list
And follow the basic tutorial here :
http://code.google.com/p/sgdk/wiki/HowToUseSGDK
It's very simple to get it work !
Also verify that you don't have any others GCC toolschain in your PATH variable or it will conflict.
To compile your own project you have to use the makefile.gen file.
Anyway your files are outdated and/or modified... i can't help you this way.
Just download the last SGDK version here :
http://code.google.com/p/sgdk/downloads/list
And follow the basic tutorial here :
http://code.google.com/p/sgdk/wiki/HowToUseSGDK
It's very simple to get it work !
Also verify that you don't have any others GCC toolschain in your PATH variable or it will conflict.
-
- Very interested
- Posts: 3131
- Joined: Thu Nov 30, 2006 9:46 pm
- Location: France - Sevres
- Contact:
If you carefully follow the tutorial you *don't need* any build file !
As it's written in the tutorial you just need to type :from your project directory.
So if you really want to use a batch file only put this line into.
If you do a fresh install of SGDK and follow correctly this simple tutorial you should get things working !
I'm really a patient guy but i'm starting going crazy with you ! Do i have to repeat 100 times the same thing ?
As it's written in the tutorial you just need to type :
Code: Select all
%GDK_WIN%\bin\make -f %GDK_WIN%\makefile.gen
So if you really want to use a batch file only put this line into.
If you do a fresh install of SGDK and follow correctly this simple tutorial you should get things working !
I'm really a patient guy but i'm starting going crazy with you ! Do i have to repeat 100 times the same thing ?