1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/CMakeLists.txt Sun Dec 05 17:35:23 2010 +0100
1.3 @@ -0,0 +1,177 @@
1.4 +CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
1.5 +
1.6 +SET(PROJECT_NAME "GLPK")
1.7 +PROJECT(${PROJECT_NAME})
1.8 +
1.9 +IF(EXISTS ${PROJECT_SOURCE_DIR}/cmake/version.cmake)
1.10 + INCLUDE(${PROJECT_SOURCE_DIR}/cmake/version.cmake)
1.11 +ELSEIF(DEFINED ENV{GLPK_VERSION})
1.12 + SET(GLPK_VERSION $ENV{GLPK_VERSION} CACHE STRING "GLPK version string.")
1.13 +ELSE()
1.14 + EXECUTE_PROCESS(
1.15 + COMMAND ${PYTHON_EXECUTABLE} ./scripts/chg-len.py
1.16 + WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
1.17 + OUTPUT_VARIABLE HG_REVISION_PATH
1.18 + ERROR_QUIET
1.19 + OUTPUT_STRIP_TRAILING_WHITESPACE
1.20 + )
1.21 + EXECUTE_PROCESS(
1.22 + COMMAND hg id -i
1.23 + WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
1.24 + OUTPUT_VARIABLE HG_REVISION
1.25 + ERROR_QUIET
1.26 + OUTPUT_STRIP_TRAILING_WHITESPACE
1.27 + )
1.28 + IF(HG_REVISION STREQUAL "")
1.29 + SET(HG_REVISION_ID "hg-tip")
1.30 + ELSE()
1.31 + IF(HG_REVISION_PATH STREQUAL "")
1.32 + SET(HG_REVISION_ID ${HG_REVISION})
1.33 + ELSE()
1.34 + SET(HG_REVISION_ID ${HG_REVISION_PATH}.${HG_REVISION})
1.35 + ENDIF()
1.36 + ENDIF()
1.37 + SET(GLPK_VERSION ${HG_REVISION_ID} CACHE STRING "GLPK version string.")
1.38 +ENDIF()
1.39 +
1.40 +SET(PROJECT_VERSION ${GLPK_VERSION})
1.41 +
1.42 +SET(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)
1.43 +
1.44 +IF(DEFINED ENV{GLPK_C_WARNING})
1.45 + SET(C_WARNING $ENV{GLPK_C_WARNING})
1.46 +ELSE()
1.47 + IF(CMAKE_COMPILER_IS_GNUC)
1.48 + SET(C_WARNING "-Wall -W -Wunused -Wformat=2 -Wctor-dtor-privacy -Wnon-virtual-dtor -Wno-char-subscripts -Wwrite-strings -Wno-char-subscripts -Wreturn-type -Wcast-qual -Wcast-align -Wsign-promo -Woverloaded-virtual -ansi -fno-strict-aliasing -Wold-style-cast -Wno-unknown-pragmas")
1.49 + SET(CMAKE_C_FLAGS_DEBUG CACHE STRING "-ggdb")
1.50 + SET(CMAKE_C_FLAGS_DEBUG CACHE STRING "-ggdb")
1.51 + ELSEIF(MSVC)
1.52 + # SET(CXX_WARNING "/wd4250 /wd4355 /wd4503 /wd4800 /wd4996")
1.53 + # # suppressed warnings:
1.54 + # # C4250: 'class1' : inherits 'class2::member' via dominance
1.55 + # # C4355: 'this' : used in base member initializer list
1.56 + # # C4503: 'function' : decorated name length exceeded, name was truncated
1.57 + # # C4800: 'type' : forcing value to bool 'true' or 'false'
1.58 + # # (performance warning)
1.59 + # # C4996: 'function': was declared deprecated
1.60 + ELSE()
1.61 + SET(C_WARNING "-Wall -W")
1.62 + ENDIF()
1.63 +ENDIF()
1.64 +SET(GLPK_C_WARNING_FLAGS ${C_WARNING} CACHE STRING "GLPK warning flags.")
1.65 +
1.66 +SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${GLPK_C_WARNING_FLAGS}")
1.67 +
1.68 +SET(CMAKE_C_FLAGS_MAINTAINER "-ggdb" CACHE STRING
1.69 + "Flags used by the C compiler during maintainer builds."
1.70 + FORCE )
1.71 +SET(CMAKE_EXE_LINKER_FLAGS_MAINTAINER
1.72 + "-Wl,--warn-unresolved-symbols,--warn-once" CACHE STRING
1.73 + "Flags used for linking binaries during maintainer builds."
1.74 + FORCE )
1.75 +SET(CMAKE_SHARED_LINKER_FLAGS_MAINTAINER
1.76 + "-Wl,--warn-unresolved-symbols,--warn-once" CACHE STRING
1.77 + "Flags used by the shared libraries linker during maintainer builds."
1.78 + FORCE )
1.79 +MARK_AS_ADVANCED(
1.80 + CMAKE_C_FLAGS_MAINTAINER
1.81 + CMAKE_EXE_LINKER_FLAGS_MAINTAINER
1.82 + CMAKE_SHARED_LINKER_FLAGS_MAINTAINER )
1.83 +
1.84 +IF(CMAKE_CONFIGURATION_TYPES)
1.85 + LIST(APPEND CMAKE_CONFIGURATION_TYPES Maintainer)
1.86 + LIST(REMOVE_DUPLICATES CMAKE_CONFIGURATION_TYPES)
1.87 + SET(CMAKE_CONFIGURATION_TYPES "${CMAKE_CONFIGURATION_TYPES}" CACHE STRING
1.88 + "Add the configurations that we need"
1.89 + FORCE)
1.90 + endif()
1.91 +
1.92 +IF(NOT CMAKE_BUILD_TYPE)
1.93 + SET(CMAKE_BUILD_TYPE "Release")
1.94 +ENDIF()
1.95 +
1.96 +SET(CMAKE_BUILD_TYPE "${CMAKE_BUILD_TYPE}" CACHE STRING
1.97 + "Choose the type of build, options are: None(CMAKE_CXX_FLAGS or CMAKE_C_FLAGS used) Debug Release RelWithDebInfo MinSizeRel Maintainer."
1.98 + FORCE )
1.99 +
1.100 +
1.101 +INCLUDE(CheckTypeSize)
1.102 +CHECK_TYPE_SIZE("long long" LONG_LONG)
1.103 +SET(GLPK_HAVE_LONG_LONG ${HAVE_LONG_LONG})
1.104 +
1.105 +ENABLE_TESTING()
1.106 +
1.107 +IF(${CMAKE_BUILD_TYPE} STREQUAL "Maintainer")
1.108 + ADD_CUSTOM_TARGET(check ALL COMMAND ${CMAKE_CTEST_COMMAND})
1.109 +ELSE()
1.110 + ADD_CUSTOM_TARGET(check COMMAND ${CMAKE_CTEST_COMMAND})
1.111 +ENDIF()
1.112 +
1.113 +INCLUDE_DIRECTORIES(
1.114 + ${PROJECT_SOURCE_DIR}/include
1.115 + ${PROJECT_SOURCE_DIR}/src
1.116 +)
1.117 +
1.118 +INCLUDE(FindLATEX)
1.119 +
1.120 +ADD_SUBDIRECTORY(src)
1.121 +ADD_SUBDIRECTORY(include)
1.122 +IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR})
1.123 + ADD_SUBDIRECTORY(examples)
1.124 + ADD_SUBDIRECTORY(doc)
1.125 +ENDIF()
1.126 +
1.127 +IF(${CMAKE_SOURCE_DIR} STREQUAL ${PROJECT_SOURCE_DIR})
1.128 + SET(CPACK_PACKAGE_NAME ${PROJECT_NAME})
1.129 + SET(CPACK_PACKAGE_VENDOR "GNU")
1.130 + SET(CPACK_PACKAGE_DESCRIPTION_SUMMARY
1.131 + "GLPK - GNU Linear Programming Kit")
1.132 + SET(CPACK_RESOURCE_FILE_LICENSE "${PROJECT_SOURCE_DIR}/COPYING")
1.133 +
1.134 + SET(CPACK_PACKAGE_VERSION ${PROJECT_VERSION})
1.135 +
1.136 + SET(CPACK_PACKAGE_INSTALL_DIRECTORY
1.137 + "${PROJECT_NAME} ${PROJECT_VERSION}")
1.138 + SET(CPACK_PACKAGE_INSTALL_REGISTRY_KEY
1.139 + "${PROJECT_NAME} ${PROJECT_VERSION}")
1.140 +
1.141 + INCLUDE(CPack)
1.142 +
1.143 + CPACK_ADD_INSTALL_TYPE(Full)
1.144 +
1.145 + CPACK_ADD_COMPONENT(headers
1.146 + DISPLAY_NAME "C headers"
1.147 + DESCRIPTION "C header files"
1.148 + DEPENDS library
1.149 + INSTALL_TYPES Full
1.150 + )
1.151 + CPACK_ADD_COMPONENT(library
1.152 + DISPLAY_NAME "Libraries"
1.153 + DESCRIPTION "DLL and import library"
1.154 + INSTALL_TYPES Full
1.155 + )
1.156 +
1.157 + CPACK_ADD_COMPONENT(bin
1.158 + DISPLAY_NAME "Command line utilities"
1.159 + DESCRIPTION "Command line utilities"
1.160 + INSTALL_TYPES Full
1.161 + )
1.162 +
1.163 + SET(CPACK_GENERATOR "NSIS")
1.164 + # SET(CPACK_NSIS_MUI_ICON "${PROJECT_SOURCE_DIR}/cmake/nsis/glpk.ico")
1.165 + # SET(CPACK_NSIS_MUI_UNIICON "${PROJECT_SOURCE_DIR}/cmake/nsis/uninstall.ico")
1.166 + # #SET(CPACK_PACKAGE_ICON "${PROJECT_SOURCE_DIR}/cmake/nsis\\\\installer.bmp")
1.167 + # SET(CPACK_NSIS_INSTALLED_ICON_NAME "bin\\\\glpk.ico")
1.168 + SET(CPACK_NSIS_DISPLAY_NAME "${CPACK_PACKAGE_INSTALL_DIRECTORY}")
1.169 + SET(CPACK_NSIS_HELP_LINK "http:\\\\\\\\www.gnu.org\\\\software\\\\glpk")
1.170 + SET(CPACK_NSIS_URL_INFO_ABOUT "http:\\\\\\\\www.gnu.org\\\\software\\\\glpk")
1.171 + SET(CPACK_NSIS_CONTACT "mao@gnu.org")
1.172 + # SET(CPACK_NSIS_CREATE_ICONS_EXTRA "
1.173 + # CreateShortCut \\\"$SMPROGRAMS\\\\$STARTMENU_FOLDER\\\\Documentation.lnk\\\" \\\"$INSTDIR\\\\share\\\\doc\\\\index.html\\\"
1.174 + # ")
1.175 + # SET(CPACK_NSIS_DELETE_ICONS_EXTRA "
1.176 + # !insertmacro MUI_STARTMENU_GETFOLDER Application $MUI_TEMP
1.177 + # Delete \\\"$SMPROGRAMS\\\\$MUI_TEMP\\\\Documentation.lnk\\\"
1.178 + # ")
1.179 +
1.180 +ENDIF()
2.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2.2 +++ b/doc/CMakeLists.txt Sun Dec 05 17:35:23 2010 +0100
2.3 @@ -0,0 +1,35 @@
2.4 +IF(PDFLATEX_COMPILER)
2.5 + ADD_CUSTOM_COMMAND(OUTPUT glpk.pdf
2.6 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk.tex ${CMAKE_CURRENT_BINARY_DIR}
2.7 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk01.tex ${CMAKE_CURRENT_BINARY_DIR}
2.8 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk02.tex ${CMAKE_CURRENT_BINARY_DIR}
2.9 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk03.tex ${CMAKE_CURRENT_BINARY_DIR}
2.10 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk04.tex ${CMAKE_CURRENT_BINARY_DIR}
2.11 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk05.tex ${CMAKE_CURRENT_BINARY_DIR}
2.12 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk06.tex ${CMAKE_CURRENT_BINARY_DIR}
2.13 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk07.tex ${CMAKE_CURRENT_BINARY_DIR}
2.14 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk08.tex ${CMAKE_CURRENT_BINARY_DIR}
2.15 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk09.tex ${CMAKE_CURRENT_BINARY_DIR}
2.16 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk10.tex ${CMAKE_CURRENT_BINARY_DIR}
2.17 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk11.tex ${CMAKE_CURRENT_BINARY_DIR}
2.18 + COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_SOURCE_DIR}/glpk12.tex ${CMAKE_CURRENT_BINARY_DIR}
2.19 + COMMAND ${PDFLATEX_COMPILER} -src \\\\nonstopmode\\\\input ${CMAKE_CURRENT_BINARY_DIR}/glpk.tex
2.20 + COMMAND ${PDFLATEX_COMPILER} -src \\\\nonstopmode\\\\input ${CMAKE_CURRENT_BINARY_DIR}/glpk.tex
2.21 + MAIN_DEPENDENCY glpk.tex
2.22 + DEPENDS glpk01.tex glpk02.tex glpk03.tex glpk04.tex glpk05.tex
2.23 + glpk06.tex glpk07.tex glpk08.tex glpk09.tex glpk10.tex glpk11.tex
2.24 + glpk12.tex
2.25 + )
2.26 + ADD_CUSTOM_COMMAND(OUTPUT graphs.pdf
2.27 + COMMAND ${PDFLATEX_COMPILER} -src \\\\nonstopmode\\\\input ${CMAKE_CURRENT_SOURCE_DIR}/graphs.tex
2.28 + COMMAND ${PDFLATEX_COMPILER} -src \\\\nonstopmode\\\\input ${CMAKE_CURRENT_SOURCE_DIR}/graphs.tex
2.29 + MAIN_DEPENDENCY graphs.tex
2.30 + )
2.31 + ADD_CUSTOM_COMMAND(OUTPUT gmpl.pdf
2.32 + COMMAND ${PDFLATEX_COMPILER} -src \\\\nonstopmode\\\\input ${CMAKE_CURRENT_SOURCE_DIR}/gmpl.tex
2.33 + COMMAND ${PDFLATEX_COMPILER} -src \\\\nonstopmode\\\\input ${CMAKE_CURRENT_SOURCE_DIR}/gmpl.tex
2.34 + MAIN_DEPENDENCY gmpl.tex
2.35 + )
2.36 + ADD_CUSTOM_TARGET(pdfdoc
2.37 + DEPENDS glpk.pdf graphs.pdf gmpl.pdf)
2.38 +ENDIF()
2.39 \ No newline at end of file
3.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
3.2 +++ b/examples/CMakeLists.txt Sun Dec 05 17:35:23 2010 +0100
3.3 @@ -0,0 +1,20 @@
3.4 +ADD_EXECUTABLE(glpsol
3.5 + glpsol.c)
3.6 +
3.7 +TARGET_LINK_LIBRARIES(glpsol glpk-static)
3.8 +IF(UNIX)
3.9 + TARGET_LINK_LIBRARIES(glpsol glpk-static m)
3.10 +ENDIF()
3.11 +
3.12 +INSTALL(
3.13 + TARGETS glpsol
3.14 + RUNTIME DESTINATION bin
3.15 + COMPONENT bin
3.16 +)
3.17 +
3.18 +ADD_TEST(NAME glpsol-test-1
3.19 + COMMAND glpsol --version)
3.20 +ADD_TEST(NAME glpsol-test-2
3.21 + COMMAND glpsol --mps ${CMAKE_CURRENT_SOURCE_DIR}/plan.mps)
3.22 +ADD_DEPENDENCIES(check glpsol)
3.23 +
4.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
4.2 +++ b/include/CMakeLists.txt Sun Dec 05 17:35:23 2010 +0100
4.3 @@ -0,0 +1,4 @@
4.4 +INSTALL(FILES glpk.h
4.5 + DESTINATION include
4.6 + COMPONENT headers
4.7 +)
5.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
5.2 +++ b/scripts/chg-len.py Sun Dec 05 17:35:23 2010 +0100
5.3 @@ -0,0 +1,46 @@
5.4 +#! /usr/bin/env python
5.5 +#
5.6 +# This file is a part of LEMON, a generic C++ optimization library.
5.7 +#
5.8 +# Copyright (C) 2003-2009
5.9 +# Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport
5.10 +# (Egervary Research Group on Combinatorial Optimization, EGRES).
5.11 +#
5.12 +# Permission to use, modify and distribute this software is granted
5.13 +# provided that this copyright notice appears in all copies. For
5.14 +# precise terms see the accompanying LICENSE file.
5.15 +#
5.16 +# This software is provided "AS IS" with no warranty of any kind,
5.17 +# express or implied, and with no claim as to its suitability for any
5.18 +# purpose.
5.19 +
5.20 +import sys
5.21 +
5.22 +from mercurial import ui, hg
5.23 +from mercurial import util
5.24 +
5.25 +util.rcpath = lambda : []
5.26 +
5.27 +if len(sys.argv)>1 and sys.argv[1] in ["-h","--help"]:
5.28 + print """
5.29 +This utility just prints the length of the longest path
5.30 +in the revision graph from revison 0 to the current one.
5.31 +"""
5.32 + exit(0)
5.33 +
5.34 +u = ui.ui()
5.35 +r = hg.repository(u, ".")
5.36 +N = r.changectx(".").rev()
5.37 +lengths=[0]*(N+1)
5.38 +for i in range(N+1):
5.39 + p=r.changectx(i).parents()
5.40 + if p[0]:
5.41 + p0=lengths[p[0].rev()]
5.42 + else:
5.43 + p0=-1
5.44 + if len(p)>1 and p[1]:
5.45 + p1=lengths[p[1].rev()]
5.46 + else:
5.47 + p1=-1
5.48 + lengths[i]=max(p0,p1)+1
5.49 +print lengths[N]
6.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
6.2 +++ b/src/CMakeLists.txt Sun Dec 05 17:35:23 2010 +0100
6.3 @@ -0,0 +1,170 @@
6.4 +SET(GLPK_LIB_SOURCES
6.5 + glpapi01.c
6.6 + glpapi02.c
6.7 + glpapi03.c
6.8 + glpapi04.c
6.9 + glpapi05.c
6.10 + glpapi06.c
6.11 + glpapi07.c
6.12 + glpapi08.c
6.13 + glpapi09.c
6.14 + glpapi10.c
6.15 + glpapi11.c
6.16 + glpapi12.c
6.17 + glpapi13.c
6.18 + glpapi14.c
6.19 + glpapi15.c
6.20 + glpapi16.c
6.21 + glpapi17.c
6.22 + glpapi18.c
6.23 + glpapi19.c
6.24 + glpapi.h
6.25 + glpavl.c
6.26 + glpavl.h
6.27 + glpbfd.c
6.28 + glpbfd.h
6.29 + glpbfx.c
6.30 + glpbfx.h
6.31 + glpcpx.c
6.32 + glpdmp.c
6.33 + glpdmp.h
6.34 + glpdmx.c
6.35 + glpenv01.c
6.36 + glpenv02.c
6.37 + glpenv03.c
6.38 + glpenv04.c
6.39 + glpenv05.c
6.40 + glpenv06.c
6.41 + glpenv07.c
6.42 + glpenv08.c
6.43 + glpenv.h
6.44 + glpfhv.c
6.45 + glpfhv.h
6.46 + glpgmp.c
6.47 + glpgmp.h
6.48 + glphbm.c
6.49 + glphbm.h
6.50 + glpini01.c
6.51 + glpini02.c
6.52 + glpios01.c
6.53 + glpios02.c
6.54 + glpios03.c
6.55 + glpios04.c
6.56 + glpios05.c
6.57 + glpios06.c
6.58 + glpios07.c
6.59 + glpios08.c
6.60 + glpios09.c
6.61 + glpios10.c
6.62 + glpios11.c
6.63 + glpios12.c
6.64 + glpios.h
6.65 + glpipm.c
6.66 + glpipm.h
6.67 + glplib01.c
6.68 + glplib02.c
6.69 + glplib03.c
6.70 + glplib.h
6.71 + glplpf.c
6.72 + glplpf.h
6.73 + glplpx01.c
6.74 + glplpx02.c
6.75 + glplpx03.c
6.76 + glpluf.c
6.77 + glpluf.h
6.78 + glplux.c
6.79 + glplux.h
6.80 + glpmat.c
6.81 + glpmat.h
6.82 + glpmpl01.c
6.83 + glpmpl02.c
6.84 + glpmpl03.c
6.85 + glpmpl04.c
6.86 + glpmpl05.c
6.87 + glpmpl06.c
6.88 + glpmpl.h
6.89 + glpmps.c
6.90 + glpnet01.c
6.91 + glpnet02.c
6.92 + glpnet03.c
6.93 + glpnet04.c
6.94 + glpnet05.c
6.95 + glpnet06.c
6.96 + glpnet07.c
6.97 + glpnet08.c
6.98 + glpnet09.c
6.99 + glpnet.h
6.100 + glpnpp01.c
6.101 + glpnpp02.c
6.102 + glpnpp03.c
6.103 + glpnpp04.c
6.104 + glpnpp05.c
6.105 + glpnpp.h
6.106 + glpqmd.c
6.107 + glpqmd.h
6.108 + glprgr.c
6.109 + glprgr.h
6.110 + glprng01.c
6.111 + glprng02.c
6.112 + glprng.h
6.113 + glpscf.c
6.114 + glpscf.h
6.115 + glpscl.c
6.116 + glpsdf.c
6.117 + glpspm.c
6.118 + glpspm.h
6.119 + glpspx01.c
6.120 + glpspx02.c
6.121 + glpspx.h
6.122 + glpsql.c
6.123 + glpsql.h
6.124 + glpssx01.c
6.125 + glpssx02.c
6.126 + glpssx.h
6.127 + glpstd.h
6.128 + glptsp.c
6.129 + glptsp.h
6.130 + amd/amd_1.c
6.131 + amd/amd_2.c
6.132 + amd/amd_aat.c
6.133 + amd/amd_control.c
6.134 + amd/amd_defaults.c
6.135 + amd/amd_dump.c
6.136 + amd/amd.h
6.137 + amd/amd_info.c
6.138 + amd/amd_internal.h
6.139 + amd/amd_order.c
6.140 + amd/amd_postorder.c
6.141 + amd/amd_post_tree.c
6.142 + amd/amd_preprocess.c
6.143 + amd/amd_valid.c
6.144 + colamd/colamd.c
6.145 + colamd/colamd.h
6.146 + )
6.147 +
6.148 +IF(MSVC)
6.149 + IF(CMAKE_CL_64)
6.150 + SET(GLPK_LIB_SOURCES ${GLPK_LIB_SOURCES}
6.151 + ${PROJECT_SOURCE_DIR}/w64/glpk_4_45.def)
6.152 + ELSE()
6.153 + SET(GLPK_LIB_SOURCES ${GLPK_LIB_SOURCES}
6.154 + ${PROJECT_SOURCE_DIR}/w32/glpk_4_45.def)
6.155 + ENDIF()
6.156 +ENDIF()
6.157 +
6.158 +ADD_LIBRARY(glpk-shared SHARED ${GLPK_LIB_SOURCES})
6.159 +SET_TARGET_PROPERTIES(glpk-shared PROPERTIES OUTPUT_NAME glpk)
6.160 +ADD_LIBRARY(glpk-static STATIC ${GLPK_LIB_SOURCES})
6.161 +SET_TARGET_PROPERTIES(glpk-static PROPERTIES OUTPUT_NAME glpk)
6.162 +SET_TARGET_PROPERTIES(glpk-static PROPERTIES PREFIX "lib")
6.163 +
6.164 +SET_TARGET_PROPERTIES(glpk-shared PROPERTIES CLEAN_DIRECT_OUTPUT 1)
6.165 +SET_TARGET_PROPERTIES(glpk-static PROPERTIES CLEAN_DIRECT_OUTPUT 1)
6.166 +
6.167 +
6.168 +INSTALL(
6.169 + TARGETS glpk-shared glpk-static
6.170 + RUNTIME DESTINATION bin COMPONENT library
6.171 + ARCHIVE DESTINATION lib COMPONENT library
6.172 + LIBRARY DESTINATION lib COMPONENT library
6.173 +)