1SUMMARY="Generate tones and test your discrimination of frequency deltas"
2DESCRIPTION="PhantomLimb is a little program to generate tones, and test \
3your discrimination of frequency deltas. I wrote it for a friend of mine who \
4is suffering from tinnitus ('ringing in the ears') due to an ear infection. \
5(the infection destroyed some nerve cells in his inner ear, and the lack of \
6signals from the destroyed nerve cells is what causes the ringing--similar to \
7the 'phantom limb' sensations experienced by amputees. Hence the name of this \
8program) By practicing discriminating between the sound of the tinnitus and \
9'nearby' sounds, he hopes to be able to train his brain to discriminate \
10between the 'phantom' sound and other, real sounds."
11HOMEPAGE="https://github.com/HaikuArchives/PhantomLimb"
12COPYRIGHT="2001 Ben Loftis
13	2013 Jeremy Friesner"
14LICENSE="Public Domain"
15REVISION="5"
16srcGitRev="2ad55873b4e9e6397d55cdedbf497117640716ee"
17SOURCE_URI="$HOMEPAGE/archive/$srcGitRev.tar.gz"
18CHECKSUM_SHA256="e6a86517b54d350a311b2f3f93a36c63b6b2088d338527bc0472d2b005a0386d"
19SOURCE_DIR="PhantomLimb-$srcGitRev"
20
21ARCHITECTURES="all"
22
23PROVIDES="
24	phantomlimb = $portVersion
25	app:PhantomLimb = $portVersion
26	"
27REQUIRES="
28	haiku
29	"
30
31BUILD_REQUIRES="
32	haiku_devel
33	"
34BUILD_PREREQUIRES="
35	cmd:g++
36	cmd:xres
37	"
38
39BUILD()
40{
41	cd source
42	gcc -c -o PhantomApp.o PhantomApp.cpp
43	gcc -c -o PhantomWindow.o PhantomWindow.cpp
44	gcc -c -o PhantomPlayer.o PhantomPlayer.cpp -D PI=3.141592
45	gcc -c -o PhantomView.o PhantomView.cpp
46	gcc -c -o LRUEntry.o LRUEntry.cpp
47	g++ -o PhantomLimb PhantomApp.o PhantomWindow.o PhantomPlayer.o PhantomView.o LRUEntry.o -lbe -lmedia
48	xres -o PhantomLimb Phantom.rsrc
49	mimeset -f PhantomLimb
50}
51
52INSTALL()
53{
54	mkdir -p $appsDir
55	cp source/PhantomLimb $appsDir
56	addAppDeskbarSymlink $appsDir/PhantomLimb
57}
58