diff --git a/README.md b/README.md index f269510..180015d 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,4 @@ # libsidplay2 +This library provides the Sound Interface Device (SID) chip emulator engine that is used by music player programs like SIDPLAY. With it you can play musics from Commodore 64 (or compatible) programs. + diff --git a/libsidplay2-2.1.1-gcc-4.0.patch b/libsidplay2-2.1.1-gcc-4.0.patch new file mode 100644 index 0000000..0b3734a --- /dev/null +++ b/libsidplay2-2.1.1-gcc-4.0.patch @@ -0,0 +1,81 @@ +--- sidplay-libs-2.1.1.orig/libsidplay/include/sidplay/SmartPtr.h 2004-06-14 22:08:04.000000000 +0200 ++++ sidplay-libs-2.1.1/libsidplay/include/sidplay/SmartPtr.h 2012-07-21 14:45:52.792511196 +0200 +@@ -17,16 +17,16 @@ + doFree = bufOwner; + if ( bufferLen >= 1 ) + { +- pBufCurrent = ( bufBegin = buffer ); +- bufEnd = bufBegin + bufferLen; +- bufLen = bufferLen; +- status = true; ++ this->pBufCurrent = ( this->bufBegin = buffer ); ++ this->bufEnd = this->bufBegin + bufferLen; ++ this->bufLen = bufferLen; ++ this->status = true; + } + else + { +- pBufCurrent = ( bufBegin = ( bufEnd = 0 )); +- bufLen = 0; +- status = false; ++ this->pBufCurrent = ( this->bufBegin = ( this->bufEnd = 0 )); ++ this->bufLen = 0; ++ this->status = false; + } + } + +@@ -211,16 +211,16 @@ + { + if ( bufferLen >= 1 ) + { +- pBufCurrent = ( bufBegin = buffer ); +- bufEnd = bufBegin + bufferLen; +- bufLen = bufferLen; +- status = true; ++ this->pBufCurrent = ( this->bufBegin = buffer ); ++ this->bufEnd = this->bufBegin + bufferLen; ++ this->bufLen = bufferLen; ++ this->status = true; + } + else + { +- pBufCurrent = bufBegin = bufEnd = 0; +- bufLen = 0; +- status = false; ++ this->pBufCurrent = this->bufBegin = this->bufEnd = 0; ++ this->bufLen = 0; ++ this->status = false; + } + } + }; +diff -Nru sidplay-libs-2.1.1.orig/builders/resid-builder/src/resid-builder.cpp sidplay-libs-2.1.1/builders/resid-builder/src/resid-builder.cpp +--- sidplay-libs-2.1.1.orig/builders/resid-builder/src/resid-builder.cpp 2004-06-14 22:07:58.000000000 +0200 ++++ sidplay-libs-2.1.1/builders/resid-builder/src/resid-builder.cpp 2012-07-21 14:53:01.984530391 +0200 +@@ -37,6 +37,7 @@ + ***************************************************************************/ + + #include ++#include + + #include "config.h" + #ifdef HAVE_EXCEPTIONS +--- sidplay-libs-2.1.1.orig/builders/resid-builder/src/resid.cpp 2004-06-14 22:07:58.000000000 +0200 ++++ sidplay-libs-2.1.1/builders/resid-builder/src/resid.cpp 2012-07-21 14:56:06.034321868 +0200 +@@ -17,6 +17,7 @@ + ***************************************************************************/ + + #include "config.h" ++#include + + #ifdef HAVE_EXCEPTIONS + # include +--- sidplay-libs-2.1.1.orig/builders/hardsid-builder/src/hardsid-builder.cpp 2004-06-14 22:07:57.000000000 +0200 ++++ sidplay-libs-2.1.1/builders/hardsid-builder/src/hardsid-builder.cpp 2012-07-21 14:57:59.891241940 +0200 +@@ -48,6 +48,7 @@ + + #include + #include "config.h" ++#include + + #ifdef HAVE_EXCEPTIONS + # include diff --git a/libsidplay2-2.1.1-pkgconfig.patch b/libsidplay2-2.1.1-pkgconfig.patch new file mode 100644 index 0000000..8ad9063 --- /dev/null +++ b/libsidplay2-2.1.1-pkgconfig.patch @@ -0,0 +1,18 @@ +--- sidplay-libs-2.1.1.orig/libsidplay/unix/libsidplay2.pc.in ++++ sidplay-libs-2.1.1/libsidplay/unix/libsidplay2.pc.in +@@ -7,5 +7,5 @@ builders=@builders@ + Name: @PACKAGE@ + Description: C64 cycle exact stereo sidplayer library. + Version: @VERSION@ +-Libs: ${libdir}/libsidplay2.la ++Libs: -L${libdir} -L${builders} -lsidplay2 + Cflags: -DHAVE_UNIX -I${includedir} +--- sidplay-libs-2.1.1.orig/libsidutils/unix/libsidutils.pc.in ++++ sidplay-libs-2.1.1/libsidutils/unix/libsidutils.pc.in +@@ -6,5 +6,5 @@ includedir=@includedir@ + Name: @PACKAGE@ + Description: Utils for supporting the libsidplay2 library. + Version: @VERSION@ +-Libs: ${libdir}/libsidutils.la ++Libs: -L${libdir} -lsidutils + Cflags: -DHAVE_UNIX -I${includedir} diff --git a/libsidplay2.spec b/libsidplay2.spec new file mode 100644 index 0000000..b271d82 --- /dev/null +++ b/libsidplay2.spec @@ -0,0 +1,92 @@ +Name: libsidplay2 +Version: 2.1.1 +Release: 1mamba +Summary: A Commodore 64 music player and SID chip emulator library +Group: System/Libraries +Vendor: openmamba +Distribution: openmamba +Packager: Silvan Calarco +URL: http://sidplay2.sourceforge.net/ +Source: http://downloads.sourceforge.net/project/sidplay2/sidplay2/sidplay-libs-2.1.1/sidplay-libs-%{version}.tar.gz +Patch0: %{name}-2.1.1-gcc-4.0.patch +Patch1: %{name}-2.1.1-pkgconfig.patch +License: GPL +## AUTOBUILDREQ-BEGIN +BuildRequires: glibc-devel +BuildRequires: libgcc +BuildRequires: libstdc++6-devel +BuildRequires: pkg-config +## AUTOBUILDREQ-END +BuildRoot: %{_tmppath}/%{name}-%{version}-root + +%description +This library provides the Sound Interface Device (SID) chip emulator engine that is used by music player programs like SIDPLAY. With it you can play musics from Commodore 64 (or compatible) programs. + +%package devel +Group: Development/Libraries +Summary: Static libraries and headers for %{name} +Requires: %{name} = %{version} + +%description devel +This library provides the Sound Interface Device (SID) chip emulator engine that is used by music player programs like SIDPLAY. With it you can play musics from Commodore 64 (or compatible) programs. + +This package contains static libraries and header files need for development. + +%prep +%setup -q -n sidplay-libs-%{version} +%patch0 -p1 +%patch1 -p1 + +%build +%configure CPPFLAGS="-fpermissive" +%make + +%install +[ "%{buildroot}" != / ] && rm -rf %{buildroot} +%makeinstall + +%clean +[ "%{buildroot}" != / ] && rm -rf %{buildroot} + +%post -p /sbin/ldconfig +%postun -p /sbin/ldconfig + +%files +%defattr(-,root,root) +%{_libdir}/libsidplay2.so.* +%{_libdir}/libsidutils.so.* +%doc libsidplay/AUTHORS libsidplay/COPYING + +%files devel +%defattr(-,root,root) +%dir %{_includedir}/sidplay +%{_includedir}/sidplay/*.h +%dir %{_includedir}/sidplay/builders +%{_includedir}/sidplay/builders/*.h +%dir %{_includedir}/sidplay/utils +%{_includedir}/sidplay/utils/*.h +%{_libdir}/libsidplay2.a +%{_libdir}/libsidplay2.la +%{_libdir}/libsidplay2.so +%{_libdir}/libsidutils.a +%{_libdir}/libsidutils.la +%{_libdir}/libsidutils.so +%dir %{_libdir}/sidplay/builders +%{_libdir}/sidplay/builders/libhardsid-builder.a +%{_libdir}/sidplay/builders/libhardsid-builder.la +%{_libdir}/sidplay/builders/libresid-builder.a +%{_libdir}/sidplay/builders/libresid-builder.la +%{_libdir}/pkgconfig/libsidplay2.pc +%{_libdir}/pkgconfig/libsidutils.pc +%doc libsidplay/README libsidplay/TODO + +%changelog +* Sat Jul 21 2012 Silvan Calarco 2.1.1-1mamba +- update to 2.1.1 + +* Sun Oct 19 2008 gil 1.36.59-2mamba +- rebuild +- fix: source; url; packager, + +* Tue Jun 14 2005 Davide Madrisan 1.36.59-1qilnx +- package created by autospec