forked from Macaulay2/M2
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'origin/development' into complexes-pr-3
# Conflicts: # M2/Macaulay2/packages/PencilsOfQuadrics.m2
- Loading branch information
Showing
182 changed files
with
10,588 additions
and
6,504 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
GNUmakefile | ||
Makefile | ||
Macaulay2 | ||
check-configure | ||
config.args | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,33 @@ | ||
include ../ubuntu/Makefile | ||
|
||
## Parameters | ||
TAG = m2-fedora-build | ||
RELEASE = latest | ||
BUILD_ARGS = --build-arg RELEASE=$(RELEASE) | ||
TAG = m2-fedora-$(RELEASE)-build | ||
BUILD_DIR = M2/BUILD/build-docker | ||
BUILD_OPT = -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr | ||
|
||
rpm:; docker run $(VOLUME) -it --entrypoint "" $(TAG) bash -c "cd M2/$(BUILD_DIR); cpack -G RPM" | ||
|
||
rpmlint:; docker run $(VOLUME) -it --entrypoint "" $(TAG) bash -c "rpmlint M2/$(BUILD_DIR)/Macaulay2-*.rpm" | ||
|
||
## autotools build | ||
## TODO: generalize this to other distros, move to toplevel Makefile | ||
|
||
CONFIG_OPT = --with-system-gc --with-system-memtailor --with-system-mathic \ | ||
--with-system-mathicgb --enable-download --enable-rpm --prefix=/usr | ||
|
||
define M2_BUILD_SCRIPT_autotools | ||
set -xe | ||
|
||
mkdir -p M2/$(BUILD_DIR) | ||
cd M2/$(BUILD_DIR) | ||
$(M2_HOME)/M2/M2/autogen.sh | ||
$(M2_HOME)/M2/M2/configure $(CONFIG_OPT) | ||
make | ||
endef | ||
export M2_BUILD_SCRIPT_autotools | ||
|
||
build-autotools: build-image | ||
docker run $(VOLUME) -it --entrypoint="" $(TAG) \ | ||
bash -c "$$M2_BUILD_SCRIPT_autotools" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
ARG DISTRIBUTION=rockylinux | ||
ARG RELEASE=9 | ||
|
||
FROM $DISTRIBUTION:$RELEASE | ||
ARG RELEASE | ||
|
||
# Configure EPEL | ||
RUN dnf install -y 'dnf-command(config-manager)' && \ | ||
if [ $RELEASE = 8 ]; \ | ||
then \ | ||
dnf config-manager --set-enabled powertools; \ | ||
else \ | ||
dnf config-manager --set-enabled crb; \ | ||
fi && \ | ||
dnf install -y epel-release | ||
|
||
# Install dependencies | ||
RUN dnf -y install autoconf automake bison boost-devel bzip2 cmake \ | ||
diffutils eigen3 flex gc-devel gcc-c++ gcc-gfortran gdbm-devel git \ | ||
glpk-devel gmp-devel lapack-devel libffi-devel libtool \ | ||
libxml2-devel make mpfr-devel ncurses-devel openblas-devel patch \ | ||
python3-devel R readline-devel rpm-build tbb-devel which xz-devel \ | ||
zlib-devel | ||
|
||
WORKDIR /home/macaulay |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
include ../Makefile | ||
|
||
## Parameters | ||
DISTRIBUTION = rockylinux | ||
RELEASE = 9 | ||
BUILD = autotools | ||
BUILD_ARGS = --build-arg DISTRIBUTION=$(DISTRIBUTION) \ | ||
--build-arg RELEASE=$(RELEASE) | ||
TAG = m2-$(BUILD)-$(DISTRIBUTION)-$(RELEASE)-build | ||
BUILD_DIR = M2/BUILD/build-docker | ||
|
||
## Script for building Macaulay2 (autotools) | ||
define M2_BUILD_SCRIPT_autotools | ||
set -xe | ||
|
||
git config --global --add safe.directory $(M2_HOME)/M2 | ||
mkdir -p M2/$(BUILD_DIR) | ||
cd M2/$(BUILD_DIR) | ||
$(M2_HOME)/M2/M2/autogen.sh | ||
$(M2_HOME)/M2/M2/configure --with-system-gc --enable-download --enable-rpm \ | ||
--prefix=/usr | ||
make | ||
endef | ||
export M2_BUILD_SCRIPT_autotools | ||
|
||
############################################################################### | ||
# Build targets | ||
|
||
build: build-image | ||
docker run $(VOLUME) -it --entrypoint="" $(TAG) \ | ||
bash -c "$$M2_BUILD_SCRIPT_$(BUILD)" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Compiling Macaulay2 in a Red Hat Enterprise Linux-compatible Container | ||
|
||
The `Dockerfile` in this directory creates a container image based a Red Hat Enterprise Linux-compatible distribution (either Rocky Linux or AlmaLInux) with all the required libraries and software for compiling Macaulay2. | ||
|
||
## Getting Started | ||
0. Install Docker and start the daemon. | ||
|
||
1. Compile Macaulay2 in a container: | ||
``` | ||
make build | ||
``` | ||
|
||
After the build is complete, rpm packages will be available in `M2/BUILD/build-docker`. | ||
|
||
2. Run Macaulay2: | ||
``` | ||
make run | ||
``` | ||
|
||
By default, the above targets are run on Rocky Linux 9. To switch to AlmaLinux, add `DISTRIBUTION=almalinux`. To switch to an RHEL 8-compatible release, add `RELEASE=8`. |
Oops, something went wrong.