From: Greg J. <gv...@gm...> - 2015-07-15 21:24:12
|
Here is the "trully vanilla" results. No additional library paths are involved (not even /mingw32/lib). To get the mingw32/lib in in a clean fashion I suggest the following lines in the if(MINGW) ... endif(): # We need the path to the MinGW/Borland compiler in order to find # the import libraries for system libraries. if(MINGW) unset(MINGWPATH) get_filename_component(MINGWBINPATH ${CMAKE_C_COMPILER} PATH) message(STATUS " MINGWBINPATH = ${MINGWBINPATH}") find_path( MINGWPATH lib PATHS ${MINGWBINPATH}/../ NO_DEFAULT_PATH) set(MINGWLIBPATH ${MINGWPATH}/lib CACHE FILEPATH DOCSTRING "Path to MinGW import libraries") list( APPEND CMAKE_LIBRARY_PATH ${MINGWPATH}/lib) list( APPEND CMAKE_INCLUDE_PATH ${CMAKE_INCLUDE_PATH};${MINGWPATH}/include) list(REMOVE_DUPLICATES CMAKE_LIBRARY_PATH) list(REMOVE_DUPLICATES CMAKE_INCLUDE_PATH) endif(MINGW) On Tue, Jul 14, 2015 at 3:03 PM, Alan W. Irwin <ir...@be...> wrote: > I just now finally found what appear to be definitive CMake > instructions (see > <http://www.openwalnut.org/projects/openwalnut/wiki/InstallMSYS2>) for > the MinGW-w64/MSYS2 platform (only the "vanilla" version as defined by > the <sf.net/projects/msys2> wiki rather than some "fixed" version) > which I think will interest all those here who are planning to test > that platform. The essential points are you should be using the "Unix > Makefiles" generator for the MSYS2 version of CMake for that platform. > > To expand the last point in more detail you should do the following two > steps. > > 1. Install the MSYS2 version of CMake and other essential > software, i.e., > > pacman -S mingw-w64-x86_64-cmake mingw-w64-x86_64-extra-cmake-modules > make pkg-config grep sed gzip tar openssh ... > > 2. "Important: to use packages that are pre-fixed with "mingw" in > their name, you need to start a mingw shell. In your Start menu, you > will find entries "MinGW-w64 Win64 Shell". ALWAYS start this shell in > the future." > > I believe these two steps are important for CMake; the closely related > Cygwin software demands you use a Cygwin version of CMake so it makes > sense there is a similar requirement that the MSYS2 platform demands > you use a MSYS2 version of CMake. > > Arjen's current test of MinGW-w64/MSYS2 uses the (incorrect) "MSYS > Makefiles" generator for that platform and also may not be using the > correct MSYS2 version of CMake. So it will be interesting to see (the > next time he has a chance to run the test which will probably be > several weeks from now) how his results change once he moves to the > recommended "Unix Makefiles" generator and the MSYS2 version of CMake. > > Meanwhile, because the popularity of the MinGW-w64/MSYS2 platform is > already large and still rising rapidly, I strongly encourage others > here with access to the vanilla version of that platform to try > comprehensive testing of that platform using the generator and cmake > version recommended by the OpenWalnut software project. > > Alan > __________________________ > Alan W. Irwin > > Astronomical research affiliation with Department of Physics and Astronomy, > University of Victoria (astrowww.phys.uvic.ca). > > Programming affiliations with the FreeEOS equation-of-state > implementation for stellar interiors (freeeos.sf.net); the Time > Ephemerides project (timeephem.sf.net); PLplot scientific plotting > software package (plplot.sf.net); the libLASi project > (unifont.org/lasi); the Loads of Linux Links project (loll.sf.net); > and the Linux Brochure Project (lbproject.sf.net). > __________________________ > > Linux-powered Science > __________________________ > > > ------------------------------------------------------------------------------ > Don't Limit Your Business. Reach for the Cloud. > GigeNET's Cloud Solutions provide you with the tools and support that > you need to offload your IT needs and focus on growing your business. > Configured For All Businesses. Start Your Cloud Today. > https://www.gigenetcloud.com/ > _______________________________________________ > Plplot-devel mailing list > Plp...@li... > https://lists.sourceforge.net/lists/listinfo/plplot-devel > |