Bug 1416691 - gettext-0.19.8.1-3.fc25 FTBFS when building without git
Summary: gettext-0.19.8.1-3.fc25 FTBFS when building without git
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Deadline: 2017-02-09
Product: Fedora
Classification: Fedora
Component: gettext
Version: 25
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Pavel Raiskup
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: BaseRuntimeFTBFS
TreeView+ depends on / blocked
 
Reported: 2017-01-26 09:25 UTC by Merlin Mathesius
Modified: 2017-03-06 17:26 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-01-26 15:03:29 UTC


Attachments (Terms of Use)
proposed patch to correct FTBFS issue and git dependency (1.49 KB, patch)
2017-01-26 09:31 UTC, Merlin Mathesius
no flags Details | Diff


Links
System ID Priority Status Summary Last Updated
Red Hat Bugzilla 1161284 None None None Never

Internal Links: 1161284

Description Merlin Mathesius 2017-01-26 09:25:32 UTC
Description of problem:
When attempting to rebuild portions of the frozen package set of Fedora 25 for the Base Runtime effort, we discovered that gettext has an undesirable hard runtime requirement upon git. When making a test build without git, it was also found that the package fails to build due to %autosetup's use of git.

Version-Release number of selected component (if applicable):
gettext-0.19.8.1-3.fc25

How reproducible:
Every time

Steps to Reproduce (rawhide):
1. fedpkg clone gettext && cd gettext
2. fedpkg switch-branch master
3. fedpkg srpm
4. mock --root=fedora-25-x86_64 --without=git gettext-0.19.8.1-6.fc26.src.rpm 

Actual results:
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.42u1jg
+ umask 022
+ cd /builddir/build/BUILD
+ cd /builddir/build/BUILD
+ rm -rf gettext-0.19.8.1
+ /usr/bin/tar -xof -
+ /usr/bin/xz -dc /builddir/build/SOURCES/gettext-0.19.8.1.tar.xz
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd gettext-0.19.8.1
+ /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ /usr/bin/git init -q
/var/tmp/rpm-tmp.42u1jg: line 42: /usr/bin/git: No such file or directory


Expected results:
Successful build of the package.

Additional info:
Attached is a patch that corrects the error when building without git. The patch also fixes the default "with git" case so the gettext-devel subpackage only Recommends: git rather than the strict Requires to avoid at unnecessary mandatory dependency upon git. This is needed for the Base Runtime Project.

Please apply the patch or respond with a reason it should not be applied within two weeks. After that time, a provenpackager will go ahead and apply it.

Comment 1 Merlin Mathesius 2017-01-26 09:31:26 UTC
Created attachment 1244654 [details]
proposed patch to correct FTBFS issue and git dependency

Comment 2 Pavel Raiskup 2017-01-26 09:36:07 UTC
Speaking about BuildRequires issue ... so does that mean that you can't
build Base Runtime package against non-Base Runtime package?  Why?

Comment 3 Pavel Raiskup 2017-01-26 09:41:16 UTC
I mean, what's wrong on '%autosetup -S git'?  I'll rather drop that
unconditionally because that's not related to 'bcond_with git' switch ..

Also, doing such changes is a bit annoying, there's basically nothing
wrong on '-S git' ... and I'm curious whether you document somewhere that
it is from now forbidden to use '%autosetup -S git' from now for "certain"
set of packages.

Comment 4 Merlin Mathesius 2017-01-26 10:36:38 UTC
Sorry if I wasn't clear, but there are two things are going on here.

1. There's nothing wrong with using %autosetup '-S git', but it does mean there needs to be a 'BuildRequires: git'--since git is not otherwise guaranteed to be in the buildroot. That BR is currently within a "%{with git}" conditional. Thus, when attempting to build using the --without=git, the build fails.

2. For Base Runtime, we are making every effort to eliminate unnecessary mandatory dependencies to minimize the size. Base Runtime should include the gettext-devel subpackage, but we do not want to include git, Changing the "Requires: git" to "Recommends: git" will allow that--since git doesn't need to be a strict requirement. Such a change should also do no harm for the standard Fedora releases.

Comment 5 Pavel Raiskup 2017-01-26 12:18:09 UTC
(In reply to Merlin Mathesius from comment #4)
> Sorry if I wasn't clear, but there are two things are going on here.
> 
> 1. There's nothing wrong with using %autosetup '-S git', but it does mean
> there needs to be a 'BuildRequires: git'--since git is not otherwise
> guaranteed to be in the buildroot. That BR is currently within a "%{with
> git}" conditional. Thus, when attempting to build using the --without=git,
> the build fails.

That sounds good then.  We can have the BuildRequires unconditional.

> 2. For Base Runtime, we are making every effort to eliminate unnecessary
>    mandatory dependencies to minimize the size. Base Runtime should
>    include the gettext-devel subpackage, but we do not want to include
>    git, Changing the "Requires: git" to "Recommends: git" will allow
>    that--since git doesn't need to be a strict requirement. Such a
>    change should also do no harm for the standard Fedora releases.

Based on bug 1161284 (and based on /bin/autopoint source code), we can
avoid git dependency.

Rawhide:
http://pkgs.fedoraproject.org/cgit/rpms/gettext.git/commit/?id=83c226dd020a8f15

Can you confirm it is OK?  There was also bug 1405433 (related to Base
Runtime?), which was _not_ merged into F25.  So I guess it is OK to stay in
Rawhide with this bugreport, right?

Comment 6 Merlin Mathesius 2017-01-26 14:56:22 UTC
Rawhide is fine. Thank you for the quick fix!


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