{"thread":{"id":"22450","subject":"[RFH] rpm packaging failure","startedAt":"2010-01-30T09:24:36Z","lastAt":"2010-01-31T23:46:08Z","messageCount":11,"participants":["Junio C Hamano","Todd Zullinger","Johan Herland","Sverre Rabbelier","David Aguilar"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"133109","messageId":"7v8wbgueqz.fsf@alter.siamese.dyndns.org","threadId":"22450","inReplyTo":null,"subject":"[RFH] rpm packaging failure","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-30T09:24:36Z","receivedAt":"2010-01-30T09:24:36Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Subject: [PATCH] experimental RPM spec change\n\n\"make rpm\" with recent 'master' fails with:\n\n    RPM build errors:\n        Installed (but unpackaged) file(s) found:\n       /usr/lib/python2.6/site-packages/git_remote_helpers-0.1.0-py2.6.egg-info\n       /usr/lib/python2.6/site-packages/git_remote_helpers/__init__.py\n       /usr/lib/python2.6/site-packages/git_remote_helpers/__init__.pyc\n       /usr/lib/python2.6/site-packages/git_remote_helpers/git/__init__.py\n       /usr/lib/python2.6/site-packages/git_remote_helpers/git/__init__.pyc\n       /usr/lib/python2.6/site-packages/git_remote_helpers/git/git.py\n       /usr/lib/python2.6/site-packages/git_remote_helpers/git/git.pyc\n       /usr/lib/python2.6/site-packages/git_remote_helpers/util.py\n       /usr/lib/python2.6/site-packages/git_remote_helpers/util.pyc\n\nHere is an attempt to fix it, but help is very appreciated, as I don't\nknow what the accepted way is to ship Python modules is in the RPM world.\n\nSigned-off-by: Junio C Hamano <gitster@pobox.com>\n---\n git.spec.in |    1 +\n 1 files changed, 1 insertions(+), 0 deletions(-)\n\ndiff --git a/git.spec.in b/git.spec.in\nindex ab224f7..1aeba90 100644\n--- a/git.spec.in\n+++ b/git.spec.in\n@@ -121,6 +121,7 @@ find $RPM_BUILD_ROOT -type f -name perllocal.pod -exec rm -f {} ';'\n (find $RPM_BUILD_ROOT%{perl_vendorlib} -type f | sed -e s@^$RPM_BUILD_ROOT@@) >> perl-files\n %if %{!?_without_docs:1}0\n (find $RPM_BUILD_ROOT%{_mandir} $RPM_BUILD_ROOT/Documentation -type f | grep -vE \"archimport|svn|git-cvs|email|gitk|git-gui|git-citool\" | sed -e s@^$RPM_BUILD_ROOT@@ -e 's/$/*/' ) >> bin-man-doc-files\n+(find $RPM_BUILD_ROOT%{_libdir}/python* -type f | sed -e s@^$RPM_BUILD_ROOT@@ -e 's/$/*/' ) >> bin-man-doc-files\n %else\n rm -rf $RPM_BUILD_ROOT%{_mandir}\n %endif\n-- \n1.7.0.rc0\n"},{"id":"133115","messageId":"20100130151921.GM29188@inocybe.localdomain","threadId":"22450","inReplyTo":"7v8wbgueqz.fsf@alter.siamese.dyndns.org","subject":"Re: [RFH] rpm packaging failure","fromName":"Todd Zullinger","fromEmail":"tmz@pobox.com","sentAt":"2010-01-30T15:19:21Z","receivedAt":"2010-01-30T15:19:21Z","isPatch":false,"sender":{"key":"tmz@pobox.com","avatar":"https://avatars.githubusercontent.com/u/806319?v=4"},"body":"Junio C Hamano wrote:\n> Here is an attempt to fix it, but help is very appreciated, as I don't\n> know what the accepted way is to ship Python modules is in the RPM world.\n\nPerhaps this will work well.  I only tested it on Fedora 10, but I\nbelieve it should work on RHEL/CentOS and most other rpm-based\ndistros.  We may well want to package the python bits in a subpackage,\nmuch as the perl modules are.  Anyone have thoughts on that?\n\n-->8--\nSubject: [PATCH] RPM spec: Package git_remote_helper python files\n\nSigned-off-by: Todd Zullinger <tmz@pobox.com>\n---\n git.spec.in |    6 ++++++\n 1 files changed, 6 insertions(+), 0 deletions(-)\n\ndiff --git a/git.spec.in b/git.spec.in\nindex ab224f7..575156c 100644\n--- a/git.spec.in\n+++ b/git.spec.in\n@@ -1,4 +1,5 @@\n # Pass --without docs to rpmbuild if you don't want the documentation\n+%{!?python_sitelib: %global python_sitelib %(%{__python} -c \"from distutils.sysconfig import get_python_lib; print get_python_lib()\")}\n \n Name: \t\tgit\n Version: \t@@VERSION@@\n@@ -9,6 +10,7 @@ Group: \t\tDevelopment/Tools\n URL: \t\thttp://kernel.org/pub/software/scm/git/\n Source: \thttp://kernel.org/pub/software/scm/git/%{name}-%{version}.tar.gz\n BuildRequires:\tzlib-devel >= 1.2, openssl-devel, curl-devel, expat-devel, gettext  %{!?_without_docs:, xmlto, asciidoc > 6.0.3}\n+BuildRequires:\tpython\n BuildRoot:\t%{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)\n \n Requires:\tperl-Git = %{version}-%{release}\n@@ -134,6 +136,7 @@ rm -rf $RPM_BUILD_ROOT\n %doc README COPYING Documentation/*.txt\n %{!?_without_docs: %doc Documentation/*.html Documentation/howto}\n %{!?_without_docs: %doc Documentation/technical}\n+%{python_sitelib}/*\n \n %files svn\n %defattr(-,root,root)\n@@ -190,6 +193,9 @@ rm -rf $RPM_BUILD_ROOT\n # No files for you!\n \n %changelog\n+* Sat Jan 30 2010 Todd Zullinger <tmz@pobox.com>\n+- Include git_remote_helper python files\n+\n * Mon Feb 04 2009 David J. Mellor <dmellor@whistlingcat.com>\n - fixed broken git help -w after renaming the git-core package to git.\n \n-- \n1.6.6\n\n-- \nTodd        OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nDon't hit a man when he's down -- kick him; it's easier.\n"},{"id":"133125","messageId":"7vsk9nsemh.fsf@alter.siamese.dyndns.org","threadId":"22450","inReplyTo":"20100130151921.GM29188@inocybe.localdomain","subject":"Re: [RFH] rpm packaging failure","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-30T17:10:14Z","receivedAt":"2010-01-30T17:10:14Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Todd Zullinger <tmz@pobox.com> writes:\n\n> Junio C Hamano wrote:\n>> Here is an attempt to fix it, but help is very appreciated, as I don't\n>> know what the accepted way is to ship Python modules is in the RPM world.\n>\n> Perhaps this will work well.  I only tested it on Fedora 10, but I\n> believe it should work on RHEL/CentOS and most other rpm-based\n> distros.  We may well want to package the python bits in a subpackage,\n> much as the perl modules are.  Anyone have thoughts on that?\n\nThanks.\n\nThe files that are problematic are only infrastructure bits to support\n\"remote helpers written in Python\" (which we don't ship at all yet).\n\nOnce we start shipping real remote helpers, separating Python bits out\ninto its own package would make a lot of sense.  People who want to use\nforeign scm helpers that happen to be written in Python would need it, and\nall others don't.\n\nBut I suspect that a safer alternative at least for 1.7.0 would be to\nleave these files out altogether.  As I understand the current state, it\nis an unused but required package dependency on Python, a downside without\nan upside.  Is it Ok with \"remote helpers in Python\" folks (I think Sverre\nand Johan are principal parties), or did I miss some reason that these\nneed to be installed/installable, perhaps to support third party packages\nthat already exist?\n\nAnd if the removal is the way to go for 1.7.0, is the following an Ok\napproach to do that removal (this is asking an RPM help again to Todd)?\n\n\n\n git.spec.in |    4 ++++\n 1 files changed, 4 insertions(+), 0 deletions(-)\n\ndiff --git a/git.spec.in b/git.spec.in\nindex ab224f7..ec3451a 100644\n--- a/git.spec.in\n+++ b/git.spec.in\n@@ -112,6 +112,7 @@ rm -rf $RPM_BUILD_ROOT\n make %{_smp_mflags} CFLAGS=\"$RPM_OPT_FLAGS\" DESTDIR=$RPM_BUILD_ROOT \\\n      %{path_settings} \\\n      INSTALLDIRS=vendor install %{!?_without_docs: install-doc}\n+rm -fr $RPM_BUILD_ROOT%{_libdir}/python*\n find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name '*.bs' -empty -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name perllocal.pod -exec rm -f {} ';'\n@@ -190,6 +191,9 @@ rm -rf $RPM_BUILD_ROOT\n # No files for you!\n \n %changelog\n+* Sat Jan 30 2010 Junio C Hamano <gitster@pobox.com>\n+- We don't ship Python bits until a real foreign scm interface comes.\n+\n * Mon Feb 04 2009 David J. Mellor <dmellor@whistlingcat.com>\n - fixed broken git help -w after renaming the git-core package to git.\n \n"},{"id":"133136","messageId":"20100130194746.GN29188@inocybe.localdomain","threadId":"22450","inReplyTo":"7vsk9nsemh.fsf@alter.siamese.dyndns.org","subject":"Re: [RFH] rpm packaging failure","fromName":"Todd Zullinger","fromEmail":"tmz@pobox.com","sentAt":"2010-01-30T19:47:46Z","receivedAt":"2010-01-30T19:47:46Z","isPatch":false,"sender":{"key":"tmz@pobox.com","avatar":"https://avatars.githubusercontent.com/u/806319?v=4"},"body":"Junio C Hamano wrote:\n> The files that are problematic are only infrastructure bits to\n> support \"remote helpers written in Python\" (which we don't ship at\n> all yet).\n\nAhh, I hadn't followed along closely enough to know that nothing which\nused these files was installed.\n\n> And if the removal is the way to go for 1.7.0, is the following an\n> Ok approach to do that removal (this is asking an RPM help again to\n> Todd)?\n\nNot shipping them if they aren't yet used/needed for anything other\nthan folks working on remote helpers seems reasonable and the rm in\nthe spec file should do the trick nicely.  But I have to wonder why\neven bother installing them via make install if folks packaging via\nrpms, debs, etc. will all have to manually remove these files?\n\n-- \nTodd        OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nI have never let my schooling interfere with my education.\n    -- Mark Twain (1835-1910)\n\n"},{"id":"133142","messageId":"7vd40rjks4.fsf@alter.siamese.dyndns.org","threadId":"22450","inReplyTo":"20100130194746.GN29188@inocybe.localdomain","subject":"Re: [RFH] rpm packaging failure","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-30T22:22:03Z","receivedAt":"2010-01-30T22:22:03Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Todd Zullinger <tmz@pobox.com> writes:\n\n> Not shipping them if they aren't yet used/needed for anything other\n> than folks working on remote helpers seems reasonable and the rm in\n> the spec file should do the trick nicely.\n\nThanks.\n\nTo allow us to go forward a bit easier, I am planning to use the attached,\nas we would need some parts of it when we do start generating a separate\npackage, I think.\n\n-- >8 --\nSubject: [PATCH] RPM packaging: don't include foreign-scm-helper bits yet\n\nThe files in /usr/lib/python* are only the support infrastructure for\nforeign scm interface yet to be written and/or shipped with git.  Don't\ninclude them in the binary package (this will also free us from Python\ndependency).\n\nWhen we ship with foreign scm interface, we will need to package these\nfiles with it in a separate subpackage, but we are not there yet.\n\nSigned-off-by: Junio C Hamano <gitster@pobox.com>\n---\n git.spec.in |    5 +++++\n 1 files changed, 5 insertions(+), 0 deletions(-)\n\ndiff --git a/git.spec.in b/git.spec.in\nindex ab224f7..0a03108 100644\n--- a/git.spec.in\n+++ b/git.spec.in\n@@ -98,6 +98,7 @@ BuildRequires:  perl(Error)\n Perl interface to Git\n \n %define path_settings ETC_GITCONFIG=/etc/gitconfig prefix=%{_prefix} mandir=%{_mandir} htmldir=%{_docdir}/%{name}-%{version}\n+%{!?python_sitelib: %define python_sitelib %(%{__python} -c \"from distutils.sysconfig import get_python_lib; print get_python_lib()\")}\n \n %prep\n %setup -q\n@@ -112,6 +113,7 @@ rm -rf $RPM_BUILD_ROOT\n make %{_smp_mflags} CFLAGS=\"$RPM_OPT_FLAGS\" DESTDIR=$RPM_BUILD_ROOT \\\n      %{path_settings} \\\n      INSTALLDIRS=vendor install %{!?_without_docs: install-doc}\n+test ! -d $RPM_BUILD_ROOT%{python_sitelib} || rm -fr $RPM_BUILD_ROOT%{python_sitelib}\n find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name '*.bs' -empty -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name perllocal.pod -exec rm -f {} ';'\n@@ -190,6 +192,9 @@ rm -rf $RPM_BUILD_ROOT\n # No files for you!\n \n %changelog\n+* Sat Jan 30 2010 Junio C Hamano <gitster@pobox.com>\n+- We don't ship Python bits until a real foreign scm interface comes.\n+\n * Mon Feb 04 2009 David J. Mellor <dmellor@whistlingcat.com>\n - fixed broken git help -w after renaming the git-core package to git.\n \n-- \n1.7.0.rc1.141.gd3fd2\n"},{"id":"133160","messageId":"201001310106.52303.johan@herland.net","threadId":"22450","inReplyTo":"7vsk9nsemh.fsf@alter.siamese.dyndns.org","subject":"Re: [RFH] rpm packaging failure","fromName":"Johan Herland","fromEmail":"johan@herland.net","sentAt":"2010-01-31T00:06:52Z","receivedAt":"2010-01-31T00:06:52Z","isPatch":false,"sender":{"key":"johan@herland.net","avatar":"https://avatars.githubusercontent.com/u/547031?v=4"},"body":"On Saturday 30 January 2010, Junio C Hamano wrote:\n> The files that are problematic are only infrastructure bits to support\n> \"remote helpers written in Python\" (which we don't ship at all yet).\n> \n> Once we start shipping real remote helpers, separating Python bits out\n> into its own package would make a lot of sense.  People who want to use\n> foreign scm helpers that happen to be written in Python would need it,\n>  and all others don't.\n> \n> But I suspect that a safer alternative at least for 1.7.0 would be to\n> leave these files out altogether.  As I understand the current state, it\n> is an unused but required package dependency on Python, a downside\n>  without an upside.  Is it Ok with \"remote helpers in Python\" folks (I\n>  think Sverre and Johan are principal parties), or did I miss some reason\n>  that these need to be installed/installable, perhaps to support third\n>  party packages that already exist?\n\nAFAICS, there's no reason why these should be installed without anything \nactually using them. Although I defer to Sverre, who did the last work in \nthis area.\n\n\n...Johan\n"},{"id":"133162","messageId":"fabb9a1e1001301656t4ca644f5lf35075ac0f2bed8e@mail.gmail.com","threadId":"22450","inReplyTo":"201001310106.52303.johan@herland.net","subject":"Re: [RFH] rpm packaging failure","fromName":"Sverre Rabbelier","fromEmail":"srabbelier@gmail.com","sentAt":"2010-01-31T00:56:51Z","receivedAt":"2010-01-31T00:56:51Z","isPatch":false,"sender":{"key":"srabbelier@gmail.com","avatar":"https://avatars.githubusercontent.com/u/3098?v=4"},"body":"Heya,\n\nOn Sun, Jan 31, 2010 at 01:06, Johan Herland <johan@herland.net> wrote:\n> AFAICS, there's no reason why these should be installed without anything\n> actually using them. Although I defer to Sverre, who did the last work in\n> this area.\n\nAgreed, no need to package the git_remote_helpers stuff yet in 1.7.0,\nsince it'll be 1.7.1 at the earliest that we'll include git-remote-hg\n(and even that's assuming I'll find the time to work on it).\n\n-- \nCheers,\n\nSverre Rabbelier\n"},{"id":"133167","messageId":"20100131041236.GP29188@inocybe.localdomain","threadId":"22450","inReplyTo":"7vd40rjks4.fsf@alter.siamese.dyndns.org","subject":"Re: [RFH] rpm packaging failure","fromName":"Todd Zullinger","fromEmail":"tmz@pobox.com","sentAt":"2010-01-31T04:12:36Z","receivedAt":"2010-01-31T04:12:36Z","isPatch":false,"sender":{"key":"tmz@pobox.com","avatar":"https://avatars.githubusercontent.com/u/806319?v=4"},"body":"Junio C Hamano wrote:\n> To allow us to go forward a bit easier, I am planning to use the\n> attached, as we would need some parts of it when we do start\n> generating a separate package, I think.\n\nSounds good.  One minor nit, below... ;)\n\n>  %define path_settings ETC_GITCONFIG=/etc/gitconfig prefix=%{_prefix} mandir=%{_mandir} htmldir=%{_docdir}/%{name}-%{version}\n> +%{!?python_sitelib: %define python_sitelib %(%{__python} -c \"from distutils.sysconfig import get_python_lib; print get_python_lib()\")}\n\nIt is probably better to use %global rather than %define here.  The\nFedora packaging guidelines now recommend this:\n\nhttp://fedoraproject.org/wiki/Packaging/Guidelines#.25global_preferred_over_.25define\n\nThe rationale is that %define only really lasts until the closing\nbrace, while %global persists.  A bug in rpm has masked this for a\nlong time, but it now fixed in upstream rpm, which is packaged for\nFedora's rawhide and possible other rpm-based distros.  A bit more\ndetail is available at:\n\nhttps://www.redhat.com/archives/fedora-devel-list/2010-January/msg00093.html\n\n(Which is linked, with an incorrect trailing '|' character from the\nFedora guidelines URL above.)\n\nUsing %global should work on older rpm versions as well as current\nversions, so there should be no downside to using s/%define/%global in\nmost cases.\n\n-- \nTodd        OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp\n~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~\nThe secret to success is knowing who to blame for your failures.\n    -- Demotivators (www.despair.com)\n\n"},{"id":"133188","messageId":"7vsk9mdqx5.fsf@alter.siamese.dyndns.org","threadId":"22450","inReplyTo":"20100131041236.GP29188@inocybe.localdomain","subject":"Re: [RFH] rpm packaging failure","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-31T19:18:14Z","receivedAt":"2010-01-31T19:18:14Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Todd Zullinger <tmz@pobox.com> writes:\n\n> It is probably better to use %global rather than %define here.\n\nThanks; will fix.\n"},{"id":"133205","messageId":"20100131231430.GA10914@gmail.com","threadId":"22450","inReplyTo":"7vd40rjks4.fsf@alter.siamese.dyndns.org","subject":"Re: [RFH] rpm packaging failure","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2010-01-31T23:14:32Z","receivedAt":"2010-01-31T23:14:32Z","isPatch":false,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"On Sat, Jan 30, 2010 at 02:22:03PM -0800, Junio C Hamano wrote:\n> Todd Zullinger <tmz@pobox.com> writes:\n> \n> > Not shipping them if they aren't yet used/needed for anything other\n> > than folks working on remote helpers seems reasonable and the rm in\n> > the spec file should do the trick nicely.\n> \n> Thanks.\n> \n> To allow us to go forward a bit easier, I am planning to use the attached,\n> as we would need some parts of it when we do start generating a separate\n> package, I think.\n> \n> -- >8 --\n> Subject: [PATCH] RPM packaging: don't include foreign-scm-helper bits yet\n> \n> The files in /usr/lib/python* are only the support infrastructure for\n> foreign scm interface yet to be written and/or shipped with git.  Don't\n> include them in the binary package (this will also free us from Python\n> dependency).\n> \n> When we ship with foreign scm interface, we will need to package these\n> files with it in a separate subpackage, but we are not there yet.\n> \n> Signed-off-by: Junio C Hamano <gitster@pobox.com>\n> ---\n>  git.spec.in |    5 +++++\n>  1 files changed, 5 insertions(+), 0 deletions(-)\n\n\nApologies for the late response to this thread.\n\nWould it be simpler to define NO_PYTHON when running make?\nWe can always resurrect %python_sitelib when it is needed.\n\nHere's what that looks like relative to master.\nI've tested this on fedora11.\n\n\nOn a slightly related note, I'm seeing this as well:\n\nerror: Installed (but unpackaged) file(s) found:\n   /usr/lib/Git.pm\n\nMaybe my setup is wanky?\n\n-- >8 --\nFrom 7fb05607633bc424fc29b645e6f4ee7e48371f94 Mon Sep 17 00:00:00 2001\nFrom: David Aguilar <davvid@gmail.com>\nDate: Sun, 31 Jan 2010 14:52:13 -0800\nSubject: [PATCH] RPM packaging: Define NO_PYTHON to avoid Python dependency\n\nWe don't use the Python bits yet so we shouldn't require\npython to build.  The %define used python to calculate\n%python_sitelib and thus incurred a build-time python\ndependency without specifying python in BuildRequires.\n\nSigned-off-by: David Aguilar <davvid@gmail.com>\n---\n git.spec.in |    7 +++++--\n 1 files changed, 5 insertions(+), 2 deletions(-)\n\ndiff --git a/git.spec.in b/git.spec.in\nindex 0a03108..ae7edc6 100644\n--- a/git.spec.in\n+++ b/git.spec.in\n@@ -98,7 +98,6 @@ BuildRequires:  perl(Error)\n Perl interface to Git\n \n %define path_settings ETC_GITCONFIG=/etc/gitconfig prefix=%{_prefix} mandir=%{_mandir} htmldir=%{_docdir}/%{name}-%{version}\n-%{!?python_sitelib: %define python_sitelib %(%{__python} -c \"from distutils.sysconfig import get_python_lib; print get_python_lib()\")}\n \n %prep\n %setup -q\n@@ -106,14 +105,15 @@ Perl interface to Git\n %build\n make %{_smp_mflags} CFLAGS=\"$RPM_OPT_FLAGS\" \\\n      %{path_settings} \\\n+     NO_PYTHON=NotYet \\\n      all %{!?_without_docs: doc}\n \n %install\n rm -rf $RPM_BUILD_ROOT\n make %{_smp_mflags} CFLAGS=\"$RPM_OPT_FLAGS\" DESTDIR=$RPM_BUILD_ROOT \\\n      %{path_settings} \\\n+     NO_PYTHON=NotYet \\\n      INSTALLDIRS=vendor install %{!?_without_docs: install-doc}\n-test ! -d $RPM_BUILD_ROOT%{python_sitelib} || rm -fr $RPM_BUILD_ROOT%{python_sitelib}\n find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name '*.bs' -empty -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name perllocal.pod -exec rm -f {} ';'\n@@ -192,6 +192,9 @@ rm -rf $RPM_BUILD_ROOT\n # No files for you!\n \n %changelog\n+* Sun Jan 31 2010 David Aguilar <davvid@gmail.com>\n+- Define NO_PYTHON until we actually need the Python bits\n+\n * Sat Jan 30 2010 Junio C Hamano <gitster@pobox.com>\n - We don't ship Python bits until a real foreign scm interface comes.\n \n-- \n1.6.2.5\n"},{"id":"133206","messageId":"20100131234607.GB10914@gmail.com","threadId":"22450","inReplyTo":"20100131231430.GA10914@gmail.com","subject":"Re: [RFH] rpm packaging failure","fromName":"David Aguilar","fromEmail":"davvid@gmail.com","sentAt":"2010-01-31T23:46:08Z","receivedAt":"2010-01-31T23:46:08Z","isPatch":false,"sender":{"key":"davvid@gmail.com","avatar":"https://avatars.githubusercontent.com/u/13196?v=4"},"body":"On Sun, Jan 31, 2010 at 03:14:32PM -0800, David Aguilar wrote:\n> On Sat, Jan 30, 2010 at 02:22:03PM -0800, Junio C Hamano wrote:\n> > Todd Zullinger <tmz@pobox.com> writes:\n> > \n> > > Not shipping them if they aren't yet used/needed for anything other\n> > > than folks working on remote helpers seems reasonable and the rm in\n> > > the spec file should do the trick nicely.\n> > \n> > Thanks.\n> > \n> > To allow us to go forward a bit easier, I am planning to use the attached,\n> > as we would need some parts of it when we do start generating a separate\n> > package, I think.\n> > \n> > -- >8 --\n> > Subject: [PATCH] RPM packaging: don't include foreign-scm-helper bits yet\n> > \n> > The files in /usr/lib/python* are only the support infrastructure for\n> > foreign scm interface yet to be written and/or shipped with git.  Don't\n> > include them in the binary package (this will also free us from Python\n> > dependency).\n> > \n> > When we ship with foreign scm interface, we will need to package these\n> > files with it in a separate subpackage, but we are not there yet.\n> > \n> > Signed-off-by: Junio C Hamano <gitster@pobox.com>\n> > ---\n> >  git.spec.in |    5 +++++\n> >  1 files changed, 5 insertions(+), 0 deletions(-)\n> \n> \n> Apologies for the late response to this thread.\n> \n> Would it be simpler to define NO_PYTHON when running make?\n> We can always resurrect %python_sitelib when it is needed.\n> \n> Here's what that looks like relative to master.\n\n\nI see you just pushed out a new master with the %define changes.\nHere's a rebased patch just in case.\n\n-- >8 --\nFrom ac09b94c332564cc7dde3c2f8961990098b5d4a0 Mon Sep 17 00:00:00 2001\nFrom: David Aguilar <davvid@gmail.com>\nDate: Sun, 31 Jan 2010 14:52:13 -0800\nSubject: [PATCH] RPM packaging: Define NO_PYTHON to avoid Python dependency\n\nWe don't use the Python bits yet so we shouldn't require python\nto build.  The %define used python to calculate %python_sitelib\nand thus incurred a build-time python dependency without\nspecifying python in BuildRequires.\n\nSigned-off-by: David Aguilar <davvid@gmail.com>\n---\n git.spec.in |    7 +++++--\n 1 files changed, 5 insertions(+), 2 deletions(-)\n\ndiff --git a/git.spec.in b/git.spec.in\nindex ee74a5e..320829a 100644\n--- a/git.spec.in\n+++ b/git.spec.in\n@@ -98,7 +98,6 @@ BuildRequires:  perl(Error)\n Perl interface to Git\n \n %define path_settings ETC_GITCONFIG=/etc/gitconfig prefix=%{_prefix} mandir=%{_mandir} htmldir=%{_docdir}/%{name}-%{version}\n-%{!?python_sitelib: %global python_sitelib %(%{__python} -c \"from distutils.sysconfig import get_python_lib; print get_python_lib()\")}\n \n %prep\n %setup -q\n@@ -106,14 +105,15 @@ Perl interface to Git\n %build\n make %{_smp_mflags} CFLAGS=\"$RPM_OPT_FLAGS\" \\\n      %{path_settings} \\\n+     NO_PYTHON=NotYet \\\n      all %{!?_without_docs: doc}\n \n %install\n rm -rf $RPM_BUILD_ROOT\n make %{_smp_mflags} CFLAGS=\"$RPM_OPT_FLAGS\" DESTDIR=$RPM_BUILD_ROOT \\\n      %{path_settings} \\\n+     NO_PYTHON=NotYet \\\n      INSTALLDIRS=vendor install %{!?_without_docs: install-doc}\n-test ! -d $RPM_BUILD_ROOT%{python_sitelib} || rm -fr $RPM_BUILD_ROOT%{python_sitelib}\n find $RPM_BUILD_ROOT -type f -name .packlist -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name '*.bs' -empty -exec rm -f {} ';'\n find $RPM_BUILD_ROOT -type f -name perllocal.pod -exec rm -f {} ';'\n@@ -192,6 +192,9 @@ rm -rf $RPM_BUILD_ROOT\n # No files for you!\n \n %changelog\n+* Sun Jan 31 2010 David Aguilar <davvid@gmail.com>\n+- Define NO_PYTHON until we actually need the Python bits.\n+\n * Sun Jan 31 2010 Junio C Hamano <gitster@pobox.com>\n - Do not use %define inside %{!?...} construct.\n \n-- \n1.7.0.rc1.7.gc0da5\n"}]}