commit:     812e799438544560111c81fb6abfd1f0b80857f9
Author:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
AuthorDate: Sun Nov 29 18:31:57 2020 +0000
Commit:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
CommitDate: Sun Nov 29 18:48:23 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=812e7994

dev-libs/libmpack: new package

This is the mpack C lib, which will be needed for a newer lua mpack
module version.

Package-Manager: Portage-3.0.9, Repoman-3.0.2
Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org>

 dev-libs/libmpack/Manifest              |  1 +
 dev-libs/libmpack/libmpack-1.0.5.ebuild | 52 +++++++++++++++++++++++++++++++++
 dev-libs/libmpack/metadata.xml          | 11 +++++++
 3 files changed, 64 insertions(+)

diff --git a/dev-libs/libmpack/Manifest b/dev-libs/libmpack/Manifest
new file mode 100644
index 00000000000..f158170965e
--- /dev/null
+++ b/dev-libs/libmpack/Manifest
@@ -0,0 +1 @@
+DIST libmpack-1.0.5.tar.gz 32966 BLAKE2B 
8ad01de11c740c3efc7b42046b89f7691dd32d228e126485bc49224e54789e7f12a611982c0fd9d2bbe8b06d1ce2df1ceea1b302e139e30d0a8c31f251129166
 SHA512 
6e30edafcacfb580b410bc6749ed7fe8f18b3be0cb98959339853e77bc3ec0cda6df08a0f1f22768cfc773458a2ea6bcef4f0421eea55cf56c58981d13711a04

diff --git a/dev-libs/libmpack/libmpack-1.0.5.ebuild 
b/dev-libs/libmpack/libmpack-1.0.5.ebuild
new file mode 100644
index 00000000000..479c92bd7b2
--- /dev/null
+++ b/dev-libs/libmpack/libmpack-1.0.5.ebuild
@@ -0,0 +1,52 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs
+
+DESCRIPTION="Simple implementation of msgpack in C"
+HOMEPAGE="https://github.com/libmpack/libmpack";
+SRC_URI="https://github.com/${PN}/${PN}/archive/${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~arm64 ~x86"
+
+DEPEND=""
+RDEPEND="${DEPEND}"
+BDEPEND=""
+
+src_prepare() {
+       default
+
+       # Make compiling verbose
+       sed -e 's/@$(LIBTOOL)/$(LIBTOOL)/g' -i Makefile || die
+
+       # Respect users CFLAGS
+       sed -e 's/-ggdb//g' -i Makefile || die
+       sed -e 's/-O3//g' -i .config/release.mk || die
+}
+
+src_compile() {
+       local myemakeargs=(
+               "CC=$(tc-getCC)"
+               "config=release"
+               "LIBDIR=/usr/$(get_libdir)"
+       )
+
+       emake "${myemakeargs[@]}" lib-bin
+}
+
+src_install() {
+       local myemakeargs=(
+               "PREFIX=/usr"
+               "DESTDIR=${ED}"
+               "LIBDIR=/usr/$(get_libdir)"
+               "XLDFLAGS=-shared"
+       )
+
+       emake "${myemakeargs[@]}" install
+
+       find "${ED}" -name '*.la' -delete || die
+}

diff --git a/dev-libs/libmpack/metadata.xml b/dev-libs/libmpack/metadata.xml
new file mode 100644
index 00000000000..def85419cfb
--- /dev/null
+++ b/dev-libs/libmpack/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd";>
+<pkgmetadata>
+       <maintainer type="person">
+               <email>conik...@gentoo.org</email>
+               <name>Conrad Kostecki</name>
+       </maintainer>
+       <upstream>
+               <remote-id type="github">libmpack/libmpack</remote-id>
+       </upstream>
+</pkgmetadata>

Reply via email to