Gentoo Archives: gentoo-commits

From: "Patrick Lauer (patrick)" <patrick@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-fs/samba: ChangeLog samba-3.2.13-r1.ebuild
Date: Fri, 26 Jun 2009 17:22:01
Message-Id: E1MKF7b-0001fu-MK@stork.gentoo.org
1 patrick 09/06/26 17:21:55
2
3 Modified: ChangeLog
4 Added: samba-3.2.13-r1.ebuild
5 Log:
6 Fixing missing symlinks, closes #275466
7 (Portage version: 2.2_rc33/cvs/Linux x86_64, RepoMan options: --force)
8
9 Revision Changes Path
10 1.360 net-fs/samba/ChangeLog
11
12 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-fs/samba/ChangeLog?rev=1.360&view=markup
13 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-fs/samba/ChangeLog?rev=1.360&content-type=text/plain
14 diff : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-fs/samba/ChangeLog?r1=1.359&r2=1.360
15
16 Index: ChangeLog
17 ===================================================================
18 RCS file: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v
19 retrieving revision 1.359
20 retrieving revision 1.360
21 diff -u -r1.359 -r1.360
22 --- ChangeLog 25 Jun 2009 19:11:27 -0000 1.359
23 +++ ChangeLog 26 Jun 2009 17:21:55 -0000 1.360
24 @@ -1,6 +1,11 @@
25 # ChangeLog for net-fs/samba
26 # Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
27 -# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v 1.359 2009/06/25 19:11:27 patrick Exp $
28 +# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v 1.360 2009/06/26 17:21:55 patrick Exp $
29 +
30 +*samba-3.2.13-r1 (26 Jun 2009)
31 +
32 + 26 Jun 2009; Patrick Lauer <patrick@g.o> +samba-3.2.13-r1.ebuild:
33 + Fixing missing symlinks, closes #275466
34
35 25 Jun 2009; Patrick Lauer <patrick@g.o> -samba-3.2.0_rc2.ebuild:
36 Remove old
37
38
39
40 1.1 net-fs/samba/samba-3.2.13-r1.ebuild
41
42 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-fs/samba/samba-3.2.13-r1.ebuild?rev=1.1&view=markup
43 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/net-fs/samba/samba-3.2.13-r1.ebuild?rev=1.1&content-type=text/plain
44
45 Index: samba-3.2.13-r1.ebuild
46 ===================================================================
47 # Copyright 1999-2009 Gentoo Foundation
48 # Distributed under the terms of the GNU General Public License v2
49 # $Header: /var/cvsroot/gentoo-x86/net-fs/samba/samba-3.2.13-r1.ebuild,v 1.1 2009/06/26 17:21:55 patrick Exp $
50
51 inherit eutils pam multilib versionator confutils
52
53 MY_P=${PN}-${PV/_/}
54
55 DESCRIPTION="A suite of SMB and CIFS client/server programs for UNIX"
56 HOMEPAGE="http://www.samba.org/"
57 SRC_URI="mirror://samba/${MY_P}.tar.gz"
58 LICENSE="GPL-3"
59 SLOT="0"
60 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd"
61 IUSE_LINGUAS="linguas_ja linguas_pl"
62 IUSE="${IUSE_LINGUAS} acl ads async automount caps cups doc examples ipv6 kernel_linux ldap fam
63 pam quotas readline selinux swat syslog winbind"
64
65 RDEPEND="dev-libs/popt
66 dev-libs/iniparser
67 virtual/libiconv
68 acl? ( virtual/acl )
69 cups? ( net-print/cups )
70 ipv6? ( sys-apps/xinetd )
71 ads? ( virtual/krb5 sys-fs/e2fsprogs )
72 ldap? ( net-nds/openldap )
73 pam? ( virtual/pam )
74 readline? ( sys-libs/readline )
75 selinux? ( sec-policy/selinux-samba )
76 swat? ( sys-apps/xinetd )
77 syslog? ( virtual/logger )
78 fam? ( virtual/fam )
79 caps? ( sys-libs/libcap )"
80 DEPEND="${RDEPEND}"
81
82 S="${WORKDIR}/${MY_P}"
83 CONFDIR="${FILESDIR}/config-3.2"
84 PRIVATE_DST=/var/lib/samba/private
85
86 # Tests are currently broken due to hardcoded paths (due to --with-fhs)
87 # The problem is that --without-fhs lets samba use lockdir (which can be changed in smb.conf)
88 # which is wrong as well.
89 RESTRICT="test"
90
91 pkg_setup() {
92 confutils_use_depend_all ads ldap
93 }
94
95 src_unpack() {
96 unpack ${A}
97 cd "${S}/source"
98
99 # Ok, agreed, this is ugly. But it avoids a patch we
100 # need for every samba version and we don't need autotools
101 sed -i \
102 -e 's|"lib32" ||' \
103 -e 's|if test -d "$i/$l" ;|if test -d "$i/$l" -o -L "$i/$l";|' \
104 configure || die "sed failed"
105
106 rm "${S}/docs/manpages"/{mount,umount}.cifs.8
107
108 sed -i \
109 -e 's|tdbsam|tdbsam:${PRIVATEDIR}/passdb.tdb|' \
110 "${S}/source/script/tests/selftest.sh" || die "sed failed"
111 }
112
113 src_compile() {
114 cd "${S}/source"
115
116 local myconf
117 local mylangs
118 local mymod_shared
119
120 mylangs="--with-manpages-langs=en"
121 use linguas_ja && mylangs="${mylangs},ja"
122 use linguas_pl && mylangs="${mylangs},pl"
123
124 use winbind && mymod_shared="--with-shared-modules=idmap_rid"
125 if use ldap ; then
126 myconf="${myconf} $(use_with ads)"
127 use winbind && mymod_shared="${mymod_shared},idmap_ad"
128 fi
129
130 [[ ${CHOST} == *-*bsd* ]] && myconf="${myconf} --disable-pie"
131 use hppa && myconf="${myconf} --disable-pie"
132
133 use caps && export ac_cv_header_sys_capability_h=yes || export ac_cv_header_sys_capability_h=no
134
135 # Otherwise we get the whole swat stuff installed
136 if ! use swat ; then
137 sed -i \
138 -e 's/^\(install:.*\)installswat \(.*\)/\1\2/' \
139 Makefile.in || die "sed failed"
140 fi
141
142 econf \
143 --with-fhs \
144 --sysconfdir=/etc/samba \
145 --localstatedir=/var \
146 --with-configdir=/etc/samba \
147 --with-libdir=/usr/$(get_libdir)/samba \
148 --with-pammodulesdir=$(getpam_mod_dir) \
149 --with-swatdir=/usr/share/doc/${PF}/swat \
150 --with-piddir=/var/run/samba \
151 --with-lockdir=/var/cache/samba \
152 --with-logfilebase=/var/log/samba \
153 --with-privatedir=${PRIVATE_DST} \
154 --with-libsmbclient \
155 --without-spinlocks \
156 --enable-socket-wrapper \
157 --enable-nss-wrapper \
158 --with-cifsmount=no \
159 $(use_with acl acl-support) \
160 $(use_with async aio-support) \
161 $(use_with automount) \
162 --without-cifsupcall \
163 $(use_enable cups) \
164 $(use_enable fam) \
165 $(use_with ads krb5) \
166 $(use_with ads dnsupdate) \
167 $(use_with ldap) \
168 $(use_with pam) $(use_with pam pam_smbpass) \
169 $(use_with quotas) $(use_with quotas sys-quotas) \
170 $(use_with readline) \
171 $(use_with syslog) \
172 $(use_with winbind) \
173 ${myconf} ${mylangs} ${mymod_shared} || die "econf failed"
174
175 emake proto || die "emake proto failed"
176 emake everything || die "emake everything failed"
177
178 }
179
180 src_test() {
181 cd "${S}/source"
182 emake test || die "tests failed"
183 }
184
185 src_install() {
186 cd "${S}/source"
187
188 emake DESTDIR="${D}" install-everything || die "emake install-everything failed"
189
190 # Extra rpctorture progs
191 local extra_bins="rpctorture"
192 for i in ${extra_bins} ; do
193 [[ -x "${S}/bin/${i}" ]] && dobin "${S}/bin/${i}"
194 done
195
196 # remove .old stuff from /usr/bin:
197 rm -f "${D}"/usr/bin/*.old
198
199 # Removing executable bits from header-files
200 fperms 644 /usr/include/libsmbclient.h
201
202 # Nsswitch extensions. Make link for wins and winbind resolvers
203 if use winbind ; then
204 dolib.so nsswitch/libnss_wins.so
205 dosym libnss_wins.so /usr/$(get_libdir)/libnss_wins.so.2
206 dolib.so nsswitch/libnss_winbind.so
207 dosym libnss_winbind.so /usr/$(get_libdir)/libnss_winbind.so.2
208 fi
209
210 # bug #46389: samba doesn't create symlink anymore
211 # beaviour seems to be changed in 3.0.6, see bug #61046
212 dosym samba/libsmbclient.so /usr/$(get_libdir)/libsmbclient.so
213 dosym samba/libsmbclient.so.0 /usr/$(get_libdir)/libsmbclient.so.0
214 dosym samba/libtalloc.so /usr/$(get_libdir)/libtalloc.so
215 dosym samba/libtalloc.so.1 /usr/$(get_libdir)/libtalloc.so.1
216 dosym samba/libtdb.so /usr/$(get_libdir)/libtdb.so
217 dosym samba/libtdb.so.1 /usr/$(get_libdir)/libtdb.so.1
218 dosym samba/libwbclient.so.0 /usr/$(get_libdir)/libwbclient.so.0
219 dosym samba/libsmbsharemodes.so.0 /usr/$(get_libdir)/libsmbsharemodes.so.0
220
221 # make the smb backend symlink for cups printing support (bug #133133)
222 if use cups ; then
223 dodir $(cups-config --serverbin)/backend
224 dosym /usr/bin/smbspool $(cups-config --serverbin)/backend/smb
225 fi
226
227 cd "${S}/source"
228
229 # General config files
230 insinto /etc/samba
231 doins "${CONFDIR}"/{smbusers,lmhosts}
232 newins "${CONFDIR}/smb.conf.example-samba3" smb.conf.example
233
234 newpamd "${CONFDIR}/samba.pam" samba
235 use winbind && dopamd "${CONFDIR}/system-auth-winbind"
236 if use swat ; then
237 insinto /etc/xinetd.d
238 newins "${CONFDIR}/swat.xinetd" swat
239 else
240 rm -f "${D}/usr/sbin/swat"
241 rm -f "${D}/usr/share/man/man8/swat.8"
242 fi
243
244 newinitd "${FILESDIR}/samba-init" samba
245 newconfd "${FILESDIR}/samba-conf" samba
246
247 if use ldap ; then
248 insinto /etc/openldap/schema
249 doins "${S}/examples/LDAP/samba.schema"
250 fi
251
252 if use ipv6 ; then
253 insinto /etc/xinetd.d
254 newins "${FILESDIR}/samba-xinetd" smb
255 fi
256
257 # dirs
258 diropts -m0700 ; keepdir "${PRIVATE_DST}"
259 diropts -m1777 ; keepdir /var/spool/samba
260
261 diropts -m0755
262 keepdir /var/{log,run,cache}/samba
263 keepdir /var/lib/samba/{netlogon,profiles}
264 keepdir /var/lib/samba/printers/{W32X86,WIN40,W32ALPHA,W32MIPS,W32PPC,X64,IA64,COLOR}
265 keepdir /usr/$(get_libdir)/samba/{rpc,idmap,auth}
266
267 # docs
268 dodoc "${FILESDIR}/README.gentoo"
269 dodoc "${S}"/{MAINTAINERS,README,Roadmap,WHATSNEW.txt}
270 dodoc "${CONFDIR}/nsswitch.conf-wins"
271 use winbind && dodoc "${CONFDIR}/nsswitch.conf-winbind"
272
273 if use examples ; then
274 insinto /usr/share/doc/${PF}
275 doins -r "${S}/examples/"
276 find "${D}/usr/share/doc/${PF}" -type d -print0 | xargs -0 chmod 755
277 find "${D}/usr/share/doc/${PF}/examples" ! -type d -print0 | xargs -0 chmod 644
278 fi
279
280 if ! use doc ; then
281 if ! use swat ; then
282 rm -rf "${D}/usr/share/doc/${PF}/swat"
283 else
284 rm -rf "${D}/usr/share/doc/${PF}/swat/help"/{guide,howto,devel}
285 rm -rf "${D}/usr/share/doc/${PF}/swat/using_samba"
286 fi
287 fi
288
289 }
290
291 pkg_preinst() {
292 local PRIVATE_SRC=/etc/samba/private
293 if [[ ! -r "${ROOT}/${PRIVATE_DST}/secrets.tdb" \
294 && -r "${ROOT}/${PRIVATE_SRC}/secrets.tdb" ]] ; then
295 ebegin "Copying ${ROOT}/${PRIVATE_SRC}/* to ${ROOT}/${PRIVATE_DST}/"
296 mkdir -p "${D}/${PRIVATE_DST}"
297 cp -pPRf "${ROOT}/${PRIVATE_SRC}"/* "${D}/${PRIVATE_DST}/"
298 eend $?
299 fi
300
301 if [[ ! -f "${ROOT}/etc/samba/smb.conf" ]] ; then
302 touch "${D}/etc/samba/smb.conf"
303 fi
304 }
305
306 pkg_postinst() {
307 if use swat ; then
308 einfo "swat must be enabled by xinetd:"
309 einfo " change the /etc/xinetd.d/swat configuration"
310 fi
311
312 if use ipv6 ; then
313 einfo "ipv6 support must be enabled by xinetd:"
314 einfo " change the /etc/xinetd.d/smb configuration"
315 fi
316
317 elog "It is possible to start/stop daemons separately:"
318 elog " Create a symlink from /etc/init.d/samba.{smbd,nmbd,winbind} to"
319 elog " /etc/init.d/samba. Calling /etc/init.d/samba directly will start"
320 elog " the daemons configured in /etc/conf.d/samba"
321
322 elog "The mount/umount.cifs helper applications are not included anymore."
323 elog "Please install net-fs/mount-cifs instead."
324
325 ewarn "If you're upgrading from 3.0.24 or earlier, please make sure to"
326 ewarn "restart your clients to clear any cached information about the server."
327 ewarn "Otherwise they might not be able to connect to the volumes."
328 }