LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 851|回复: 1

[ebuild]amule-svn-10254, 支持粘贴ed2k中文链接,优化了KAD搜索,优化了界面,等等。

[复制链接]
发表于 2010-7-28 09:09:30 | 显示全部楼层 |阅读模式

  1. # Copyright 1999-2010 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. # $Header: $

  4. EAPI=3

  5. inherit eutils flag-o-matic wxwidgets

  6. # bleeding-edge development
  7. MY_P="aMule-SVN-r${PV}"
  8. # 2_2_X branch, currently unavailable
  9. # MY_P="aMule-SVN-r${PV}-RELEASE-2_2_X"

  10. S="${WORKDIR}/${MY_P}"

  11. DESCRIPTION="aMule, the all-platform eMule p2p client"
  12. HOMEPAGE="http://www.amule.org/"
  13. SRC_URI="http://amule.sourceforge.net/tarballs/${MY_P}.tar.bz2"

  14. LICENSE="GPL-2"
  15. SLOT="0"
  16. KEYWORDS="~alpha ~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
  17. IUSE="daemon debug geoip gtk nls remote stats unicode upnp xchat"

  18. RESTRICT="nomirror"

  19. DEPEND="=x11-libs/wxGTK-2.8*
  20.         >=dev-libs/crypto++-5.5.2
  21.         >=sys-libs/zlib-1.2.1
  22.         stats? ( >=media-libs/gd-2.0.26[jpeg] )
  23.         geoip? ( dev-libs/geoip )
  24.         upnp? ( >=net-libs/libupnp-1.6.6 )
  25.         remote? ( >=media-libs/libpng-1.2.0
  26.         unicode? ( >=media-libs/gd-2.0.26 ) )"

  27. RDEPEND="$DEPEND
  28.         xchat? ( net-irc/xchat[perl] )"


  29. pkg_setup() {
  30.         if ! use gtk && ! use remote && ! use daemon; then
  31.                 eerror ""
  32.                 eerror "You have to specify at least one of gtk, remote or daemon"
  33.                 eerror "USE flag to build amule."
  34.                 eerror ""
  35.                 die "Invalid USE flag set"
  36.         fi

  37.         if use stats && ! use gtk; then
  38.                 einfo "Note: You would need both the gtk and stats USE flags"
  39.                 einfo "to compile aMule Statistics GUI."
  40.                 einfo "I will now compile console versions only."
  41.         fi
  42. }

  43. pkg_preinst() {
  44.         if use daemon || use remote; then
  45.                 enewgroup p2p
  46.                 enewuser p2p -1 -1 /home/p2p p2p
  47.         fi
  48. }

  49. src_configure() {
  50.         local myconf

  51.         WX_GTK_VER="2.8"

  52.         if use gtk; then
  53.                 einfo "wxGTK with gtk support will be used"
  54.                 need-wxwidgets unicode
  55.         else
  56.                 einfo "wxGTK without X support will be used"
  57.                 need-wxwidgets base
  58.         fi

  59.         if use gtk ; then
  60.                 use stats && myconf="${myconf}
  61.                         --enable-wxcas
  62.                         --enable-alc"
  63.                 use remote && myconf="${myconf}
  64.                         --enable-amule-gui"
  65.         else
  66.                 myconf="
  67.                         --disable-monolithic
  68.                         --disable-amule-gui
  69.                         --disable-wxcas
  70.                         --disable-alc"
  71.         fi

  72.         econf \
  73.                 --with-wx-config=${WX_CONFIG} \
  74.                 --with-wxbase-config=${WX_CONFIG} \
  75.                 --enable-amulecmd \
  76.                 $(use_enable debug) \
  77.                 $(use_enable !debug optimize) \
  78.                 $(use_enable daemon amule-daemon) \
  79.                 $(use_enable geoip) \
  80.                 $(use_enable nls) \
  81.                 $(use_enable remote webserver) \
  82.                 $(use_enable stats cas) \
  83.                 $(use_enable stats alcc) \
  84.                 $(use_enable xchat xas) \
  85.                 ${myconf} || die
  86. }

  87. src_install() {
  88.         emake DESTDIR="${D}" install || die

  89.         if use daemon; then
  90.                 newconfd "${FILESDIR}"/amuled.confd amuled
  91.                 newinitd "${FILESDIR}"/amuled.initd amuled
  92.         fi
  93.         if use remote; then
  94.                 newconfd "${FILESDIR}"/amuleweb.confd amuleweb
  95.                 newinitd "${FILESDIR}"/amuleweb.initd amuleweb
  96.         fi
  97. }

复制代码
发表于 2010-7-28 17:03:47 | 显示全部楼层
安装成功:
1。把文件命名为amule-10254.ebuild,放到 portage 目录,
2。ebuild  amule-10254.ebuild manifest
3。emerge amule
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表