Results 1 to 8 of 8

Thread: openSUSE-specific RPM build instructions?

  1. #1

    Question openSUSE-specific RPM build instructions?

    Hi all,

    I'm trying to learn how to properly make RPMs for openSUSE. I am insanely confused after wiki & google searches. The openSUSE wiki has dozens of technical pages discussing "best practises" and if there is a page there that explains step by step how to make an RPM, I could not find it. In fact, an openSUSE wiki page directed me to Fedora's https://fedoraproject.org/wiki/How_t...an_RPM_package, but even that wasn't 100% helpful since the
    Code:
    $ rpmdev-setuptree
    does not work in openSUSE.

    Google directed me to two pages thus far: http://eureka.ykyuen.info/2009/12/28...a-rpm-package/ & http://ordinatechnic.com/os-specific...l-installation, but I just want to be 100% sure that I'm doing everything correctly. Is there a page specific to openSUSE on how to make RPMs?

    Thanks

  2. #2
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    26,497
    Blog Entries
    15

    Default Re: openSUSE-specific RPM build instructions?

    On Mon 01 Jun 2015 06:16:01 AM CDT, sinayion wrote:


    Hi all,

    I'm trying to learn how to properly make RPMs for openSUSE. I am
    insanely confused after wiki & google searches. The openSUSE wiki has
    dozens of technical pages discussing "best practises" and if there is a
    page there that explains step by step how to make an RPM, I could not
    find it. In fact, an openSUSE wiki page directed me to Fedora's
    https://fedoraproject.org/wiki/How_t...an_RPM_package, but even
    that wasn't 100% helpful since the
    Code:
    --------------------
    $ rpmdev-setuptree
    --------------------
    does not work in openSUSE.

    Google directed me to two pages thus far:
    http://eureka.ykyuen.info/2009/12/28...a-rpm-package/ &
    http://tinyurl.com/qbdhaju, but I just want to be 100% sure that I'm
    doing everything correctly. Is there a page specific to openSUSE on how
    to make RPMs?

    Thanks


    Hi
    There are, but generally most folks use the openSUSE Build Service,
    there is a command line tool for this called osc which enables local
    building of rpms (in it's own build environment) and interfacing with
    the build service.

    You can see many (thousands in fact) examples of rpm spec files if you
    search here;
    https://software.opensuse.org/search?

    The specifics are all detailed here;
    https://en.opensuse.org/Portalackaging

    And of course look around here;
    https://build.opensuse.org/

    I would suggest a peruse around the above and if there is a particular
    application your wanting to package, then post back (probably in the
    build service subforum) and will see what we can do

    --
    Cheers Malcolm °¿° LFCS, SUSE Knowledge Partner (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 12 GNOME 3.10.1 Kernel 3.12.39-47-default
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!


  3. #3

    Default Re: openSUSE-specific RPM build instructions?

    Quote Originally Posted by malcolmlewis View Post
    Hi
    There are, but generally most folks use the openSUSE Build Service,
    there is a command line tool for this called osc which enables local
    building of rpms (in it's own build environment) and interfacing with
    the build service.

    You can see many (thousands in fact) examples of rpm spec files if you
    search here;
    https://software.opensuse.org/search?

    The specifics are all detailed here;
    https://en.opensuse.org/Portalackaging

    And of course look around here;
    https://build.opensuse.org/

    I would suggest a peruse around the above and if there is a particular
    application your wanting to package, then post back (probably in the
    build service subforum) and will see what we can do

    --
    Cheers Malcolm °¿° LFCS, SUSE Knowledge Partner (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 12 GNOME 3.10.1 Kernel 3.12.39-47-default
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!
    That Packaging section of the openSUSE wiki is what threw me off. It keeps linking to Fedora docs, which in turn keep linking to the "rpmdev-setuptree" command. Plus, (unless I'm missing it, and I hope I am), it shows nothing about how to create a package on our own PCs, before teaching OBS.

    Is there a good guide for osc? I just realised that the most up to date link I posted earlier has a ridiculous claim:
    When installing rpmbuild the default build directories will be created in your home directory. After installing the required package, as indicated above, you will have in your /home/username directory, a folder named rpmbuild. This will in turn have the following directories:
    • BUILD
    • BUILDROOT
    • SOURCES
    • SPECS
    • RPMS
    • SRPMS


    How on earth would that even be possible, since we're installing rpmbuild as root...?

    The package I'm trying to build is for fcgiwrap.

  4. #4
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    26,497
    Blog Entries
    15

    Default Re: openSUSE-specific RPM build instructions?

    Quote Originally Posted by sinayion View Post
    That Packaging section of the openSUSE wiki is what threw me off. It keeps linking to Fedora docs, which in turn keep linking to the "rpmdev-setuptree" command. Plus, (unless I'm missing it, and I hope I am), it shows nothing about how to create a package on our own PCs, before teaching OBS.

    Is there a good guide for osc? I just realised that the most up to date link I posted earlier has a ridiculous claim: [/LIST]

    How on earth would that even be possible, since we're installing rpmbuild as root...?

    The package I'm trying to build is for fcgiwrap.
    Hi
    Correct, rpmbuild will create those directories in your /home/username always builds as a user, only install as root user...

    Fire up an editor create the rpm spec file, add the source and build away...

    So some folks have it built on OBS;
    https://software.opensuse.org/packag..._term=fcgiwrap

    And the spec file;
    https://build.opensuse.org/package/v....spec?expand=1

    If you grab a src rpm and rebuild it locally as your user in you home directory it will create the directory structure under rpmbuild.

    Or manually create the directory structure...
    Cheers Malcolm °¿° SUSE Knowledge Partner (Linux Counter #276890)
    SUSE SLE, openSUSE Leap/Tumbleweed (x86_64) | GNOME DE
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!

  5. #5

    Default Re: openSUSE-specific RPM build instructions?

    Quote Originally Posted by malcolmlewis View Post
    Hi
    Correct, rpmbuild will create those directories in your /home/username always builds as a user, only install as root user...

    Fire up an editor create the rpm spec file, add the source and build away...

    So some folks have it built on OBS;
    https://software.opensuse.org/packag..._term=fcgiwrap

    And the spec file;
    https://build.opensuse.org/package/v....spec?expand=1

    If you grab a src rpm and rebuild it locally as your user in you home directory it will create the directory structure under rpmbuild.


    Or manually create the directory structure...
    Oh, so it creates that structure when you build a spec file? That makes more sense than the page! Thanks, I'll check this out once I get home tonight.

    EDIT: I just want to say, that in Tumbleweed I installed rpmbuild, and do not have those folders in my user's home directory. That's why I was confused with the website. The rpmdev-setup command in fedora seems to build that, whereas openSUSE has no such command.

  6. #6

    Default Re: openSUSE-specific RPM build instructions?

    I'm encountering errors that are not immediately obvious. Where is the best place to ask questions for help regarding our own spec files? I was temped to hit up stackexchange, but wanted to see what the first avenue for openSUSE devs was.

  7. #7
    Join Date
    Feb 2009
    Location
    Spain
    Posts
    25,547

    Default Re: openSUSE-specific RPM build instructions?

    On 2015-06-07 21:16, sinayion wrote:
    >
    > I'm encountering errors that are not immediately obvious. Where is the
    > best place to ask questions for help regarding our own spec files? I was
    > temped to hit up stackexchange, but wanted to see what the first avenue
    > for openSUSE devs was.


    Not many devs hit the forums here, but you could try on the
    programming-scripting forum here. There is also a programming mail list,
    but it is almost inactive. There is also a packaging mail list.

    --
    Cheers / Saludos,

    Carlos E. R.

    (from 13.1 x86_64 "Bottle" (Minas Tirith))

  8. #8
    Join Date
    Jun 2008
    Location
    Podunk
    Posts
    26,497
    Blog Entries
    15

    Default Re: openSUSE-specific RPM build instructions?

    On Sun 07 Jun 2015 07:16:01 PM CDT, sinayion wrote:


    I'm encountering errors that are not immediately obvious. Where is the
    best place to ask questions for help regarding our own spec files? I was
    temped to hit up stackexchange, but wanted to see what the first avenue
    for openSUSE devs was.


    Hi
    Are you using OBS? if so there is a subforum here. What sort of spec
    errors, or are they actual compile errors?

    --
    Cheers Malcolm °¿° LFCS, SUSE Knowledge Partner (Linux Counter #276890)
    SUSE Linux Enterprise Desktop 12 GNOME 3.10.1 Kernel 3.12.39-47-default
    If you find this post helpful and are logged into the web interface,
    please show your appreciation and click on the star below... Thanks!


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •