summaryrefslogtreecommitdiff
path: root/math
diff options
context:
space:
mode:
Diffstat (limited to 'math')
-rw-r--r--math/scilab/Makefile12
1 files changed, 11 insertions, 1 deletions
diff --git a/math/scilab/Makefile b/math/scilab/Makefile
index f41c7c33ab4b..7f497638d3fe 100644
--- a/math/scilab/Makefile
+++ b/math/scilab/Makefile
@@ -27,6 +27,7 @@ RUN_DEPENDS= xdg-open:devel/xdg-utils
USES= compiler:c++17-lang cpe desktop-file-utils eigen:3,build \
fortran gettext gmake gnome iconv:wchar_t libtool \
localbase ncurses pathfix pkgconfig shared-mime-info
+USE_CXXSTD= c++14
USE_LOCALE= en_US.UTF-8
GNU_CONFIGURE= yes
@@ -132,10 +133,14 @@ CONFIGURE_ARGS+= --enable-debug
.include <bsd.port.pre.mk>
-.if ${OPSYS} == FreeBSD && ( ${OSVERSION} >= 1400079 || ( ${OSVERSION} >= 1302505 && ${OSVERSION} < 1400000 ))
+.if ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 150
CFLAGS+= -Wno-error=int-conversion
.endif
+.if ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 160
+CFLAGS+= -Wno-error=incompatible-function-pointer-types
+.endif
+
.if ${GCC_DEFAULT} >= 10
# workaround for Rank mismatch between actual argument at (1) and actual argument at (2) (rank-1 and scalar)
FFLAGS+= -fallow-argument-mismatch
@@ -144,6 +149,11 @@ FFLAGS+= -fallow-argument-mismatch
post-patch:
@${REINPLACE_CMD} 's,/usr/local,${LOCALBASE},' ${WRKSRC}/etc/librarypath.xml
@${REINPLACE_CMD} -e 's, gfortran, ${FC},' ${WRKSRC}/modules/dynamic_link/src/scripts/configure
+.if ${COMPILER_TYPE} == clang && ${COMPILER_VERSION} >= 160
+ @${REINPLACE_CMD} -e 's|std::filesystem|std::__fs::filesystem|g' \
+ ${WRKSRC}/modules/fileio/src/cpp/fullpath.cpp \
+ ${WRKSRC}/modules/fileio/sci_gateway/cpp/sci_get_absolute_file_path.cpp
+.endif
post-patch-GUI-on:
# scilab segfaults on FreeBSD with C locale