Building on Windows from Command Line

338 views
Skip to first unread message

Christian Henning

unread,
Jan 8, 2016, 12:56:28 AM1/8/16
to MathGL
Hi there, 

I get MathGL to be build via cmake-gui but I have issues from the command line. Here is what I'm doing:

1. open command line with Visual Studio x64 tools loaded
2. remove CMakeFiles folder in my mathgl folder
3. Run the following command line

cmake "-DZLIB_INCLUDE_DIR=c:\users\chenning\projects\zlib-1.2.8\" "-DZLIB_LIBRARY=c:\users\chenning\projects\zlib-1.2.8\zlib.lib" "-DPNG_PNG_INCLUDE_DIR=C:\Users\chenning\projects\lpng1620\" "-DPNG_LIBRARY_DEBUG=C:\Users\chenning\projects\lpng1620\projects\vstudio\x64\Debug\libpng16.lib" "-DPNG_LIBRARY_Release=C:\Users\chenning\projects\lpng1620\projects\vstudio\x64\Release\libpng16.lib" .


cmake returns:


-- The C compiler identification is MSVC 18.0.31101.0
-- The CXX compiler identification is MSVC 18.0.31101.0
-- Check for working C compiler using: Visual Studio 12 2013
-- Check for working C compiler using: Visual Studio 12 2013 -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler using: Visual Studio 12 2013
-- Check for working CXX compiler using: Visual Studio 12 2013 -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Could NOT find ZLIB (missing:  ZLIB_LIBRARY)
CMake Error at CMakeLists.txt:328 (message):
  Couldn't find ZLib library.


-- Could NOT find ZLIB (missing:  ZLIB_LIBRARY)
-- Could NOT find PNG (missing:  PNG_LIBRARY PNG_PNG_INCLUDE_DIR)
CMake Error at CMakeLists.txt:341 (message):
  Couldn't find PNG library.


CMake Error: The following variables are used in this project, but they are set
to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake file
s:
ZLIB_LIBRARY (ADVANCED)
    linked by target "mgl" in directory C:/Users/chenning/projects/mathgl-2.3.3/
src

-- Configuring incomplete, errors occurred!
See also "C:/Users/chenning/projects/mathgl-2.3.3/CMakeFiles/CMakeOutput.log".

I have double checked the path and made sure all files exist.

Anyone knows what's wrong here?

Thanks,
Christian





Alexey Balakin

unread,
Jan 8, 2016, 1:15:47 AM1/8/16
to mat...@googlegroups.com
Dear Christian,

I think that the simplest solution is the use of cmake-gui (see https://cmake.org/runningcmake/ ) to resolve all error messages.

06.01.2016 22:19, Christian Henning пишет:
--
You received this message because you are subscribed to the Google Groups "MathGL" group.
To unsubscribe from this group and stop receiving emails from it, send an email to mathgl+un...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


-- 
Kind regards,
Alexey Balakin
Reply all
Reply to author
Forward
0 new messages