You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
0.3.7 fails to build with PGI (versions 18.10, 19.4 and probably more) #2236
I am trying to build version 0.3.7 with PGI 19.4 (I've also tried 18.10 and it has the same problem) and it fails immediately with an "Unknown switch" error.
+ make USE_OPENMP=1 CC=pgcc CXX=pgc++ FC=pgfortran F90=pgfortran F77=pgfortran
pgcc-Error-Unknown switch: -march=native
make: *** [getarch] Error 1
Makefile.system:216: Makefile.conf: No such file or directory
make: *** No rule to make target `Makefile.conf'. Stop.
+ exit 1
I tried to debug the issue by looking at the build system and it appears that the problem has something to do with creation of Makefile.conf and config.h. For some reason, Makefile.conf is not getting created and the value of $(C_COMPILER) is wrong when it gets to line 147 of Makefile.system. Even though I'm using the PGI compiler, it still tries to use the -march=native flag even though there is a check to prevent that.
# On x86_64 build getarch with march=native. This is required to detect AVX512 support in getarch.
ifeq ($(ARCH), x86_64)
ifneq ($(C_COMPILER), PGI)
GETARCH_FLAGS += -march=native
endif
endif
Thank you! That fixes this issue. Unfortunately, PGI 19.4 fails with a different problem later on (18.10 works). I'll close this issue and open a new one to address the new problem.
You can attach full build log like with script command, that prevents long chain of further questions.
If you have an idea hot to get getarch built with PGI - share that, there is a place for #ifdef to make it permanent.
Activity
brada4 commentedon Aug 23, 2019
Try HOSTCC=cc
christopherwharrop-noaa commentedon Aug 23, 2019
Thank you! That fixes this issue. Unfortunately, PGI 19.4 fails with a different problem later on (18.10 works). I'll close this issue and open a new one to address the new problem.
brada4 commentedon Aug 23, 2019
You can attach full build log like with
scriptcommand, that prevents long chain of further questions.If you have an idea hot to get getarch built with PGI - share that, there is a place for
#ifdefto make it permanent.