\(\newcommand{\B}[1]{ {\bf #1} }\) \(\newcommand{\R}[1]{ {\rm #1} }\) \(\newcommand{\W}[1]{ \; #1 \; }\)
install_settings.py¶
View page sourcebin/install_settings.py: User Configuration Options¶
Syntax¶
The cases below must be executed from the directory that the dismod_at repository was cloned into; i.e., the top source directory.
Python¶
This sets install_settings to a python dictionary that has a key-value pair for of the settings listed below:
sys.path.insert(0, os.getcwd() + '/bin')
import install_settings
install_settings = install_settings.install_settings()
sys.path.pop(0)
Bash¶
This prints the value for each of the install settings:
bin/install_settings.py
This sets a bash variable to its value for each of the install settings:
eval $(bin/install_settings.py)
verbose_makefile¶
Use ‘no’ for normal and ‘yes’ for verbose make output:
verbose_makefile = 'no'
build_type¶
Use either debug or release for the type of this build:
build_type = 'release'
dismod_at_prefix¶
Prefix where dismod_at will be installed:
dismod_at_prefix = os.environ['HOME'] + '/prefix/dismod_at'
If dismod_at_prefix ends in dismod_at ,
install_settings.py will use a soft link from this prefix to
dismod_at_prefix . debug or
dismod_at_prefix . release
depending on the choice for build_type .
Debug and Release¶
If a soft link is used for the install,
the same technique will be used to map the build
directory to the debug or release version.
If you are using both a debug and release versions of dismod_at,
both versions of the
Special Requirements
will need to be installed.
python3_executable¶
Path to the python3 executable on this machine.
python3_executable = sys.executable
You can use the command which python3 to determine the location
of the default version for this system.
specific_compiler¶
On some systems, e.g. the Mac using port, there are problems with mixing
different compiler systems for fortran and C++; see
ipopt issue 471.
This variable allows you to set a specific compiler for
C, and or CXX and or FC. For example
specific_compiler='CC=gcc CXX=g++ FC=gfortran'
uses the gnu versions of these compilers.
The configuration will automatically find compilers that are not specified;
i.e., if
specific_compiler = ''
extra_cxx_flags¶
Extra C++ flags used during compilation:
extra_cxx_flags = '-std=c++17 -Wpedantic -Wall -Wshadow -Wconversion'
extra_cxx_flags += ' -Wno-bitwise-instead-of-logical'
if shutil.which('brew') != None :
cmd = [ 'brew', '--prefix' ]
result = subprocess.run(cmd, capture_output=True, encoding='utf-8')
if result.returncode == 0:
brew_prefix = result.stdout.strip()
extra_cxx_flags += f' -Wno-sign-conversion -I {brew_prefix}/include'
An alternative might be -Wall .
cmake_libdir¶
Sub-directory of each prefix where libraries are installed.
cmake_libdir = 'lib64'
system_specific_library_list¶
List of libraries that are needed for a particular system. For example,
if when you build dismod_at the pthread library is
required by your system, then include it here.
Libraries in the list can be separated by spaces or semi-colons.
system_specific_library_list = ''