libnatpmp-20140401-r1.ebuild 882 B

123456789101112131415161718192021222324252627282930
  1. # Copyright 1999-2014 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI="5"
  4. inherit eutils toolchain-funcs multilib
  5. DESCRIPTION="An alternative protocol to UPnP IGD specification"
  6. HOMEPAGE="http://miniupnp.free.fr/libnatpmp.html"
  7. SRC_URI="http://miniupnp.free.fr/files/download.php?file=${P}.tar.gz -> ${P}.tar.gz"
  8. LICENSE="BSD"
  9. SLOT="0"
  10. KEYWORDS="~amd64 ~arm ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
  11. IUSE="static-libs"
  12. src_prepare() {
  13. epatch "${FILESDIR}"/respect-FLAGS-20140401.patch
  14. epatch "${FILESDIR}"/respect-libdir-20120821.patch
  15. use static-libs || epatch "${FILESDIR}"/remove-static-lib-20130911.patch
  16. tc-export CC
  17. }
  18. src_install() {
  19. # Override HEADERS for missing declspec.h wrt #506832
  20. emake HEADERS='declspec.h natpmp.h' PREFIX="${D}" GENTOO_LIBDIR="$(get_libdir)" install
  21. dodoc Changelog.txt README
  22. doman natpmpc.1
  23. }