rougier / freetype-gl

OpenGL text using one vertex buffer, one texture and FreeType
Other
1.65k stars 266 forks source link

Visual Studio 2015 - problem with GLFW & CMake (urgent help pls) #108

Closed demoaces closed 7 years ago

demoaces commented 8 years ago

Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) CMake Error at demos/CMakeLists.txt:64 (find_package): By not providing "Findglfw3.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "glfw3", but CMake did not find one.

Could not find a package configuration file provided by "glfw3" with any of the following names:

glfw3Config.cmake
glfw3-config.cmake

Add the installation prefix of "glfw3" to CMAKE_PREFIX_PATH or set "glfw3_DIR" to a directory containing one of the above files. If "glfw3" provides a separate development package or SDK, be sure it has been installed.

Please help urgently - we're running academic project & would like to use Your lib since seems to perfectly fit our needs.

best regards Rafal

rougier commented 8 years ago

What is your system ? Did you check issue #94 ? You might find some solution in this issue.

wmamrak commented 8 years ago

Hi,

you need to provide the following cache entries (case sensitive) to the CMake: glfw3_DIR -> pointing to the location of where glfw3Config.cmake resides GLFW3_INCLUDE_DIR -> pointing to GLFW's include dir GLFW3_LIBRARY_DIR -> pointing to GLFW's lib dir GLFW3_LIBRARY -> glfw3dll.lib

But I guess GLFW is only needed for demos, so you can simply unset entry freetype-gl_BUILD_DEMOS.

demoaces commented 8 years ago

Thanks for replies. I'm using MS Windows. Sorry for stupid question but how can I make cache entries - do I need manually edit CMakeList.txt or something else?

demoaces commented 8 years ago

And yes I want to compile demos in oder to learn the library.

demoaces commented 8 years ago

btw. where glfw3Config.cmake resides?

wmamrak commented 8 years ago

How you define entries depends whether you are using command line tool or CMake GUI. Using GUI is straightforward, and here is the description of CLI tool: https://cmake.org/cmake/help/v3.5/manual/cmake.1.html glfwConfig.cmake should be in a directory specified by CMAKE_INSTALL_PREFIX (again, you can set it to whatever directory you want) after compiling and installing GLFW.

jshamble commented 8 years ago

Try this: place the attached file in the CMakeModules directory.

findglfw3.txt

Rename it from findglfw3.txt to findglfw3.cmake

You will need to replace the strings

"C:/opengl-wrappers/glfw/lib-vc2015". and "C:/opengl-wrappers/glfw/include"

with the location of your glfw3 libs and includes.