Skip to content

Commit

Permalink
Update arch files
Browse files Browse the repository at this point in the history
  • Loading branch information
mkrack committed Jul 8, 2022
1 parent 2caeb6f commit efaae6c
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 12 deletions.
22 changes: 13 additions & 9 deletions arch/Linux-gnu-aarch64-static.ssmp
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
#
# CP2K (GNU aarch64) arch file for a serial static ARM64 binary
#
# Tested with: GNU 11.2.0, FFTW 3.3.10, LIBINT 2.6.0, LIBVORI 220621,
# Tested with: GNU 11.3.0, FFTW 3.3.10, LIBINT 2.6.0, LIBVORI 220621,
# LIBXC 5.2.3, OpenBLAS 0.3.20, SPGLIB 1.16.2
#
# Usage: Source this arch file and then run make as instructed.
#
# Author: Matthias Krack (23.06.2022)
# Author: Matthias Krack (08.07.2022)
#
# \
if [[ "${0}" == "${BASH_SOURCE}" ]]; then \
if [[ "${0}" == "${BASH_SOURCE}" ]]; then \
echo "ERROR: Script ${0##*/} must be sourced"; \
echo "Usage: source ${0##*/}"; \
exit 1; \
Expand All @@ -21,11 +21,10 @@
cd ../..; \
echo; \
echo "Check the output above for error messages and consistency!"; \
echo "If everything is OK, you can build a CP2K production binary with"; \
echo " make -j ARCH=${this_file%%.*} VERSION=${this_file##*.}"; \
echo "Alternatively, you can add further checks, e.g. for regression testing, with"; \
echo " make -j ARCH=${this_file%%.*} VERSION=${this_file##*.} DO_CHECKS=yes"; \
return
echo "If everything is OK, you can build a CP2K production binary with"; \
echo " make -j ARCH=${this_file%%.*} VERSION=${this_file##*.}"; \
echo "Further checks are performed, if DO_CHECKS=yes is added."; \
return

# Set options
DO_CHECKS := no
Expand Down Expand Up @@ -144,7 +143,12 @@ FCFLAGS += -ffree-line-length-none
FCFLAGS += -fno-omit-frame-pointer
FCFLAGS += -std=f2008

LDFLAGS += $(FCFLAGS) -static
# The LeakSanitizer does not work with static linking
ifeq ($(DO_CHECKS), yes)
LDFLAGS += $(FCFLAGS)
else
LDFLAGS += $(FCFLAGS) -static
endif

LIBS += -ldl -lstdc++

Expand Down
11 changes: 8 additions & 3 deletions arch/Linux-gnu-x86_64-static.ssmp
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
#
# CP2K (GNU) arch file for a serial static x86_64 binary
#
# Tested with: GNU 11.2.0, FFTW 3.3.10, LIBINT 2.6.0, LIBVORI 220621,
# Tested with: GNU 12.1.0, FFTW 3.3.10, LIBINT 2.6.0, LIBVORI 220621,
# LIBXC 5.2.3, OpenBLAS 0.3.20, SPGLIB 1.16.2
#
# Usage: Source this arch file and then run make as instructed.
# Add "generic" as argument to compile for a generic x86_64 target.
#
# Author: Matthias Krack (23.06.2022)
# Author: Matthias Krack (08.07.2022)
#
# \
if [[ "${0}" == "${BASH_SOURCE}" ]]; then \
Expand Down Expand Up @@ -158,7 +158,12 @@ FCFLAGS += -ffree-line-length-none
FCFLAGS += -fno-omit-frame-pointer
FCFLAGS += -std=f2008

LDFLAGS += $(FCFLAGS) -static
# The LeakSanitizer does not work with static linking
ifeq ($(DO_CHECKS), yes)
LDFLAGS += $(FCFLAGS)
else
LDFLAGS += $(FCFLAGS) -static
endif

LIBS += -ldl -lstdc++

Expand Down

0 comments on commit efaae6c

Please sign in to comment.