Hello community,
here is the log from the commit of package libgme for openSUSE:Factory
checked in at Sat Feb 12 11:52:06 CET 2011.
--------
New Changes file:
--- /dev/null 2010-08-26 16:28:41.000000000 +0200
+++ /mounts/work_src_done/STABLE/libgme/libgme.changes 2010-12-14 09:00:35.000000000 +0100
@@ -0,0 +1,5 @@
+-------------------------------------------------------------------
+Tue Dec 14 07:54:59 UTC 2010 - reddwarf@opensuse.org
+
+- Initial package
+
calling whatdependson for head-i586
New:
----
_service
_service:download_url:game-music-emu-0.5.5.tbz2
_service:set_version:libgme.spec
libgme-0.5.5-LIB_SUFFIX.patch
libgme-0.5.5-pkg_config.patch
libgme-0.5.5-symbol_visibility.patch
libgme.changes
libgme.spec
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ _service:set_version:libgme.spec ++++++
#
# spec file for package libgme
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define soname 0
Name: libgme
Version: 0.5.5
Release: 1
License: LGPLv2.1+
Summary: Collection of video game music file emulators
Url: http://code.google.com/p/game-music-emu/
Group: System/Libraries
Source0: game-music-emu-%{version}.tbz2
# PATCH-FIX-UPSTREAM %{name}-0.5.5-LIB_SUFFIX.patch http://code.google.com/p/game-music-emu/issues/detail?id=8 reddwarf@opensuse.org -- Add LIB_SUFFIX support
Patch0: %{name}-0.5.5-LIB_SUFFIX.patch
# PATCH-FIX-UPSTREAM %{name}-0.5.5-pkg_config.patch reddwarf@opensuse.org -- Add pkg-config file. From upstream SVN.
Patch1: %{name}-0.5.5-pkg_config.patch
# PATCH-FIX-UPSTREAM %{name}-0.5.5-symbol_visibility.patch reddwarf@opensuse.org -- Don't export internal symbols. From upstream SVN.
Patch2: %{name}-0.5.5-symbol_visibility.patch
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: pkg-config
%description
Game_Music_Emu is a collection of video game music file emulators that support
the following formats and systems:
- AY: ZX Spectrum/Amstrad CPC
- GBS: Nintendo Game Boy
- GYM: Sega Genesis/Mega Drive
- HES: NEC TurboGrafx-16/PC Engine
- KSS: MSX Home Computer/other Z80 systems (doesn't support FM sound)
- NSF/NSFE: Nintendo NES/Famicom (with VRC 6, Namco 106, and FME-7 sound)
- SAP: Atari systems using POKEY sound chip
- SPC: Super Nintendo/Super Famicom
- VGM/VGZ: Sega Master System/Mark III, Sega Genesis/Mega Drive,BBC Micro
%package -n %{name}%{soname}
Summary: Collection of video game music file emulators
Group: System/Libraries
%description -n %{name}%{soname}
Game_Music_Emu is a collection of video game music file emulators that support
the following formats and systems:
- AY: ZX Spectrum/Amstrad CPC
- GBS: Nintendo Game Boy
- GYM: Sega Genesis/Mega Drive
- HES: NEC TurboGrafx-16/PC Engine
- KSS: MSX Home Computer/other Z80 systems (doesn't support FM sound)
- NSF/NSFE: Nintendo NES/Famicom (with VRC 6, Namco 106, and FME-7 sound)
- SAP: Atari systems using POKEY sound chip
- SPC: Super Nintendo/Super Famicom
- VGM/VGZ: Sega Master System/Mark III, Sega Genesis/Mega Drive,BBC Micro
%package devel
License: LGPLv2.1+
Summary: Development libraries and headers for %{name}
Group: Development/Libraries/C and C++
Requires: %{name}%{soname} = %{version}
%description devel
The developmental files that must be installed in order to compile applications
which use %{name}.
%prep
%setup -q -n game-music-emu-%{version}
%patch0
%patch1
%patch2
sed -i 's/\r$//' changes.txt design.txt gme.txt license.txt readme.txt
%build
export CFLAGS='%{optflags}'
export CXXFLAGS='%{optflags}'
%{__mkdir} build
cd build
cmake -DCMAKE_SKIP_RPATH=1 \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DLIB_SUFFIX=$(echo %{_lib} | cut -b4-) \
-DCMAKE_BUILD_TYPE=Release ..
%{__make} %{?_smp_mflags} VERBOSE=1
%install
cd build
%make_install
%post -n %{name}%{soname} -p /sbin/ldconfig
%postun -n %{name}%{soname} -p /sbin/ldconfig
%files -n %{name}%{soname}
%defattr(0644, root, root, 0755)
%doc changes.txt gme.txt license.txt readme.txt
%{_libdir}/%{name}.so.%{soname}*
%files devel
%defattr(0644, root, root, 0755)
%doc design.txt
%{_includedir}/gme
%{_libdir}/%{name}.so
%{_libdir}/pkgconfig/%{name}.pc
%changelog
++++++ libgme.spec ++++++
#
# spec file for package libgme
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define soname 0
Name: libgme
Version: to_be_filled_by_service
Release: 1
License: LGPLv2.1+
Summary: Collection of video game music file emulators
Url: http://code.google.com/p/game-music-emu/
Group: System/Libraries
Source0: game-music-emu-%{version}.tbz2
# PATCH-FIX-UPSTREAM %{name}-0.5.5-LIB_SUFFIX.patch http://code.google.com/p/game-music-emu/issues/detail?id=8 reddwarf@opensuse.org -- Add LIB_SUFFIX support
Patch0: %{name}-0.5.5-LIB_SUFFIX.patch
# PATCH-FIX-UPSTREAM %{name}-0.5.5-pkg_config.patch reddwarf@opensuse.org -- Add pkg-config file. From upstream SVN.
Patch1: %{name}-0.5.5-pkg_config.patch
# PATCH-FIX-UPSTREAM %{name}-0.5.5-symbol_visibility.patch reddwarf@opensuse.org -- Don't export internal symbols. From upstream SVN.
Patch2: %{name}-0.5.5-symbol_visibility.patch
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: pkg-config
%description
Game_Music_Emu is a collection of video game music file emulators that support
the following formats and systems:
- AY: ZX Spectrum/Amstrad CPC
- GBS: Nintendo Game Boy
- GYM: Sega Genesis/Mega Drive
- HES: NEC TurboGrafx-16/PC Engine
- KSS: MSX Home Computer/other Z80 systems (doesn't support FM sound)
- NSF/NSFE: Nintendo NES/Famicom (with VRC 6, Namco 106, and FME-7 sound)
- SAP: Atari systems using POKEY sound chip
- SPC: Super Nintendo/Super Famicom
- VGM/VGZ: Sega Master System/Mark III, Sega Genesis/Mega Drive,BBC Micro
%package -n %{name}%{soname}
Summary: Collection of video game music file emulators
Group: System/Libraries
%description -n %{name}%{soname}
Game_Music_Emu is a collection of video game music file emulators that support
the following formats and systems:
- AY: ZX Spectrum/Amstrad CPC
- GBS: Nintendo Game Boy
- GYM: Sega Genesis/Mega Drive
- HES: NEC TurboGrafx-16/PC Engine
- KSS: MSX Home Computer/other Z80 systems (doesn't support FM sound)
- NSF/NSFE: Nintendo NES/Famicom (with VRC 6, Namco 106, and FME-7 sound)
- SAP: Atari systems using POKEY sound chip
- SPC: Super Nintendo/Super Famicom
- VGM/VGZ: Sega Master System/Mark III, Sega Genesis/Mega Drive,BBC Micro
%package devel
License: LGPLv2.1+
Summary: Development libraries and headers for %{name}
Group: Development/Libraries/C and C++
Requires: %{name}%{soname} = %{version}
%description devel
The developmental files that must be installed in order to compile applications
which use %{name}.
%prep
%setup -q -n game-music-emu-%{version}
%patch0
%patch1
%patch2
sed -i 's/\r$//' changes.txt design.txt gme.txt license.txt readme.txt
%build
export CFLAGS='%{optflags}'
export CXXFLAGS='%{optflags}'
%{__mkdir} build
cd build
cmake -DCMAKE_SKIP_RPATH=1 \
-DCMAKE_INSTALL_PREFIX=%{_prefix} \
-DLIB_SUFFIX=$(echo %{_lib} | cut -b4-) \
-DCMAKE_BUILD_TYPE=Release ..
%{__make} %{?_smp_mflags} VERBOSE=1
%install
cd build
%make_install
%post -n %{name}%{soname} -p /sbin/ldconfig
%postun -n %{name}%{soname} -p /sbin/ldconfig
%files -n %{name}%{soname}
%defattr(0644, root, root, 0755)
%doc changes.txt gme.txt license.txt readme.txt
%{_libdir}/%{name}.so.%{soname}*
%files devel
%defattr(0644, root, root, 0755)
%doc design.txt
%{_includedir}/gme
%{_libdir}/%{name}.so
%{_libdir}/pkgconfig/%{name}.pc
%changelog
++++++ libgme-0.5.5-LIB_SUFFIX.patch ++++++
Index: gme/CMakeLists.txt
===================================================================
--- gme/CMakeLists.txt.orig
+++ gme/CMakeLists.txt
@@ -158,6 +158,6 @@ set_target_properties(gme
SOVERSION 0)
# TODO: Libsuffix for 64-bit?
-install(TARGETS gme LIBRARY DESTINATION lib)
+install(TARGETS gme LIBRARY DESTINATION lib${LIB_SUFFIX})
install(FILES ${EXPORTED_HEADERS} DESTINATION include/gme)
++++++ libgme-0.5.5-pkg_config.patch ++++++
Index: gme/libgme.pc.in
===================================================================
--- /dev/null
+++ gme/libgme.pc.in
@@ -0,0 +1,15 @@
+# entries grouped with CMake are expanded by CMake
+# ${foo} entries are left alone by CMake and much
+# later are used by pkg-config.
+prefix=@CMAKE_INSTALL_PREFIX@
+exec_prefix=${prefix}
+lib_suffix=@LIB_SUFFIX@
+libdir=${exec_prefix}/lib${lib_suffix}
+includedir=${prefix}/include
+
+Name: Game_Music_Emu
+Description: A video game emulation library for music.
+URL: http://code.google.com/p/game-music-emu/
+Version: @GME_VERSION@
+Cflags: -I${includedir}
+Libs: -L${libdir} -lgme
Index: gme/CMakeLists.txt
===================================================================
--- gme/CMakeLists.txt.orig
+++ gme/CMakeLists.txt
@@ -144,6 +144,9 @@ set (EXPORTED_HEADERS gme.h
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/gme_types.h.in
${CMAKE_CURRENT_BINARY_DIR}/gme_types.h)
+configure_file(${CMAKE_CURRENT_SOURCE_DIR}/libgme.pc.in
+ ${CMAKE_CURRENT_BINARY_DIR}/libgme.pc @ONLY)
+
# For the gme_types.h
include_directories(${CMAKE_CURRENT_BINARY_DIR})
@@ -154,10 +157,11 @@ add_library(gme SHARED ${libgme_SRCS})
# as only build fixes are performed (i.e. no changes/additions to API) the
# SOVERSION should be the same even when bumping up VERSION.
set_target_properties(gme
- PROPERTIES VERSION 0.5.3
+ PROPERTIES VERSION ${GME_VERSION}
SOVERSION 0)
# TODO: Libsuffix for 64-bit?
install(TARGETS gme LIBRARY DESTINATION lib${LIB_SUFFIX})
install(FILES ${EXPORTED_HEADERS} DESTINATION include/gme)
+install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libgme.pc DESTINATION lib${LIB_SUFFIX}/pkgconfig)
Index: CMakeLists.txt
===================================================================
--- CMakeLists.txt.orig
+++ CMakeLists.txt
@@ -1,6 +1,8 @@
# CMake project definition file.
project(libgme)
+set(GME_VERSION 0.5.5 CACHE INTERNAL "libgme Version")
+
# 2.6+ always assumes FATAL_ERROR, but 2.4 and below don't.
# Of course, 2.4 might work, in which case you're welcome to drop
# down the requirement, but I can't test that.
++++++ libgme-0.5.5-symbol_visibility.patch ++++++
Index: gme/gme.cpp
===================================================================
--- gme/gme.cpp.orig
+++ gme/gme.cpp
@@ -22,7 +22,7 @@ Inc., 51 Franklin Street, Fifth Floor, B
#include "blargg_source.h"
-gme_type_t const* gme_type_list()
+BLARGG_EXPORT gme_type_t const* gme_type_list()
{
static gme_type_t const gme_type_list_ [] = {
#ifdef USE_GME_AY
@@ -61,7 +61,7 @@ gme_type_t const* gme_type_list()
return gme_type_list_;
}
-const char* gme_identify_header( void const* header )
+BLARGG_EXPORT const char* gme_identify_header( void const* header )
{
switch ( get_be32( header ) )
{
@@ -90,7 +90,7 @@ static void to_uppercase( const char* in
*out = 0; // extension too long
}
-gme_type_t gme_identify_extension( const char* extension_ )
+BLARGG_EXPORT gme_type_t gme_identify_extension( const char* extension_ )
{
char const* end = strrchr( extension_, '.' );
if ( end )
@@ -105,7 +105,7 @@ gme_type_t gme_identify_extension( const
return 0;
}
-gme_err_t gme_identify_file( const char* path, gme_type_t* type_out )
+BLARGG_EXPORT gme_err_t gme_identify_file( const char* path, gme_type_t* type_out )
{
*type_out = gme_identify_extension( path );
// TODO: don't examine header if file has extension?
@@ -120,7 +120,7 @@ gme_err_t gme_identify_file( const char*
return 0;
}
-gme_err_t gme_open_data( void const* data, long size, Music_Emu** out, int sample_rate )
+BLARGG_EXPORT gme_err_t gme_open_data( void const* data, long size, Music_Emu** out, int sample_rate )
{
require( (data || !size) && out );
*out = 0;
@@ -144,7 +144,7 @@ gme_err_t gme_open_data( void const* dat
return err;
}
-gme_err_t gme_open_file( const char* path, Music_Emu** out, int sample_rate )
+BLARGG_EXPORT gme_err_t gme_open_file( const char* path, Music_Emu** out, int sample_rate )
{
require( path && out );
*out = 0;
@@ -181,7 +181,7 @@ gme_err_t gme_open_file( const char* pat
return err;
}
-Music_Emu* gme_new_emu( gme_type_t type, int rate )
+BLARGG_EXPORT Music_Emu* gme_new_emu( gme_type_t type, int rate )
{
if ( type )
{
@@ -214,27 +214,27 @@ Music_Emu* gme_new_emu( gme_type_t type,
return 0;
}
-gme_err_t gme_load_file( Music_Emu* me, const char* path ) { return me->load_file( path ); }
+BLARGG_EXPORT gme_err_t gme_load_file( Music_Emu* me, const char* path ) { return me->load_file( path ); }
-gme_err_t gme_load_data( Music_Emu* me, void const* data, long size )
+BLARGG_EXPORT gme_err_t gme_load_data( Music_Emu* me, void const* data, long size )
{
Mem_File_Reader in( data, size );
return me->load( in );
}
-gme_err_t gme_load_custom( Music_Emu* me, gme_reader_t func, long size, void* data )
+BLARGG_EXPORT gme_err_t gme_load_custom( Music_Emu* me, gme_reader_t func, long size, void* data )
{
Callback_Reader in( func, size, data );
return me->load( in );
}
-void gme_delete( Music_Emu* me ) { delete me; }
+BLARGG_EXPORT void gme_delete( Music_Emu* me ) { delete me; }
-gme_type_t gme_type( Music_Emu const* me ) { return me->type(); }
+BLARGG_EXPORT gme_type_t gme_type( Music_Emu const* me ) { return me->type(); }
-const char* gme_warning( Music_Emu* me ) { return me->warning(); }
+BLARGG_EXPORT const char* gme_warning( Music_Emu* me ) { return me->warning(); }
-int gme_track_count( Music_Emu const* me ) { return me->track_count(); }
+BLARGG_EXPORT int gme_track_count( Music_Emu const* me ) { return me->track_count(); }
struct gme_info_t_ : gme_info_t
{
@@ -243,7 +243,7 @@ struct gme_info_t_ : gme_info_t
BLARGG_DISABLE_NOTHROW
};
-gme_err_t gme_track_info( Music_Emu const* me, gme_info_t** out, int track )
+BLARGG_EXPORT gme_err_t gme_track_info( Music_Emu const* me, gme_info_t** out, int track )
{
*out = NULL;
@@ -309,12 +309,12 @@ gme_err_t gme_track_info( Music_Emu cons
return 0;
}
-void gme_free_info( gme_info_t* info )
+BLARGG_EXPORT void gme_free_info( gme_info_t* info )
{
delete STATIC_CAST(gme_info_t_*,info);
}
-void gme_set_stereo_depth( Music_Emu* me, double depth )
+BLARGG_EXPORT void gme_set_stereo_depth( Music_Emu* me, double depth )
{
#if !GME_DISABLE_STEREO_DEPTH
if ( me->effects_buffer )
@@ -322,23 +322,25 @@ void gme_set_stereo_depth( Music_Emu* me
#endif
}
-void* gme_user_data ( Music_Emu const* me ) { return me->user_data(); }
-void gme_set_user_data ( Music_Emu* me, void* new_user_data ) { me->set_user_data( new_user_data ); }
-void gme_set_user_cleanup(Music_Emu* me, gme_user_cleanup_t func ) { me->set_user_cleanup( func ); }
-
-gme_err_t gme_start_track ( Music_Emu* me, int index ) { return me->start_track( index ); }
-gme_err_t gme_play ( Music_Emu* me, int n, short* p ) { return me->play( n, p ); }
-void gme_set_fade ( Music_Emu* me, int start_msec ) { me->set_fade( start_msec ); }
-int gme_track_ended ( Music_Emu const* me ) { return me->track_ended(); }
-int gme_tell ( Music_Emu const* me ) { return me->tell(); }
-gme_err_t gme_seek ( Music_Emu* me, int msec ) { return me->seek( msec ); }
-int gme_voice_count ( Music_Emu const* me ) { return me->voice_count(); }
-void gme_ignore_silence ( Music_Emu* me, int disable ) { me->ignore_silence( disable != 0 ); }
-void gme_set_tempo ( Music_Emu* me, double t ) { me->set_tempo( t ); }
-void gme_mute_voice ( Music_Emu* me, int index, int mute ) { me->mute_voice( index, mute != 0 ); }
-void gme_mute_voices ( Music_Emu* me, int mask ) { me->mute_voices( mask ); }
+BLARGG_EXPORT void* gme_user_data ( Music_Emu const* me ) { return me->user_data(); }
+BLARGG_EXPORT void gme_set_user_data ( Music_Emu* me, void* new_user_data ) { me->set_user_data( new_user_data ); }
+BLARGG_EXPORT void gme_set_user_cleanup(Music_Emu* me, gme_user_cleanup_t func ) { me->set_user_cleanup( func ); }
+
+BLARGG_EXPORT gme_err_t gme_start_track ( Music_Emu* me, int index ) { return me->start_track( index ); }
+BLARGG_EXPORT gme_err_t gme_play ( Music_Emu* me, int n, short* p ) { return me->play( n, p ); }
+BLARGG_EXPORT void gme_set_fade ( Music_Emu* me, int start_msec ) { me->set_fade( start_msec ); }
+BLARGG_EXPORT int gme_track_ended ( Music_Emu const* me ) { return me->track_ended(); }
+BLARGG_EXPORT int gme_tell ( Music_Emu const* me ) { return me->tell(); }
+BLARGG_EXPORT gme_err_t gme_seek ( Music_Emu* me, int msec ) { return me->seek( msec ); }
+BLARGG_EXPORT int gme_voice_count ( Music_Emu const* me ) { return me->voice_count(); }
+BLARGG_EXPORT void gme_ignore_silence ( Music_Emu* me, int disable ) { me->ignore_silence( disable != 0 ); }
+BLARGG_EXPORT void gme_set_tempo ( Music_Emu* me, double t ) { me->set_tempo( t ); }
+BLARGG_EXPORT void gme_mute_voice ( Music_Emu* me, int index, int mute ) { me->mute_voice( index, mute != 0 ); }
+BLARGG_EXPORT void gme_mute_voices ( Music_Emu* me, int mask ) { me->mute_voices( mask ); }
+BLARGG_EXPORT void gme_clear_playlist ( Music_Emu* me ) { me->clear_playlist(); }
+BLARGG_EXPORT int gme_type_multitrack( gme_type_t t ) { return t->track_count != 1; }
-void gme_set_equalizer ( Music_Emu* me, gme_equalizer_t const* eq )
+BLARGG_EXPORT void gme_set_equalizer ( Music_Emu* me, gme_equalizer_t const* eq )
{
Music_Emu::equalizer_t e = me->equalizer();
e.treble = eq->treble;
@@ -346,7 +348,7 @@ void gme_set_equalizer ( Music_Emu
me->set_equalizer( e );
}
-void gme_equalizer( Music_Emu const* me, gme_equalizer_t* out )
+BLARGG_EXPORT void gme_equalizer( Music_Emu const* me, gme_equalizer_t* out )
{
gme_equalizer_t e = { };
e.treble = me->equalizer().treble;
@@ -354,13 +356,13 @@ void gme_equalizer( Music_Emu const* me,
*out = e;
}
-const char* gme_voice_name( Music_Emu const* me, int i )
+BLARGG_EXPORT const char* gme_voice_name( Music_Emu const* me, int i )
{
assert( (unsigned) i < (unsigned) me->voice_count() );
return me->voice_names() [i];
}
-const char* gme_type_system( gme_type_t type )
+BLARGG_EXPORT const char* gme_type_system( gme_type_t type )
{
assert( type );
return type->system;
Index: gme/M3u_Playlist.cpp
===================================================================
--- gme/M3u_Playlist.cpp.orig
+++ gme/M3u_Playlist.cpp
@@ -52,9 +52,9 @@ blargg_err_t Gme_File::load_m3u( const c
blargg_err_t Gme_File::load_m3u( Data_Reader& in ) { return load_m3u_( playlist.load( in ) ); }
-gme_err_t gme_load_m3u( Music_Emu* me, const char* path ) { return me->load_m3u( path ); }
+BLARGG_EXPORT gme_err_t gme_load_m3u( Music_Emu* me, const char* path ) { return me->load_m3u( path ); }
-gme_err_t gme_load_m3u_data( Music_Emu* me, const void* data, long size )
+BLARGG_EXPORT gme_err_t gme_load_m3u_data( Music_Emu* me, const void* data, long size )
{
Mem_File_Reader in( data, size );
return me->load_m3u( in );
Index: gme/blargg_source.h
===================================================================
--- gme/blargg_source.h.orig
+++ gme/blargg_source.h
@@ -66,6 +66,17 @@ inline T max( T x, T y )
#define byte byte_
typedef unsigned char byte;
+// Setup compiler defines useful for exporting required public API symbols in gme.cpp
+#ifndef BLARGG_EXPORT
+ #if defined (_WIN32) && defined(BLARGG_BUILD_DLL)
+ #define BLARGG_EXPORT __declspec(dllexport)
+ #elif defined (LIBGME_VISIBILITY)
+ #define BLARGG_EXPORT __attribute__((visibility ("default")))
+ #else
+ #define BLARGG_EXPORT
+ #endif
+#endif
+
// deprecated
#define BLARGG_CHECK_ALLOC CHECK_ALLOC
#define BLARGG_RETURN_ERR RETURN_ERR
Index: player/Music_Player.h
===================================================================
--- player/Music_Player.h.orig
+++ player/Music_Player.h
@@ -4,18 +4,18 @@
#ifndef MUSIC_PLAYER_H
#define MUSIC_PLAYER_H
-#include "gme/Music_Emu.h"
+#include "gme.h"
class Music_Player {
public:
// Initialize player and set sample rate
- blargg_err_t init( long sample_rate = 44100 );
+ gme_err_t init( long sample_rate = 44100 );
// Load game music file. NULL on success, otherwise error string.
- blargg_err_t load_file( const char* path );
+ gme_err_t load_file( const char* path );
// (Re)start playing track. Tracks are numbered from 0 to track_count() - 1.
- blargg_err_t start_track( int track );
+ gme_err_t start_track( int track );
// Stop playing current file
void stop();
@@ -26,7 +26,7 @@ public:
int track_count() const;
// Info for current track
- track_info_t const& track_info() const { return track_info_; }
+ gme_info_t const& track_info() const { return *track_info_; }
// Pause/resume playing current track.
void pause( int );
@@ -59,7 +59,7 @@ private:
long sample_rate;
int scope_buf_size;
bool paused;
- track_info_t track_info_;
+ gme_info_t* track_info_;
void suspend();
void resume();
Index: player/Music_Player.cpp
===================================================================
--- player/Music_Player.cpp.orig
+++ player/Music_Player.cpp
@@ -2,12 +2,10 @@
#include "Music_Player.h"
-#include "gme/Music_Emu.h"
-
#include