[CMake] newbie FindRuby.cmake win7
Rolf Eike Beer
eike at sf-mail.de
Wed Jan 2 18:25:52 EST 2013
dario.minonne wrote:
> Hi all,
> many apologizes for the newbie question but I've a small issue with cmake
> 2.8.10.2 and ruby 1.91 on Windows7
> I'd like create a simple binder between C++ and ruby but cmake is not able
> to find the library:
>
> Here is my short CMakeLists.txt
>
> cmake_minimum_required(VERSION 2.8)
> project(extRubyCmake)
>
> SET(_RUBY_DEBUG_OUTPUT TRUE)
>
> find_package( Ruby REQUIRED )
>
> MESSAGE(STATUS "Ruby executable: ${RUBY_EXECUTABLE}")
> MESSAGE(STATUS "Ruby vendor arch dir: ${RUBY_VENDORARCH_DIR}")
> MESSAGE(STATUS "Ruby include path: ${RUBY_INCLUDE_PATH}")
>
> include_directories(${RUBY_INCLUDE_DIRS})
>
> FILE(GLOB DOT_CPP ${CMAKE_CURRENT_SOURCE_DIR}/src/*.cpp)
> FILE(GLOB DOT_H ${CMAKE_CURRENT_SOURCE_DIR}/src/*.h)
> INCLUDE_DIRECTORIES(AFTER SYSTEM ${CMAKE_CURRENT_SOURCE_DIR}/src)
> add_library(extRubyCmake ${DOT_CPP} ${DOT_H})
Has nothing to do with your question, but: don't use file(GLOB) for project
sources. See the documentation why this is a bad idea.
> RUBY_LIBRARY: RUBY_LIBRARY-NOTFOUND
Please look into the library dir for the .lib file and tell us it's name, then
we may get a clue why this is not working. Until it is fixed you can go to your
build dir and do
cmake -D RUBY_LIBRARY=c:/ruby/193/foo/bar/baz.lib .
Eike
--
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://www.cmake.org/pipermail/cmake/attachments/20130103/80ce6343/attachment.pgp>
More information about the CMake
mailing list