aboutsummaryrefslogtreecommitdiffstats
path: root/main/samba/APKBUILD
blob: 41477ee4ede1be8abe864367623a298d6ac07cb7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=samba
pkgver=4.10.18
pkgrel=0
pkgdesc="Tools to access a server's filespace and printers via SMB"
url="https://www.samba.org/"
arch="all"
license="GPL-3.0-or-later LGPL-3.0-or-later"
subpackages="
	$pkgname-dev $pkgname-doc $pkgname-server-openrc
	$pkgname-common::noarch
	$pkgname-common-tools:_common_tools
	$pkgname-common-server-libs:_common_server_libs
	$pkgname-common-libs:_common_libs
	libsmbclient
	$pkgname-client
	$pkgname-client-libs:_client_libs

	$pkgname-winbind
	libwbclient
	$pkgname-winbind-clients:_winbind_clients
	$pkgname-winbind-krb5-locator:_winbind_krb5_locator
	$pkgname-libnss-winbind:_libnss_winbind
	pam-winbind:_pam_winbind

	$pkgname-heimdal-libs:_heimdal_libs
	$pkgname-dc
	$pkgname-dc-libs:_dc_libs

	$pkgname-server
	$pkgname-server-libs:_server_libs
	$pkgname-pidl::noarch
	py3-$pkgname:_py3
	$pkgname-test:_test
	$pkgname-libs-py3:_libs_py3
	$pkgname-libs
	"

depends="
	$pkgname-server=$pkgver-r$pkgrel
	$pkgname-client=$pkgver-r$pkgrel
	$pkgname-common-tools=$pkgver-r$pkgrel
	"

# note that heimdal is required (over mit krb5) for AD DC functionality
makedepends="
	acl-dev
	cups-dev
	dbus-dev
	docbook-xsl
	e2fsprogs-dev
	fuse-dev
	iniparser-dev
	jansson-dev
	ldb-dev
	libarchive-dev
	libcap-dev
	libtirpc-dev
	linux-pam-dev
	ncurses-dev
	openldap-dev
	perl
	popt-dev
	py3-tdb
	py3-tevent
	python3-dev
	rpcgen
	subunit-dev
	talloc-dev
	tdb-dev
	tevent-dev
	"
source="
	https://us1.samba.org/samba/ftp/stable/$pkgname-$pkgver.tar.gz
	getpwent_r.patch
	musl_uintptr.patch
	netdb-defines.patch
	netapp.patch
	bind-9.12.patch
	missing-headers.patch
	musl_rm_unistd_incl.patch
	$pkgname.initd
	$pkgname.confd
	$pkgname.logrotate
	"
pkggroups="winbind"
builddir="$srcdir/$pkgname-$pkgver"

# secfixes:
#   4.10.18-r0:
#     - CVE-2020-1472
#   4.10.17-r0:
#     - CVE-2020-10730
#     - CVE-2020-10745
#     - CVE-2020-10760
#     - CVE-2020-14303
#   4.10.15-r0:
#     - CVE-2020-10700
#     - CVE-2020-10704
#   4.10.12-r0:
#     - CVE-2019-14902
#     - CVE-2019-14907
#     - CVE-2019-19344
#   4.10.11-r0:
#     - CVE-2019-14861
#     - CVE-2019-14870
#   4.10.10-r0:
#     - CVE-2019-10218
#     - CVE-2019-14833
#     - CVE-2019-14847
#   4.10.8-r0:
#     - CVE-2019-10197
#   4.10.5-r0:
#     - CVE-2019-12435
#     - CVE-2019-12436
#   4.10.3-r0:
#     - CVE-2018-16860
#   4.8.11-r0:
#     - CVE-2018-14629
#     - CVE-2019-3880
#   4.8.7-r0:
#     - CVE-2018-14629
#     - CVE-2018-16841
#     - CVE-2018-16851
#     - CVE-2018-16853
#   4.8.4-r0:
#     - CVE-2018-1139
#     - CVE-2018-1140
#     - CVE-2018-10858
#     - CVE-2018-10918
#     - CVE-2018-10919
#   4.7.6-r0:
#     - CVE-2018-1050
#     - CVE-2018-1057
#   4.7.3-r0:
#     - CVE-2017-14746
#     - CVE-2017-15275
#   4.7.0-r0:
#     - CVE-2017-12150
#     - CVE-2017-12151
#     - CVE-2017-12163
#   4.6.1-r0:
#     - CVE-2017-2619

