-
Notifications
You must be signed in to change notification settings - Fork 631
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
FDS Build: Change Build scripts to allow both ifx and ifort, and keep…
… same fortran compiler for FDS and thirdparty.
- Loading branch information
Showing
17 changed files
with
170 additions
and
193 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
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 |
---|---|---|
@@ -0,0 +1,64 @@ | ||
@echo off | ||
|
||
:: Initialize compiler flags | ||
set set_COMP_CC=0 | ||
set set_COMP_FC=0 | ||
|
||
:: Check and set C compiler | ||
if defined FIREMODELS_CC ( | ||
set COMP_CC=%FIREMODELS_CC% | ||
where /q %COMP_CC% && ( | ||
set set_COMP_CC=1 | ||
) || ( | ||
echo Warning: %FIREMODELS_CC% is not available. Searching for an alternative. | ||
) | ||
) | ||
if %set_COMP_CC%==0 ( | ||
for %%C in (icx icc) do ( | ||
where /q %%C && set COMP_CC=%%C && set set_COMP_CC=1 && goto :found_cc | ||
) | ||
echo Error: Neither icx nor icc is available. Thirdparty libs will not be built. | ||
) | ||
:found_cc | ||
|
||
:: Check and set Fortran compiler | ||
if defined FIREMODELS_FC ( | ||
set COMP_FC=%FIREMODELS_FC% | ||
where /q %COMP_FC% && ( | ||
set set_COMP_FC=1 | ||
) || ( | ||
echo Warning: %FIREMODELS_FC% is not available. Searching for an alternative. | ||
) | ||
) | ||
if %set_COMP_FC%==0 ( | ||
for %%F in (ifx ifort) do ( | ||
where /q %%F && set COMP_FC=%%F && set set_COMP_FC=1 && goto :found_fc | ||
) | ||
echo Error: Neither ifx nor ifort is available. & exit /b 1 | ||
) | ||
:found_fc | ||
|
||
:: Display selected compilers | ||
echo. | ||
echo Third-party libs C Compiler: %COMP_CC% | ||
echo Firemodels and Third-party libs Fortran Compiler: %COMP_FC% | ||
echo. | ||
|
||
|
||
::Check if make.bat or make.exe exists, and set CMAKE_MAKE_PROGRAM accordingly | ||
::------------------------------------------------------------------------------ | ||
set CMAKE_MAKE_PROGRAM= | ||
for /f "delims=" %%i in ('where make.bat 2^>nul') do set CMAKE_MAKE_PROGRAM=%%i | ||
if not defined CMAKE_MAKE_PROGRAM ( | ||
for /f "delims=" %%i in ('where make.exe 2^>nul') do set CMAKE_MAKE_PROGRAM=%%i | ||
) | ||
if not defined CMAKE_MAKE_PROGRAM ( | ||
echo Error: Neither make.bat nor make.exe found in PATH. | ||
exit /b 1 | ||
) | ||
|
||
echo. | ||
echo make proram is %CMAKE_MAKE_PROGRAM% | ||
echo. | ||
|
||
|
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
Oops, something went wrong.