Open shoubhikraj opened 3 years ago
Thank you for this instruction.
option_with_flags(ENABLE_XHOST "Enable processor-specific optimization" ON "-QxHost")
Please, provide this change to LibXC (https://gitlab.com/libxc/libxc) as an improvement for Win10 support, but do not remove other options.
What was the reason not to use ${GMS_PATH}/tools/libxc/download-libxc.csh?
One place, which should be changed, is adding -G"NMake Makefiles"
to CMake command in Makefile.in
, but I don't have Win10 to test it. Can you try it, please?
I can work on integrating these changes for your libxc repo and testing on Windows 10.
@saromleang, I'll be glad for your help! If you fork the libxc-5.1.0
branch, it will be better than pushing to the libxc-5.1.0
branch directly. Later, I'll rebase your changes.
@FulgurIgor
I didn't use the download-libxc.csh script because the curl command does not work from cygwin on Windows for some reason.
Ok. Which command for downloading is available on Windows?
@FulgurIgor
Hi, I have managed to make the download-libxc.csh script work on Cygwin.
The argument --ssl-no-revoke
just needs to be added to the curl command:
curl https://gitlab.com/libxc/libxc/-/archive/5.0.0/libxc-5.0.0.tar.gz -o ${GMS_PATH}/libxc/libxc-5.0.0.tar.gz --ssl-no-revoke
Turns out the curl command wasn't working due to some kind of certificate problem.
The --ssl-no-revoke
flag is available only on Windows :-|
Was it be the problem with your computer or is it a general problem with Windows?
@FulgurIgor I am not sure if it's a problem with only my computer. I don't have access to other windows computers right now so I can't check.
The --insecure
flag will disable all types of certificate checking all together, and it works on both Windows and Linux as far as I can tell. But it will greatly reduce security as well.
Would it be acceptable to make a separate script for windows, perhaps a native windows batch script?
Another solution might be to use:
source ../install.info
if ($GMS_TARGET == win64) then
curl https://gitlab.com/libxc/libxc/-/archive/5.0.0/libxc-5.0.0.tar.gz -o ${GMS_PATH}/libxc/libxc-5.0.0.tar.gz --ssl-no-revoke
else
curl https://gitlab.com/libxc/libxc/-/archive/5.0.0/libxc-5.0.0.tar.gz -o ${GMS_PATH}/libxc/libxc-5.0.0.tar.gz
@ShoubhikRaj, why do you add -QxHost
, but not /QxHost
? According to https://software.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/compiler-options/compiler-option-details/code-generation-options/xhost-qxhost.html, /QxHost
should be.
@ShoubhikRaj, why do you add
-QxHost
, but not/QxHost
? According to https://software.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/compiler-options/compiler-option-details/code-generation-options/xhost-qxhost.html,/QxHost
should be.
it depends where you are compiling. if you are compiling from windows command prompt you use '/'. if you are compiling within cygwin you can use either '-' or '/'.
cygwin provides access to csh/tcsh/bash however, there is no access for shells or any linux commands via the command prompt.
I have tested both '-' and '/' for arguments, and Intel compilers accept both everywhere, even when compiling from windows command prompt i.e. -QxHost
will work outside cygwin too.
operating system : Windows 10
compiler : Intel oneAPI v2021 (at least MKL from base toolkit and C/C++ and Fortran compiler from HPC toolkit required). The Intel compilers also require an installation of visual studio. In my case, I used Visual Studio 2019, but earlier versions should also work.
math library : Intel MKL (supplied with oneAPI)
communication library : MS-MPI
I have already mentioned some fixes to get the default GAMESS build working on Windows with Intel compilers in #42 . This is a way of running the LibXC interface to GAMESS on windows.
For compiling LibXC:
set PATH="C:\Program Files\CMake\bin\";%PATH%
to this:
This will compile LibXC, and it will take some time. After compilation is finished, there should be "xc.lib", "xcf90.lib", and "xc_f90_lib_m.mod" in the build directory. Create a new directory gamess/libxc/ (where the gamess source files are) and then paste these files in the gamess/libxc folder.
set LIBXC_FLAGS="C:/cygwin64$GMS_PATH/libxc/xcf90.lib C:/cygwin64$GMS_PATH/libxc/xc.lib"
This is so that the libxc libraries are linked with gamess. In comp (line 2788) change it toset EXTRAOPT='-fpp -IC:\cygwin64\gamess\libxc'
This is so that the .mod file is accessible to the compiler when compiling the GAMESS libxc interface files.After this the GAMESS-LibXC interface should hopefully run without any issue. I have only tested it with rdft-APF-gradient.inp and rdft-He-unnamed-gradient.inp test files.
Now that Intel compilers are free, this should make compiling easier on Windows systems.
The modified comp, and lked scripts are attached: comp.txt lked.txt