Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 608572 - app-crypt/pesign-0.112: Version bump
Summary: app-crypt/pesign-0.112: Version bump
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: No maintainer - Look at https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers if you want to take care of it
URL:
Whiteboard:
Keywords: EBUILD, PATCH
Depends on:
Blocks: 608578
  Show dependency tree
 
Reported: 2017-02-07 21:30 UTC by David Michael
Modified: 2017-02-09 23:42 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
app-crypt/pesign: Add an ebuild for 0.112 (0001-app-crypt-pesign-Add-an-ebuild-for-0.112.patch,3.16 KB, patch)
2017-02-07 21:30 UTC, David Michael
Details | Diff
Updated patch (0001-app-crypt-pesign-Add-an-ebuild-for-0.112.patch,5.88 KB, patch)
2017-02-08 00:43 UTC, David Michael
Details | Diff
Updated updated patch (0001-app-crypt-pesign-Add-an-ebuild-for-0.112.patch,6.04 KB, patch)
2017-02-09 20:13 UTC, David Michael
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description David Michael 2017-02-07 21:30:06 UTC
Created attachment 462830 [details, diff]
app-crypt/pesign: Add an ebuild for 0.112

I'd like to have some of the new commands that were added to the pesign project after Gentoo's latest version.  Can it be updated?  Attached is a patch to add an ebuild for pesign-0.112, based off the existing pesign-0.108 ebuild.
Comment 1 Jonas Stein gentoo-dev 2017-02-07 22:46:49 UTC
Thank you.

I suggest to bump EAPI=6 too and move the

src_prepare() {
	epatch "${FILESDIR}"/${P}-fix-initializer.patch
}

section in one patch array.
https://devmanual.gentoo.org/ebuild-writing/eapi/

Unfortunately we have no maintainer for this ebuild at the moment.
Do you want to proxy maintain it? If yes, look at
https://wiki.gentoo.org/wiki/Project:Proxy_Maintainers
and contact the proxy project.
Comment 2 David Michael 2017-02-08 00:43:43 UTC
Created attachment 462838 [details, diff]
Updated patch

I've updated the patch to EAPI=6 (with some other tweaks), and I've submitted the maintainership request at #608578.
Comment 3 Göktürk Yüksek archtester gentoo-dev 2017-02-09 07:30:59 UTC
Hi,

I'd like to suggest a few changes to your ebuild:

- You don't need to inherit multilib because it's not utilized
- The build system uses gcc for CC blindly. We should override it with the proper CC. To do so,
  - inherit toolchain-funcs
  - create a custom src_compile:

      src_compile() {
	emake CC="$(tc-getCC)"
      }

- The version string is not compatible with the Gentoo versioning, so we need to override VERSION in src_install:
  - replace "default" in src_install() with the following:

      emake DESTDIR="${ED}" VERSION="${PVR}" install
      einstalldocs

- The variable ${ED} ends with a trailing slash by default. Instead of typing ${ED}/etc, use ${ED%/}/etc
- We do not copy licenses to the user's system, so remove "${ED%/}/usr/share/doc/${PF}/COPYING" at the end of src_install()

Here's the total diff of the proposed changes:

@@ -4,7 +4,7 @@
 
 EAPI=6
 
-inherit eutils multilib
+inherit eutils toolchain-funcs
 
 DESCRIPTION="Tools for manipulating signed PE-COFF binaries"
 HOMEPAGE="https://github.com/vathpela/pesign"
@@ -33,9 +33,15 @@
 	"${FILESDIR}"/${PN}-0.112-fix-initializer.patch
 )
 
+src_compile() {
+	emake CC="$(tc-getCC)"
+}
+
 src_install() {
-	default
+	emake DESTDIR="${ED}" VERSION="${PVR}" install
+	einstalldocs
 
 	# remove some files that don't make sense for Gentoo installs
-	rm -rf "${ED}/etc/" "${ED}/var/" || die
+	rm -rf "${ED%/}/etc/" "${ED%/}/var/" \
+	   "${ED%/}/usr/share/doc/${PF}/COPYING" || die
 }

Let me know if you have any questions
Comment 4 David Michael 2017-02-09 20:13:43 UTC
Created attachment 463052 [details, diff]
Updated updated patch

Okay, thanks, I've attached a patch incorporating your changes.
Comment 5 Göktürk Yüksek archtester gentoo-dev 2017-02-09 23:42:28 UTC
commit bc18c616f9a7e080e08092b848032c5af38120f1
Author:     David Michael <david.michael@coreos.com>
AuthorDate: Tue Feb 7 13:23:11 2017 -0800
Commit:     Göktürk Yüksek <gokturk@gentoo.org>
CommitDate: Thu Feb 9 18:41:17 2017 -0500

    app-crypt/pesign: Add an ebuild for 0.112 #608572