Add a spec template in rpmdevtools

Casper fantom at fedoraproject.org
Tue Feb 12 14:20:46 UTC 2013


Le mardi 12 février 2013 à 11:08 +0100, Simone Caronni a écrit :
> Hello,
> 
> The situation is already much better:
> 
> rpmdev-newinit
> rpmdev-newspec
> cpanspec
> 
> Examples:
> 
> $ rpmdev-newspec -m -r 4.5 -o package.spec
> 
> Generates a spec file with all the tags required for RHEL 5 systems; while
> the following:
> 
> $ rpmdev-newspec -m -o package.spec
> 
> Generates a spec file with all the tags required for RHEL 6 and Fedora
> systems.
> 
> You can experiment with -r for the various rpm versions and there's also
> some logic in the command to generate the correct %post and %postun
> sections if the spec file has "libs" in its name. The same goes for python,
> etc.
> 
> For perl; you can use cpanspec:
> 
> $ cpanspec -m Math-Polygon-Tree
> 
> This super handy tool generates a spec file that already includes license,
> description, version, etc. all generated from CPAN; with the "-o" switch
> you can also generate for older RHEL/Fedora releases.
> 
> For RHEL SysV init scripts use:
> 
> $ rpmdev-newinit -o package.init
> 
> The various init scripts and rpm spec files do follow of course the package
> guidelines.
You're right but rpmdev-newspec is provided by rpmdevtools, and
rpmdev-newspec create new spec based on spectemplate already present in
rpmdevtools.

  $ rpm -qf /usr/bin/rpmdev-newspec
  rpmdevtools-8.3-1.fc18.noarch
  $ rpm -ql rpmdevtools-8.3-1.fc18.noarch|grep spectemplate
  /etc/rpmdevtools/spectemplate-R.spec
  /etc/rpmdevtools/spectemplate-dummy.spec
  /etc/rpmdevtools/spectemplate-lib.spec
  /etc/rpmdevtools/spectemplate-minimal.spec
  /etc/rpmdevtools/spectemplate-ocaml.spec
  /etc/rpmdevtools/spectemplate-perl.spec
  /etc/rpmdevtools/spectemplate-php-pear.spec
  /etc/rpmdevtools/spectemplate-python.spec
  /etc/rpmdevtools/spectemplate-ruby.spec

My spectemplate is just to package D programs, I would like to include
it in rpmdevtools then rpmdev-newpec will be able to use it.

Regards
-- 
Pour encrypter vos emails
Clef GPG ID : 83288189 @ hkp://pgp.mit.edu:11371
Empreinte : CC26 692F 5205 AC8F 7912  7783 D7A7 F4C5 8328 8189
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part
URL: <http://lists.fedoraproject.org/pipermail/devel/attachments/20130212/e4f462d2/attachment.sig>


More information about the devel mailing list