From 8c0ec0cc020b86635d2bfcf025ec701981f8058c Mon Sep 17 00:00:00 2001 From: Silvan Calarco Date: Sat, 6 Jan 2024 08:32:03 +0100 Subject: [PATCH] rebuilt using system SDL* add version requirements for SDL to force rebuild on update of those packages [release 1.440-2mamba;Thu Jul 18 2013] --- README.md | 2 + ...Alien-SDL-1.440-use-system-libraries.patch | 15 +++ perl-Alien-SDL.spec | 109 ++++++++++++++++++ 3 files changed, 126 insertions(+) create mode 100644 perl-Alien-SDL-1.440-use-system-libraries.patch create mode 100644 perl-Alien-SDL.spec diff --git a/README.md b/README.md index 21bb20b..7202955 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,4 @@ # perl-Alien-SDL +Alien::SDL - building, finding and using SDL binaries. + diff --git a/perl-Alien-SDL-1.440-use-system-libraries.patch b/perl-Alien-SDL-1.440-use-system-libraries.patch new file mode 100644 index 0000000..e2cea7e --- /dev/null +++ b/perl-Alien-SDL-1.440-use-system-libraries.patch @@ -0,0 +1,15 @@ +--- Alien-SDL-1.440/Build.PL.orig 2013-07-18 17:35:04.515696493 +0200 ++++ Alien-SDL-1.440/Build.PL 2013-07-18 17:37:34.616231291 +0200 +@@ -208,11 +208,8 @@ + $prompt_string .= "[" . $i++ . "] " . $c->{title} . "\n"; + } + $prompt_string .= "\nWhat way do you wanna go?"; +- my $ans = $build->prompt($prompt_string, $recommended_candidate); + +- if($ans > 0 && $ans < scalar(@candidates)) { +- $choice = $candidates[$ans - 1]; +- } ++ $choice = $candidates[0]; + + $| = 0; + } # end else search and prompt for build method diff --git a/perl-Alien-SDL.spec b/perl-Alien-SDL.spec new file mode 100644 index 0000000..8d23390 --- /dev/null +++ b/perl-Alien-SDL.spec @@ -0,0 +1,109 @@ +%define perl_major_ver %(eval `perl -V:version`; echo ${version%*.[0-9]*}.0) +%define SDL_ver %(rpm -q --queryformat=%%{version} libSDL) +%define SDL_image_ver %(rpm -q --queryformat=%%{version} libSDL_image) +%define SDL_mixer_ver %(rpm -q --queryformat=%%{version} libSDL_mixer) +%define SDL_ttf_ver %(rpm -q --queryformat=%%{version} libSDL_ttf) +%define SDL_gfx_ver %(rpm -q --queryformat=%%{version} libSDL_gfx) +%define SDL_Pango_ver %(rpm -q --queryformat=%%{version} libSDL_Pango) + +Name: perl-Alien-SDL +Version: 1.440 +Release: 2mamba +Summary: Alien::SDL - building, finding and using SDL binaries +Group: System/Libraries/Perl +Vendor: openmamba +Distribution: openmamba +Packager: Silvan Calarco +URL: http://www.cpan.org +Source: http://search.cpan.org/CPAN/authors/id/F/FR/FROGGS/Alien-SDL-%{version}.tar.gz +Patch0: perl-Alien-SDL-1.440-use-system-libraries.patch +License: GPL, Artistic +## AUTOBUILDREQ-BEGIN +BuildRequires: perl-Capture-Tiny +BuildRequires: perl-devel +BuildRequires: perl-File-ShareDir +## AUTOBUILDREQ-END +BuildRequires: perl-Text-Patch +BuildRequires: libSDL-devel >= %{SDL_ver} +BuildRequires: libSDL_image-devel >= %{SDL_image_ver} +BuildRequires: libSDL_mixer-devel >= %{SDL_mixer_ver} +BuildRequires: libSDL_ttf-devel >= %{SDL_ttf_ver} +BuildRequires: libSDL_gfx-devel >= %{SDL_gfx_ver} +BuildRequires: libSDL_Pango-devel >= %{SDL_Pango_ver} +#Requires: libSDL +#Requires: libSDL_image +#Requires: libSDL_mixer +#Requires: libSDL_ttf +#Requires: libSDL_gfx +#Requires: libSDL_Pango +Requires: perl >= %perl_major_ver +BuildRoot: %{_tmppath}/%{name}-%{version}-root + +%description +Alien::SDL - building, finding and using SDL binaries. + +%prep +%setup -q -n Alien-SDL-%{version} +%patch0 -p1 + +%build +%{__perl} Build.PL PREFIX=%{_prefix} INSTALLDIRS=vendor OPTIMIZE="%{optflags}" +./Build +./Build test + +%install +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" + +# Build.PL requires '1' from stdin to use system libraries: +#You have the following options: +#[1] Already installed SDL ver=1.2.15 path=/usr +# SDL(v1.2.15) SDL_image(v1.2.12) SDL_mixer(v1.2.12) SDL_ttf(v2.0.11) SDL_gfx(v2.0.24) SDL_Pango(v1.3) +#[2] Source code build +# SDL(v1.2.15) SDL_image(v1.2.11) SDL_mixer(v1.2.12) SDL_ttf(v2.0.11) SDL_gfx(v2.0.23) SDL_Pango(v1.2) +#[3] Quit installation +# +#What way do you wanna go? [2 ]1 +#Using already installed SDL ver=1.2.15 path=/usr +# SDL(v1.2.15) SDL_image(v1.2.12) SDL_mixer(v1.2.12) SDL_ttf(v2.0.11) SDL_gfx(v2.0.24) SDL_Pango(v1.3) + +./Build install destdir=%{buildroot} << __EOF +1 +__EOF + +packlist=`find %{buildroot} -name .packlist` +#[ -z "$packlist" ] && exit 1 || cat $packlist | \ +# sed "s,%{buildroot},,g" | \ +# sort -u > .packlist && +rm -f $packlist +# +#strid=`echo $packlist | sed 's,.*auto\(.*\)/.packlist,\1,'` +#for dir in `find %{buildroot} -type d | grep $strid`; do +# echo "%dir ${dir#%buildroot}" >> .packlist +#done + +%clean +[ "%{buildroot}" != / ] && rm -rf "%{buildroot}" + +%files +%defattr(-,root,root) +%{_bindir}/sdl-config.pl +%dir %{perl_sitelib}/Alien +%{perl_sitelib}/Alien/SDL.pm +%{perl_sitelib}/Alien/SDL/ConfigData.pm +%{_mandir}/man3/Alien::SDL.3pm* +%{_mandir}/man3/Alien::SDL::ConfigData.3pm* +%doc LICENSE + +%changelog +* Thu Jul 18 2013 Silvan Calarco 1.440-2mamba +- rebuilt using system SDL* +- add version requirements for SDL to force rebuild on update of those packages + +* Wed May 08 2013 Automatic Build System 1.440-1mamba +- update to 1.440 + +* Sat Mar 02 2013 Automatic Build System 1.439_1-1mamba +- automatic version update by autodist + +* Mon Feb 11 2013 Silvan Calarco 1.438-1mamba +- package created by silvan using the webbuild interface