1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-18 19:49:40 +00:00

Fix build with clang 6.

The fix also causes the port to fail on 10.x, so add USES-compiler
and USE_CXXSTD=c++11 to address that problem too.

PR:		225835
Submitted by:	Thibault Payet <monwarez@mailoo.org> (maintainer)
This commit is contained in:
Guido Falsi 2018-02-24 00:28:10 +00:00
parent ebd70d6e46
commit bd53ea2c20
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=462754
4 changed files with 40 additions and 1 deletions

View File

@ -19,12 +19,13 @@ RUN_DEPENDS= bash:shells/bash
MAKE_JOBS_UNSAFE= yes
USES= cpe gmake openal:al,alut shebangfix tar:bzip2
USES= compiler:c++11-lang cpe gmake openal:al,alut shebangfix tar:bzip2
CPE_VENDOR= bernhard_wymann
SHEBANG_FILES= src/tools/accc/accc.in src/tools/nfsperf/nfsperf.in \
src/tools/texmapper/texmapper.in src/tools/nfs2ac/nfs2ac.in \
src/tools/trackgen/trackgen.in \
src/modules/telemetry/telemetry.sh robotgen
USE_CXXSTD= c++11
USE_XORG= xrender xmu ice xext x11 xxf86vm xrandr xi xt sm
USE_GL= glut glu gl
GNU_CONFIGURE= yes

View File

@ -9,3 +9,12 @@
dep: .depend
@@ -181,7 +181,7 @@ win32setup: win32start exportswin32 installshipswin32
linuxconfstart:
@rm -f ${SETUP_LINUX}
- @echo '#! /bin/bash' >> ${SETUP_LINUX}
+ @echo '#! /usr/local/bin/bash' >> ${SETUP_LINUX}
@echo '' >> ${SETUP_LINUX}
@echo '[ -z "$$1" ] && exit 1' >> ${SETUP_LINUX}
@echo '[ ! -d "$$1" ] && exit 1' >> ${SETUP_LINUX}

View File

@ -0,0 +1,11 @@
--- src/drivers/olethros/driver.cpp.orig 2018-02-11 21:23:59 UTC
+++ src/drivers/olethros/driver.cpp
@@ -802,7 +802,7 @@ namespace olethros {
rpmMaxTq,
rpmMaxPw,
rpmMax,
- rpmMax*2.0
+ rpmMax*2.0f
};
int N = 5;
for (int i=0; i<N - 1; i++) {

View File

@ -0,0 +1,18 @@
--- src/libs/musicplayer/OpenALMusicPlayer.cpp.orig 2018-02-11 19:14:32 UTC
+++ src/libs/musicplayer/OpenALMusicPlayer.cpp
@@ -161,7 +161,7 @@ bool OpenALMusicPlayer::streamBuffer(ALuint buffer)
{
char pcm[BUFFERSIZE];
int size = 0;
- const char* error = '\0';
+ const char* error = nullptr;
if (!stream->read(pcm, BUFFERSIZE, &size, &error)) {
GfError("OpenALMusicPlayer: Stream read error: %s\n", error);
@@ -268,4 +268,4 @@ bool OpenALMusicPlayer::startPlayback()
alSourcePlay(source);
return true;
-}
\ No newline at end of file
+}