churchyard / rpms / smoldyn

Forked from rpms/smoldyn 11 months ago
Clone

Blame smoldyn-fix_libpaths.patch

00ff2c8
--- CMakeLists.txt.fix_libpaths	2018-09-18 23:33:59.000000000 +0200
00ff2c8
+++ CMakeLists.txt	2019-02-03 19:25:01.064012276 +0100
00ff2c8
@@ -73,10 +73,7 @@
00ff2c8
 	source/lib/SFMT/SFMT.h
00ff2c8
 	source/Smoldyn/smoldyn.h
00ff2c8
 	source/Smoldyn/smoldynfuncs.h
00ff2c8
-	source/vcell/SimpleMesh.h
00ff2c8
-	source/vcell/SimpleValueProvider.h
00ff2c8
 	source/NextSubVolume/nsvc.h
00ff2c8
-	source/vtk/vtkwrapper.h
00ff2c8
 )
00ff2c8
 
00ff2c8
 set(SRC_FILES
00ff2c8
@@ -130,7 +127,7 @@
00ff2c8
 set_source_files_properties(${SRC_FILES} PROPERTIES LANGUAGE CXX )
00ff2c8
 set_source_files_properties(${MAIN_FILES} PROPERTIES LANGUAGE CXX )
00ff2c8
 
00ff2c8
-include_directories(source/lib source/Smoldyn source/vcell source/NextSubVolume source/vtk ${CMAKE_BINARY_DIR})
00ff2c8
+include_directories(source/lib source/Smoldyn source/NextSubVolume source/vtk ${CMAKE_BINARY_DIR})
00ff2c8
 
00ff2c8
 
00ff2c8
 
00ff2c8
@@ -141,8 +138,8 @@
00ff2c8
 endif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
00ff2c8
 
00ff2c8
 if(CMAKE_COMPILER_IS_GNUCXX OR COMPILER_IS_CLANGXX)
00ff2c8
-	set(CMAKE_CXX_FLAGS_DEBUG "-O0 -g -Wall -Wno-deprecated-declarations")
00ff2c8
-	set(CMAKE_CXX_FLAGS_RELEASE "-O2 -Wall  -Wno-deprecated-declarations -DNDEBUG")
00ff2c8
+	set(CMAKE_CXX_FLAGS_DEBUG "-O0 -g -Wall -I/usr/include")
00ff2c8
+	set(CMAKE_CXX_FLAGS_RELEASE "-O2 -Wall -DNDEBUG -I/usr/include")
00ff2c8
 endif(CMAKE_COMPILER_IS_GNUCXX OR COMPILER_IS_CLANGXX)
00ff2c8
 
00ff2c8
 if(NOT CMAKE_BUILD_TYPE)
00ff2c8
@@ -193,7 +190,7 @@
00ff2c8
 	set(BNG2_PATH "/usr/local/bin/BioNetGen/BNG2.pl")
00ff2c8
 else()
00ff2c8
 	set(NIX_BUILD 1)
00ff2c8
-	set(BNG2_PATH "/usr/local/bin/BioNetGen/BNG2.pl")
00ff2c8
+	set(BNG2_PATH "${PERL_VENDORLIB}/BioNetGen/BNG2.pl")
00ff2c8
 endif()
00ff2c8
 
00ff2c8
 
00ff2c8
@@ -348,7 +345,8 @@
00ff2c8
 		find_path(ZLIB_INCLUDE_DIRS zlib.h)
00ff2c8
 		find_library(ZLIB_LIBRARIES libz.a)
00ff2c8
 	else()
00ff2c8
-		include(FindZlib)
00ff2c8
+		find_path(ZLIB_INCLUDE_DIRS zlib.h PATHS ${INCLUDE_INSTALL_DIR})
00ff2c8
+		find_library(ZLIB_LIBRARIES libz.so PATHS ${CMAKE_INSTALL_LIBDIR})
00ff2c8
 	endif()
00ff2c8
 
00ff2c8
 	if(ZLIB_INCLUDE_DIRS AND ZLIB_LIBRARIES)
00ff2c8
@@ -406,7 +404,7 @@
00ff2c8
 
00ff2c8
 	list(APPEND SRC_FILES source/vtk/vtkwrapper.cpp)
00ff2c8
 	list(APPEND HEADER_FILES source/vtk/vtkwrapper.h)
00ff2c8
-	add_definitions("-Wno-deprecated")
00ff2c8
+	add_definitions(" ")
00ff2c8
 	list(APPEND DEP_LIBS ${VTK_LIBRARIES})
00ff2c8
 
00ff2c8
 endif(OPTION_VTK)
00ff2c8
@@ -430,7 +428,7 @@
00ff2c8
 	endif()
00ff2c8
 
00ff2c8
 
00ff2c8
-    set(Boost_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/source/NextSubVolume/boost_include)
00ff2c8
+    set(Boost_INCLUDE_DIR ${INCLUDE_INSTALL_DIR}/boost)
00ff2c8
     include_directories(SYSTEM ${Boost_INCLUDE_DIR})
00ff2c8
 
00ff2c8
 	list(APPEND SRC_FILES 
00ff2c8
@@ -457,7 +455,7 @@
00ff2c8
 					source/NextSubVolume/nsvc.h
00ff2c8
 					)
00ff2c8
 						
00ff2c8
-	add_definitions("-Wno-deprecated")
00ff2c8
+	add_definitions(" ")
00ff2c8
 endif(OPTION_NSV)
00ff2c8
 
00ff2c8
 ####### Option: Build with PDE ##########
00ff2c8
@@ -489,9 +487,9 @@
00ff2c8
 	endif()
00ff2c8
 
00ff2c8
 	if(OPTION_TARGET_LIBSMOLDYN)
00ff2c8
-		install(TARGETS smoldyn_shared LIBRARY DESTINATION lib)
00ff2c8
-		install(TARGETS smoldyn_static ARCHIVE DESTINATION lib)
00ff2c8
-		install(FILES source/Smoldyn/libsmoldyn.h source/Smoldyn/smoldyn.h ${CMAKE_CURRENT_BINARY_DIR}/smoldynconfigure.h DESTINATION include)
00ff2c8
+		install(TARGETS smoldyn_shared LIBRARY DESTINATION lib${LIB_SUFFIX}/smoldyn)
00ff2c8
+		install(TARGETS smoldyn_static ARCHIVE DESTINATION lib${LIB_SUFFIX}/smoldyn)
00ff2c8
+		install(FILES source/Smoldyn/libsmoldyn.h source/Smoldyn/smoldyn.h ${CMAKE_CURRENT_BINARY_DIR}/smoldynconfigure.h DESTINATION include/smoldyn)
00ff2c8
 	endif(OPTION_TARGET_LIBSMOLDYN)
00ff2c8
 
00ff2c8
 endif(NOT OPTION_MINGW)