Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (107)
games submitted by our members
Games in WIP (534)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Compiling odejava and ode from scratch  (Read 1326 times)
0 Members and 1 Guest are viewing this topic.
Offline lhkbob

JGO Knight


Medals: 32



« Posted 2007-11-19 01:50:18 »

I'm having terrible difficulty trying to compile ode and odejava from scratch, mostly because the instructions don't add up.  If filenames aren't exact, I'm doing this from memory, so bear with me.
Here is what I did on my Mac (osx 10.4.10):
1. Checked out odejava from odejava's cvs
2. Downloaded ode-.9 source
3. Looking at the various readmes, I put the source in compile/odejava/ode, although there was no config/user_settings to edit.
4. Ignoring this problem, I tried to compile ODE by running the configure script and then make.
   a. Couldn't get it to compile with OPCODE, compiled when I edited some include statements for GIMPACT, however even though it generated no errors, there were no libraries outputted for my use (or .o files that I could tell).  The directories it claimed to put them in didn't exist (I think they were /usr/local/lib (this one existed but had no new files in it after running make) and /usr/local/ode).

This is essentially where I gave up.  I'm just looking for up to date binaries and .jar libraries for odejava, but odejava.org seemed very out of date (since 2004 for the natives).  Are there any more up-to-date packaged versions out there (preferably able to run ode .9, since that has new features that I would like).

Offline irrisor

Junior Member





« Reply #1 - Posted 2007-11-19 09:52:06 »

odejava-jni has build-scripts in the build folder. We are currently struggling with building universal binaries, but if you remove one of the -arch flags osx binaries should build fine. Probably you can even help out with the universal binaries?
You can use odejava-jni (HEAD) with the other odejava parts in the branch "with-odejava-jni".
Offline lhkbob

JGO Knight


Medals: 32



« Reply #2 - Posted 2007-11-19 17:09:33 »

That may have been my problem, I just checked out the odejava branch and not odejava-jni.  I'll give that a try once I have a bit more free time and I'll let you know how it went.  If I figure out how to get it working, I'd be glad to write up a more modern tutorial for mac users.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline lhkbob

JGO Knight


Medals: 32



« Reply #3 - Posted 2007-11-20 00:39:57 »

Starting from the odejava-jni branch, I've successfully been able to compile ode-0.9.  Here are some notes of what I had to change to make it work correctly:
0. Make sure XCode is installed since that gives mac the gcc compiler.
1. Can't use svn, doesn't give the configure file (sh autogen.sh didn't help either).  Used the snapshot release from sourceforge.
2. run ./configure --enable-release --with-trimesh=gimpact.  The other options in odejava readme caused it to fail.
3. open GIMPACT/src/gim_memory.cpp and remove the include for malloc.h (not necessary for mac os x)
4. run make
5. The .o files and libode.dylib are placed in ./ode/src even though the configure script claims they go to /usr/local/include and /usr/local/lib

That's the good news.  The bad news is that I'm stuck running swig to generate the necessary files.  I used the newest swig if it makes a difference.  To get it to not generate errors, I had to change some paths in the odejava.i file, although it confused me as to why some worked and others didn't since they all seemed to point incorrectly.  Anyway, once it ran, there were no new files placed in the generated/ folder.

Any help would be appreciated.

Offline lhkbob

JGO Knight


Medals: 32



« Reply #4 - Posted 2007-11-20 02:08:11 »

Actually swig did generate code, just once again in a place unexpected --> went to generated/org/etc instead of generated/java/org/etc
Anyway with that discovered I began trying to compile and link the odejava stuff and it made more errors.  I got around some by moving some of the opende directories so that the include statements could actually read them (this is also where I'm having trouble since I'm not familiar with gcc so I don't know the purpose or syntax for all of the flagged options).  When running these, there are thousands of errors generated from the odejava.cxx file.  Oddly enough the errors shouldn't be errors when looking at the source code for odejava.cxx, so I have a feeling that I should use a slightly older version of swig.

Once I try this and the build scripts in the build folder, if it doesn't compile, I'm not sure that there is much more that I can try.  Also, I think that someone needs to rewrite the odejava.i file for swig since ode has progressed a lot since the .i file was last written.

Offline lhkbob

JGO Knight


Medals: 32



« Reply #5 - Posted 2007-11-20 03:58:46 »

Tried the build scripts, didn't work because I need a dos2unix executable.  Where would I get one?

Offline irrisor

Junior Member





« Reply #6 - Posted 2007-11-20 09:47:43 »

fink? (I don't know - ask google Wink) You need new autotools (automake etc.) as well, these can be installed with fink, at least.
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

pw (35 views)
2014-07-24 01:59:36

Riven (33 views)
2014-07-23 21:16:32

Riven (21 views)
2014-07-23 21:07:15

Riven (24 views)
2014-07-23 20:56:16

ctomni231 (55 views)
2014-07-18 06:55:21

Zero Volt (47 views)
2014-07-17 23:47:54

danieldean (38 views)
2014-07-17 23:41:23

MustardPeter (43 views)
2014-07-16 23:30:00

Cero (59 views)
2014-07-16 00:42:17

Riven (56 views)
2014-07-14 18:02:53
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!