Bug 1378093 - Mageia builds for COPR need %mkrel and %mklibname defined from the very beginning
Summary: Mageia builds for COPR need %mkrel and %mklibname defined from the very begin...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Copr
Classification: Community
Component: backend
Version: unspecified
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: clime
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-09-21 13:18 UTC by Neal Gompa
Modified: 2017-01-11 13:07 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-11 13:07:12 UTC


Attachments (Terms of Use)

Description Neal Gompa 2016-09-21 13:18:07 UTC
Description of problem:
If a properly compliant Mageia package is submitted to COPR for build, it fails due to the lack of support for %mkrel and %mklibname macros. Because of this, it chokes on processing the spec for building the source RPM and the binary RPMs.

Here's the macro definitions ripped from our build macros file included in rpm-mageia-setup-build:

=== mklibname ===

# Macro: %{mklibname <name> [<major> [<minor>]] [-s] [-d]}
# - %{mklibname test}           => %{_lib}test
# - %{mklibname test 1 -d}      => %{_lib}test1-devel
# - %{mklibname test 1 -d 0 -s} => %{_lib}test1_0-static-devel
%mklibname(ds)  %{_lib}%{1}%{?2:%{2}}%{?3:_%{3}}%{-s:-static}%{-d:-devel}

=== mkrel ===

# Macro: %mkrel [-c <snapver>] <number>
# - %mkrel 1                    => 1%{?subrel:.%subrel}%{?dist}
# - %mkrel -c rc1 1             => 0.rc1.1%{?subrel:.%subrel}%{?dist}
%mkrel(c:) %{-c: 0.%{-c*}.}%{1}%{?subrel:.%subrel}%{?dist:%dist}

Comment 1 clime 2016-09-29 14:29:04 UTC
Fixed by https://github.com/fedora-copr/copr/commit/13b53c9d.


Note You need to log in before you can comment on or make changes to this bug.