Gentoo Archives: gentoo-commits

From: "Andreas HAttel (dilfridge)" <dilfridge@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in sci-libs/linux-gpib: linux-gpib-3.2.20.ebuild ChangeLog linux-gpib-3.2.18.ebuild
Date: Fri, 06 Dec 2013 00:05:05
Message-Id: 20131206000457.6D73D2004B@flycatcher.gentoo.org
1 dilfridge 13/12/06 00:04:57
2
3 Modified: ChangeLog
4 Added: linux-gpib-3.2.20.ebuild
5 Removed: linux-gpib-3.2.18.ebuild
6 Log:
7 Version bump, remove old
8
9 (Portage version: 2.2.7/cvs/Linux x86_64, signed Manifest commit with key EBE6A336BE19039C!)
10
11 Revision Changes Path
12 1.22 sci-libs/linux-gpib/ChangeLog
13
14 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-libs/linux-gpib/ChangeLog?rev=1.22&view=markup
15 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-libs/linux-gpib/ChangeLog?rev=1.22&content-type=text/plain
16 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-libs/linux-gpib/ChangeLog?r1=1.21&r2=1.22
17
18 Index: ChangeLog
19 ===================================================================
20 RCS file: /var/cvsroot/gentoo-x86/sci-libs/linux-gpib/ChangeLog,v
21 retrieving revision 1.21
22 retrieving revision 1.22
23 diff -u -r1.21 -r1.22
24 --- ChangeLog 13 Nov 2013 11:10:23 -0000 1.21
25 +++ ChangeLog 6 Dec 2013 00:04:57 -0000 1.22
26 @@ -1,6 +1,12 @@
27 # ChangeLog for sci-libs/linux-gpib
28 # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
29 -# $Header: /var/cvsroot/gentoo-x86/sci-libs/linux-gpib/ChangeLog,v 1.21 2013/11/13 11:10:23 nimiux Exp $
30 +# $Header: /var/cvsroot/gentoo-x86/sci-libs/linux-gpib/ChangeLog,v 1.22 2013/12/06 00:04:57 dilfridge Exp $
31 +
32 +*linux-gpib-3.2.20 (06 Dec 2013)
33 +
34 + 06 Dec 2013; Andreas K. Huettel <dilfridge@g.o>
35 + -linux-gpib-3.2.18.ebuild, +linux-gpib-3.2.20.ebuild:
36 + Version bump, remove old
37
38 13 Nov 2013; Chema Alonso <nimiux@g.o> linux-gpib-3.2.19.ebuild:
39 Stable for amd64 wrt bug #488798
40
41
42
43 1.1 sci-libs/linux-gpib/linux-gpib-3.2.20.ebuild
44
45 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-libs/linux-gpib/linux-gpib-3.2.20.ebuild?rev=1.1&view=markup
46 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/sci-libs/linux-gpib/linux-gpib-3.2.20.ebuild?rev=1.1&content-type=text/plain
47
48 Index: linux-gpib-3.2.20.ebuild
49 ===================================================================
50 # Copyright 1999-2013 Gentoo Foundation
51 # Distributed under the terms of the GNU General Public License v2
52 # $Header: /var/cvsroot/gentoo-x86/sci-libs/linux-gpib/linux-gpib-3.2.20.ebuild,v 1.1 2013/12/06 00:04:57 dilfridge Exp $
53
54 EAPI=4
55 PERL_EXPORT_PHASE_FUNCTIONS=no
56 GENTOO_DEPEND_ON_PERL=no
57 PYTHON_DEPEND="python? 2"
58
59 inherit base linux-mod autotools perl-module python toolchain-funcs udev user
60
61 DESCRIPTION="Kernel module and driver library for GPIB (IEEE 488.2) hardware"
62 HOMEPAGE="http://linux-gpib.sourceforge.net/"
63 SRC_URI="mirror://sourceforge/linux-gpib/${P}.tar.gz
64 firmware? ( http://linux-gpib.sourceforge.net/firmware/gpib_firmware-2006-11-12.tar.gz )"
65
66 LICENSE="GPL-2"
67 SLOT="0"
68 KEYWORDS="~amd64 ~arm ~x86"
69 IUSE="pcmcia static debug guile perl php python tcl doc firmware"
70
71 COMMONDEPEND="
72 tcl? ( dev-lang/tcl )
73 guile? ( dev-scheme/guile )
74 perl? ( dev-lang/perl )
75 php? ( dev-lang/php )
76 firmware? ( sys-apps/fxload )"
77 RDEPEND="${COMMONDEPEND}"
78 DEPEND="${COMMONDEPEND}
79 virtual/pkgconfig
80 doc? ( app-text/docbook-sgml-utils )
81 perl? ( virtual/perl-ExtUtils-MakeMaker )"
82
83 PATCHES=(
84 "${FILESDIR}"/${PN}-3.2.15-build.patch
85 "${FILESDIR}"/${PN}-3.2.16-perl.patch
86 "${FILESDIR}"/${PN}-3.2.16-reallydie.patch
87 )
88
89 pkg_setup () {
90 use perl && perl-module_pkg_setup
91 python_pkg_setup
92 python_set_active_version 2
93 linux-mod_pkg_setup
94
95 if kernel_is -lt 2 6 8; then
96 die "Kernel versions older than 2.6.8 are not supported."
97 fi
98
99 # https://sourceforge.net/tracker/?func=detail&aid=3285657&group_id=42378&atid=432940
100 if use pcmcia && kernel_is -ge 2 6 38; then
101 die "pcmcia support is broken on kernels newer 2.6.38"
102 fi
103 }
104
105 src_prepare () {
106 base_src_prepare
107 eautoreconf
108 }
109
110 src_configure() {
111 set_arch_to_kernel
112 export PYTHON=$(PYTHON -2 -a)
113 econf \
114 $(use_enable pcmcia) \
115 $(use_enable static) \
116 $(use_enable debug driver-debug) \
117 $(use_enable guile guile-binding) \
118 $(use_enable perl perl-binding) \
119 $(use_enable php php-binding) \
120 $(use_enable python python-binding) \
121 $(use_enable tcl tcl-binding) \
122 $(use_enable doc documentation) \
123 --with-linux-srcdir=${KV_DIR}
124 }
125
126 src_compile() {
127 set_arch_to_kernel
128 FIRM_DIR=/usr/share/usb
129 emake \
130 DESTDIR="${D}" \
131 INSTALL_MOD_PATH="${D}" \
132 HOTPLUG_USB_CONF_DIR="${D}"/etc/hotplug/usb \
133 USB_FIRMWARE_DIR="${D}"${FIRM_DIR} \
134 docdir=/usr/share/doc/${PF}/html
135 }
136
137 src_install() {
138 set_arch_to_kernel
139 FIRM_DIR=/usr/share/usb
140 emake \
141 DESTDIR="${D}" \
142 INSTALL_MOD_PATH="${D}" \
143 HOTPLUG_USB_CONF_DIR="${D}"/etc/hotplug/usb \
144 USB_FIRMWARE_DIR="${D}"${FIRM_DIR} \
145 docdir=/usr/share/doc/${PF}/html install
146
147 if use perl; then
148 einfo "Installing perl module"
149 cd "${S}"/language/perl || die
150 DESTDIR=${D} perl-module_src_install
151 cd "${S}" || die
152 fi
153
154 echo "KERNEL==\"gpib[0-9]*\", MODE=\"0660\", GROUP=\"gpib\"" >> 99-gpib.rules
155 udev_dorules 99-gpib.rules
156
157 dodoc doc/linux-gpib.pdf ChangeLog AUTHORS README* NEWS
158
159 insinto /etc
160 newins util/templates/gpib.conf gpib.conf
161 newins util/templates/gpib.conf gpib.conf.example
162
163 if use pcmcia; then
164 dodir /etc/pcmcia
165 insinto /etc/pcmcia
166 doins "${S}"/etc/pcmcia/*
167 fi
168
169 if use firmware; then
170 insinto "${FIRM_DIR}"/agilent_82357a
171 doins "${WORKDIR}"/gpib_firmware-2006-11-12/agilent_82357a/*
172
173 insinto "${FIRM_DIR}"/ni_gpib_usb_b
174 doins "${WORKDIR}"/gpib_firmware-2006-11-12/ni_gpib_usb_b/*
175
176 insinto /usr/share/linux-gpib/hp_82341
177 # do not install precompiled generate_firmware
178 doins "${WORKDIR}"/gpib_firmware-2006-11-12/hp_82341/{*.bin,README}
179 fi
180 }
181
182 pkg_preinst () {
183 linux-mod_pkg_preinst
184 use perl && perl-module_pkg_preinst
185 enewgroup gpib
186 }
187
188 pkg_postinst () {
189 linux-mod_pkg_postinst
190 use perl && perl-module_pkg_postinst
191
192 einfo "You need to run the 'gpib_config' utility to setup the driver before"
193 einfo "you can use it. In order to do it automatically you can add to your"
194 einfo "start script something like this (supposing the appropriate driver"
195 einfo "is loaded on the startup):"
196 einfo " gpib_config --minor 0"
197 einfo ""
198 einfo "To give a user access to the computer's gpib board you will have to add"
199 einfo "them to the group 'gpib' or, you could change the permissions on the device"
200 einfo "files /dev/gpib[0-15] to something you like better, using 'chmod'."
201 einfo ""
202 einfo "Edit /etc/gpib.conf to match your interface board, and any devices you wish"
203 einfo "to open via ibfind(). See the documentation in /usr/share/linux-gpib/html for"
204 einfo "more information."
205 einfo ""
206
207 if use pcmcia; then
208 einfo "For PCMCIA cards:"
209 einfo "All files needed for a PCMCIA board were copied to /etc/pcmcia."
210 einfo "You may wish to edit the options passed to the gpib_config call in the"
211 einfo "/etc/pcmcia/linux-gpib-pcmcia script."
212 einfo "You may need to send a SIGHUP signal to the cardmgr daemon to force it"
213 einfo "to reload the files in /etc/pcmcia (alternatively you could use your"
214 einfo "pcmcia init.d script to restart the cardmgr, or you could just reboot)."
215 einfo "The driver module will be loaded as needed by the cardmgr."
216 einfo ""
217 fi
218
219 if use firmware; then
220 einfo "For Agilent (HP) 82341C and 82341D cards:"
221 einfo "The firmware for these boards is uploaded by passing the appropriate"
222 einfo "firmware file from /usr/share/linux-gpib/hp_82341 directory to"
223 einfo "gpib_config using the -I or --init-data command line option. Example:"
224 einfo "gpib_config --minor 0 --init-data \\"
225 einfo "/usr/share/linux-gpib/hp_82341/hp_82341c_fw.bin"
226 einfo ""
227 fi
228
229 }