diff options
author | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-05-30 20:39:12 +0000 |
---|---|---|
committer | Baptiste Daroussin <bapt@FreeBSD.org> | 2015-05-30 20:39:12 +0000 |
commit | 3fef6c52f0fc4ef44d16f7c2f73fab20c9c251e5 (patch) | |
tree | c6487f309b5d29e868c4ea46df98e320c50df957 /games/cultivation | |
parent | - Reset maintainer to ports@ (diff) |
Update portaudio to v19/Remove portaudio2 [1]
Chase portaudio change
Add patches from debian for games/cultivation
Add patches from upsteam for audio/rezound
Mark py-fastaudio as broken
Approved by: maintainer
Notes
Notes:
svn path=/head/; revision=387982
Diffstat (limited to 'games/cultivation')
-rw-r--r-- | games/cultivation/Makefile | 6 | ||||
-rw-r--r-- | games/cultivation/files/patch-gameSource_sound_SoundEffectsBank.cpp | 10 | ||||
-rw-r--r-- | games/cultivation/files/patch-gameSource_sound_SoundPlayer.h | 13 | ||||
-rw-r--r-- | games/cultivation/files/portaudio19.patch | 78 |
4 files changed, 105 insertions, 2 deletions
diff --git a/games/cultivation/Makefile b/games/cultivation/Makefile index 6fefc8e59d81..a26acf31a372 100644 --- a/games/cultivation/Makefile +++ b/games/cultivation/Makefile @@ -3,7 +3,7 @@ PORTNAME= cultivation PORTVERSION= 8 -PORTREVISION= 4 +PORTREVISION= 5 CATEGORIES= games MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/v${PORTVERSION} DISTNAME= Cultivation_${PORTVERSION}_UnixSource @@ -11,7 +11,7 @@ DISTNAME= Cultivation_${PORTVERSION}_UnixSource MAINTAINER= amdmi3@FreeBSD.org COMMENT= Unique game of conflict and cooperation in a gardening community -LIB_DEPENDS= libportaudio.so.0:${PORTSDIR}/audio/portaudio +LIB_DEPENDS= libportaudio.so:${PORTSDIR}/audio/portaudio USES= gmake USE_XORG= x11 xi xext xmu @@ -21,6 +21,8 @@ WRKSRC= ${WRKDIR}/${DISTNAME}/game2 BUILD_WRKSRC= ${WRKSRC}/gameSource MAKE_ARGS= CXX=${CXX} +EXTRA_PATCHES= ${FILESDIR}/portaudio19.patch:-p2 + PLIST_FILES= bin/Cultivation PORTDATA= * PORTDOCS= changeLog.txt how_to_play.txt diff --git a/games/cultivation/files/patch-gameSource_sound_SoundEffectsBank.cpp b/games/cultivation/files/patch-gameSource_sound_SoundEffectsBank.cpp new file mode 100644 index 000000000000..b43b590b1ff8 --- /dev/null +++ b/games/cultivation/files/patch-gameSource_sound_SoundEffectsBank.cpp @@ -0,0 +1,10 @@ +--- gameSource/sound/SoundEffectsBank.cpp.orig 2007-08-09 15:45:15 UTC ++++ gameSource/sound/SoundEffectsBank.cpp +@@ -10,6 +10,7 @@ + + #include "minorGems/util/random/StdRandomSource.h" + ++#include <math.h> + + extern int globalSoundSampleRate; + diff --git a/games/cultivation/files/patch-gameSource_sound_SoundPlayer.h b/games/cultivation/files/patch-gameSource_sound_SoundPlayer.h new file mode 100644 index 000000000000..1ffd5d98428f --- /dev/null +++ b/games/cultivation/files/patch-gameSource_sound_SoundPlayer.h @@ -0,0 +1,13 @@ +--- gameSource/sound/SoundPlayer.h.orig 2015-05-30 19:01:03 UTC ++++ gameSource/sound/SoundPlayer.h +@@ -52,9 +52,7 @@ + #include "SoundFilter.h" + #include "PlayableSound.h" + +-#include "minorGems/sound/portaudio/pa_common/portaudio.h" +-#include "minorGems/sound/portaudio/pablio/pablio.h" +- ++#include <portaudio.h> + + #include "minorGems/util/SimpleVector.h" + diff --git a/games/cultivation/files/portaudio19.patch b/games/cultivation/files/portaudio19.patch new file mode 100644 index 000000000000..4cac2eb4de8e --- /dev/null +++ b/games/cultivation/files/portaudio19.patch @@ -0,0 +1,78 @@ +Author: Barry deFreese <bdefreese@debian.org> +Description: Patch system to utilize portaudio v19 +Bug-Debian: http://bugs.debian.org/594015 +Last-Update: 2013-06-01 +--- a/game2/gameSource/sound/SoundPlayer.h ++++ b/game2/gameSource/sound/SoundPlayer.h +@@ -239,7 +239,7 @@ + char mFadingIn; + int mNumFadeFramesRemaining; + +- PortAudioStream *mAudioStream; ++ PaStream *mAudioStream; + + // realtime sounds that should be mixed into the next to-speaker call + SimpleVector<PlayableSound *> *mRealtimeSounds; +--- a/game2/gameSource/sound/SoundPlayer.cpp ++++ b/game2/gameSource/sound/SoundPlayer.cpp +@@ -52,9 +52,11 @@ + + + // callback passed into portaudio +-static int portaudioCallback( void *inputBuffer, void *outputBuffer, ++int portaudioCallback( const void *inputBuffer, void *outputBuffer, + unsigned long framesPerBuffer, +- PaTimestamp outTime, void *userData ) { ++ const PaStreamCallbackTimeInfo *outTime, ++ PaStreamCallbackFlags statusFlags, ++ void *userData ) { + + + SoundPlayer *player = (SoundPlayer *)userData; +@@ -157,21 +159,13 @@ + + if( error == paNoError ) { + +- error = Pa_OpenStream( ++ error = Pa_OpenDefaultStream( + &mAudioStream, +- paNoDevice,// default input device + 0, // no input +- paFloat32, // 32 bit floating point input +- NULL, +- Pa_GetDefaultOutputDeviceID(), + 2, // stereo output + paFloat32, // 32 bit floating point output +- NULL, + mSampleRate, + 1024, // frames per buffer +- 0, // number of buffers, if zero then use default minimum +- paClipOff, // we won't output out of range samples so +- // don't bother clipping them + portaudioCallback, + (void *)this ); // pass self-pointer to callback function + +--- a/game2/gameSource/sound/MusicPlayer.cpp ++++ b/game2/gameSource/sound/MusicPlayer.cpp +@@ -112,13 +112,14 @@ + + // get parts and positions of gardeners + int numParts = 0; +- Vector3D **positions = +- globalWorld->getAllGardenerPositions( &numParts ); +- MusicPart **musicParts = +- globalWorld->getAllGardenerMusicParts( &numParts ); +- double *volumeModifiers = +- globalWorld->getAllGardenerMusicVolumeModifiers( &numParts ); +- ++ Vector3D **positions = NULL; ++ MusicPart **musicParts = NULL; ++ double *volumeModifiers = NULL; ++ if ( globalWorld ){ ++ positions = globalWorld->getAllGardenerPositions( &numParts ); ++ musicParts = globalWorld->getAllGardenerMusicParts( &numParts ); ++ volumeModifiers = globalWorld->getAllGardenerMusicVolumeModifiers( &numParts ); ++ } + + // get center position from current player position + Vector3D *centerPosition = new Vector3D( &globalPlayerCurrentPosition ); |