From 430636942a1ff185190c039945938739915deda5 Mon Sep 17 00:00:00 2001 From: Sergey Torokhov Date: Sun, 23 Apr 2023 16:00:42 +0300 Subject: sci-physics/SU2: 7.5.1, add missed unbundle system libs patch Signed-off-by: Sergey Torokhov --- .../SU2/files/SU2-7.5.1-system-libraries.patch | 144 +++++++++++++++++++++ 1 file changed, 144 insertions(+) create mode 100644 sci-physics/SU2/files/SU2-7.5.1-system-libraries.patch (limited to 'sci-physics') diff --git a/sci-physics/SU2/files/SU2-7.5.1-system-libraries.patch b/sci-physics/SU2/files/SU2-7.5.1-system-libraries.patch new file mode 100644 index 000000000..06d68657d --- /dev/null +++ b/sci-physics/SU2/files/SU2-7.5.1-system-libraries.patch @@ -0,0 +1,144 @@ +diff -Nuar a/SU2_CFD/include/SU2_CFD.hpp b/SU2_CFD/include/SU2_CFD.hpp +--- a/SU2_CFD/include/SU2_CFD.hpp 2023-02-06 19:03:44.000000000 +0300 ++++ b/SU2_CFD/include/SU2_CFD.hpp 2023-03-18 17:24:35.000000000 +0300 +@@ -29,7 +29,7 @@ + + #include "../../Common/include/parallelization/mpi_structure.hpp" + #include "../../Common/include/parallelization/omp_structure.hpp" +-#include "CLI11.hpp" ++#include "CLI.hpp" + + #include "drivers/CDriver.hpp" + #include "drivers/CSinglezoneDriver.hpp" +diff -Nuar a/meson.build b/meson.build +--- a/meson.build 2023-02-06 19:03:44.000000000 +0300 ++++ b/meson.build 2023-04-22 18:51:55.000000000 +0300 +@@ -6,15 +6,11 @@ + 'c_std=c99', + 'cpp_std=c++11']) + +-if meson.version() != '0.61.1' +- error('SU2 must be configured with the extended Meson script (./meson.py) in the SU2 root directory.') +-endif +- + pymod = import('python') + python = pymod.find_installation() + + su2_cpp_args = [] +-su2_deps = [declare_dependency(include_directories: 'externals/CLI11')] ++su2_deps = [declare_dependency(include_directories: '/usr/include/CLI')] + + default_warning_flags = [] + if build_machine.system() != 'windows' +@@ -70,7 +66,7 @@ + endif + + if get_option('enable-autodiff') or get_option('enable-directdiff') +- codi_dep = [declare_dependency(include_directories: 'externals/codi/include')] ++ codi_dep = [declare_dependency(include_directories: '/usr/include/codi')] + codi_rev_args = ['-DCODI_REVERSE_TYPE'] + codi_for_args = ['-DCODI_FORWARD_TYPE'] + endif +@@ -87,7 +83,8 @@ + + # add cgns library + if get_option('enable-cgns') +- subdir('externals/cgns') ++ cpp = meson.get_compiler('cpp') ++ cgns_dep = cpp.find_library('cgns') + su2_deps += cgns_dep + su2_cpp_args += '-DHAVE_CGNS' + endif +@@ -125,7 +122,7 @@ + + # add medi dependency + if get_option('enable-autodiff') or get_option('enable-directdiff') +- codi_dep += declare_dependency(include_directories: ['externals/medi/include', 'externals/medi/src']) ++ codi_dep += declare_dependency(include_directories: ['/usr/share/MeDiPack/include', '/usr/share/MeDiPack/src']) + endif + endif + +@@ -135,7 +132,7 @@ + + # add opdi dependency + if get_option('enable-autodiff') +- codi_dep += declare_dependency(include_directories: 'externals/opdi/include') ++ codi_dep += declare_dependency(include_directories: '/usr/include/opdi') + + if get_option('opdi-backend') == 'macro' + su2_cpp_args += '-DFORCE_OPDI_MACRO_BACKEND' +@@ -203,20 +200,16 @@ + + if get_option('enable-librom') + +- assert(get_option('librom_root')!='', +- 'Must specify librom folder (-Dlibrom_root=path/to/libROM)') +- + su2_cpp_args += '-DHAVE_LIBROM' + +- librom_root = get_option('librom_root') +- librom_dep = declare_dependency(include_directories: librom_root+'/lib', +- link_args: ['-L'+librom_root+'/build', '-lROM']) ++ librom_dep = declare_dependency(include_directories: '/usr/include/libROM', ++ link_args: ['-lROM']) + + su2_deps += librom_dep + + endif + +-mel_dep = declare_dependency(include_directories: 'externals/mel') ++mel_dep = declare_dependency(include_directories: '/usr/include/MEL') + su2_deps += mel_dep + + extra_deps = get_option('extra-deps').split(',') +@@ -226,12 +219,12 @@ + endif + endforeach + +-catch2_dep = declare_dependency(include_directories: 'externals/catch2/') ++if get_option('enable-tests') ++ catch2_dep = declare_dependency(include_directories: '/usr/include/catch2/') ++endif + + if get_option('enable-mpp') +- cmake = import('cmake') +- mpp_subproj = cmake.subproject('Mutationpp') +- mpp_dep = mpp_subproj.dependency('mutation++') ++ mpp_dep = dependency('mutation++') + su2_deps += mpp_dep + su2_cpp_args += '-DHAVE_MPP' + endif +@@ -258,7 +251,7 @@ + + if omp and get_option('enable-autodiff') + py = find_program('python3','python') +- p = run_command(py, 'externals/opdi/syntax/check.py', 'su2omp.syntax.json', 'Common', 'SU2_CFD', '-p', '*.hpp', '*.cpp', '*.inl', '-r', '-q') ++ p = run_command(py, '/usr/share/OpDiLib/syntax/check.py', 'su2omp.syntax.json', 'Common', 'SU2_CFD', '-p', '*.hpp', '*.cpp', '*.inl', '-r', '-q') + if p.returncode() != 0 + error(p.stdout()) + endif +@@ -323,24 +316,6 @@ + get_option('enable-openblas'), get_option('enable-pastix'), get_option('enable-mixedprec'), get_option('enable-librom'), get_option('enable-coolprop'), + meson.build_root().startswith(meson.source_root()) ? meson.build_root().split('/')[-1] : meson.build_root())) + +-if get_option('enable-mpp') +- message(''' To run SU2 with Mutation++ library, add these lines to your .bashrc file: +- +- export MPP_DATA_DIRECTORY=$SU2_HOME/subprojects/Mutationpp/data +- export LD_LIBRARY_PATH=$SU2_HOME//subprojects/Mutationpp +- +- ''') +-endif +- +-if get_option('enable-librom') +- message(''' To run SU2 with libROM library, add this line to your .bashrc file: +- +- export LD_LIBRARY_PATH=@0@/build/:$LD_LIBRARY_PATH +- +- '''.format(get_option('librom_root'))) +- +-endif +- + if get_option('enable-pywrapper') and get_option('enable-cgns') and not get_option('static-cgns-deps') + message(''' WARNING: If compilation fails with a message regarding "attempted static link of dynamic object", reconfigure with option -Dstatic-cgns-deps=true.''') + endif -- cgit v1.2.3-65-gdbad