hjm168168 / libmv

Automatically exported from code.google.com/p/libmv
MIT License
0 stars 0 forks source link

Cmake Won't Build Working Xcode Project #17

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. run cmake on the src/ folder
2. specify generator as Xcode project and use Default native Compilers
3. Configure eand Generate

What is the expected output? What do you see instead?
The Xcode project that it generates fails with this error.

"Project LIBMV.xcodeproj cannot be opened because the project file cannot
be parsed."

What version of the product are you using? On what operating system?
Code Revision: 847
Mac OS X 10.6.2 
i386 arch
CMake 2.8

I helps development to be able to run Xcode's debugger on the code. 
I hope someone can help me here.

Original issue reported on code.google.com by sirhcsen...@gmail.com on 27 Mar 2010 at 9:48

GoogleCodeExporter commented 9 years ago
I'm using Xcode 3.2.1

Original comment by sirhcsen...@gmail.com on 27 Mar 2010 at 9:49

GoogleCodeExporter commented 9 years ago
3/27/10 3:07:35 PM  Xcode[851]  CFPropertyListCreateFromXMLData(): Old-style plist
parser: missing semicolon in dictionary.

only clue I have.

Original comment by sirhcsen...@gmail.com on 27 Mar 2010 at 10:16

GoogleCodeExporter commented 9 years ago
It certainly a Cmake error. Have you try to generate a Code::Blocks project and 
compile it. Code::blocks must run on Mac.

Original comment by pmou...@gmail.com on 29 Mar 2010 at 12:42

GoogleCodeExporter commented 9 years ago
You can get Xcode projects to build using these changes.
However, I haven't been able to get cmake to understand to use the line
on a mac IF Xcode is your generator. So, the Unix Makefile system on mac is 
broken
however the line inside src/libmv/image/CMakeList.txt
was the issue.

Index: libmv/image/CMakeLists.txt
===================================================================
--- libmv/image/CMakeLists.txt  (revision 848)
+++ libmv/image/CMakeLists.txt  (working copy)
@@ -1,4 +1,10 @@
-ADD_DEFINITIONS(-DTHIS_SOURCE_DIR="\\"${CMAKE_CURRENT_SOURCE_DIR}\\"")
+# Note how slashes are handled
+# http://msdn.microsoft.com/en-us/library/a1y7w461%28VS.80%29.aspx
+if (APPLE)
+   ADD_DEFINITIONS(-DTHIS_SOURCE_DIR=\\\\"${CMAKE_CURRENT_SOURCE_DIR}\\\\")
+else()
+   ADD_DEFINITIONS(-DTHIS_SOURCE_DIR="\\"${CMAKE_CURRENT_SOURCE_DIR}\\"")
+endif()

 IF(WIN32)
   INCLUDE_DIRECTORIES(
Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt  (revision 848)
+++ CMakeLists.txt  (working copy)
@@ -36,7 +36,7 @@
 ENDIF (WIN32)

 IF(CMAKE_COMPILER_IS_GNUCXX)
-  SET(CMAKE_CXX_FLAGS "-Wall -W -Wno-sign-compare -Wno-strict-aliasing")
+  SET(CMAKE_CXX_FLAGS "-Wall -W -Wno-sign-compare -Wno-strict-aliasing 
-fpermissive")
   ADD_DEFINITIONS(-D_GNU_SOURCE)
 ENDIF(CMAKE_COMPILER_IS_GNUCXX)

Original comment by sirhcsen...@gmail.com on 10 Apr 2010 at 5:00

GoogleCodeExporter commented 9 years ago
It gets past the Xcode Parse error but the Xcode project still has issues 
building.
I'll keep working on it.

Original comment by sirhcsen...@gmail.com on 10 Apr 2010 at 5:10

GoogleCodeExporter commented 9 years ago
have there been any further updates regarding these issues, XCode project would 
be great!

Original comment by joelkron...@gmail.com on 16 May 2011 at 4:03

GoogleCodeExporter commented 9 years ago
I second that. Any news on this?

Original comment by perarnetron on 25 Feb 2012 at 2:17