Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/test_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ jobs:
-DCMAKE_BUILD_TYPE=Release -DBUILD_NATIVE=OFF \
-DCMAKE_PREFIX_PATH="`brew --prefix`;`brew --prefix libffi`" \
-DCMAKE_INSTALL_PREFIX=/usr \
-DBUILD_SHARED_LIBS=ON \
--debug-trycompile

- name: Build libraries using Ninja
Expand Down
6 changes: 3 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
[submodule "M2/submodules/memtailor"]
path = M2/submodules/memtailor
url = https://github.com/Macaulay2/memtailor
url = https://github.com/passagemath/upstream-memtailor
[submodule "M2/submodules/mathic"]
path = M2/submodules/mathic
url = https://github.com/Macaulay2/mathic
url = https://github.com/passagemath/upstream-mathic
[submodule "M2/submodules/mathicgb"]
path = M2/submodules/mathicgb
url = https://github.com/Macaulay2/mathicgb
url = https://github.com/passagemath/upstream-mathicgb
[submodule "M2/submodules/bdwgc"]
path = M2/submodules/bdwgc
url = https://github.com/ivmai/bdwgc.git
Expand Down
1 change: 0 additions & 1 deletion M2/Macaulay2/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@ file(STRINGS "packages/\=distributed-packages" DISTRIBUTED_PACKAGES REGEX "^[a-z
list(JOIN DISTRIBUTED_PACKAGES " " DISTRIBUTED_PACKAGES)

# This tells CMake how to set the RPATH on the installed executable
set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/Macaulay2/lib)
set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)

# Add extra compiler warning flags for Macaulay2
Expand Down
10 changes: 4 additions & 6 deletions M2/Macaulay2/e/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -357,9 +357,8 @@ endif()
## Compile the engine
# TODO: enable INTERPROCEDURAL_OPTIMIZATION?

# TODO: remove STATIC once M2-engine can be used independently, then we can
# set -DBUILD_SHARED_LIBS=ON to generate a shared library
add_library(M2-engine STATIC ${SOURCES} ${HEADERS} ${TAGS})
# Set -DBUILD_SHARED_LIBS=ON to generate a shared library
add_library(M2-engine ${SOURCES} ${HEADERS} ${TAGS})

# TODO: Which headers should be included in the development build?
set_target_properties(M2-engine PROPERTIES PUBLIC_HEADER "${HEADERS}")
Expand All @@ -369,7 +368,7 @@ target_include_directories(M2-engine PUBLIC
$<INSTALL_INTERFACE:include/Macaulay2>)

# TODO: make engine independent of interpreter headers
target_link_libraries(M2-engine PUBLIC memtailor mathic mathicgb)
target_link_libraries(M2-engine PUBLIC memtailor mathic mathicgb M2-supervisor)

if(EIGEN3_FOUND)
target_link_libraries(M2-engine PUBLIC Eigen3::Eigen)
Expand Down Expand Up @@ -417,9 +416,8 @@ target_compile_options(M2-engine PRIVATE
###############################################################################
## Export the target

# TODO: change ARCHIVE to LIBRARY once M2-engine can be used independently
install(TARGETS M2-engine mathicgb mathic memtailor EXPORT Macaulay2
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}/Macaulay2/lib
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
COMPONENT devel EXCLUDE_FROM_ALL
PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/Macaulay2
COMPONENT devel EXCLUDE_FROM_ALL)
Expand Down
2 changes: 1 addition & 1 deletion M2/Macaulay2/system/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## entity responsible for managing Macaulay2 threads.

# TODO: m2util.hpp is not used
add_library(M2-supervisor OBJECT
add_library(M2-supervisor
supervisorinterface.h supervisor.hpp supervisor.cpp # used .. a lot
m2fileinterface.h m2file.hpp m2file.cpp # used by stdio.d
pthread-methods.hpp # used by m2file
Expand Down
2 changes: 1 addition & 1 deletion M2/submodules/mathic
Submodule mathic updated 1 files
+1 −1 src/CMakeLists.txt
2 changes: 1 addition & 1 deletion M2/submodules/mathicgb
Submodule mathicgb updated 1 files
+1 −1 src/CMakeLists.txt
2 changes: 1 addition & 1 deletion M2/submodules/memtailor
Submodule memtailor updated 1 files
+1 −1 src/CMakeLists.txt
Loading