From: Branan R. <br...@gm...> - 2008-09-07 02:48:06
|
The 2.x-lite branch of GLFW is now being pulled on a GLSDK checkout, via svn:externals. It currently fails to build for me on Linux, using CMake 2.6, due to a change in the way CMake handles X11 stuff. I can make a patch, but it will move the minimum required CMake version up to 2.6. All the recent distro releases have 2.6, and it's the version we're requiring for the GLSDK. There are a couple problems with that, though: * On Gentoo, CMake 2.6 is still marked as testing * I think that Hardy (and soon Intrepid) are the only Ubuntu versions with 2.6 I have no idea what the versions are for other distros For now, it's only set to build on Windows. So if anyone on Windows wants to try to build GLSDK revsion 66, and see what happens, that would be awesome Branan |
From: H. H. <hen...@gm...> - 2008-09-07 08:35:20
|
I'm using Arch Linux and CMake 2.6 version is supported. I have no objections to this. On Sun, Sep 7, 2008 at 5:48 AM, Branan Riley <br...@gm...> wrote: > The 2.x-lite branch of GLFW is now being pulled on a GLSDK checkout, > via svn:externals. > > It currently fails to build for me on Linux, using CMake 2.6, due to a > change in the way CMake handles X11 stuff. I can make a patch, but it > will move the minimum required CMake version up to 2.6. All the recent > distro releases have 2.6, and it's the version we're requiring for the > GLSDK. There are a couple problems with that, though: > > * On Gentoo, CMake 2.6 is still marked as testing > * I think that Hardy (and soon Intrepid) are the only Ubuntu versions with > 2.6 > > I have no idea what the versions are for other distros > > For now, it's only set to build on Windows. So if anyone on Windows > wants to try to build GLSDK revsion 66, and see what happens, that > would be awesome > > Branan > > ------------------------------------------------------------------------- > This SF.Net email is sponsored by the Moblin Your Move Developer's > challenge > Build the coolest Linux based applications with Moblin SDK & win great > prizes > Grand prize is a trip for two to an Open Source event anywhere in the world > http://moblin-contest.org/redirect.php?banner_id=100&url=/ > _______________________________________________ > Glsdk-devel mailing list > Gls...@li... > https://lists.sourceforge.net/lists/listinfo/glsdk-devel > -- Henri 'henux' Häkkinen |
From: Orhun B. <orh...@gm...> - 2008-09-07 18:16:31
|
I just tried building but CMake failed with CMake Error in third_party/glfw/lib/win32/CMakeLists.txt: Cannont find source file "enable.c". Tried extensions .c .C .c++ .cc .cpp [snip] -- Orhun Birsoy |
From: Branan R. <br...@gm...> - 2008-09-07 18:32:43
Attachments:
glfw_cmake.patch
|
I see the problem. GLFW asumes that it's a top-level project. This patch should fix that Branan On Sun, Sep 7, 2008 at 11:16 AM, Orhun Birsoy <orh...@gm...> wrote: > I just tried building but CMake failed with > CMake Error in third_party/glfw/lib/win32/CMakeLists.txt: > Cannont find source file "enable.c". Tried extensions .c .C .c++ .cc .cpp [snip] |
From: Orhun B. <orh...@gm...> - 2008-09-07 18:49:39
|
OK. It worked. But the compile fails with 1>win32_dllmain.c 1>..\..\..\..\..\glsdk\third_party\glfw\lib\win32\win32_dllmain.c(31) : fatal error C1083: Cannot open include file: 'internal.h': No such file or directory "third_party\glfw\lib" is missing from the include directories. After manually adding this directory to Visual Studio project, glfw lib compiles but the triangle example compile fails with, 2>triangle.c 2>..\..\..\..\glsdk\third_party\glfw\examples\triangle.c(10) : fatal error C1083: Cannot open include file: 'GL/glfw.h': No such file or directory Triangle project has these include directories set, C:\home\orhun\development\3rdparty\glsdk\inc;C:\home\orhun\development\3rdparty\glsdkbuild\inc;C:\home\orhun\development\3rdparty\glsdk\include either "third_party\glfw\include" should be included to the search paths or, glfw.h should be added (or copied during build) to "inc/GLSDK", but I am not sure whether it should be "GLSDK/GL/glfw.h" or just "GLSDK/glfw.h". -- Orhun Birsoy |
From: Branan R. <br...@gm...> - 2008-09-07 18:56:28
Attachments:
glfw_cmake.patch
|
OK, this should fix those. This patch includes the first one, so be sure to run 'svn revert' in the glfw directory before applying it. Branan |
From: Orhun B. <orh...@gm...> - 2008-09-07 19:11:55
|
It almost worked.. It compiles but, the link fails with 1>Linking... 1>MSVCRTD.lib(crtexew.obj) : error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup 1>C:\home\orhun\development\3rdparty\glsdkbuild\third_party\glfw\examples\Debug\triangle.exe : fatal error LNK1120: 1 unresolved externals The reason is SubSystem flag in Linker/System is set to "Windows", It should have been "Console". If I manually change it to "Console", everything works and I see the spinning triangle. I have no idea how this is set in CMake though. -- Orhun Birsoy |
From: Branan R. <br...@gm...> - 2008-09-07 19:19:21
|
The CMake file looks like it's correct to generate a win32 program, rather than a console app... Does it give the same error building boing.exe or gears.exe? Branan |
From: Orhun B. <orh...@gm...> - 2008-09-07 19:23:32
|
They all fail with the same error. PS: I have to leave for the rest of the day. But I'll look into this tonight if I don't hear back from you. -- Orhun Birsoy |
From: Branan R. <br...@gm...> - 2008-09-08 01:36:55
|
I have no idea why it's failing. The executable targets _should_ work fine, as far as I can tell. I'm probably just not seeing it. I'll look again tomorrow, maybe fresh eyes will help. For now, I've add a new CMake option to the GLSDK build system, so GLFW is diabled by default on all platforms, and can be enabled with -DGLSDK_GLFW=1. Branan |
From: Branan R. <br...@gm...> - 2008-09-08 02:37:17
Attachments:
glfw_cmake.patch
|
I see it *slaps forehead* I got your error backwards. For some reason, I was thinking it was showing console and needed to be set to Windows. I've set it to console, but now it will show the dos box. The real solution is to chaing the entry point to mainCRTStartup, as described in tutorial 0 on the GLFW website. I'm not sure how to do that in CMake, but I will look into it. Once again, the patch is all-inclusive Branan |
From: Camilla B. <cam...@gm...> - 2008-09-09 15:15:40
|
Running a little behind... Branan Riley wrote: > The 2.x-lite branch of GLFW is now being pulled on a GLSDK checkout, > via svn:externals. Yay. [1] https://sourceforge.net/tracker/?atid=534940&group_id=72569 > I have no idea what the versions are for other distros Etch (Debian stable) still has 2.4, with no 2.6 on backports.org. Lenny (testing) has 2.6, but when I installed this laptop, that package still lacked ccmake so I'm running the Sid (unstable) package. ...but since neither project is going to be released tomorrow, perhaps that's okay. Regards, elmindreda |
From: Camilla B. <cam...@gm...> - 2008-09-09 15:31:45
|
Branan Riley wrote: > Once again, the patch is all-inclusive Applied, except for the console stuff. Regards, elmindreda |
From: Branan R. <br...@gm...> - 2008-09-09 15:59:23
|
I'm at work so I can't make a patch right now, but here's the CMake code to make a win32 GUI-app use main() as the entry point: IF(${CMAKE_SYSTEM_NAME} STREQUAL "Windows") SET_TARGET_PROPERTIES(<exename> PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") ENDIF(${CMAKE_SYSTEM_NAME} STREQUAL "Windows") These lines needsto be added after the ADD_EXECUTABLE call in all the examples. I can do it and make a patch when I get home tonight (about 8.5-9 hours), if no one gets to it by then. |
From: Camilla B. <cam...@gm...> - 2008-09-09 17:34:16
|
Branan Riley wrote: > IF(${CMAKE_SYSTEM_NAME} STREQUAL "Windows") > SET_TARGET_PROPERTIES(<exename> PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") > ENDIF(${CMAKE_SYSTEM_NAME} STREQUAL "Windows") That won't make GCC-based (or any other non-VS) build chains happy, though. How about something like: if(MSVC) set_target_properties(boing PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") set_target_properties(splitview PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") set_target_properties(triangle PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") set_target_properties(wave PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") endif(MSVC) Oh, and -mno-cygwin isn't set yet. I'll fix that not today. Regards, elmindreda |
From: Branan R. <br...@gm...> - 2008-09-09 17:50:57
|
You are, of course, absolutely right about it breaking non-msvc. Also, since you've reminded me that all the examples are in one CMake file, you can set the property for all of the targets in one command - just place all of the targets before PROPERTIES: set_target_properties(boing splitview triangle wave PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") Branan On Tue, Sep 9, 2008 at 10:34 AM, Camilla Berglund <cam...@gm...> wrote: > Branan Riley wrote: >> IF(${CMAKE_SYSTEM_NAME} STREQUAL "Windows") >> SET_TARGET_PROPERTIES(<exename> PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") >> ENDIF(${CMAKE_SYSTEM_NAME} STREQUAL "Windows") > > That won't make GCC-based (or any other non-VS) build chains happy, though. > > How about something like: > > if(MSVC) > set_target_properties(boing PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") > set_target_properties(splitview PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") > set_target_properties(triangle PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") > set_target_properties(wave PROPERTIES LINK_FLAGS "/ENTRY:mainCRTStartup") > endif(MSVC) > > Oh, and -mno-cygwin isn't set yet. I'll fix that not today. > > Regards, > elmindreda |