diff options
author | amdmi3 <amdmi3@FreeBSD.org> | 2010-04-13 08:24:21 +0800 |
---|---|---|
committer | amdmi3 <amdmi3@FreeBSD.org> | 2010-04-13 08:24:21 +0800 |
commit | 16ed672053bd11e4b3f004be04909bb461f28434 (patch) | |
tree | e29c5beb98c5d840e013c7d14a7b89606e14ac94 /audio/clunk | |
parent | 66c092398e93e5ebd06296f858ca8ab494e05924 (diff) | |
download | freebsd-ports-graphics-16ed672053bd11e4b3f004be04909bb461f28434.tar.gz freebsd-ports-graphics-16ed672053bd11e4b3f004be04909bb461f28434.tar.zst freebsd-ports-graphics-16ed672053bd11e4b3f004be04909bb461f28434.zip |
The CLUNK C++ library provides support for real-time 3D sound
generation. It puts virtually no limitations on the developer;
people who is experienced on working with other solutions (such as
SDL_Mixer or Creative OpenAL) will respect this advantage.
The library supports mixing of any number of sound channels and any
number of objects that have sounds connected to them. The SDL library
is used for sound output. The project is currently at beta testing
stage, preparing to the first release.
WWW: http://media.netive.ru/clunk/
Diffstat (limited to 'audio/clunk')
-rw-r--r-- | audio/clunk/Makefile | 43 | ||||
-rw-r--r-- | audio/clunk/distinfo | 3 | ||||
-rw-r--r-- | audio/clunk/files/patch-SConstruct | 36 | ||||
-rw-r--r-- | audio/clunk/files/patch-sse_fft_context.cpp | 30 | ||||
-rw-r--r-- | audio/clunk/pkg-descr | 11 | ||||
-rw-r--r-- | audio/clunk/pkg-plist | 21 |
6 files changed, 144 insertions, 0 deletions
diff --git a/audio/clunk/Makefile b/audio/clunk/Makefile new file mode 100644 index 00000000000..bddee6bf451 --- /dev/null +++ b/audio/clunk/Makefile @@ -0,0 +1,43 @@ +# New ports collection makefile for: clunk +# Date created: 05 Aug 2009 +# Whom: Dmitry Marakasov <amdmi3@FreeBSD.org> +# +# $FreeBSD$ +# + +PORTNAME= clunk +DISTVERSION= r20100412 +CATEGORIES= audio +MASTER_SITES= http://mirror.amdmi3.ru/distfiles/ + +MAINTAINER= amdmi3@FreeBSD.org +COMMENT= Real-time 3D sound generation library + +USE_BZIP2= yes +USE_SDL= sdl +MAKE_JOBS_SAFE= yes +USE_LDCONFIG= yes + +USE_SCONS= yes + +WRKSRC= ${WRKDIR}/${PORTNAME} + +OPTIONS= SIMD "Enable SIMD support (SSE)" off + +.include <bsd.port.options.mk> + +.if !defined(WITH_SIMD) +post-patch: + @${REINPLACE_CMD} -e '/^have_sse/ s|True|False|' ${WRKSRC}/SConstruct +.endif + +.if ${OSVERSION} < 700000 +BROKEN= Requires posix_memalign() +.endif + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/libclunk.so ${PREFIX}/lib/ + ${MKDIR} ${PREFIX}/include/clunk + ${INSTALL_DATA} ${WRKSRC}/*.h ${PREFIX}/include/clunk/ + +.include <bsd.port.mk> diff --git a/audio/clunk/distinfo b/audio/clunk/distinfo new file mode 100644 index 00000000000..b37d62aa645 --- /dev/null +++ b/audio/clunk/distinfo @@ -0,0 +1,3 @@ +MD5 (clunk-r20100412.tar.bz2) = 2e3b23a9cceeb2bb5385721af19a62e1 +SHA256 (clunk-r20100412.tar.bz2) = 13accf3764ca4ae3018d112aa92dd55b5681b5113c8a1973cc58ab9b4cdf596b +SIZE (clunk-r20100412.tar.bz2) = 1378603 diff --git a/audio/clunk/files/patch-SConstruct b/audio/clunk/files/patch-SConstruct new file mode 100644 index 00000000000..f50d4a5a605 --- /dev/null +++ b/audio/clunk/files/patch-SConstruct @@ -0,0 +1,36 @@ +--- SConstruct.orig 2009-07-16 16:14:29.000000000 +0400 ++++ SConstruct 2009-08-06 04:24:21.000000000 +0400 +@@ -1,6 +1,6 @@ + import os, sys + +-env = Environment() ++env = Environment(ENV=os.environ, **dict((k, v.split()) for k, v in ARGUMENTS.iteritems())) + debug = False + + sdl_cflags = env.ParseFlags('!pkg-config --cflags sdl') +@@ -29,13 +29,6 @@ + if have_sse: + env.Append(CPPDEFINES=['USE_SIMD']) + +-if debug: +- buildmode = 'debug' +- env.Append(CXXFLAGS=['-ggdb']) +-else: +- buildmode = 'release' +- env.Append(CXXFLAGS=['-O3', '-mtune=native', '-march=native']) +- + clunk_src = [ + 'context.cpp', 'sample.cpp', 'object.cpp', 'source.cpp', 'sdl_ex.cpp', 'stream.cpp', + 'kemar.c', 'buffer.cpp', 'distance_model.cpp', 'logger.cpp', 'clunk_ex.cpp', +@@ -49,9 +42,7 @@ + + + if sys.platform != 'win32': +- env.Append(CFLAGS=['-Wall', '-pedantic']) +- env.Append(CXXFLAGS=['-Wall', '-pedantic']) +- env.Append(LINKFLAGS=['-Wl,-rpath,'+ lib_dir]) +- env.Append(LINKFLAGS=['-Wl,-rpath-link,.']) ++ env.Append(CFLAGS=['-Wall']) ++ env.Append(CXXFLAGS=['-Wall']) + + env.Program('clunk_test', ['test.cpp'], LIBS=['clunk']) diff --git a/audio/clunk/files/patch-sse_fft_context.cpp b/audio/clunk/files/patch-sse_fft_context.cpp new file mode 100644 index 00000000000..6734d426490 --- /dev/null +++ b/audio/clunk/files/patch-sse_fft_context.cpp @@ -0,0 +1,30 @@ +--- sse_fft_context.cpp.orig 2009-08-05 01:28:34.000000000 +0400 ++++ sse_fft_context.cpp 2010-04-13 04:16:03.000000000 +0400 +@@ -1,5 +1,4 @@ + #include <stdlib.h> +-#include <malloc.h> + #include <stdio.h> + #include <new> + #include "fft_context.h" +@@ -9,20 +8,11 @@ + + void * aligned_allocator::allocate(size_t size, size_t alignment) { + void * ptr; +-#ifdef _WINDOWS +- ptr = _aligned_malloc(size, alignment); +-#else +- ptr = memalign(alignment, size); +-#endif +- if (ptr == NULL) ++ if (posix_memalign(&ptr, alignment, size) != 0) + throw std::bad_alloc(); + return ptr; + } + + void aligned_allocator::deallocate(void *ptr) { +-#ifdef _WINDOWS +- _aligned_free(ptr); +-#else + free(ptr); +-#endif + } diff --git a/audio/clunk/pkg-descr b/audio/clunk/pkg-descr new file mode 100644 index 00000000000..2bb5e3c8780 --- /dev/null +++ b/audio/clunk/pkg-descr @@ -0,0 +1,11 @@ +The CLUNK C++ library provides support for real-time 3D sound +generation. It puts virtually no limitations on the developer; +people who is experienced on working with other solutions (such as +SDL_Mixer or Creative OpenAL) will respect this advantage. + +The library supports mixing of any number of sound channels and any +number of objects that have sounds connected to them. The SDL library +is used for sound output. The project is currently at beta testing +stage, preparing to the first release. + +WWW: http://media.netive.ru/clunk/ diff --git a/audio/clunk/pkg-plist b/audio/clunk/pkg-plist new file mode 100644 index 00000000000..e3839fe34a8 --- /dev/null +++ b/audio/clunk/pkg-plist @@ -0,0 +1,21 @@ +include/clunk/buffer.h +include/clunk/clunk.h +include/clunk/clunk_assert.h +include/clunk/clunk_ex.h +include/clunk/context.h +include/clunk/distance_model.h +include/clunk/export_clunk.h +include/clunk/fft_context.h +include/clunk/kemar.h +include/clunk/locker.h +include/clunk/logger.h +include/clunk/mdct_context.h +include/clunk/object.h +include/clunk/sample.h +include/clunk/sdl_ex.h +include/clunk/source.h +include/clunk/sse_fft_context.h +include/clunk/stream.h +include/clunk/v3.h +lib/libclunk.so +@dirrm include/clunk |