LinuxSir.cn,穿越时空的Linuxsir!

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

请教一个ebuild写法

[复制链接]
发表于 2009-3-14 15:54:29 | 显示全部楼层 |阅读模式
第一次写ebuild, 还不是一般的难。实在不会了, 请兄弟们指点一下。谢谢了.

一切祸事源于想装那个csv2latex, 因为想做latex表格省点事, csv2latex网址是 http://brouits.free.fr/csv2latex/.

但是网站的那个ebuild (http://brouits.free.fr/csv2latex/csv2latex.ebuild) 用不了。而且依赖也没有处理好。只好自己动手,把它重命名为csv2latex-0.13.ebuild方便以后识别版本,并且把它放到/usr/local/portage/dev-tex/里面去了(感觉它是dev-tex类的).

ebuild 改成了下面这个样子,因为网站上说它要依赖docbook-to-man这个utility,用eix查到一个docbook2x, 所以我加上了app-text/docbook2X这个包. 它原来的PREFIX写法感觉也不是那么回事,ebuild老是报错,也改了.


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

  4. DESCRIPTION="A csv to LaTeX file converter"
  5. HOMEPAGE="http://brouits.free.fr/csv2latex/"
  6. SRC_URI="${HOMEPAGE}/${P}.tar.gz"

  7. LICENSE="GPL-2"
  8. SLOT="0"
  9. KEYWORDS="~x86"
  10. IUSE=""

  11. RDEPEND="app-text/docbook2X"
  12. DEPEND="${RDEPEND}"

  13. src_compile() {
  14.      emake || die "emake failed"
  15. }

  16. src_install() {
  17.     --prefix=/usr/local/bin
  18.     emake DESTDIR="${D}" install  || die "Install failed"
  19. }
复制代码


但还是装不了。从完装完docbook2X的提示可以得知:

>>> Installing app-text/docbook2X-0.8.8-r2
* To avoid conflict with docbook-sgml-utils, which is much more widely used,
* all executables have been renamed to *.pl.

cvs2latex依赖的是docbook-to-man, 而现在这个命令好象变成了: docbook2man.pl.

所以现在想emerge cvs2latex出现的状况是:

  1. >>> Emerging (7 of 7) dev-tex/csv2latex-0.13
  2. * csv2latex-0.13.tar.gz RMD160 SHA1 SHA256 size ;-) ...                 [ ok ]
  3. * checking ebuild checksums ;-) ...                                     [ ok ]
  4. * checking auxfile checksums ;-) ...                                    [ ok ]
  5. * checking miscfile checksums ;-) ...                                   [ ok ]
  6. >>> Unpacking source...
  7. >>> Unpacking csv2latex-0.13.tar.gz to /var/tmp/portage/dev-tex/csv2latex-0.13/work
  8. >>> Source unpacked in /var/tmp/portage/dev-tex/csv2latex-0.13/work
  9. >>> Compiling source in /var/tmp/portage/dev-tex/csv2latex-0.13/work/csv2latex-0.13 ...
  10. make -j3
  11. cc -Wall -Wextra -pedantic -Os csv2latex.c -o csv2latex
  12. docbook-to-man csv2latex.sgml > csv2latex.1
  13. /bin/sh: docbook-to-man: command not found
  14. make: *** [all] Error 127
  15. *
  16. * ERROR: app-office/csv2latex-0.13 failed.
  17. * Call stack:
  18. *               ebuild.sh, line   49:  Called src_compile
  19. *             environment, line   80:  Called die
  20. * The specific snippet of code:
  21. *       emake || die "emake failed"
  22. *  The die message:
  23. *   emake failed
  24. *
  25. * If you need support, post the topmost build error, and the call stack if relevant.
  26. * A complete build log is located at '/var/tmp/portage/dev-tex/csv2latex-0.13/temp/build.log'.
  27. * The ebuild environment file is located at '/var/tmp/portage/dev-tex/csv2latex-0.13/temp/environment'.
  28. * This ebuild is from an overlay: '/usr/local/portage/'
复制代码


请教一下如果依赖的关系变名称了,ebuild该怎么写?
发表于 2009-3-14 16:57:50 | 显示全部楼层
http://devmanual.gentoo.org/
去这里学习下
回复 支持 反对

使用道具 举报

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

本版积分规则

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