Jump to content
  • Advertisement
Sign in to follow this  
AgentC

CMake, Xcode (iOS) and AngelScript

This topic is 2322 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi,
has anyone managed to build AngelScript for iOS successfully by using CMake? My problem is the inclusion of the assembly source code file as_callfunc_arm_xcode.S. In the Xcode project that CMake generates, it does not set the "lastKnownFileType" to "sourcecode.asm" for that file like it should, instead it sets it to just "sourcecode". As a result Xcode does not know that it's supposed to invoke the assembler for it.

I wouldn't like to rely on CMake actually fixing that bug, because there is no telling how long that takes, or if they even view it as a problem. But any creative workarounds?

EDIT: for now I went with simple postprocessing of the project file using sed. This has the downside that when/if CMake decides to regenerate the project, also the "postprocess" has to be repeated. Edited by AgentC

Share this post


Link to post
Share on other sites
Advertisement
I'm not sure about CMake as I've never used it myself.

However, I'd like to know what changes you're making with sed to work around the problem. Perhaps it is something I can add to the manual for others that compile with CMake.

Share this post


Link to post
Share on other sites
Here's the command (project name needs to be replaced)


sed -i.bak 's/lastKnownFileType = sourcecode; name = "as_callfunc_arm_xcode.S"/lastKnownFileType = sourcecode.asm; name = "as_callfunc_arm_xcode.S"/g' MyProjectFile.xcodeproj/project.pbxproj


Also the CMake script supplied by default with AngelScript does not list the platform-specific asm files, so the file in question also needs to be added there. But I'm not sure there's a clean way to recognize in CMake that you're crosscompiling on Xcode for iOS.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!