diff --git a/meson.build b/meson.build index 39e7fa78..72bc400a 100644 --- a/meson.build +++ b/meson.build @@ -153,7 +153,7 @@ add_project_arguments(fc.get_supported_arguments(compile_args), language: 'fortr add_project_arguments(cc.get_supported_arguments(c_compile_args), language: 'c') add_project_link_arguments(fc.get_supported_arguments(link_args), language: 'fortran') -include_directories('C:/Program Files/netCDF 4.9.0/include') +#include_directories('C:/Program Files/netCDF 4.9.0/include') subdir('src') subdir('test/unit_tests') diff --git a/src/meson.build b/src/meson.build index e6a94a50..638c6480 100644 --- a/src/meson.build +++ b/src/meson.build @@ -146,19 +146,21 @@ swbstats2_src = files( subdir('proj4') dependencies = [ - meson.get_compiler('cpp').find_library('netcdf', dirs : ['C:/Program Files/netCDF 4.9.0/lib/']) -# meson.get_compiler('cpp').find_library('netcdf') +# meson.get_compiler('cpp').find_library('netcdf', dirs : ['C:/Program Files/netCDF 4.9.0/lib/']) + meson.get_compiler('cpp').find_library('netcdf') ] swb_library = static_library('swb_library', swb_src, link_with: [swb_external]) executable('swb2', swb_src, link_with: [swb_external], + link_language : 'fortran', dependencies : dependencies, install: true) executable('swbstats2', swbstats2_src, link_with: [swb_external], + link_language : 'fortran', dependencies : dependencies, install: true) diff --git a/src/netcdf4_support.F90 b/src/netcdf4_support.F90 index 62a3091b..830582ee 100644 --- a/src/netcdf4_support.F90 +++ b/src/netcdf4_support.F90 @@ -3291,9 +3291,6 @@ subroutine nf_create(NCFILE, sFilename, iLU) character (len=*) :: sFilename integer (c_int), optional :: iLU - character (len=256) :: sBuf - call getcwd(sBuf) - call nf_trap(nc_create(path=trim(fortran_to_c_string(sFilename)), & cmode=NC_NETCDF4, & ncidp=NCFILE%iNCID), & diff --git a/test/unit_tests/meson.build b/test/unit_tests/meson.build index bdca2885..b0c0b6b3 100644 --- a/test/unit_tests/meson.build +++ b/test/unit_tests/meson.build @@ -13,5 +13,6 @@ swbtest_src = files( executable('swbtest', swbtest_src, link_with: [swb_external, swb_library], + link_language: 'fortran', dependencies : dependencies, install: true)