diff options
Diffstat (limited to 'sci-libs/libsc/files')
4 files changed, 129 insertions, 57 deletions
diff --git a/sci-libs/libsc/files/libsc-2.8.3-fix_build_system.patch b/sci-libs/libsc/files/libsc-2.8.3-fix_build_system.patch new file mode 100644 index 000000000000..b5bdc734ab55 --- /dev/null +++ b/sci-libs/libsc/files/libsc-2.8.3-fix_build_system.patch @@ -0,0 +1,41 @@ +https://github.com/cburstedde/libsc/pull/54 +https://github.com/cburstedde/libsc/pull/55 + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 2ce08e2..a588beb 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -8,6 +8,8 @@ HOMEPAGE_URL https://www.p4est.org/ + DESCRIPTION "The SC library supports parallel scientific applications." + VERSION ${PROJECT_VERSION}) + ++set(CMAKE_POSITION_INDEPENDENT_CODE ON) ++ + include(CTest) + + include(cmake/options.cmake) +@@ -28,8 +30,7 @@ if(MPI_FOUND) + endif() + + # --- libb64 +-add_library(libb64 OBJECT libb64/cencode.c libb64/cdecode.c +- libb64/b64dec.c libb64/b64enc.c) ++add_library(libb64 OBJECT libb64/cencode.c libb64/cdecode.c) + target_include_directories(libb64 PRIVATE libb64) + + # --- sc +diff --git a/CMakeLists.txt b/CMakeLists.txt +index a588beb..aff0eca 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -64,8 +64,8 @@ install(DIRECTORY ${PROJECT_SOURCE_DIR}/src/ ${PROJECT_SOURCE_DIR}/src/sc_builti + + install(TARGETS sc + EXPORT ${PROJECT_NAME}Targets +- ARCHIVE DESTINATION lib +- LIBRARY DESTINATION lib) ++ ARCHIVE DESTINATION ${library_reldir} ++ LIBRARY DESTINATION ${library_reldir}) + + add_subdirectory(src) + diff --git a/sci-libs/libsc/files/libsc-2.8.3-set_version.patch b/sci-libs/libsc/files/libsc-2.8.3-set_version.patch new file mode 100644 index 000000000000..dcd63994cc67 --- /dev/null +++ b/sci-libs/libsc/files/libsc-2.8.3-set_version.patch @@ -0,0 +1,44 @@ +diff --git a/cmake/git.cmake b/cmake/git.cmake +index dd6009e..7c5c8f3 100644 +--- a/cmake/git.cmake ++++ b/cmake/git.cmake +@@ -1,36 +1,3 @@ + # --- extract version from Git + +-set(PROJECT_VERSION 0.0.0) +-find_program(GIT_VERSION_GEN NAMES git-version-gen +- PATHS ${CMAKE_SOURCE_DIR}/build-aux NO_DEFAULT_PATH) +-if(GIT_VERSION_GEN) +- execute_process(COMMAND ${GIT_VERSION_GEN} .tarball_version +- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} +- RESULT_VARIABLE _err +- OUTPUT_VARIABLE git_version +- OUTPUT_STRIP_TRAILING_WHITESPACE) +-endif() +-if(_err EQUAL 0) +- if(git_version MATCHES +- "^(0|[1-9][0-9]*)[.](0|[1-9][0-9]*)[.](0|[1-9][0-9]*)[.].*") +- set(_major "${CMAKE_MATCH_1}") +- set(_minor "${CMAKE_MATCH_2}") +- set(_patch "${CMAKE_MATCH_3}") +- set(PROJECT_VERSION ${_major}.${_minor}.${_patch}.999) +- elseif(git_version MATCHES +- "^(0|[1-9][0-9]*)[.](0|[1-9][0-9]*)[.](0|[1-9][0-9]*)") +- set(_major "${CMAKE_MATCH_1}") +- set(_minor "${CMAKE_MATCH_2}") +- set(_patch "${CMAKE_MATCH_3}") +- set(PROJECT_VERSION ${_major}.${_minor}.${_patch}) +- elseif(git_version MATCHES +- "^(0|[1-9][0-9]*)[.](0|[1-9][0-9]*)") +- set(_major "${CMAKE_MATCH_1}") +- set(_minor "${CMAKE_MATCH_2}") +- set(PROJECT_VERSION ${_major}.${_minor}) +- elseif(git_version MATCHES +- "^(0|[1-9][0-9]*)") +- set(_major "${CMAKE_MATCH_1}") +- set(PROJECT_VERSION ${_major}) +- endif() +-endif() ++set(PROJECT_VERSION 2.8.3) + + diff --git a/sci-libs/libsc/files/libsc-9999-set_version.patch b/sci-libs/libsc/files/libsc-9999-set_version.patch new file mode 100644 index 000000000000..0820b001d8cd --- /dev/null +++ b/sci-libs/libsc/files/libsc-9999-set_version.patch @@ -0,0 +1,44 @@ +diff --git a/cmake/git.cmake b/cmake/git.cmake +index dd6009e..7c5c8f3 100644 +--- a/cmake/git.cmake ++++ b/cmake/git.cmake +@@ -1,36 +1,3 @@ + # --- extract version from Git + +-set(PROJECT_VERSION 0.0.0) +-find_program(GIT_VERSION_GEN NAMES git-version-gen +- PATHS ${CMAKE_SOURCE_DIR}/build-aux NO_DEFAULT_PATH) +-if(GIT_VERSION_GEN) +- execute_process(COMMAND ${GIT_VERSION_GEN} .tarball_version +- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} +- RESULT_VARIABLE _err +- OUTPUT_VARIABLE git_version +- OUTPUT_STRIP_TRAILING_WHITESPACE) +-endif() +-if(_err EQUAL 0) +- if(git_version MATCHES +- "^(0|[1-9][0-9]*)[.](0|[1-9][0-9]*)[.](0|[1-9][0-9]*)[.].*") +- set(_major "${CMAKE_MATCH_1}") +- set(_minor "${CMAKE_MATCH_2}") +- set(_patch "${CMAKE_MATCH_3}") +- set(PROJECT_VERSION ${_major}.${_minor}.${_patch}.999) +- elseif(git_version MATCHES +- "^(0|[1-9][0-9]*)[.](0|[1-9][0-9]*)[.](0|[1-9][0-9]*)") +- set(_major "${CMAKE_MATCH_1}") +- set(_minor "${CMAKE_MATCH_2}") +- set(_patch "${CMAKE_MATCH_3}") +- set(PROJECT_VERSION ${_major}.${_minor}.${_patch}) +- elseif(git_version MATCHES +- "^(0|[1-9][0-9]*)[.](0|[1-9][0-9]*)") +- set(_major "${CMAKE_MATCH_1}") +- set(_minor "${CMAKE_MATCH_2}") +- set(PROJECT_VERSION ${_major}.${_minor}) +- elseif(git_version MATCHES +- "^(0|[1-9][0-9]*)") +- set(_major "${CMAKE_MATCH_1}") +- set(PROJECT_VERSION ${_major}) +- endif() +-endif() ++set(PROJECT_VERSION 9999.0.0) + + diff --git a/sci-libs/libsc/files/libsc-9999_20201220-autoconf_lua_version.patch b/sci-libs/libsc/files/libsc-9999_20201220-autoconf_lua_version.patch deleted file mode 100644 index c138bb3fc4ba..000000000000 --- a/sci-libs/libsc/files/libsc-9999_20201220-autoconf_lua_version.patch +++ /dev/null @@ -1,57 +0,0 @@ ---- a/config/sc_include.m4 -+++ b/config/sc_include.m4 -@@ -281,7 +281,7 @@ AC_DEFUN([SC_CHECK_LIBRARIES], - [ - SC_REQUIRE_LIB([m], [fabs]) - SC_CHECK_LIB([z], [adler32_combine], [ZLIB], [$1]) --SC_CHECK_LIB([lua53 lua5.3 lua52 lua5.2 lua51 lua5.1 lua lua5], [lua_createtable], -+SC_CHECK_LIB([$LUA_IMPL], [lua_createtable], - [LUA], [$1]) - SC_CHECK_BLAS_LAPACK([$1]) - SC_BUILTIN_ALL_PREFIX([$1]) ---- a/configure.ac -+++ b/configure.ac -@@ -74,7 +74,7 @@ echo "| Checking headers" - echo "o---------------------------------------" - - AC_CHECK_HEADERS([execinfo.h signal.h sys/time.h sys/types.h time.h]) --AC_CHECK_HEADERS([lua.h lua5.1/lua.h lua5.2/lua.h lua5.3/lua.h]) -+AC_CHECK_HEADERS([$LUA_IMPL/lua.h]) - - echo "o---------------------------------------" - echo "| Checking functions" ---- a/src/sc_lua.h -+++ b/src/sc_lua.h -@@ -30,29 +30,9 @@ - - SC_EXTERN_C_BEGIN; - --#ifdef SC_HAVE_LUA5_3_LUA_H --#include <lua5.3/lua.h> --#include <lua5.3/lualib.h> --#include <lua5.3/lauxlib.h> --#else --#ifdef SC_HAVE_LUA5_2_LUA_H --#include <lua5.2/lua.h> --#include <lua5.2/lualib.h> --#include <lua5.2/lauxlib.h> --#else --#ifdef SC_HAVE_LUA5_1_LUA_H --#include <lua5.1/lua.h> --#include <lua5.1/lualib.h> --#include <lua5.1/lauxlib.h> --#else --#ifdef SC_HAVE_LUA_H --#include <lua.h> --#include <lualib.h> --#include <lauxlib.h> --#endif --#endif --#endif --#endif -+#include <@LUA_IMPL@/lua.h> -+#include <@LUA_IMPL@/lualib.h> -+#include <@LUA_IMPL@/lauxlib.h> - - SC_EXTERN_C_END; - |