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: samba-3.5.21.ebuild ChangeLog
Date: Thu, 31 Jan 2013 07:29:58
Message-Id: 20130131072953.D01D12171D@flycatcher.gentoo.org
1 patrick 13/01/31 07:29:53
2
3 Modified: ChangeLog
4 Added: samba-3.5.21.ebuild
5 Log:
6 Bump of 3.5
7
8 (Portage version: 2.2.0_alpha161/cvs/Linux x86_64, unsigned Manifest commit)
9
10 Revision Changes Path
11 1.555 net-fs/samba/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-fs/samba/ChangeLog?rev=1.555&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-fs/samba/ChangeLog?rev=1.555&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-fs/samba/ChangeLog?r1=1.554&r2=1.555
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v
20 retrieving revision 1.554
21 retrieving revision 1.555
22 diff -u -r1.554 -r1.555
23 --- ChangeLog 29 Jan 2013 09:56:47 -0000 1.554
24 +++ ChangeLog 31 Jan 2013 07:29:53 -0000 1.555
25 @@ -1,6 +1,11 @@
26 # ChangeLog for net-fs/samba
27 # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v 1.554 2013/01/29 09:56:47 polynomial-c Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v 1.555 2013/01/31 07:29:53 patrick Exp $
30 +
31 +*samba-3.5.21 (31 Jan 2013)
32 +
33 + 31 Jan 2013; Patrick Lauer <patrick@g.o> +samba-3.5.21.ebuild:
34 + Bump of 3.5
35
36 *samba-3.6.11 (29 Jan 2013)
37
38
39
40
41 1.1 net-fs/samba/samba-3.5.21.ebuild
42
43 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-fs/samba/samba-3.5.21.ebuild?rev=1.1&view=markup
44 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-fs/samba/samba-3.5.21.ebuild?rev=1.1&content-type=text/plain
45
46 Index: samba-3.5.21.ebuild
47 ===================================================================
48 # Copyright 1999-2013 Gentoo Foundation
49 # Distributed under the terms of the GNU General Public License v2
50 # $Header: /var/cvsroot/gentoo-x86/net-fs/samba/samba-3.5.21.ebuild,v 1.1 2013/01/31 07:29:53 patrick Exp $
51
52 EAPI=4
53
54 inherit pam versionator multilib eutils
55
56 MY_PV=${PV/_/}
57 MY_P="${PN}-${MY_PV}"
58
59 DESCRIPTION="Library bits of the samba network filesystem"
60 HOMEPAGE="http://www.samba.org/"
61 SRC_URI="mirror://samba/stable/${P}.tar.gz
62 http://dev.gentoo.org/~dagger/files/smb_traffic_analyzer_v2.diff.bz2"
63 LICENSE="GPL-3"
64 SLOT="0"
65 KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd"
66 IUSE="acl addns ads +aio avahi caps +client cluster cups debug doc examples fam
67 ldap ldb +netapi pam quota +readline selinux +server +smbclient smbsharemodes smbtav2
68 swat syslog winbind"
69
70 # upstream doesn't support cups 1.6 for samba 3.5
71 DEPEND="dev-libs/popt
72 !net-fs/samba-client
73 !net-fs/samba-libs
74 !net-fs/samba-server
75 !net-fs/cifs-utils
76 sys-libs/talloc
77 sys-libs/tdb
78 virtual/libiconv
79 ads? ( virtual/krb5 sys-fs/e2fsprogs
80 client? ( sys-apps/keyutils ) )
81 avahi? ( net-dns/avahi[dbus] )
82 caps? ( sys-libs/libcap )
83 client? ( !net-fs/mount-cifs
84 dev-libs/iniparser )
85 cluster? ( >=dev-db/ctdb-1.0.114_p1 )
86 cups? ( <net-print/cups-1.6 )
87 fam? ( virtual/fam )
88 ldap? ( net-nds/openldap )
89 pam? ( virtual/pam
90 winbind? ( dev-libs/iniparser )
91 )
92 readline? ( >=sys-libs/readline-5.2 )
93 selinux? ( sec-policy/selinux-samba )
94 syslog? ( virtual/logger )"
95
96 RDEPEND="${DEPEND}"
97
98 # Disable tests since we don't want to build that much here
99 RESTRICT="test"
100
101 SBINPROGS=""
102 BINPROGS=""
103 KRBPLUGIN=""
104 PLUGINEXT=".so"
105 SHAREDMODS=""
106
107 S="${WORKDIR}/${MY_P}/source3"
108
109 # TODO:
110 # - enable iPrint on Prefix/OSX and Darwin?
111 # - selftest-prefix? selftest?
112 # - AFS?
113
114 CONFDIR="${FILESDIR}/$(get_version_component_range 1-2)"
115
116 REQUIRED_USE="
117 ads? ( ldap )
118 swat? ( server )
119 "
120
121 pkg_setup() {
122 if use server ; then
123 SBINPROGS="${SBINPROGS} bin/smbd bin/nmbd"
124 BINPROGS="${BINPROGS} bin/testparm bin/smbstatus bin/smbcontrol bin/pdbedit
125 bin/profiles bin/sharesec bin/eventlogadm"
126
127 use smbtav2 && BINPROGS="${BINPROGS} bin/smbta-util"
128 use swat && SBINPROGS="${SBINPROGS} bin/swat"
129 use winbind && SBINPROGS="${SBINPROGS} bin/winbindd"
130 use ads && use winbind && KRBPLUGIN="${KRBPLUGIN} bin/winbind_krb5_locator"
131 fi
132
133 if use client ; then
134 BINPROGS="${BINPROGS} bin/smbclient bin/net bin/smbget bin/smbtree
135 bin/nmblookup bin/smbpasswd bin/rpcclient bin/smbcacls bin/smbcquotas
136 bin/ntlm_auth"
137
138 use ads && SBINPROGS="${SBINPROGS} bin/cifs.upcall"
139 fi
140
141 use cups && BINPROGS="${BINPROGS} bin/smbspool"
142 use ldb && BINPROGS="${BINPROGS} bin/ldbedit bin/ldbsearch bin/ldbadd bin/ldbdel bin/ldbmodify bin/ldbrename";
143
144 if use winbind ; then
145 BINPROGS="${BINPROGS} bin/wbinfo"
146 SHAREDMODS="${SHAREDMODS}idmap_rid,idmap_hash"
147 use ads && SHAREDMODS="${SHAREDMODS},idmap_ad"
148 use ldap && SHAREDMODS="${SHAREDMODS},idmap_ldap,idmap_adex"
149 fi
150
151 if use winbind &&
152 [[ $(tc-getCC)$ == *gcc* ]] &&
153 [[ $(gcc-major-version)$(gcc-minor-version) -lt 43 ]]
154 then
155 eerror "It is a known issue that ${P} will not build with "
156 eerror "winbind use flag enabled when using gcc < 4.3 ."
157 eerror "Please use at least the latest stable gcc version."
158 die "Using sys-devel/gcc < 4.3 with winbind use flag."
159 fi
160 }
161
162 src_prepare() {
163 cp "${FILESDIR}/samba-3.4.2-lib.tevent.python.mk" "../lib/tevent/python.mk"
164
165 # ensure that winbind has correct ldflags (QA notice)
166 sed -i \
167 -e 's|LDSHFLAGS="|LDSHFLAGS="\\${LDFLAGS} |g' \
168 configure || die "sed failed"
169
170 epatch "${CONFDIR}"/${PN}-3.5.6-kerberos-dummy.patch
171 use smbtav2 && cd "${WORKDIR}/${P}" && epatch "${WORKDIR}"/smb_traffic_analyzer_v2.diff
172 cd "${WORKDIR}/${MY_P}" && epatch "${CONFDIR}"/${PN}-3.5.8-uclib-build.patch
173 epatch "${CONFDIR}"/smb.conf.default.patch
174 }
175
176 src_configure() {
177 local myconf
178
179 # Filter out -fPIE
180 [[ ${CHOST} == *-*bsd* ]] && myconf+=" --disable-pie"
181
182 # Upstream refuses to make this configurable
183 use caps && export ac_cv_header_sys_capability_h=yes || export ac_cv_header_sys_capability_h=no
184
185 # use_with doesn't accept 2 USE-flags
186 if use client && use ads ; then
187 myconf+=" --with-cifsupcall"
188 else
189 myconf+=" --without-cifsupcall"
190 fi
191
192 if use client && use kernel_linux ; then
193 myconf+=" --with-cifsmount --with-cifsumount"
194 else
195 myconf+=" --without-cifsmount --without-cifsumount"
196 fi
197
198 #bug #399141 wrap newer iniparser version
199 has_version ">=dev-libs/iniparser-3.0.0" && \
200 export CPPFLAGS+=" -Diniparser_getstr\(d,i\)=iniparser_getstring\(d,i,NULL\)"
201
202 # Notes:
203 # - automount is only needed in conjunction with NIS and we don't have that
204 # anymore => LDAP?
205 # - --without-dce-dfs and --without-nisplus-home can't be passed to configure but are disabled by default
206 econf ${myconf} \
207 --with-piddir=/var/run/samba \
208 --sysconfdir=/etc/samba \
209 --localstatedir=/var \
210 $(use_enable debug developer) \
211 --enable-largefile \
212 --enable-socket-wrapper \
213 --enable-nss-wrapper \
214 $(use_enable swat) \
215 $(use_enable cups) \
216 --disable-iprint \
217 $(use_enable fam) \
218 --enable-shared-libs \
219 --disable-dnssd \
220 $(use_enable avahi) \
221 --with-fhs \
222 --with-privatedir=/var/lib/samba/private \
223 --with-rootsbindir=/var/cache/samba \
224 --with-lockdir=/var/cache/samba \
225 --with-swatdir=/usr/share/doc/${PF}/swat \
226 --with-configdir=/etc/samba \
227 --with-logfilebase=/var/log/samba \
228 --with-pammodulesdir=$(getpam_mod_dir) \
229 --without-afs \
230 --without-fake-kaserver \
231 --without-vfs-afsacl \
232 $(use_with ldap) \
233 $(use_with ads) \
234 $(use_with ads krb5 /usr) \
235 $(use_with ads dnsupdate) \
236 --without-automount \
237 $(use_with pam) \
238 $(use_with pam pam_smbpass) \
239 $(use_with syslog) \
240 $(use_with quota quotas) \
241 $(use_with quota sys-quotas) \
242 --without-utmp \
243 --without-lib{talloc,tdb} \
244 $(use_with netapi libnetapi) \
245 $(use_with smbclient libsmbclient) \
246 $(use_with smbsharemodes libsmbsharemodes) \
247 $(use_with addns libaddns) \
248 $(use_with cluster ctdb /usr) \
249 $(use_with cluster cluster-support) \
250 $(use_with acl acl-support) \
251 $(use_with aio aio-support) \
252 --with-sendfile-support \
253 $(use_with winbind) \
254 --with-shared-modules=${SHAREDMODS} \
255 --without-included-popt \
256 --without-included-iniparser
257 }
258
259 src_compile() {
260 # compile libs
261 if use addns ; then
262 einfo "make addns library"
263 emake libaddns
264 fi
265 if use netapi ; then
266 einfo "make netapi library"
267 emake libnetapi
268 fi
269 if use smbclient ; then
270 einfo "make smbclient library"
271 emake libsmbclient
272 fi
273 if use smbsharemodes ; then
274 einfo "make smbsharemodes library"
275 emake libsmbsharemodes
276 fi
277
278 # compile modules
279 emake modules
280
281 # compile pam moudles
282 if use pam ; then
283 einfo "make pam modules"
284 emake pam_modules
285 fi
286
287 # compile winbind nss modules
288 if use winbind ; then
289 einfo "make nss modules"
290 emake nss_modules
291 fi
292
293 # compile utilities
294 if [ -n "${BINPROGS}" ] ; then
295 einfo "make binprogs"
296 emake ${BINPROGS}
297 fi
298 if [ -n "${SBINPROGS}" ] ; then
299 einfo "make sbinprogs"
300 emake ${SBINPROGS}
301 fi
302
303 if [ -n "${KRBPLUGIN}" ] ; then
304 einfo "make krbplugin"
305 emake ${KRBPLUGIN}${PLUGINEXT}
306 fi
307
308 if use client && use kernel_linux; then
309 einfo "make {,u}mount.cifs"
310 emake bin/{,u}mount.cifs
311 fi
312 }
313
314 src_install() {
315 # install libs
316 if use addns ; then
317 einfo "install addns library"
318 emake installlibaddns DESTDIR="${D}"
319 fi
320 if use netapi ; then
321 einfo "install netapi library"
322 emake installlibnetapi DESTDIR="${D}"
323 fi
324 if use smbclient ; then
325 einfo "install smbclient library"
326 emake installlibsmbclient DESTDIR="${D}"
327 fi
328 if use smbsharemodes ; then
329 einfo "install smbsharemodes library"
330 emake installlibsmbsharemodes DESTDIR="${D}"
331 fi
332
333 # install modules
334 emake installmodules DESTDIR="${D}"
335
336 if use pam ; then
337 einfo "install pam modules"
338 emake installpammodules DESTDIR="${D}"
339
340 if use winbind ; then
341 newpamd "${CONFDIR}/system-auth-winbind.pam" system-auth-winbind
342 doman ../docs/manpages/pam_winbind.8
343 # bug #376853
344 insinto /etc/security
345 doins ../examples/pam_winbind/pam_winbind.conf || die
346 fi
347
348 newpamd "${CONFDIR}/samba.pam" samba
349 dodoc pam_smbpass/README
350 fi
351
352 # Nsswitch extensions. Make link for wins and winbind resolvers
353 if use winbind ; then
354 einfo "install libwbclient"
355 emake installlibwbclient DESTDIR="${D}"
356 dolib.so ../nsswitch/libnss_wins.so
357 dosym libnss_wins.so /usr/$(get_libdir)/libnss_wins.so.2
358 dolib.so ../nsswitch/libnss_winbind.so
359 dosym libnss_winbind.so /usr/$(get_libdir)/libnss_winbind.so.2
360 einfo "install libwbclient related manpages"
361 doman ../docs/manpages/idmap_rid.8
362 doman ../docs/manpages/idmap_hash.8
363 if use ldap ; then
364 doman ../docs/manpages/idmap_adex.8
365 doman ../docs/manpages/idmap_ldap.8
366 fi
367 if use ads ; then
368 doman ../docs/manpages/idmap_ad.8
369 fi
370 fi
371
372 # install binaries
373 insinto /usr
374 for prog in ${SBINPROGS} ; do
375 dosbin ${prog}
376 doman ../docs/manpages/${prog/bin\/}*
377 done
378
379 for prog in ${BINPROGS} ; do
380 dobin ${prog}
381 doman ../docs/manpages/${prog/bin\/}*
382 done
383
384 # install krbplugin
385 if [ -n "${KRBPLUGIN}" ] ; then
386 if has_version app-crypt/mit-krb5 ; then
387 insinto /usr/$(get_libdir)/krb5/plugins/libkrb5
388 doins ${KRBPLUGIN}${PLUGINEXT}
389 elif has_version app-crypt/heimdal ; then
390 insinto /usr/$(get_libdir)/plugin/krb5
391 doins ${KRBPLUGIN}${PLUGINEXT}
392 fi
393 insinto /usr
394 for prog in ${KRBPLUGIN} ; do
395 doman ../docs/manpages/${prog/bin\/}*
396 done
397 fi
398
399 # install server components
400 if use server ; then
401 doman ../docs/manpages/vfs* ../docs/manpages/samba.7
402
403 diropts -m0700
404 keepdir /var/lib/samba/private
405
406 diropts -m1777
407 keepdir /var/spool/samba
408
409 diropts -m0755
410 keepdir /var/{cache,log}/samba
411 keepdir /var/lib/samba/{netlogon,profiles}
412 keepdir /var/lib/samba/printers/{W32X86,WIN40,W32ALPHA,W32MIPS,W32PPC,X64,IA64,COLOR}
413 keepdir /usr/$(get_libdir)/samba/{auth,pdb,rpc,idmap,nss_info,gpext}
414
415 newconfd "${CONFDIR}/samba.confd" samba
416 newinitd "${CONFDIR}/samba.initd" samba
417
418 insinto /etc/samba
419 doins "${CONFDIR}"/{smbusers,lmhosts}
420
421 if use ldap ; then
422 insinto /etc/openldap/schema
423 doins ../examples/LDAP/samba.schema
424 fi
425
426 if use swat ; then
427 insinto /etc/xinetd.d
428 newins "${CONFDIR}/swat.xinetd" swat
429 script/installswat.sh "${D}" "${ROOT}/usr/share/doc/${PF}/swat" "${S}"
430 fi
431
432 dodoc ../MAINTAINERS ../README* ../Roadmap ../WHATSNEW.txt ../docs/THANKS
433 fi
434
435 # install client files ({u,}mount.cifs into /)
436 if use client && use kernel_linux ; then
437 into /
438 dosbin bin/{u,}mount.cifs
439 doman ../docs/manpages/{u,}mount.cifs.8
440 fi
441
442 # install the spooler to cups
443 if use cups ; then
444 dosym /usr/bin/smbspool $(cups-config --serverbin)/backend/smb
445 fi
446
447 # install misc files
448 insinto /etc/samba
449 doins ../examples/smb.conf.default
450 doman ../docs/manpages/smb.conf.5
451
452 insinto /usr/"$(get_libdir)"/samba
453 doins ../codepages/{valid.dat,upcase.dat,lowcase.dat}
454
455 # install docs
456 if use doc ; then
457 dohtml -r ../docs/htmldocs/*
458 dodoc ../docs/*.pdf
459 fi
460
461 # install examples
462 if use examples ; then
463 insinto /usr/share/doc/${PF}/examples
464
465 if use smbclient ; then
466 doins -r ../examples/libsmbclient
467 fi
468
469 if use winbind ; then
470 doins -r ../examples/pam_winbind ../examples/nss
471 fi
472
473 if use server ; then
474 cd ../examples
475 doins -r auth autofs dce-dfs LDAP logon misc pdb \
476 perfcounter printer-accounting printing scripts tridge \
477 validchars VFS
478 fi
479 fi
480
481 # Remove empty installation directories
482 rmdir --ignore-fail-on-non-empty \
483 "${D}/usr/$(get_libdir)/samba" \
484 "${D}/usr"/{sbin,bin} \
485 "${D}/usr/share"/{man,locale,} \
486 "${D}/var"/{run,lib/samba/private,lib/samba,lib,cache/samba,cache,} \
487 # || die "tried to remove non-empty dirs, this seems like a bug in the ebuild"
488 }
489
490 pkg_postinst() {
491 elog "The default value of 'wide links' has been changed to 'no' in samba 3.5"
492 elog "to avoid an insecure default configuration"
493 elog "('wide links = yes' and 'unix extensions = yes'). For more details,"
494 elog "please see http://www.samba.org/samba/news/symlink_attack.html ."
495 elog ""
496 elog "An EXPERIMENTAL implementation of the SMB2 protocol has been added."
497 elog "SMB2 can be enabled by setting 'max protocol = smb2'. SMB2 is a new "
498 elog "implementation of the SMB protocol used by Windows Vista and higher"
499 elog ""
500 elog "For further information make sure to read the release notes at"
501 elog "http://samba.org/samba/history/${P}.html and "
502 elog "http://samba.org/samba/history/${PN}-3.5.0.html"
503 }