Skip to content

Commit

Permalink
add libzip submodule to source build it as static lib on all platforms
Browse files Browse the repository at this point in the history
  • Loading branch information
jcschaff committed Sep 12, 2024
1 parent 52a4e9e commit 5e8725c
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 18 deletions.
4 changes: 0 additions & 4 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ jobs:
run: |
brew install boost
brew install hdf5
brew install libzip
brew install ninja
brew install llvm
Expand All @@ -91,7 +90,6 @@ jobs:
run: |
brew install boost
brew install hdf5
brew install libzip
brew install ninja
brew install llvm
Expand Down Expand Up @@ -119,7 +117,6 @@ jobs:
mingw-w64-clang-x86_64-cmake
mingw-w64-clang-x86_64-boost
mingw-w64-clang-x86_64-hdf5
mingw-w64-clang-x86_64-libzip
mingw-w64-clang-x86_64-zlib
mingw-w64-clang-x86_64-libaec
Expand All @@ -129,7 +126,6 @@ jobs:
sudo apt-get update
sudo apt-get install -y libboost-all-dev
sudo apt-get install -y libhdf5-dev
sudo apt-get install -y libzip-dev
sudo apt-get install -y ninja-build
gcc --version
Expand Down
19 changes: 8 additions & 11 deletions .github/workflows/pip.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ jobs:
run: |
brew install boost
brew install hdf5
brew install libzip
brew install ninja
brew install llvm
Expand All @@ -57,7 +56,6 @@ jobs:
run: |
brew install boost
brew install hdf5
brew install libzip
brew install ninja
brew install llvm
Expand Down Expand Up @@ -85,7 +83,6 @@ jobs:
mingw-w64-clang-x86_64-cmake
mingw-w64-clang-x86_64-boost
mingw-w64-clang-x86_64-hdf5
mingw-w64-clang-x86_64-libzip
mingw-w64-clang-x86_64-zlib
mingw-w64-clang-x86_64-libaec
mingw-w64-clang-x86_64-python-pip-tools
Expand Down Expand Up @@ -136,9 +133,9 @@ jobs:

- name: Build and install manylinux for python 3.9
run: |
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux2014_x86_64 \
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux_2_28_x86_64 \
/bin/bash -c \
"yum install -y boost-devel hdf5-devel libzip-devel ninja-build && \
"yum install -y boost-devel hdf5-devel ninja-build && \
/opt/python/cp39-cp39/bin/pip wheel /io/ -w /io/dist && \
auditwheel repair /io/dist/*.whl -w /io/dist/"
echo "keeping only the manylinux wheels, remove those with -linux_x86_64.whl in the name"
Expand All @@ -148,9 +145,9 @@ jobs:

- name: Build and install manylinux for python 3.10
run: |
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux2014_x86_64 \
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux_2_28_x86_64 \
/bin/bash -c \
"yum install -y boost-devel hdf5-devel libzip-devel ninja-build && \
"yum install -y boost-devel hdf5-devel ninja-build && \
/opt/python/cp310-cp310/bin/pip wheel /io/ -w /io/dist && \
auditwheel repair /io/dist/*.whl -w /io/dist/"
echo "keeping only the manylinux wheels, remove those with -linux_x86_64.whl in the name"
Expand All @@ -160,9 +157,9 @@ jobs:

- name: Build and install manylinux for python 3.11
run: |
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux2014_x86_64 \
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux_2_28_x86_64 \
/bin/bash -c \
"yum install -y boost-devel hdf5-devel libzip-devel ninja-build && \
"yum install -y boost-devel hdf5-devel ninja-build && \
/opt/python/cp311-cp311/bin/pip wheel /io/ -w /io/dist && \
auditwheel repair /io/dist/*.whl -w /io/dist/"
echo "keeping only the manylinux wheels, remove those with -linux_x86_64.whl in the name"
Expand All @@ -172,9 +169,9 @@ jobs:

- name: Build and install manylinux for python 3.12
run: |
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux2014_x86_64 \
docker run --rm -v $(pwd):/io quay.io/pypa/manylinux_2_28_x86_64 \
/bin/bash -c \
"yum install -y boost-devel hdf5-devel libzip-devel ninja-build && \
"yum install -y boost-devel hdf5-devel ninja-build && \
/opt/python/cp312-cp312/bin/pip wheel /io/ -w /io/dist && \
auditwheel repair /io/dist/*.whl -w /io/dist/"
echo "keeping only the manylinux wheels, remove those with -linux_x86_64.whl in the name"
Expand Down
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,6 @@
[submodule "libzippp"]
path = libzippp
url = https://github.com/ctabin/libzippp.git
[submodule "extern/libzip"]
path = extern/libzip
url = https://github.com/nih-at/libzip.git
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,6 @@ include(GetGitRevisionDescription)
git_describe(GIT_DESCRIBE ALLOW_LOOKING_ABOVE_CMAKE_SOURCE_DIR)

include (FindZLIB)
include (FindLIBZIP)


if (NOT OPTION_TARGET_PYTHON_BINDING)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
Expand Down Expand Up @@ -201,6 +199,8 @@ add_subdirectory(VCellMessaging)

add_subdirectory(VCellZipUtils)

add_subdirectory(extern/libzip)

add_subdirectory(libzippp)

add_subdirectory(ExpressionParser)
Expand Down
2 changes: 1 addition & 1 deletion bridgeVCellSmoldyn/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ file (GLOB HEADER_FILES *.h)
file (GLOB SOURCE_FILES ${CMAKE_CURRENT_SOURCE_DIR}/*.cpp)
list(REMOVE_ITEM SOURCE_FILES ${VCELL_SMOL_MAIN})

add_library(vcellsmoldynbridge ${HEADER_FILES} ${SOURCE_FILES})
add_library(vcellsmoldynbridge STATIC ${HEADER_FILES} ${SOURCE_FILES})
target_link_libraries(vcellsmoldynbridge vcell smoldyn_static)
target_include_directories(vcellsmoldynbridge PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
target_compile_definitions(vcellsmoldynbridge PUBLIC -DVCELL_HYBRID -DVCELL -D_CRT_SECURE_NO_WARNINGS)
Expand Down
1 change: 1 addition & 0 deletions extern/libzip
Submodule libzip added at 6593c0

0 comments on commit 5e8725c

Please sign in to comment.