/[gentoo-x86]/sci-electronics/kicad/kicad-20130518.ebuild
Gentoo

Contents of /sci-electronics/kicad/kicad-20130518.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Sun Aug 10 20:27:55 2014 UTC (5 years, 11 months ago) by slyfox
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +3 -3 lines
QA: drop trailing '.' from DESCRIPTION

(Portage version: 2.2.11_p9/cvs/Linux x86_64, signed Manifest commit with key 611FF3AA)

1 # Copyright 1999-2014 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/sci-electronics/kicad/kicad-20130518.ebuild,v 1.1 2013/06/06 19:24:31 calchan Exp $
4
5 #TODO:
6 # - python and wxpython scripting
7
8 EAPI="5"
9
10 WX_GTK_VER="2.8"
11
12 inherit eutils unpacker cmake-utils wxwidgets fdo-mime gnome2-utils
13
14 DESCRIPTION="Electronic Schematic and PCB design tools"
15 HOMEPAGE="http://www.kicad-pcb.org"
16
17 RELEASE_DATE="2013-05-18"
18 BZR_REV="4017"
19 UBUNTU_VER="12.04"
20 BASE_SRC_URI="http://iut-tice.ujf-grenoble.fr/cao"
21 SRC_URI="${BASE_SRC_URI}/${PN}-sources-stable_${RELEASE_DATE}_BZR${BZR_REV}.zip
22 ${BASE_SRC_URI}/${PN}-${RELEASE_DATE}-BZR${BZR_REV}-stable-UBUNTU_${UBUNTU_VER}_full_with_components_doc.tgz"
23
24 LICENSE="GPL-2 kicad-doc"
25 SLOT="0"
26
27 KEYWORDS="~amd64 ~x86"
28
29 IUSE="debug"
30 LANGS="de en es fr hu it ja pl pt ru zh_CN"
31 for lang in ${LANGS} ; do
32 IUSE="${IUSE} linguas_${lang}"
33 done
34
35 CDEPEND="x11-libs/wxGTK:${WX_GTK_VER}[gnome,opengl,X]
36 dev-python/wxpython:${WX_GTK_VER}[opengl]"
37 DEPEND="${CDEPEND}
38 >=dev-util/cmake-2.6.4
39 >=dev-libs/boost-1.49[python]
40 app-doc/doxygen"
41 RDEPEND="${CDEPEND}
42 sys-libs/zlib
43 sci-electronics/electronics-menu"
44
45 S="${WORKDIR}/stable_${RELEASE_DATE}_BZR${BZR_REV}"
46
47 src_prepare() {
48 epatch "${FILESDIR}/${PN}-native-boost.patch"
49 epatch "${FILESDIR}/${PN}-desktop-file.patch"
50 epatch "${FILESDIR}/${PN}-scripts.patch"
51 epatch "${FILESDIR}/${PN}-missing-doc.patch"
52 rm -f resources/linux/mime/applications/eeschema.desktop
53 }
54
55 src_configure() {
56 need-wxwidgets unicode
57
58 mycmakeargs="${mycmakeargs}
59 -DKICAD_STABLE_VERSION=ON
60 -DKICAD_wxUSE_UNICODE=ON
61 -DKICAD_DOCS=/usr/share/doc/${PN}
62 -DKICAD_HELP=/usr/share/doc/${PN}"
63
64 # -DKICAD_SCRIPTING=ON
65 # -DKICAD_SCRIPTING_MODULES=ON
66 # -DKICAD_SCRIPTING_WXPYTHON=ON
67
68 cmake-utils_src_configure
69 }
70
71 src_compile() {
72 cmake-utils_src_compile all doxygen-docs
73 }
74
75 src_install() {
76 cmake-utils_src_install
77
78 insinto /usr/share/${PN}
79 doins -r "${WORKDIR}/${PN}/share/library"
80 doins -r "${WORKDIR}/${PN}/share/modules"
81
82 insinto /usr/share/doc/${PN}
83 doins -r "${WORKDIR}/${PN}/doc/contrib"
84
85 insinto /usr/share/doc/${PN}/help
86 for lang in $LANGS ; do
87 if [[ -d "${WORKDIR}/${PN}/doc/help/${lang}" ]] ; then
88 use linguas_$lang && doins -r "${WORKDIR}/${PN}/doc/help/${lang}"
89 fi
90 done
91
92 insinto /usr/share/doc/${PN}/tutorials
93 for lang in $LANGS ; do
94 if [[ -d "${WORKDIR}/${PN}/doc/tutorials/${lang}" ]] ; then
95 use linguas_$lang && doins -r "${WORKDIR}/${PN}/doc/tutorials/${lang}"
96 fi
97 done
98
99 local dev_doc="/usr/share/doc/${PN}/development"
100 insinto ${dev_doc}
101 doins HOW_TO_CONTRIBUTE.txt notes_about_pcbnew_new_file_format.odt TODO.txt uncrustify.cfg
102 doins "${WORKDIR}/${PN}/doc/help/file_formats/file_formats.pdf"
103 cd Documentation
104 doins -r *
105
106 docompress -x \
107 ${dev_doc}/GUI_Translation_HOWTO.odt \
108 ${dev_doc}/notes_about_pcbnew_new_file_format.odt \
109 ${dev_doc}/uncrustify.cfg
110 ${dev_doc}/file_formats.pdf
111 }
112
113 pkg_preinst() {
114 gnome2_icon_savelist
115 }
116
117 pkg_postinst() {
118 fdo-mime_desktop_database_update
119 fdo-mime_mime_database_update
120 gnome2_icon_cache_update
121
122 elog "You may want to emerge media-gfx/wings if you want to create 3D models of components."
123 }
124
125 pkg_postrm() {
126 fdo-mime_desktop_database_update
127 fdo-mime_mime_database_update
128 gnome2_icon_cache_update
129 }

  ViewVC Help
Powered by ViewVC 1.1.20