2024-01-06 06:54:19 +01:00
|
|
|
%define tagver %(echo %version | tr -d .)
|
2024-01-06 06:54:19 +01:00
|
|
|
Name: mame
|
2024-01-06 06:54:20 +01:00
|
|
|
Version: 0.248
|
2024-01-06 06:54:19 +01:00
|
|
|
Release: 1mamba
|
|
|
|
Summary: A virtual environment where you can run software written for other platforms, namely old arcades
|
|
|
|
Group: Applications/Emulators
|
|
|
|
Vendor: openmamba
|
|
|
|
Distribution: openmamba
|
|
|
|
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
|
2024-01-06 06:54:19 +01:00
|
|
|
URL: https://sdlmame.wallyweek.org/
|
|
|
|
Source: https://gitlab.com/mamedev/mame.git/mame%{tagver}/mame-%{version}.tar.bz2
|
2024-01-06 06:54:19 +01:00
|
|
|
License: BSD
|
|
|
|
## AUTOBUILDREQ-BEGIN
|
|
|
|
BuildRequires: glibc-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libSDL2-devel
|
|
|
|
BuildRequires: libSDL2_ttf-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libX11-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libXext-devel
|
|
|
|
BuildRequires: libXi-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libXinerama-devel
|
|
|
|
BuildRequires: libalsa-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libexpat-devel
|
|
|
|
BuildRequires: libflac-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libfontconfig-devel
|
|
|
|
BuildRequires: libfreetype-devel
|
|
|
|
BuildRequires: libgcc
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libglvnd-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libjpeg-devel
|
|
|
|
BuildRequires: liblua-devel
|
|
|
|
BuildRequires: libportaudio-devel
|
|
|
|
BuildRequires: libportmidi-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libpulseaudio-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libsqlite-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libstdc++6-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: libutf8proc-devel
|
|
|
|
BuildRequires: libz-devel
|
|
|
|
BuildRequires: pugixml-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: qt5-qtbase-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
## AUTOBUILDREQ-END
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: python3
|
|
|
|
BuildRequires: librapidjson-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
BuildRequires: liblua53-devel
|
2024-01-06 06:54:19 +01:00
|
|
|
Requires: %{name}-data = %{?epoch:%epoch:}%{version}-%{release}
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
MAME stands for "Multiple Arcade Machine Emulator". It provides a virtual environment where you can run software written for other platforms, namely old arcades.
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
%package tools
|
|
|
|
Group: Applications/Games
|
|
|
|
Summary: Additional tools for MAME
|
|
|
|
Requires: %{name} = %{?epoch:%epoch:}%{version}-%{release}
|
|
|
|
|
|
|
|
%description tools
|
|
|
|
%{summary}.
|
|
|
|
|
|
|
|
%package data
|
|
|
|
Group: Applications/Games
|
|
|
|
Summary: Data files used by MAME
|
|
|
|
|
|
|
|
%description data
|
|
|
|
%{summary}.
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
%debug_package
|
|
|
|
|
|
|
|
%prep
|
2024-01-06 06:54:19 +01:00
|
|
|
%setup -q
|
|
|
|
#-D -T
|
|
|
|
#:<< _EOF
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
# Use system libraries
|
|
|
|
sed -e 's|\# USE_SYSTEM_LIB|USE_SYSTEM_LIB|g' -i makefile
|
|
|
|
# except for asio
|
|
|
|
sed -e 's|USE_SYSTEM_LIB_ASIO|\# USE_SYSTEM_LIB_ASIO|g' -i makefile
|
|
|
|
|
|
|
|
# Hack to force linking to lua5.3
|
|
|
|
mkdir lib
|
2024-01-06 06:54:19 +01:00
|
|
|
ln -s %{_libdir}/liblua5.3.so lib/liblua.so
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
# Create ini file
|
|
|
|
cat > %{name}.ini << EOF
|
|
|
|
# Define multi-user paths
|
|
|
|
artpath %{_datadir}/%{name}/artwork;%{_datadir}/%{name}/effects
|
|
|
|
bgfx_path %{_datadir}/%{name}/bgfx
|
|
|
|
cheatpath %{_datadir}/%{name}/cheat
|
|
|
|
crosshairpath %{_datadir}/%{name}/crosshair
|
|
|
|
ctrlrpath %{_datadir}/%{name}/ctrlr
|
|
|
|
fontpath %{_datadir}/%{name}/fonts
|
|
|
|
hashpath %{_datadir}/%{name}/hash
|
|
|
|
languagepath %{_datadir}/%{name}/language
|
|
|
|
pluginspath %{_datadir}/%{name}/plugins
|
|
|
|
rompath %{_datadir}/%{name}/roms;%{_datadir}/%{name}/chds
|
|
|
|
samplepath %{_datadir}/%{name}/samples
|
|
|
|
|
|
|
|
# Allow user to override ini settings
|
|
|
|
inipath \$HOME/.%{name}/ini;%{_sysconfdir}/%{name}
|
|
|
|
|
|
|
|
# Set paths for local storage
|
|
|
|
cfg_directory \$HOME/.%{name}/cfg
|
|
|
|
comment_directory \$HOME/.%{name}/comments
|
|
|
|
diff_directory \$HOME/.%{name}/diff
|
|
|
|
input_directory \$HOME/.%{name}/inp
|
|
|
|
nvram_directory \$HOME/.%{name}/nvram
|
|
|
|
snapshot_directory \$HOME/.%{name}/snap
|
|
|
|
state_directory \$HOME/.%{name}/sta
|
|
|
|
|
|
|
|
# openmamba custom defaults
|
|
|
|
video opengl
|
|
|
|
autosave 1
|
|
|
|
EOF
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
%build
|
2024-01-06 06:54:19 +01:00
|
|
|
#:<< _EOF
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
# From Fedora
|
|
|
|
#standard -g caused problems with OOM or relocation overflows
|
|
|
|
RPM_OPT_FLAGS=$(echo $RPM_OPT_FLAGS | sed "s@-g@-g1@")
|
|
|
|
#32-bit architectures need even more measures
|
|
|
|
%ifarch %{ix86} arm
|
|
|
|
RPM_OPT_FLAGS=$(echo $RPM_OPT_FLAGS | sed "s@-O2@-Os@")
|
|
|
|
RPM_LD_FLAGS="$RPM_LD_FLAGS -Wl,--no-keep-memory -fuse-ld=gold"
|
|
|
|
%endif
|
|
|
|
|
|
|
|
export CFLAGS+="-I%{_includedir}/lua5.3/"
|
|
|
|
export CXXFLAGS+="-I%{_includedir}/lua5.3/"
|
2024-01-06 06:54:19 +01:00
|
|
|
export LDFLAGS+=" -L${PWD}/lib"
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
%make_build -j2 \
|
|
|
|
PYTHON_EXECUTABLE=%{__python3} \
|
|
|
|
NOWERROR=1 \
|
|
|
|
OPTIMIZE=2 \
|
|
|
|
TOOLS=1 \
|
|
|
|
ARCHOPTS=-flifetime-dse=1 \
|
|
|
|
OPT_FLAGS="$RPM_OPT_FLAGS" \
|
|
|
|
LDOPTS="$RPM_LD_FLAGS"
|
|
|
|
|
|
|
|
#cd docs
|
2024-01-06 06:54:19 +01:00
|
|
|
#% make html
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
%install
|
|
|
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
# create directories
|
|
|
|
install -d %{buildroot}%{_sysconfdir}/%{name}
|
|
|
|
for folder in cfg comments diff ini inp memcard nvram snap sta
|
|
|
|
do
|
|
|
|
install -d %{buildroot}%{_sysconfdir}/skel/.%{name}/$folder
|
|
|
|
done
|
|
|
|
|
|
|
|
for folder in artwork bgfx chds cheats ctrlr effects fonts hash language \
|
|
|
|
plugins keymaps roms samples shader
|
|
|
|
do
|
|
|
|
install -d %{buildroot}%{_datadir}/%{name}/$folder
|
|
|
|
done
|
|
|
|
install -d %{buildroot}%{_mandir}/man1
|
|
|
|
install -d %{buildroot}%{_mandir}/man6
|
|
|
|
|
|
|
|
# install files
|
|
|
|
install -pm 644 %{name}.ini %{buildroot}%{_sysconfdir}/%{name}
|
|
|
|
install -D -pm 755 %{name} %{buildroot}%{_bindir}/%{name}
|
2024-01-06 06:54:19 +01:00
|
|
|
ln -s mame %{buildroot}%{_bindir}/sdlmame
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
install -pm 755 castool chdman floptool imgtool jedutil ldresample ldverify \
|
|
|
|
nltool nlwav pngcmp romcmp unidasm %{buildroot}%{_bindir}
|
|
|
|
for tool in regrep split srcclean
|
|
|
|
do
|
|
|
|
install -pm 755 $tool %{buildroot}%{_bindir}/%{name}-$tool
|
|
|
|
done
|
|
|
|
pushd artwork
|
|
|
|
find -type d -exec install -d %{buildroot}%{_datadir}/%{name}/artwork/{} \;
|
|
|
|
find -type f -exec install -pm 644 {} %{buildroot}%{_datadir}/%{name}/artwork/{} \;
|
|
|
|
popd
|
|
|
|
pushd bgfx
|
|
|
|
find -type d -a ! -wholename \*dx\* -a ! -wholename \*metal\* -exec install -d %{buildroot}%{_datadir}/%{name}/bgfx/{} \;
|
|
|
|
find -type f -a ! -wholename \*dx\* -a ! -wholename \*metal\* -exec install -pm 644 {} %{buildroot}%{_datadir}/%{name}/bgfx/{} \;
|
|
|
|
popd
|
|
|
|
install -pm 644 hash/* %{buildroot}%{_datadir}/%{name}/hash
|
|
|
|
install -pm 644 keymaps/* %{buildroot}%{_datadir}/%{name}/keymaps
|
|
|
|
pushd language
|
|
|
|
find -type d -exec install -d %{buildroot}%{_datadir}/%{name}/language/{} \;
|
|
|
|
find -type f -name \*.mo -exec install -pm 644 {} %{builroot}%{_datadir}/%{name}/language/{} \;
|
|
|
|
# flag the translation files as %%lang
|
2024-01-06 06:54:19 +01:00
|
|
|
grep -r --include=*.po Language: | grep -v Source | sed -r 's@(.*)/strings\.po:".*Language: ([[:alpha:]]{2}(_[[:alpha:]]{2})?)\\n"@%lang(\2) %{_datadir}/%{name}/language/\1@' > ../%{name}.lang
|
2024-01-06 06:54:19 +01:00
|
|
|
popd
|
|
|
|
pushd plugins
|
|
|
|
find -type d -exec install -d %{buildroot}%{_datadir}/%{name}/plugins/{} \;
|
|
|
|
find -type f -exec install -pm 644 {} %{buildroot}%{_datadir}/%{name}/plugins/{} \;
|
|
|
|
popd
|
|
|
|
pushd src/osd/modules/opengl
|
|
|
|
install -pm 644 shader/*.?sh %{buildroot}%{_datadir}/%{name}/shader
|
|
|
|
popd
|
|
|
|
pushd docs/man
|
|
|
|
install -pm 644 castool.1 chdman.1 imgtool.1 floptool.1 jedutil.1 ldresample.1 \
|
2024-01-06 06:54:20 +01:00
|
|
|
ldplayer.1 ldverify.1 romcmp.1 %{buildroot}%{_mandir}/man1
|
|
|
|
install -pm 644 mame.6 %{buildroot}%{_mandir}/man6
|
2024-01-06 06:54:19 +01:00
|
|
|
popd
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
%clean
|
|
|
|
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root)
|
2024-01-06 06:54:19 +01:00
|
|
|
%config(noreplace) %{_sysconfdir}/%{name}/%{name}.ini
|
|
|
|
%dir %{_sysconfdir}/%{name}
|
|
|
|
%{_sysconfdir}/skel/.%{name}
|
2024-01-06 06:54:19 +01:00
|
|
|
%{_bindir}/mame
|
|
|
|
%{_bindir}/sdlmame
|
2024-01-06 06:54:19 +01:00
|
|
|
%{_mandir}/man6/mame.6*
|
|
|
|
%doc COPYING
|
|
|
|
|
|
|
|
%files tools
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_bindir}/castool
|
|
|
|
%{_bindir}/chdman
|
|
|
|
%{_bindir}/floptool
|
|
|
|
%{_bindir}/imgtool
|
|
|
|
%{_bindir}/jedutil
|
|
|
|
%{_bindir}/ldresample
|
|
|
|
%{_bindir}/ldverify
|
|
|
|
%{_bindir}/nltool
|
|
|
|
%{_bindir}/nlwav
|
|
|
|
%{_bindir}/pngcmp
|
|
|
|
%{_bindir}/%{name}-regrep
|
|
|
|
%{_bindir}/romcmp
|
|
|
|
%{_bindir}/%{name}-split
|
|
|
|
%{_bindir}/%{name}-srcclean
|
|
|
|
%{_bindir}/unidasm
|
|
|
|
%{_mandir}/man1/castool.1*
|
|
|
|
%{_mandir}/man1/chdman.1*
|
|
|
|
%{_mandir}/man1/floptool.1*
|
|
|
|
%{_mandir}/man1/imgtool.1*
|
|
|
|
%{_mandir}/man1/jedutil.1*
|
2024-01-06 06:54:20 +01:00
|
|
|
%{_mandir}/man1/ldplayer.1*
|
2024-01-06 06:54:19 +01:00
|
|
|
%{_mandir}/man1/ldresample.1*
|
|
|
|
%{_mandir}/man1/ldverify.1*
|
|
|
|
%{_mandir}/man1/romcmp.1*
|
|
|
|
|
|
|
|
%files data -f %{name}.lang
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%dir %{_datadir}/%{name}
|
|
|
|
%{_datadir}/%{name}/artwork
|
|
|
|
%{_datadir}/%{name}/bgfx
|
|
|
|
%{_datadir}/%{name}/chds
|
|
|
|
%{_datadir}/%{name}/cheats
|
|
|
|
%{_datadir}/%{name}/effects
|
|
|
|
%{_datadir}/%{name}/fonts
|
|
|
|
%{_datadir}/%{name}/keymaps
|
|
|
|
%dir %{_datadir}/%{name}/language
|
|
|
|
%{_datadir}/%{name}/plugins
|
|
|
|
%{_datadir}/%{name}/roms
|
|
|
|
%{_datadir}/%{name}/samples
|
|
|
|
%{_datadir}/%{name}/shader
|
|
|
|
%{_datadir}/%{name}/hash
|
|
|
|
%license COPYING docs/legal/*
|
2024-01-06 06:54:19 +01:00
|
|
|
|
|
|
|
%changelog
|
2024-01-06 06:54:20 +01:00
|
|
|
* Wed Sep 28 2022 Automatic Build System <autodist@mambasoft.it> 0.248-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:20 +01:00
|
|
|
* Thu Sep 01 2022 Automatic Build System <autodist@mambasoft.it> 0.247-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
|
|
|
* Mon Aug 01 2022 Automatic Build System <autodist@mambasoft.it> 0.246-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:20 +01:00
|
|
|
* Fri Jul 15 2022 Automatic Build System <autodist@mambasoft.it> 0.245-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:20 +01:00
|
|
|
* Sat Apr 30 2022 Automatic Build System <autodist@mambasoft.it> 0.243-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:20 +01:00
|
|
|
* Sat Apr 02 2022 Automatic Build System <autodist@mambasoft.it> 0.242-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:20 +01:00
|
|
|
* Fri Feb 25 2022 Automatic Build System <autodist@mambasoft.it> 0.241-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Sun Jan 30 2022 Automatic Build System <autodist@mambasoft.it> 0.240-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Sun Jan 09 2022 Automatic Build System <autodist@mambasoft.it> 0.239-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Wed Nov 24 2021 Automatic Build System <autodist@mambasoft.it> 0.238-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Wed Oct 27 2021 Automatic Build System <autodist@mambasoft.it> 0.237-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Thu Sep 30 2021 Automatic Build System <autodist@mambasoft.it> 0.236-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Fri Aug 27 2021 Automatic Build System <autodist@mambasoft.it> 0.235-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Wed Jul 28 2021 Automatic Build System <autodist@mambasoft.it> 0.234-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Thu Jul 01 2021 Automatic Build System <autodist@mambasoft.it> 0.233-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Sun May 30 2021 Automatic Build System <autodist@mambasoft.it> 0.232-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Mon May 10 2021 Automatic Build System <autodist@mambasoft.it> 0.231-1mamba
|
|
|
|
- automatic version update by autodist
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Tue Mar 09 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 0.229-1mamba
|
|
|
|
- update to 0.229
|
|
|
|
|
2024-01-06 06:54:19 +01:00
|
|
|
* Sun Dec 29 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 0.151-1mamba
|
|
|
|
- package created using the webbuild interface
|