Skip to content
Snippets Groups Projects
Commit 1df75787 authored by Peter W. Draper's avatar Peter W. Draper
Browse files

Use OPT_CFLAGS as optimizations are no longer in CFLAGS

parent 49cc96df
No related branches found
No related tags found
1 merge request!1763Draft: Add ICC Milan optimization and change AMD architecture to corei7-avx.
......@@ -38,7 +38,7 @@ MYFLAGS =
# Add the source directory and the non-standard paths to the included library headers to CFLAGS
AM_CFLAGS = -I$(top_srcdir)/src -I$(top_srcdir)/argparse $(HDF5_CPPFLAGS) \
$(GSL_INCS) $(FFTW_INCS) $(NUMA_INCS) $(GRACKLE_INCS) $(OPENMP_CFLAGS) \
$(CHEALPIX_CFLAGS)
$(CHEALPIX_CFLAGS) $(OPT_CFLAGS)
AM_LDFLAGS = $(HDF5_LDFLAGS)
......
......@@ -22,7 +22,7 @@ AM_SOURCES = argparse.c
# Sources and flags for regular library
libargparse_la_SOURCES = $(AM_SOURCES)
libargparse_la_CFLAGS = $(AM_CFLAGS)
libargparse_la_CFLAGS = $(AM_CFLAGS) $(OPT_CFLAGS)
libargparse_la_LDFLAGS = $(AM_LDFLAGS)
EXTRA_DIST = LICENSE README.md
......@@ -576,8 +576,9 @@ if test "$enable_opt" = "yes" ; then
# Choose the best flags for this compiler and architecture
ac_test_CFLAGS="no"
AX_CC_MAXOPT
AX_CC_MAXOPT_SWIFT
ac_test_CFLAGS="yes"
AC_ARG_VAR([OPT_CFLAGS], [C compiler flags added to the basic CFLAGS for good optimization])
# Choose the best flags for the gravity sub-library on this compiler and architecture
if test "$ax_cv_c_compiler_vendor" = "intel"; then
......@@ -3003,7 +3004,7 @@ AC_MSG_RESULT([
Compiler : $CC
- vendor : $ax_cv_c_compiler_vendor
- version : $ax_cv_c_compiler_version
- flags : $CFLAGS $OPENMP_CFLAGS
- flags : $OPT_CFLAGS $CFLAGS $OPENMP_CFLAGS
MPI enabled : $enable_mpi
HDF5 enabled : $with_hdf5
- parallel : $have_parallel_hdf5
......
......@@ -15,7 +15,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# Add the source directory and the non-standard paths to the included library headers to CFLAGS
AM_CFLAGS = -I$(top_srcdir)/src -I$(top_builddir)/examples $(HDF5_CPPFLAGS) $(GSL_INCS) $(FFTW_INCS) $(NUMA_INCS) $(OPENMP_CFLAGS) $(CHEALPIX_CFLAGS)
AM_CFLAGS = -I$(top_srcdir)/src -I$(top_builddir)/examples $(HDF5_CPPFLAGS) $(GSL_INCS) $(FFTW_INCS) $(NUMA_INCS) $(OPENMP_CFLAGS) $(CHEALPIX_CFLAGS) $(OPT_CFLAGS)
AM_LDFLAGS = $(HDF5_LDFLAGS) $(HDF5_LIBS) $(FFTW_LIBS) $(NUMA_LIBS) $(TCMALLOC_LIBS) $(JEMALLOC_LIBS) $(TBBMALLOC_LIBS) $(GRACKLE_LIBS) $(GSL_LIBS) $(PROFILER_LIBS)
......
......@@ -16,7 +16,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# Add the non-standard paths to the included library headers
AM_CFLAGS = $(HDF5_CPPFLAGS) $(GSL_INCS) $(FFTW_INCS) $(NUMA_INCS) $(GRACKLE_INCS) $(SUNDIALS_INCS) $(OPENMP_CFLAGS) $(CHEALPIX_CFLAGS)
AM_CFLAGS = $(HDF5_CPPFLAGS) $(GSL_INCS) $(FFTW_INCS) $(NUMA_INCS) $(GRACKLE_INCS) $(SUNDIALS_INCS) $(OPENMP_CFLAGS) $(CHEALPIX_CFLAGS) $(OPT_CFLAGS)
# Assign a "safe" version number
AM_LDFLAGS = $(HDF5_LDFLAGS) $(FFTW_LIBS)
......@@ -528,14 +528,14 @@ version_string.h: version_string.h.in Makefile $(AM_SOURCES) $(include_HEADERS)
-e "s,@GIT_REVISION\@,$${GIT_REVISION}," \
-e "s|@GIT_BRANCH\@|$${GIT_BRANCH}|" \
-e "s|@GIT_DATE\@|$${GIT_DATE}|" \
-e "s|@SWIFT_CFLAGS\@|$(CFLAGS)|" $< > version_string.h; \
-e "s|@SWIFT_CFLAGS\@|$(OPT_CFLAGS) $(CFLAGS)|" $< > version_string.h; \
else \
if test ! -f version_string.h; then \
sed -e "s,@PACKAGE_VERSION\@,$(PACKAGE_VERSION)," \
-e "s,@GIT_REVISION\@,unknown," \
-e "s,@GIT_BRANCH\@,unknown," \
-e "s,@GIT_DATE\@,unknown," \
-e "s|@SWIFT_CFLAGS\@|$(CFLAGS)|" $< > version_string.h; \
-e "s|@SWIFT_CFLAGS\@|$(OPT_CFLAGS) $(CFLAGS)|" $< > version_string.h; \
fi; \
fi
......
......@@ -15,7 +15,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# Add the source directory and the non-standard paths to the included library headers to CFLAGS
AM_CFLAGS = -I$(top_srcdir)/src $(HDF5_CPPFLAGS) $(GSL_INCS) $(FFTW_INCS) $(NUMA_INCS) $(OPENMP_CFLAGS) $(CHEALPIX_CFLAGS)
AM_CFLAGS = -I$(top_srcdir)/src $(HDF5_CPPFLAGS) $(GSL_INCS) $(FFTW_INCS) $(NUMA_INCS) $(OPENMP_CFLAGS) $(CHEALPIX_CFLAGS) $(OPT_CFLAGS)
AM_LDFLAGS = ../src/.libs/libswiftsim.a $(HDF5_LDFLAGS) $(HDF5_LIBS) $(FFTW_LIBS) $(NUMA_LIBS) $(TCMALLOC_LIBS) $(JEMALLOC_LIBS) $(TBBMALLOC_LIBS) $(GRACKLE_LIBS) $(GSL_LIBS) $(PROFILER_LIBS) $(CHEALPIX_LIBS)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment