It looks like you're new here. If you want to get involved, click one of these buttons!
1>------ Build started: Project: 01_Object, Configuration: Debug Win32 ------
1>C:Program Files (x86)MSBuildMicrosoft.Cppv4.0Microsoft.CppBuild.targets(935,5): warning MSB8012: TargetPath(c:usersjuhadocumentsvisual studio 2010ProjectsmainDebug1_Object.exe) does not match the Linker's OutputFile property value (C:UsersJuhaDocumentsVisual Studio 2010Projectsin1_Object_d.exe). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile).
1>C:Program Files (x86)MSBuildMicrosoft.Cppv4.0Microsoft.CppBuild.targets(937,5): warning MSB8012: TargetName(01_Object) does not match the Linker's OutputFile property value (01_Object_d). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile).
1> Creating library c:usersjuhadocumentsvisual studio 2010ProjectsmainDebug1_Object.lib and object c:usersjuhadocumentsvisual studio 2010ProjectsmainDebug1_Object.exp
1>LINK : fatal error LNK1561: entry point must be defined
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Comments
I haven't vs 2010 express at home yet, but I think I know the issue. Grey's tutorial was for creating a new project for a stand alone executable made with orx.
However, tutorials #1 - #9 are plugins projects (ie. a .DLL not a .EXE) to be used with orx launcher (orx.exe/orxd.exe). I suggest you use the vs2008 solution from the tutorial package in /build/msvs2008 and load it with vs express 2010, I presume it will then convert the solution to the new format and you'll have all the tutorials ready for compiling.
If you still want to start with an empty project from scratch, you can do so with the source code from tutorial #10 or #11 (they both are stand alones).
I'll probably convert all the tutorials to stand alone in the future and provide express 2010 pre-compiled files but it won't happen before a couple of months.
I have managed to get the linker things straight.
But the problem's still there.
It goes away when putting int main(){} in the beginning, but then the program just flashes, and doesn't run the rest.
I also tried loading the solution from orx utorialuildmsvs2008 and converting them, but they wont compile.
This is compiling tutorial 11
NP
That means you're linking to create an executable instead of a dynamic library as it's looking for an entry point. Adding a main won't make it work, unfortunately. I'll see if there's something I'm missing as soon as I have a working vs2010 installed at home.
I'll try to get vs express 2010 on my computer during the week as soon as I find enough time for that and I'll try on my side.
There's a difference in output paths here: a Dynamic Release has been added by visual 2010. Also he's not finding orx.lib which should be in the tutorial/lib/msvs2008 folder. So again I suspect something weird happening with the paths when converting the project to vs2010. :dry:
I'll have a pretty busy week but I'll try to find some time so that you can get started as it's frustrating to get stuck with silly linking issue.
I totally know the feeling: that was exactly what happened to me yesterday for many hours when trying to build an iPhone executable with orx: I kept getting mystical linking errors I've never seen in 15 years of coding! :S
Everything should work even if you get some warning when compiling about paths being different. I'll clean all this mess later, probably for the next release.
Also I'm adding the orx-dev-msvs2010 and orx-tutorial-msvs2010 packages to the sourceforge files (they should be there before tonight).
If you have any trouble with the new files, please let me know!
Otherwise, the tutorials & support is much better than elsewhere.
If you wish to see what I do differently with ORX, there's a link in my signature to my tutorial set. Which is also available at the bottom of the tutorials wiki page.
So yes, tutorial #1-#9 are confusing as they create plugins for orx launcher. Tutorials 10&11 are for making stand alones though. But it's probably better to go with Grey's ones from the beginning as they as much more easy to understand.
I'm glad you enjoy the wiki and orx so far, let us know if you have any other questions/concerns/comments!
I went back to project -> linker properties and...
1. changed output file to .dll
2. set Init as entry point symbol.
3. set Subsystem to Windows/Console.
Those should probably go at the end of the existing tutorial.
(VS 2008 Screenshots included)
That being said, it still doesn't work. I'm still pretty sure the last steps are needed because the linker won't generate a dll image without them.
Now the builds with no errors or warnings, but when I run "orx hellorx_d.dll" from command line, nothing shows up on screen or in debug log. If I use -c switch (like the demos) it crashes. The .ini file is in same folder.
I'll try building the standalone later. I prefer this "old school" way even though it can be a headache at first because if an .exe is made & I can get the debugger to step into my source code, the way is clear.
Our pleasure!
So, normally you shouldnt put any entry point, orx will scan the dll till it find its own entry point (declared by the macro you used, so it's not Init ).
The subsystem shouldn't matter for a .dll, console is a good settings.
You also need to adjust a couple of things like no manifest, linking against the non-dll version of visual C library runtime, ...
It's a sweet nightmare but you can just download the corresponding orx-tutorial-* package and see how the projects setups are done there.
I was more thinking of replacing all the plugins tutorials by stand alone ones. Simply it takes time to update all the project files + wiki, and I'd rather focus on the 1.2 release (iPhone + SDL/OpenGL/OpenAL) for now.
The -c switch only takes config files as parameters. Adding the dll on the command line won't change anything either.
In order to load your dll, you need to specify it inside orx.ini (look at the GameFile config property). Again, you can download the tutorial package and see how things are done with it. But if I were you I'd directly make a stand alone!
And it's definitely easier to setup in visual studio. Even the required code is now very short with only 3 callbacks to define and a single function call to initialize and run orx. The plugins were a valid alternative back in the days when creating a stand alone with orx was really painful.
A wiser man might give up at this point but let me assure you, I am not he! On to the standalone!
If this works, I will save you the tutorial rewrite & post every step for a Hello World type tutorial. (With a bit more spice, of course.)
I've tried to write them so someone who's never touched a compiler before can at least have a go at this.
Either way, good luck!
<edit>
ugh... okay just to be clear, my tutorials are how to create -using- orx, not compile orx itself.
If the issue is compiling orx, please disregard my comments
</edit>
All I had to do was follow the directions... >.> <.<
I didn't have any problems compiling, just copying the right project options. Your screen shots did most the work for me.
Thanks a million! :woohoo:
Did you decide what you wanted to put in it?
Hint, hint: FX could be nice as they're an unusual feature for game engines.
http://caca.zoy.org/wiki/libcaca