Re: rpmbuild

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Sep 17, 2017 at 09:48:26PM +0200, Patrick Dupre wrote:
> Hello,
> 
> Can somebody tell me whatis wrong in the spec file

In addition to the other reply, some stylistic points ...

> Group:          Development/Libraries

This is not needed.

> BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

This is not needed.

> BuildRequires:  perl(Data::Visitor::Callback) >= 0.30
> BuildRequires:  perl(ExtUtils::MakeMaker)
> BuildRequires:  perl(Forest) >= 0.06
> BuildRequires:  perl(Geometry::Primitive) >= 0.16
> BuildRequires:  perl(Graphics::Color) >= 0.20
> BuildRequires:  perl(JSON::Any) >= 1.22
> BuildRequires:  perl(Moose) >= 0.90
> BuildRequires:  perl(MooseX::Clone) >= 0.04
> BuildRequires:  perl(MooseX::Storage) >= 0.17
> BuildRequires:  perl(Test::More)

You'll likely want to add:

  BuildRequires: perl-interpreter
  BuildRequires: perl-devel
  BuildRequires: perl-generators

However this has changed recently, so check the Perl packaging
guidelines against your version of Fedora.

> Requires:       perl(Data::Visitor::Callback) >= 0.30
> Requires:       perl(Forest) >= 0.06
> Requires:       perl(Geometry::Primitive) >= 0.16
> Requires:       perl(Graphics::Color) >= 0.20
> Requires:       perl(JSON::Any) >= 1.22
> Requires:       perl(Moose) >= 0.90
> Requires:       perl(MooseX::Clone) >= 0.04
> Requires:       perl(MooseX::Storage) >= 0.17

These should be generated automatically, although if you really need
to specify minimum version numbers then I suppose you do need them.

> %{__perl} Makefile.PL INSTALLDIRS=vendor

I usually ignore the ‘__perl’ macro and similar ones.  Plain old
‘perl’ should work and is less obtuse.  However it's a matter of
style.

> %install
> rm -rf $RPM_BUILD_ROOT

You don't need the rm command here.

> find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} \;

‘-delete’ is simpler and better than ‘-exec rm -f {} \;’

> %clean
> rm -rf $RPM_BUILD_ROOT

You can completely delete the ‘%clean’ section.  It is not needed.

> %files
> %defattr(-,root,root,-)

You can delete all ‘%defattr’ lines.  They are not needed in almost
all circumstances.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
libguestfs lets you edit virtual machines.  Supports shell scripting,
bindings from many languages.  http://libguestfs.org
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux