Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/0.84/platform/olpcsound/SPECS/olpcsound.spec
blob: 69250d33e55b697ad2721b22fe6a42de9cf29c8a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
# NOTE: Do not edit, file was generated by jhconvert

%define libname %{name}
%define pyname python-%{name}

Name: olpcsound
Version: 5.10.1
%if 0%{?suse_version}
Release: 1
%else
Release: %mkrel 2
%endif

Summary: Csound - sound synthesis language and library, OLPC subset
License: LGPLv2+
Group: Sound
Url: http://csound.sourceforge.net/

Source: http://downloads.sourceforge.net/csound/Csound5.10.1.tar.gz

Patch: olpcsound-5.10.1-gentoo-proaudio-csound-SConsruct.patch
Patch1: olpcsound-5.10.1-sugar-csound-64bit.patch
Patch2: olpcsound-5.10.1-sugar-csound-bad-symbols.patch


BuildRequires: alsa-devel  
BuildRequires: gettext-runtime  
BuildRequires: liblo-devel  
BuildRequires: libogg-devel  
BuildRequires: libpng-devel  
BuildRequires: libsndfile-devel  
BuildRequires: libvorbis-devel  
BuildRequires: python-devel  
BuildRequires: scons  
BuildRequires: swig  
BuildPreReq: gcc-c++

%description
Olpcsound is a subset of the Csound sound and music synthesis system,
tailored specifically for XO platform.

%package -n %{libname}
Summary: Libraries for %{name}
Group: System/Libraries

%description -n %{libname}
Olpcsound is a subset of the Csound sound and music synthesis system,
tailored specifically for XO platform.

%package devel
Summary: Development files for %{name}
Group: Development/C
Requires: %{libname} = %{version}-%{release}

%description devel
Olpcsound is a subset of the Csound sound and music synthesis system,
tailored specifically for XO platform.

%package -n %{pyname}
Summary: Python bindings for %{name}
Group: Development/Python
Requires: %{libname} = %{version}-%{release}
Requires: python  

%description -n %{pyname}
Olpcsound is a subset of the Csound sound and music synthesis system,
tailored specifically for XO platform.

%prep
%setup -q -n Csound5.10.1
%patch -p1
%patch1 -p1
%patch2 -p1

%ifarch x86_64
%global x86_64_flags Word64=1 Lib64=1
%else
%global x86_64_flags Word64=0 Lib64=0
%endif

%build
%define Werror_cflags %nil
scons  \
	customCCFLAGS="$CFLAGS -D_GNU_SOURCE" \
	customCXXCFLAGS="$CFLAGS -D_GNU_SOURCE" \
	buildOLPC=1 \
	useJack=0 \
	gcc3opt=0 \
	gcc4opt=0 \
	customCCFLAGS="%{optflags}" \
	customCXXFLAGS="%{optflags}" \
	%{x86_64_flags}

%install
rm -rf %{buildroot}
python  \
	install-olpc.py \
	--install-python \
	--install-headers \
	--instdir=%{buildroot} \
	--libdir=%{_libdir}
%ifarch x86_64
mkdir -p %{buildroot}/%{python_sitelib}
mv %{buildroot}/%{_libdir}/python*/site-packages/* 
%{buildroot}/%{python_sitelib}/
%endif
%find_lang csound5

%clean
rm -rf %{buildroot}

%files -f csound5.lang
%defattr(-,root,root,-)
%{_bindir}/*
%{_datadir}/doc/csound/*

%files -n %{libname}
%defattr(-,root,root,-)
%{_libdir}/*.so.*
%{_libdir}/csound/plugins/*

%files devel
%defattr(-,root,root,-)
%{_includedir}/csound/*
%{_libdir}/libcsound.so
%{_libdir}/libcsnd.so

%files -n %{pyname}
%defattr(-,root,root,-)
%{python_sitelib}/*

%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig