[crossfire] common/ and the build system.

Amorya North amorya at amorya.freeserve.co.uk
Thu Aug 11 20:19:03 CDT 2005


Not doing too well here. I decided the first thing to do was to try  
and get all the files in common/ into an XCode project. This proved a  
major challenge and I still haven't properly succeeded!

The problem appears to be that common/ is not just drop-in stuff, but  
is tied to the crossfire build system. I have not yet been able to  
build crossfire client as a whole on my Mac - it complains of not  
being able to find libpng (which is in /sw/includes). That's ok for  
playing as I use the binary client. For messing with the source it's  
not so good!

So as far as I can gather to use the common/ files as a base for my  
client, I have to build a standard crossfire client, and then take  
the autogenerated config.h file and drop that, as well as common/ and  
help/, into my XCode project. Is that correct? Is that the _only_ way  
I can use the common/ files?


I tried writing the defines for config.h myself, to the best of my  
knowledge. Once this was done the crossfire code compiled (after a  
lot of hacking - dunno if it worked!), but was a nightmare as soon as  
I tried to link to it in any file of mine. The problem here was that  
I didn't know which headers to include in which order. Eventually it  
got all tangled up with errors in <string.h>, which is one of Apple's  
headers, so I don't know what was going on there.


I probably seem really clueless here. Coding Unix stuff is mostly  
outside my area of knowledge... I've never had to think about  
multiple platform issues before. Please don't write me off yet  
though, as once I get started I should be able to pick up speed!


Posted by tchize:
>
     
      Just from my experience compiling the sdl-alpha releases of client  
     
     >
     
      on mac os x,
     
     >
     
      the common part compiles without any problems using x-code IDE, the  
     
     >
     
      most
     
     >
     
      difficult part, i'll say, was to get the sdl libs and dependencies  
     
     >
     
      to compile statically
     
     >
     
      (so mac os x users don't need to install bunch of libraries before  
     
     >
     
      using it) and
     
     >
     
      get xcode to use relative paths for includes instead of absolute  
     
     >
     
      ones (never achieved
     
     >
     
      it but didn't search much).
     
     
Don't suppose you could send me your xcode project and files, if you  
still have it around? I could then compare what's different in the  
stuff I'm wrestling with!


Amorya


    
    


More information about the crossfire mailing list