Coder Social home page Coder Social logo

Bad rpm spec file about grive HOT 10 CLOSED

Vascom avatar Vascom commented on July 21, 2024
Bad rpm spec file

from grive.

Comments (10)

nestal avatar nestal commented on July 21, 2024

Can you tell me what's the different? I don't know much about rpm specs.

from grive.

Vascom avatar Vascom commented on July 21, 2024
  1. Not needed some BuildRequires, because them installed as dependencies for other:
    BuildRequires:libstdc++-devel
    BuildRequires:json-c-devel
    BuildRequires:openssl-devel
    BuildRequires:expat-devel
    BuildRequires:cppunit
    BuildRequires:libcurl-devel

But needed
BuildRequires: boost-devel
BuildRequires: cmake

  1. Requires not needed at all. Them maked automatically by rpmbuild.
  2. Build section better use macros:
    %build
    %cmake .
    make %{?_smp_mflags}
  3. Postinstall ldconfig must be executed:
    %post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

  1. In section %files all standart path must be macros. It needed for i686 and x86_64 builds because them use different lib path /usr/lib/ and /usr/lib64/ :
    %files
    %doc COPYING README
    %{_bindir}/%{name}
    %{_libdir}/libgrive.so.*
  2. All headers and devel files must be in separate subpackage grive-devel:
    %files devel
    %{_includedir}/%{name}*
    %{_libdir}/libgrive.so

Thats all. I think this is enough.

from grive.

nestal avatar nestal commented on July 21, 2024

OK. I will merge it.
On Jun 5, 2012 1:08 PM, "Vasiliy Glazov" <
[email protected]>
wrote:

  1. Not needed some BuildRequires, because them installed as dependencies
    for other:
    BuildRequires:libstdc++-devel
    BuildRequires:json-c-devel
    BuildRequires:openssl-devel
    BuildRequires:expat-devel
    BuildRequires:cppunit
    BuildRequires:libcurl-devel

But needed
BuildRequires: boost-devel
BuildRequires: cmake

  1. Requires not needed at all. Them maked automatically by rpmbuild.
  2. Build section better use macros:
    %build
    %cmake .
    make %{?_smp_mflags}
  3. Postinstall ldconfig must be executed:
    %post -p /sbin/ldconfig

%postun -p /sbin/ldconfig

  1. In section %files all standart path must be macros. It needed for i686
    and x86_64 builds because them use different lib path /usr/lib/ and
    /usr/lib64/ :
    %files
    %doc COPYING README
    %{_bindir}/%{name}
    %{_libdir}/libgrive.so.*
  2. All headers and devel files must be in separate subpackage grive-devel:
    %files devel
    %{_includedir}/%{name}*
    %{_libdir}/libgrive.so

Thats all. I think this is enough.


Reply to this email directly or view it on GitHub:
https://github.com/match065/grive/issues/44#issuecomment-6117670

from grive.

nestal avatar nestal commented on July 21, 2024

Do we need to put the git commit SHA in the release string? Is it a standard practice in all fedora packages? I don't remember seeing an SHA in rpm filenames...

from grive.

Vascom avatar Vascom commented on July 21, 2024

http://fedoraproject.org/wiki/Packaging:NamingGuidelines#Snapshot_packages
It not nesessary, but may be:
For instance, if you create a snapshot from a git repository on January 2, 2011 with git hash 9e88d7e9efb1bcd5b41a408037bb7cfd47220a64, %{checkout} string could be any of the following:

20110102snap
20110102git
20110102git9e88d7e

from grive.

nestal avatar nestal commented on July 21, 2024

I am not interested in doing snapshot builds in RPM formats right now. I plan to only build RPMs for milestone releases only (e.g. v0.1.0). Can I use 0.1.0 as the release part in the RPM file?

Grateful if you can modify the spec file before I merge it.

from grive.

Vascom avatar Vascom commented on July 21, 2024

OK. I'll modify it.

from grive.

nestal avatar nestal commented on July 21, 2024

Thanks!

from grive.

Vascom avatar Vascom commented on July 21, 2024

Done
https://github.com/RussianFedora/grive/blob/master/grive.spec

from grive.

Vascom avatar Vascom commented on July 21, 2024

I will try to become a maintainer package in Fedora.

from grive.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.