build() {
	cd "$builddir"
	local _jobs=$JOBS
	local _idmap_modules=idmap_ad,idmap_rid,idmap_adex,idmap_hash,idmap_tdb2
	local _pdb_modules=pdb_tdbsam,pdb_ldap,pdb_ads,pdb_smbpasswd,pdb_wbc_sam,pdb_samba4
	local _auth_modules=auth_unix,auth_wbc,auth_server,auth_netlogond,auth_script,auth_samba4

	if [ -z "$_jobs" ]; then
		_jobs=$(awk '/^core id/ {n++} END{print n}' /proc/cpuinfo)
	fi
	./configure --prefix=/usr \
		--jobs=${_jobs:-2} \
		--sysconfdir=/etc/$pkgname \
		--with-configdir=/etc/$pkgname \
		--localstatedir=/var \
		--libexecdir=/usr/lib \
		--enable-fhs \
		--with-lockdir=/var/cache/$pkgname \
		--with-piddir=/run/$pkgname \
		--with-logfilebase=/var/log/$pkgname \
		--with-pam \
		--without-systemd \
		--with-ads \
		--with-shared-modules=$_idmap_modules,$_pdb_modules,$_auth_modules \
		--enable-cups \
		--without-gettext \
		--bundled-libraries=NONE,ntdb,roken,wind,hx509,asn1,heimbase,hcrypto,krb5,gssapi,heimntlm,hdb,kdc,cmocka \
		--disable-rpath-install \
		--without-gpgme
	make
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install

	install -d "$pkgdir"/var/log/$pkgname \
		"$pkgdir"/usr/share/doc/$pkgname
	install -dm755 "$pkgdir"/var/lib/$pkgname/sysvol
	install -Dm644 examples/smb.conf.default \
		"$pkgdir"/etc/$pkgname/smb.conf
	install -m744 packaging/printing/smbprint \
		"$pkgdir"/usr/bin/smbprint
	install -Dm644 "$srcdir"/$pkgname.logrotate \
		"$pkgdir"/etc/logrotate.d/$pkgname

	install -Dm755 "$srcdir/$pkgname.initd" "$pkgdir/etc/init.d/$pkgname"
	install -Dm644 "$srcdir/$pkgname.confd" "$pkgdir/etc/conf.d/$pkgname"
}

