x2x-1.27-r3.ebuild 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. # Copyright 1999-2014 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. inherit eutils toolchain-funcs
  4. DESCRIPTION="A utility to connect the Mouse and KeyBoard to another X"
  5. HOMEPAGE="http://www.the-labs.com/X11/#x2x"
  6. LICENSE="x2x"
  7. SRC_URI="http://ftp.digital.com/pub/Digital/SRC/x2x/${P}.tar.gz
  8. mirror://debian/pool/main/x/x2x/x2x_1.27-8.diff.gz
  9. mirror://gentoo/x2x_1.27-8-initvars.patch.gz
  10. mirror://gentoo/${P}-license.patch.gz
  11. mirror://gentoo/${P}-keymap.diff.gz"
  12. SLOT="0"
  13. KEYWORDS="amd64 ~arm ~mips ppc x86"
  14. IUSE=""
  15. RDEPEND="x11-libs/libX11
  16. x11-libs/libXtst
  17. x11-libs/libXext"
  18. DEPEND="${RDEPEND}
  19. x11-proto/inputproto
  20. app-text/rman
  21. x11-misc/imake
  22. x11-proto/xproto"
  23. src_unpack() {
  24. unpack ${A}
  25. cd "${S}"
  26. # Patch from Debian to add -north and -south, among other fixes
  27. epatch "${DISTDIR}"/x2x_1.27-8.diff.gz
  28. # Revert part of debian patch messing with CFLAGS
  29. sed -i '/CFLAGS = -Wall/d' Imakefile || die
  30. # Fix variable initialization in Debian patch
  31. epatch "${DISTDIR}"/x2x_1.27-8-initvars.patch.gz
  32. # Patch to add LICENSE
  33. epatch "${DISTDIR}"/${P}-license.patch.gz
  34. # Patch to fix bug #126939
  35. # AltGr does not work in x2x with different keymaps:
  36. epatch "${DISTDIR}"/${P}-keymap.diff.gz
  37. # Man-page is packaged as x2x.1 but needs to be x2x.man for building
  38. mv x2x.1 x2x.man || die
  39. }
  40. src_compile() {
  41. xmkmf || die
  42. emake CC="$(tc-getCC)" CDEBUGFLAGS="${CFLAGS}" \
  43. EXTRA_LDOPTIONS="${LDFLAGS}" || die
  44. }
  45. src_install () {
  46. emake DESTDIR="${D}" install || die
  47. newman x2x.man x2x.1 || die
  48. }