diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /media-sound/chuck |
reinit the tree, so we can have metadata
Diffstat (limited to 'media-sound/chuck')
-rw-r--r-- | media-sound/chuck/Manifest | 9 | ||||
-rw-r--r-- | media-sound/chuck/chuck-1.3.5.1.ebuild | 72 | ||||
-rw-r--r-- | media-sound/chuck/chuck-1.3.5.2.ebuild | 72 | ||||
-rw-r--r-- | media-sound/chuck/files/chuck-1.2.1.1-hid-smc.patch | 149 | ||||
-rw-r--r-- | media-sound/chuck/files/chuck-1.3.5.1-makefile.patch | 27 | ||||
-rw-r--r-- | media-sound/chuck/metadata.xml | 19 |
6 files changed, 348 insertions, 0 deletions
diff --git a/media-sound/chuck/Manifest b/media-sound/chuck/Manifest new file mode 100644 index 000000000000..6028f693a39e --- /dev/null +++ b/media-sound/chuck/Manifest @@ -0,0 +1,9 @@ +AUX chuck-1.2.1.1-hid-smc.patch 3066 SHA256 5b07a22881c36bede4d041993cc4b6b26faf13f3e3c549ff9f31cc127fda1554 SHA512 854e2134f49b29f928f2752ab5228879f5fb2be4eab07ad68d2a66effcc8b0e6cb798bcd499a7cef6f3476923ae9f4dafe9e299c714a22020094074d2cbd3482 WHIRLPOOL 79a293fad5632ebef2fbee94e4ee8b3da23dd7fe4cf6c8a5b8a113ea8eaca9bbb3fd2c2acb049bdf646b59facf127d6963c714fc017fb6678ddc4e1c18c5b2eb +AUX chuck-1.3.5.1-makefile.patch 865 SHA256 031ad7f4798477f8aafe54f1de7444aacb4eff2ad6be64ae5f0096c94df4ad7e SHA512 3b338b8f744e273ad90d8982a5df0c516eef070c27c604d22c9c091ff2f6ac713305ac6f52db121f3bb224b4171bfa6996d16f1e364532386bf17d05267450f2 WHIRLPOOL 19a34825e877145e4112863d9a258155c814cabbf13aaed211d3da3982f489bf92506ff806c1edc1f363f60276c5c8e3df62f145973fadd48ea5b7076fa02d07 +DIST chuck-1.3.5.1.tgz 14686970 SHA256 d141ca61547131edd2b29bdb88183835e4133ef09807674bfa33a4e6e09d1f53 SHA512 450237207150b285954dc2661d6f7829424d4353cdc457a7dce637b6877247b106ad0ed58bdbded17c1f7558e0f01daa7a06642f2727136f6edca5a64d202f73 WHIRLPOOL 5b70e6badffa39e38ea795ea688b4a452cd290dd849d6779e799c7a79e00513fa4b8c07ed64b7243bd0075936ce3ab4bdc99482268d564391ef3a1a96b9f9e8f +DIST chuck-1.3.5.2.tgz 14687476 SHA256 e900b8545ffcb69c6d49354b18c43a9f9b8f789d3ae822f34b408eaee8d3e70b SHA512 00407b0f20fa9adcd9d0c31078ef7593f8a5b026f19086942c3fa56128fd07e202848651e5e8f41f1d70566de766e84f4a049ca4013e65a61b6f6fb10d69ffbc WHIRLPOOL 1eb7da2136d88cec35d7cb26b56e2e4073eb546ee304d6113cf44a82852e0bc5b87e4064bfb87224cfb1080931e68e179d6468be26da9b8e1ad6d987f7d71d7e +EBUILD chuck-1.3.5.1.ebuild 1929 SHA256 105351ce22648f73276f994b02983b5dd74a59593ed30836e1812c9d8704e1af SHA512 e220556b04dc04e84accecddc815fe7e38ce856eca1731e8eb22d49daae7bfb54a8844c5454f4a311b423354cb70f70ae7cd329995f0671d2118c4b310bfafa5 WHIRLPOOL e1f9a16eeb07c4dcc366754e5c7d61b8cfa5131794b64ee99bb88d3e7fec79285fbe5dea337fa9fd52bb7aebb68ebf230d5409a211fda4489aa5fdf8a8e4070f +EBUILD chuck-1.3.5.2.ebuild 1918 SHA256 d5fffe72add71ecbd1e69b0461b4b1e61c787c53676184433fcd7c8cf1cac5c6 SHA512 45e6e77187cc65a4e4740b84a6e18212b62f98a7be100b0d374102b6ae30c554a5ac1d5f6ed62b6266a542c821eaab61c603d6d56e122b4e79e23a7610168c8f WHIRLPOOL db332d177f5ddf1a346837f8d53b3416b3da576e8135202c8789a742398f307c984db98800359f30e9471de7ef5bb63015c6b70282066feb4c07fa2b11445c7d +MISC ChangeLog 2721 SHA256 302e32482f21d5b3dd2e1b66bab3d0925a926ab6310d4d1cfdf0be91eca328db SHA512 2ae28af8d1d1546e8d798e397405eaa28793aefdeddfc4949ab3470c4e3e5f0adba35085cf77ee7184f28b5996e7e61b826752ca6fb2e3fd7c42414cf55ad72c WHIRLPOOL 7033ac0778342555099461fe6ade4e8133ffdd61ae1064a550eb480a73858afa6b7fb2648657b8c9dbd8757dee9bf6d44cde70b95075dc7780cb4a33b0eb9a54 +MISC ChangeLog-2015 3282 SHA256 729557d5899753decf066aaec1ee6cccb0e3406b03234c0099b6f8210cb8b556 SHA512 76dab5863a80aa0cd6272e48a8d96dd5a9fbd223ae6157915e5c92fae821354573fd804e8b6ebb8f800190285401a00cb95d2fe5f7016c2a23f037cb8a35c2a2 WHIRLPOOL 5a70c636c7927b0d7b364638742e0d7ca55a3541561d21ad80421a9d3f1096de22d4072d7d090c4b5029788157a0f98308f2e5c1ff5b04786f53117a8af4c72d +MISC metadata.xml 967 SHA256 5644ca43484755597c4b3b8d3496b8b49665974da7f2a5819dba71724ac2ef60 SHA512 9d4c5d826ec6f90bf81a84e389f2ecca527b5116693fc5c32ccb456f5cb29f7daa42f4d655d57d4ed11a0c7625ec65904777e765a64217a4c3b5ad8a9e17b6e0 WHIRLPOOL 9a08bd1f0cbc497c48608bf7c070d48fffeb95c5e339434a0fd7ca67fb01d5b2d7f42c02b3465090ad32b9d88585d22816d4b158b75719eac2302fa4a70f4877 diff --git a/media-sound/chuck/chuck-1.3.5.1.ebuild b/media-sound/chuck/chuck-1.3.5.1.ebuild new file mode 100644 index 000000000000..249ca778cb9a --- /dev/null +++ b/media-sound/chuck/chuck-1.3.5.1.ebuild @@ -0,0 +1,72 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=5 +inherit toolchain-funcs flag-o-matic eutils + +DESCRIPTION="Strongly-timed, concurrent, and on-the-fly audio programming language" +HOMEPAGE="http://chuck.cs.princeton.edu/" +SRC_URI="http://chuck.cs.princeton.edu/release/files/${P}.tgz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="+alsa jack examples" +REQUIRED_USE="|| ( alsa jack )" + +RDEPEND="app-eselect/eselect-chuck + media-libs/libsndfile + alsa? ( media-libs/alsa-lib ) + jack? ( media-sound/jack-audio-connection-kit )" +DEPEND="${RDEPEND} + sys-devel/bison + sys-devel/flex" + +src_prepare() { + epatch "${FILESDIR}"/${PN}-1.2.1.1-hid-smc.patch \ + "${FILESDIR}"/${PN}-1.3.5.1-makefile.patch +} + +compile_backend() { + backend=$1 + pushd "${S}/src" &>/dev/null || die + einfo "Compiling against ${backend}" + emake CC=$(tc-getCC) CXX=$(tc-getCXX) linux-${backend} + mv chuck{,-${backend}} + emake clean + popd &>/dev/null || die +} + +src_compile() { + # when compile with athlon or athlon-xp flags + # chuck crashes on removing a shred with a double free or corruption + # it happens in Chuck_VM_Stack::shutdown() on the line + # SAFE_DELETE_ARRAY( stack ); + replace-cpu-flags athlon athlon-xp i686 + + use jack && compile_backend jack + use alsa && compile_backend alsa +} + +src_install() { + use jack && dobin src/chuck-jack + use alsa && dobin src/chuck-alsa + + dodoc AUTHORS DEVELOPER PROGRAMMER QUICKSTART README THANKS TODO VERSIONS + docinto doc + dodoc doc/* + if use examples; then + insinto /usr/share/doc/${PF}/ + doins -r examples + docompress -x /usr/share/doc/${PF}/examples + fi +} + +pkg_postinst() { + elog "Chuck now can use multiple audio engines, so you can specify" + elog "the preferred audio engine with chuck-{jack,alsa}" + elog "Or you can use 'eselect chuck' to set the audio engine" + + einfo "Calling eselect chuck update..." + eselect chuck update --if-unset +} diff --git a/media-sound/chuck/chuck-1.3.5.2.ebuild b/media-sound/chuck/chuck-1.3.5.2.ebuild new file mode 100644 index 000000000000..fd5abfa7224b --- /dev/null +++ b/media-sound/chuck/chuck-1.3.5.2.ebuild @@ -0,0 +1,72 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 +inherit toolchain-funcs flag-o-matic + +DESCRIPTION="Strongly-timed, concurrent, and on-the-fly audio programming language" +HOMEPAGE="http://chuck.cs.princeton.edu/" +SRC_URI="http://chuck.cs.princeton.edu/release/files/${P}.tgz" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~x86" +IUSE="+alsa jack examples" +REQUIRED_USE="|| ( alsa jack )" + +RDEPEND="app-eselect/eselect-chuck + media-libs/libsndfile + alsa? ( media-libs/alsa-lib ) + jack? ( media-sound/jack-audio-connection-kit )" +DEPEND="${RDEPEND} + sys-devel/bison + sys-devel/flex" + +PATCHES=( + "${FILESDIR}"/${PN}-1.2.1.1-hid-smc.patch + "${FILESDIR}"/${PN}-1.3.5.1-makefile.patch +) + +compile_backend() { + backend=$1 + pushd "${S}/src" &>/dev/null || die + einfo "Compiling against ${backend}" + emake CC=$(tc-getCC) CXX=$(tc-getCXX) linux-${backend} + mv chuck{,-${backend}} || die + emake clean + popd &>/dev/null || die +} + +src_compile() { + # when compile with athlon or athlon-xp flags + # chuck crashes on removing a shred with a double free or corruption + # it happens in Chuck_VM_Stack::shutdown() on the line + # SAFE_DELETE_ARRAY( stack ); + replace-cpu-flags athlon athlon-xp i686 + + use jack && compile_backend jack + use alsa && compile_backend alsa +} + +src_install() { + use jack && dobin src/chuck-jack + use alsa && dobin src/chuck-alsa + + dodoc AUTHORS DEVELOPER PROGRAMMER QUICKSTART README THANKS TODO VERSIONS + docinto doc + dodoc doc/* + if use examples; then + insinto /usr/share/doc/${PF}/ + doins -r examples + docompress -x /usr/share/doc/${PF}/examples + fi +} + +pkg_postinst() { + if [[ -z ${REPLACING_VERSIONS} ]]; then + elog "Chuck now can use multiple audio engines, so you can specify" + elog "the preferred audio engine with chuck-{jack,alsa}" + elog "Or you can use 'eselect chuck' to set the audio engine" + fi + eselect chuck update --if-unset +} diff --git a/media-sound/chuck/files/chuck-1.2.1.1-hid-smc.patch b/media-sound/chuck/files/chuck-1.2.1.1-hid-smc.patch new file mode 100644 index 000000000000..e5dcef9da811 --- /dev/null +++ b/media-sound/chuck/files/chuck-1.2.1.1-hid-smc.patch @@ -0,0 +1,149 @@ +diff -ru chuck-1.2.1.1~/src/util_hid.cpp chuck-1.2.1.1/src/util_hid.cpp +--- chuck-1.2.1.1~/src/util_hid.cpp 2008-03-29 23:24:21.000000000 +0100 ++++ chuck-1.2.1.1/src/util_hid.cpp 2008-03-29 23:24:54.000000000 +0100 +@@ -7175,14 +7175,139 @@ + int WiiRemote_send( const HidMsg * msg ){ return -1; } + const char * WiiRemote_name( int wr ){ return NULL; } + ++#define SYSFS_TILTSENSOR_FILE "/sys/devices/platform/applesmc/position" ++#define TILTSENSOR_BUF_LEN 32 ++ ++static struct t_TiltSensor_data ++{ ++ union ++ { ++ struct t_macbook ++ { ++ int x; ++ int y; ++ int z; ++ } macbook; ++ } data; ++ int dataType; ++ int detected; ++ int refcount; ++ ++ t_TiltSensor_data() ++ { ++ refcount = 0; ++ dataType = -1; ++ detected = 0; ++ } ++ ++} TiltSensor_data; ++enum ++{ ++ linuxAppleSMCMacBookDataType ++}; ++static int TiltSensor_detect() ++{ ++ int fd; ++ ++ fd = open(SYSFS_TILTSENSOR_FILE, O_RDONLY); ++ ++ if (fd > 0) ++ { ++ TiltSensor_data.dataType = linuxAppleSMCMacBookDataType; ++ TiltSensor_data.detected = 1; ++ close(fd); ++ return 1; ++ } ++ ++ TiltSensor_data.detected = -1; ++ ++ return 0; ++} ++ ++static int TiltSensor_do_read() ++{ ++ ++ switch(TiltSensor_data.dataType) ++ { ++ case linuxAppleSMCMacBookDataType: ++ char buf[TILTSENSOR_BUF_LEN]; ++ int ret, fd; ++ fd = open(SYSFS_TILTSENSOR_FILE, O_RDONLY); ++ ++ if (fd < 0) { ++ return -1; ++ } ++ ret = read(fd, buf, TILTSENSOR_BUF_LEN); ++ if (ret < 0) { ++ close(fd); ++ return -1; ++ } ++ if (sscanf(buf, "(%d,%d,%d)\n", &TiltSensor_data.data.macbook.x, &TiltSensor_data.data.macbook.y, &TiltSensor_data.data.macbook.z) != 3) { ++ close(fd); ++ return -1; ++ } ++ close(fd); ++ break; ++ default: ++ return 0; ++ } ++ return 1; ++} + void TiltSensor_init(){} + void TiltSensor_quit(){} + void TiltSensor_probe(){} +-int TiltSensor_count(){ return 0; } +-int TiltSensor_open( int ts ){ return -1; } +-int TiltSensor_close( int ts ){ return -1; } +-int TiltSensor_read( int ts, int type, int num, HidMsg * msg ){ return -1; } +-const char * TiltSensor_name( int ts ){ return NULL; } ++int TiltSensor_count() ++{ ++ if(TiltSensor_data.detected == 0) ++ TiltSensor_detect(); ++ ++ if(TiltSensor_data.detected == -1) ++ return 0; ++ else if(TiltSensor_data.detected == 1) ++ return 1; ++ ++ return 0; ++} ++int TiltSensor_open( int ts ) ++{ ++ if(TiltSensor_data.detected == 0) ++ TiltSensor_detect(); ++ ++ if(TiltSensor_data.detected == -1) ++ return -1; ++ ++ TiltSensor_data.refcount++; ++ ++ return 0; ++} ++int TiltSensor_close( int ts ) ++{ ++ TiltSensor_data.refcount--; ++ ++ return 0; ++} ++int TiltSensor_read( int ts, int type, int num, HidMsg * msg ) ++{ ++ ++ if(TiltSensor_data.detected == -1) ++ return -1; ++ ++ if(!TiltSensor_do_read()) ++ return -1; ++ ++ if(TiltSensor_data.dataType == linuxAppleSMCMacBookDataType) ++ { ++ msg->idata[0] = TiltSensor_data.data.macbook.x; ++ msg->idata[1] = TiltSensor_data.data.macbook.y; ++ msg->idata[2] = TiltSensor_data.data.macbook.z; ++ } ++ ++ return 0; ++} ++const char * TiltSensor_name( int ts ) ++{ ++ return "Apple Sudden Motion Sensor"; ++} + + + #endif +Only in chuck-1.2.1.1/src: util_hid.cpp.orig diff --git a/media-sound/chuck/files/chuck-1.3.5.1-makefile.patch b/media-sound/chuck/files/chuck-1.3.5.1-makefile.patch new file mode 100644 index 000000000000..e714d20e6b92 --- /dev/null +++ b/media-sound/chuck/files/chuck-1.3.5.1-makefile.patch @@ -0,0 +1,27 @@ +--- chuck-1.3.5.1/src/makefile ++++ chuck-1.3.5.1/src/makefile +@@ -40,8 +40,6 @@ + + ifneq ($(CHUCK_DEBUG),) + CFLAGS+= -g +-else +-CFLAGS+= -O3 + endif + + ifneq ($(USE_64_BIT_SAMPLE),) +--- chuck-1.3.5.1/src/makefile.alsa ++++ chuck-1.3.5.1/src/makefile.alsa +@@ -1,4 +1,4 @@ + +-CFLAGS+= -D__LINUX_ALSA__ -D__PLATFORM_LINUX__ -O3 -fno-strict-aliasing -D__CK_SNDFILE_NATIVE__ ++CFLAGS+= -D__LINUX_ALSA__ -D__PLATFORM_LINUX__ -fno-strict-aliasing -D__CK_SNDFILE_NATIVE__ + LDFLAGS+= -lasound -lstdc++ -ldl -lm -lsndfile -lpthread + +--- chuck-1.3.5.1/src/makefile.jack ++++ chuck-1.3.5.1/src/makefile.jack +@@ -1,4 +1,4 @@ + +-CFLAGS+= -D__UNIX_JACK__ -D__PLATFORM_LINUX__ -O3 -fno-strict-aliasing -D__CK_SNDFILE_NATIVE__ ++CFLAGS+= -D__UNIX_JACK__ -D__PLATFORM_LINUX__ -fno-strict-aliasing -D__CK_SNDFILE_NATIVE__ + LDFLAGS+= -lasound -ljack -lstdc++ -ldl -lm -lsndfile -lpthread + diff --git a/media-sound/chuck/metadata.xml b/media-sound/chuck/metadata.xml new file mode 100644 index 000000000000..2be677dfc4d0 --- /dev/null +++ b/media-sound/chuck/metadata.xml @@ -0,0 +1,19 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>proaudio@gentoo.org</email> + </maintainer> + <longdescription> + ChucK is a programming language for real-time sound synthesis and music + creation. It is open-source and freely available on MacOS X, Windows, and + Linux. ChucK presents a unique time-based, concurrent programming model + that is precise and expressive (we call this strongly-timed), dynamic + control rates, and the ability to add and modify code on-the-fly. In + addition, ChucK supports MIDI, OpenSoundControl, HID device, and + multi-channel audio. It is fun and easy to learn, and offers composers, + researchers, and performers a powerful programming tool for building and + experimenting with complex audio synthesis/analysis programs, and real-time + interactive music. + </longdescription> +</pkgmetadata> |