_mv_files() {
	local i
	for i in "$@"; do
		case $i in
		*/*) mkdir -p "$subpkgdir"/${i%/*};;
		*) mkdir -p "$subpkgdir";;
		esac
		mv "$pkgdir"/$i "$subpkgdir"/$i
	done
}

common() {
	pkgdesc="Samba common files for both client an servers"
	depends=
	cd "$pkgdir"
	_mv_files \
		etc \
		var
	install -d -m700 "$subpkgdir"/var/lib/$pkgname/private
}

# common-libs is an attempt to avoid libpython dependency for libsmbclient
_libs_py3() {
	pkgdesc="Libraries that require libpython"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/$pkgname/libsamba-net*samba4.so \
		usr/lib/$pkgname/libsamba-python*samba4.so
	return 0
}

_common_tools() {
	pkgdesc="Tools for Samba servers and clients"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/bin/net \
		usr/bin/pdbedit \
		usr/bin/profiles \
		usr/bin/smbcontrol \
		usr/bin/smbpasswd \
		usr/bin/testparm \
		usr/lib/$pkgname/libgpext-samba4.so \
		usr/lib/$pkgname/libnet-keytab-samba4.so
}

_common_server_libs() {
	pkgdesc="Samba libraries shared by common-tools and servers"
	depends=""
	cd "$pkgdir"
	_mv_files \
		usr/lib/libnetapi.so.* \
		usr/lib/libsmbldap.so.* \
		usr/lib/$pkgname/libads-samba4.so \
		usr/lib/$pkgname/libauth-samba4.so \
		usr/lib/$pkgname/libdfs-server-ad-samba4.so \
		usr/lib/$pkgname/libnpa-tstream-samba4.so \
		usr/lib/$pkgname/libprinting-migrate-samba4.so \
		usr/lib/$pkgname/libsmbd-base-samba4.so \
		usr/lib/$pkgname/libsmbd-conn-samba4.so \
		usr/lib/$pkgname/libsmbldaphelper-samba4.so \
		usr/lib/$pkgname/pdb
}

_common_libs() {
	pkgdesc="Samba libraries shared by common-tools, server and clients"
	depends=""
	cd "$pkgdir"
	_mv_files \
		usr/lib/$pkgname/libcli-spoolss-samba4.so \
		usr/lib/$pkgname/libtrusts-util-samba4.so \
		usr/lib/libdcerpc-binding.so.* \
		usr/lib/libsamba-passdb.so.* \
		usr/lib/$pkgname/libdcerpc-samba-samba4.so \
		usr/lib/$pkgname/liblibcli-lsa3-samba4.so \
		usr/lib/$pkgname/liblibcli-netlogon3-samba4.so \
		usr/lib/$pkgname/liblibsmb-samba4.so \
		usr/lib/$pkgname/libmsrpc3-samba4.so \
		usr/lib/$pkgname/libndr-samba4.so \
		usr/lib/$pkgname/libMESSAGING-SEND-samba4.so
}

libsmbclient() {
	pkgdesc="The SMB client library"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/libsmbclient.so.*
}

_client_libs() {
	pkgdesc="Samba libraries used by clients"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/libdcerpc.so.* \
		usr/lib/$pkgname/libcli-ldap-samba4.so \
		usr/lib/$pkgname/libclidns-samba4.so \
		usr/lib/$pkgname/libcmdline-contexts-samba4.so \
		usr/lib/$pkgname/libcmdline-credentials-samba4.so \
		usr/lib/$pkgname/libdsdb-garbage-collect-tombstones-samba4.so \
		usr/lib/$pkgname/libevents-samba4.so \
		usr/lib/$pkgname/libhttp-samba4.so \
		usr/lib/$pkgname/libmscat-samba4.so \
		usr/lib/$pkgname/libnetif-samba4.so \
		usr/lib/$pkgname/libpopt-samba3-cmdline-samba4.so \
		usr/lib/$pkgname/libregistry-samba4.so \
		usr/lib/$pkgname/libsmbclient-raw-samba4.so
}

client() {
	pkgdesc="Samba client programs"
	depends="$pkgname-common=$pkgver-r$pkgrel"
	cd "$pkgdir"
	_mv_files \
		usr/bin/cifsdd \
		usr/bin/dumpmscat \
		usr/bin/findsmb \
		usr/bin/dbwrap_tool \
		usr/bin/mvxattr \
		usr/bin/nmblookup \
		usr/bin/oLschema2ldif \
		usr/bin/regdiff \
		usr/bin/regpatch \
		usr/bin/regshell \
		usr/bin/regtree \
		usr/bin/rpcclient \
		usr/bin/samba-regedit \
		usr/bin/sharesec \
		usr/bin/smbcacls \
		usr/bin/smbclient \
		usr/bin/smbcquotas \
		usr/bin/smbget \
		usr/bin/smbprint \
		usr/bin/smbspool \
		usr/bin/smbtar \
		usr/bin/smbtree \
		usr/lib/$pkgname/smbspool_krb5_wrapper
}

_server_libs() {
	pkgdesc="Samba libraries shared by server and windbind"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/$pkgname/libMESSAGING-samba4.so \
		usr/lib/$pkgname/libdcerpc-samba4.so \
		usr/lib/$pkgname/libidmap-samba4.so \
		usr/lib/$pkgname/libnss-info-samba4.so \
		\
		usr/lib/$pkgname/libnon-posix-acls-samba4.so
}


winbind() {
	pkgdesc="Samba user and group resolver"
	depends="$pkgname-common=$pkgver-r$pkgrel"
	install="winbind.pre-install winbind.pre-upgrade winbind.post-install
		winbind.post-upgrade"
	cd "$pkgdir"
	_mv_files \
		usr/sbin/winbindd \
		usr/lib/$pkgname/idmap \
		usr/lib/$pkgname/nss_info
	install -d -g winbind -m 750 \
		"$subpkgdir"/var/cache/$pkgname/winbindd_privileged
}

libwbclient() {
	pkgdesc="Samba winbind client libraries"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/libwbclient.so.* \
		usr/lib/$pkgname/libreplace-samba4.so \
		usr/lib/$pkgname/libwinbind-client-samba4.so
}

_winbind_clients() {
	pkgdesc="Samba winbind client tools"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/bin/ntlm_auth \
		usr/bin/wbinfo
}

_libnss_winbind() {
	pkgdesc="Samba winbind NSS plugin"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/libnss_winbind.so* \
		usr/lib/libnss_wins.so*
}

_winbind_krb5_locator() {
	pkgdesc="Samba winbind krb5 locator"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/samba/krb5
}

_pam_winbind() {
	pkgdesc="PAM module for winbind"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/security
}

dc() {
	pkgdesc="Samba AD Domain Controller"
	depends="$pkgname-common=$pkgver-r$pkgrel
		$pkgname-server=$pkgver-r$pkgrel
		$pkgname-winbind=$pkgver-r$pkgrel
		py3-$pkgname=$pkgver-r$pkgrel tdb"
	cd "$pkgdir"
	_mv_files \
		usr/bin/samba-tool \
		usr/sbin/samba* \
		usr/share/$pkgname \
		usr/lib/$pkgname/auth/samba4.so \
		usr/lib/$pkgname/gensec \
		usr/lib/$pkgname/ldb \
		usr/lib/$pkgname/libsmbpasswdparser-samba4.so \
		usr/lib/$pkgname/vfs/posix_eadb.so
}

_dc_libs() {
	pkgdesc="Samba AD Domain Controller libraries"
	cd "$pkgdir"
	_mv_files \
		usr/lib/libdcerpc-samr.so.* \
		usr/lib/libdcerpc-server.so.* \
		usr/lib/libsamba-policy.* \
		usr/lib/$pkgname/bind9 \
		usr/lib/$pkgname/libHDB-SAMBA4-samba4.so \
		usr/lib/$pkgname/libLIBWBCLIENT-OLD-samba4.so \
		usr/lib/$pkgname/libauth-unix-token-samba4.so \
		usr/lib/$pkgname/libauth4-samba4.so \
		usr/lib/$pkgname/libcluster-samba4.so \
		usr/lib/$pkgname/libdb-glue-samba4.so \
		usr/lib/$pkgname/libdnsserver-common-samba4.so \
		usr/lib/$pkgname/libdsdb-module-samba4.so \
		usr/lib/$pkgname/libhdb-samba4.so.* \
		usr/lib/$pkgname/libkdc-samba4.so.* \
		usr/lib/$pkgname/libpac-samba4.so \
		usr/lib/$pkgname/libposix-eadb-samba4.so \
		usr/lib/$pkgname/libprocess-model-samba4.so \
		usr/lib/$pkgname/libscavenge-dns-records-samba4.so \
		usr/lib/$pkgname/libservice-samba4.so \
		usr/lib/$pkgname/libshares-samba4.so \
		usr/lib/$pkgname/process_model \
		usr/lib/$pkgname/service
}

_heimdal_libs() {
	pkgdesc="Samba heimdal libraries"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/$pkgname/libasn1-samba4.so.* \
		usr/lib/$pkgname/libgssapi-samba4.so.* \
		usr/lib/$pkgname/libhcrypto-samba4.so.* \
		usr/lib/$pkgname/libheimbase-samba4.so.* \
		usr/lib/$pkgname/libheimntlm-samba4.so.* \
		usr/lib/$pkgname/libhx509-samba4.so.* \
		usr/lib/$pkgname/libkrb5-samba4.so.* \
		usr/lib/$pkgname/libroken-samba4.so.* \
		usr/lib/$pkgname/libwind-samba4.so.*
}

server() {
	pkgdesc="Samba server"
	depends="$pkgname-common=$pkgver-r$pkgrel"
	cd "$pkgdir"
	_mv_files \
		usr/sbin/nmbd \
		usr/sbin/smbd \
		usr/sbin/eventlogadm \
		usr/bin/smbstatus \
		\
		usr/lib/$pkgname/auth \
		usr/lib/$pkgname/libxattr-tdb-samba4.so \
		usr/lib/$pkgname/vfs
}


pidl() {
	pkgdesc="Perl IDL compiler"
	depends="perl"
	cd "$pkgdir"
	_mv_files \
		usr/bin/pidl \
		usr/share/perl*
}

_py3() {
	pkgdesc="Samba python libraries"
	depends="py3-tdb"
	mkdir -p "$subpkgdir"/usr/lib
	mv "$pkgdir"/usr/lib/python* "$subpkgdir"/usr/lib/
}

_test() {
	pkgdesc="Samba server and client testing tools"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/bin/gentest \
		usr/bin/locktest \
		usr/bin/masktest \
		usr/bin/ndrdump \
		usr/bin/smbtorture \
		usr/lib/$pkgname/libdlz-bind9-for-torture-samba4.so \
		usr/lib/$pkgname/libtorture-samba4.so
}

libs() {
	pkgdesc="Samba core libraries"
	depends=
	cd "$pkgdir"
	_mv_files \
		usr/lib/libndr-krb5pac.so.* \
		usr/lib/libndr-nbt.so.* \
		usr/lib/libndr-standard.so.* \
		usr/lib/libndr.so.* \
		usr/lib/libsamba-credentials.so.* \
		usr/lib/libsamba-errors.so.* \
		usr/lib/libsamba-hostconfig.so.* \
		usr/lib/libsamba-util.so.* \
		usr/lib/libsamdb.so.* \
		usr/lib/libsmbconf.so.* \
		usr/lib/libtevent-util.so.* \
		usr/lib/$pkgname/libCHARSET3-samba4.so \
		usr/lib/$pkgname/libaddns-samba4.so \
		usr/lib/$pkgname/libasn1util-samba4.so \
		usr/lib/$pkgname/libauthkrb5-samba4.so \
		usr/lib/$pkgname/libcli-cldap-samba4.so \
		usr/lib/$pkgname/libcli-ldap-common-samba4.so \
		usr/lib/$pkgname/libcli-nbt-samba4.so \
		usr/lib/$pkgname/libcli-smb-common-samba4.so \
		usr/lib/$pkgname/libcliauth-samba4.so \
		usr/lib/$pkgname/libcommon-auth-samba4.so \
		usr/lib/$pkgname/libcmocka-samba4.so \
		usr/lib/$pkgname/libdbwrap-samba4.so \
		usr/lib/$pkgname/libflag-mapping-samba4.so \
		usr/lib/$pkgname/libgenrand-samba4.so \
		usr/lib/$pkgname/libgensec-samba4.so \
		usr/lib/$pkgname/libgse-samba4.so \
		usr/lib/$pkgname/libinterfaces-samba4.so \
		usr/lib/$pkgname/libiov-buf-samba4.so \
		usr/lib/$pkgname/libkrb5samba-samba4.so \
		usr/lib/$pkgname/libldbsamba-samba4.so \
		usr/lib/$pkgname/libmessages-dgm-samba4.so \
		usr/lib/$pkgname/libmessages-util-samba4.so \
		usr/lib/$pkgname/libmsghdr-samba4.so \
		usr/lib/$pkgname/libndr-samba-samba4.so \
		usr/lib/$pkgname/libpopt-samba3-samba4.so \
		usr/lib/$pkgname/libsamba-cluster-support-samba4.so \
		usr/lib/$pkgname/libsamba-debug-samba4.so \
		usr/lib/$pkgname/libsamba-modules-samba4.so \
		usr/lib/$pkgname/libsamba-security-samba4.so \
		usr/lib/$pkgname/libsamba-sockets-samba4.so \
		usr/lib/$pkgname/libsamba3-util-samba4.so \
		usr/lib/$pkgname/libsamdb-common-samba4.so \
		usr/lib/$pkgname/libsecrets3-samba4.so \
		usr/lib/$pkgname/libserver-id-db-samba4.so \
		usr/lib/$pkgname/libserver-role-samba4.so \
		usr/lib/$pkgname/libsmb-transport-samba4.so \
		usr/lib/$pkgname/libsmbd-shim-samba4.so \
		usr/lib/$pkgname/libsocket-blocking-samba4.so \
		usr/lib/$pkgname/libsys-rw-samba4.so \
		usr/lib/$pkgname/libtalloc-report-samba4.so \
		usr/lib/$pkgname/libtdb-wrap-samba4.so \
		usr/lib/$pkgname/libtime-basic-samba4.so \
		usr/lib/$pkgname/libutil-cmdline-samba4.so \
		usr/lib/$pkgname/libutil-reg-samba4.so \
		usr/lib/$pkgname/libutil-setid-samba4.so \
		usr/lib/$pkgname/libutil-tdb-samba4.so
	# exit with error if some stuff stayed at main pack
	rmdir "$pkgdir"/usr/lib/$pkgname \
		"$pkgdir"/usr/share \
		"$pkgdir"/usr/sbin \
		"$pkgdir"/usr/bin \
		"$pkgdir"/usr/lib \
		"$pkgdir"/usr
}

sha512sums="8e1ea3dd76645df12bca8253d21151eb28bb524b480ce8247fb2c850906d81c9659e2dd20904ee66889aacbf56a89c9f803b69649e12adc1f1b921561ddb2013  samba-4.10.18.tar.gz
0d4fd9862191554dc9c724cec0b94fd19afbfd0c4ed619e4c620c075e849cb3f3d44db1e5f119d890da23a3dd0068d9873703f3d86c47b91310521f37356208b  getpwent_r.patch
a99e771f28d787dc22e832b97aa48a1c5e13ddc0c030c501a3c12819ff6e62800ef084b62930abe88c6767d785d5c37e2e9f18a4f9a24f2ee1f5d9650320c556  musl_uintptr.patch
1854577d0e4457e27da367a6c7ec0fb5cfd63cefea0a39181c9d6e78cf8d3eb50878cdddeea3daeec955d00263151c2f86ea754ff4276ef98bc52c0276d9ffe8  netdb-defines.patch
202667cb0383414d9289cd67574f5e1140c9a0ff63bb82a746a59b2397a00db15654bfb30cb5ec1cd68a097899be0f849d9aab4c0d210152386c9e66c640f0c0  netapp.patch
27f12c8395be25d9806d232cc30334f2f7c7d175971d2d1944dd886d699e0381a6f222c17e3d7bc087cf7a29bfb3e98cf25ba98f414c4afe0297b9d134a28bd8  bind-9.12.patch
c0afe8b1dfddc5290c9aa611163d20adc3a546f54bba0081f739cda4255829f1a72bae422b6cb049aca82e58d4daf63ad5553f4c5c51671019bfbbc2781460f0  missing-headers.patch
5cda0a07089b99d99f33de74aae89a338954451167f72a9972cc437a7d06d92590c07386fd24e94c72ff34f1dd42494c5d7fcb48ca1823affa8168e83c239067  musl_rm_unistd_incl.patch
96070e2461370437f48571e7de550c13a332fef869480cfe92e7cac73a998f6c2ee85d2580df58211953bebd0e577691aa710c8edddf3ea0f30e9d47d0a2fd44  samba.initd
e2b49cb394e758447ca97de155a61b4276499983a0a5c00b44ae621c5559b759a766f8d1c8d3ee98ad5560f4064a847a7a20cfa2e14f85c061bec8b80fd649eb  samba.confd
3458a4e1f8a8b44c966afb339b2dca51615be049f594c14911fc4d8203623deee416b6fe881436e246fc7d49c97a2b3bf9c5f33ba774302b24190a1103d6b67d  samba.logrotate"