[opensuse-packaging] Help with a perl module specfile
All, I have a package that is not building with the recent factory changes to not allow duplicate files: project=home:gregfreemyer:Tools-for-forensic-boot-cd package=perl-Image-ExifTool The error is: ERROR: /usr/share/man/man1/exiftool.1.gz is packaged in both exiftool and perl-Image-ExifTool, and the packages do not conflict I mean for it to be in the exiftool sub-package, but not in the main package perl-Image-ExifTool. Can someone tell me what I'm doing wrong? The relevant part of the specfile is: ======================== %prep %setup -q -n %{cpan_name}-%{version} %build %{__perl} Makefile.PL INSTALLDIRS=vendor %{__make} %{?_smp_mflags} %check %{__make} test %install %perl_make_install %perl_process_packlist %perl_gen_filelist # remove exiftool and exiftool.1.gz from the file list sed -i '/\/exiftool$/d;/\/exiftool.1\(.gz\)\?/d;' %{name}.files %clean %{__rm} -rf %{buildroot} %files -n exiftool %defattr(644,root,root,755) %attr(755, root, root) %{_bindir}/exiftool %doc %{_mandir}/man1/exiftool.1.gz %files -f %{name}.files %defattr(644,root,root,755) ExifTool.spec README xmp2exif.args xmp2gps.args xmp2iptc.args %doc Changes ExifTool_config README html %{perl_vendorlib}/File/RandomAccess.pm %{perl_vendorlib}/Image/ExifTool/* %doc %{_mandir}/man3/* ================================== Thanks Greg -- Greg Freemyer Head of EDD Tape Extraction and Processing team Litigation Triage Solutions Specialist http://www.linkedin.com/in/gregfreemyer CNN/TruTV Aired Forensic Imaging Demo - http://insession.blogs.cnn.com/2010/03/23/how-computer-evidence-gets-retriev... The Norcross Group The Intersection of Evidence & Technology http://www.norcrossgroup.com -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On 2011-12-05 19:25:18 (-0500), Greg Freemyer <greg.freemyer@gmail.com> wrote: [...]
I mean for it to be in the exiftool sub-package, but not in the main package perl-Image-ExifTool. Can someone tell me what I'm doing wrong? The relevant part of the specfile is: [...] %install %perl_make_install %perl_process_packlist %perl_gen_filelist # remove exiftool and exiftool.1.gz from the file list sed -i '/\/exiftool$/d;/\/exiftool.1\(.gz\)\?/d;' %{name}.files
%__perl -i -n -e \ 'print unless m,%{_bindir}/exiftool(\.1.*)?,' \ "%{name}.files" [...] cheers -- -o) Pascal Bleser /\\ http://opensuse.org -- we haz green _\_v http://fosdem.org -- we haz conf
On Mon, Dec 5, 2011 at 8:08 PM, Pascal Bleser <pascal.bleser@opensuse.org> wrote:
On 2011-12-05 19:25:18 (-0500), Greg Freemyer <greg.freemyer@gmail.com> wrote: [...]
I mean for it to be in the exiftool sub-package, but not in the main package perl-Image-ExifTool. Can someone tell me what I'm doing wrong? The relevant part of the specfile is: [...] %install %perl_make_install %perl_process_packlist %perl_gen_filelist # remove exiftool and exiftool.1.gz from the file list sed -i '/\/exiftool$/d;/\/exiftool.1\(.gz\)\?/d;' %{name}.files
%__perl -i -n -e \ 'print unless m,%{_bindir}/exiftool(\.1.*)?,' \ "%{name}.files"
[...]
cheers -- -o) Pascal Bleser
Thanks, but that's not it. (I just tried it.) Looking further back in the log, I'm getting tons of warnings like: warning: File listed twice: /usr/share/man/man3/Image::ExifTool::Shortcuts.3pm.gz warning: File listed twice: /usr/share/man/man3/Image::ExifTool::Sigma.3pm.gz warning: File listed twice: /usr/share/man/man3/Image::ExifTool::SigmaRaw.3pm.gz My strong suspicion is I'm getting the full list of files to include in the package twice. And the sed command (or your __perl command) is just addressing one of the lists. The log is very verbose and I don't know what I'm really looking for: https://build.opensuse.org/package/rawlog?arch=x86_64&package=perl-Image-ExifTool&project=home%3Agregfreemyer%3ATools-for-forensic-boot-cd&repository=openSUSE_Factory I suspect I need to get rid entirely of the other list of files, but I don't know what in my specifle could be causing it. === Updated key areas of the specfile %prep %setup -q -n %{cpan_name}-%{version} %build %{__perl} Makefile.PL INSTALLDIRS=vendor %{__make} %{?_smp_mflags} %check %{__make} test %install %perl_make_install %perl_process_packlist %perl_gen_filelist # remove exiftool and exiftool.1.gz from the file list %__perl -i -n -e \ 'print unless m,%{_bindir}/exiftool(\.1.*)?,' \ "%{name}.files" %clean %{__rm} -rf %{buildroot} %files -n exiftool %defattr(644,root,root,755) %attr(755, root, root) %{_bindir}/exiftool %doc %{_mandir}/man1/exiftool.1.gz %files -f %{name}.files %defattr(644,root,root,755) # No idea why this had such a long % doc list # % doc Changes exif2xmp.args ExifTool_config gps2xmp.args gpx.fmt gpx_wpt.fmt iptc2xmp.args kml.fmt perl-Image-ExifTool.spec README xmp2exif.args xmp2gps.args xmp2iptc.args %doc Changes ExifTool_config README html %{perl_vendorlib}/File/RandomAccess.pm %{perl_vendorlib}/Image/ExifTool/* %doc %{_mandir}/man3/* %changelog ======================== Thanks Greg -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On Monday 05 December 2011 20:30:29 Greg Freemyer wrote:
%__perl -i -n -e \ 'print unless m,%{_bindir}/exiftool(\.1.*)?,' \ "%{name}.files"
[...]
cheers -- -o) Pascal Bleser
Thanks, but that's not it. (I just tried it.)
You're looking for a man page in %{_bindir}, I don't think that's going to work. Your sed command sed -i '/\/exiftool$/d;/\/exiftool.1\(.gz\)\?/d;' %{name}.files looks like it should work. Interesting that it doesn't Anders -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
* V Tuesday 6. December 2011, 01:25:18 [CET] Greg Freemyer napsal:
All,
I have a package that is not building with the recent factory changes to not allow duplicate files:
project=home:gregfreemyer:Tools-for-forensic-boot-cd package=perl-Image-ExifTool
The error is: ERROR: /usr/share/man/man1/exiftool.1.gz is packaged in both exiftool and perl-Image-ExifTool, and the packages do not conflict
I mean for it to be in the exiftool sub-package, but not in the main package perl-Image-ExifTool.
You can exclude a file from a package with %exclude. Try adding this to %files: %exclude %{_mandir}/man1/exiftool.1.gz -- Vita Cizek
On Tue, Dec 6, 2011 at 6:05 AM, Vitezslav Cizek <vcizek@suse.cz> wrote:
* V Tuesday 6. December 2011, 01:25:18 [CET] Greg Freemyer napsal:
All,
I have a package that is not building with the recent factory changes to not allow duplicate files:
project=home:gregfreemyer:Tools-for-forensic-boot-cd package=perl-Image-ExifTool
The error is: ERROR: /usr/share/man/man1/exiftool.1.gz is packaged in both exiftool and perl-Image-ExifTool, and the packages do not conflict
I mean for it to be in the exiftool sub-package, but not in the main package perl-Image-ExifTool.
You can exclude a file from a package with %exclude. Try adding this to %files:
%exclude %{_mandir}/man1/exiftool.1.gz
-- Vita Cizek
Excellent That is both more transparent and it actually works. A better combination I can't imagine. Thanks Greg -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
participants (4)
-
Anders Johansson
-
Greg Freemyer
-
Pascal Bleser
-
Vitezslav Cizek