You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

453 lines
16 KiB

  1. # Based partially on (wongsyrone/hbl0307106015) versions
  2. include $(TOPDIR)/rules.mk
  3. PKG_NAME:=samba
  4. PKG_VERSION:=4.12.3
  5. PKG_RELEASE:=2
  6. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  7. PKG_SOURCE_URL:= \
  8. https://ftp.gwdg.de/pub/samba/stable/ \
  9. https://ftp.heanet.ie/mirrors/ftp.samba.org/stable/ \
  10. https://ftp.riken.jp/net/samba/samba/stable/ \
  11. http://www.nic.funet.fi/index/samba/pub/samba/stable/ \
  12. http://samba.mirror.bit.nl/samba/ftp/stable/ \
  13. https://download.samba.org/pub/samba/stable/
  14. PKG_HASH:=3fadbca4504937820d0d8a34e500a1efdcc35e0c554f05bd0a844916ae528727
  15. PKG_MAINTAINER:=Andy Walsh <andy.walsh44+github@gmail.com>
  16. PKG_LICENSE:=GPL-3.0-only
  17. PKG_LICENSE_FILES:=COPYING
  18. PKG_CPE_ID:=cpe:/a:samba:samba
  19. # samba4=(asn1_compile,compile_et) rpcsvc-proto=(rpcgen)
  20. HOST_BUILD_DEPENDS:=python3/host rpcsvc-proto/host perl/host perl-parse-yapp/host
  21. PKG_BUILD_DEPENDS:=samba4/host libtasn1/host
  22. PKG_CONFIG_DEPENDS:= \
  23. CONFIG_SAMBA4_SERVER_NETBIOS \
  24. CONFIG_SAMBA4_SERVER_AVAHI \
  25. CONFIG_SAMBA4_SERVER_VFS \
  26. CONFIG_SAMBA4_SERVER_VFSX \
  27. CONFIG_SAMBA4_SERVER_AD_DC \
  28. CONFIG_PACKAGE_kmod-fs-btrfs \
  29. CONFIG_PACKAGE_kmod-fs-xfs
  30. PYTHON3_PKG_BUILD:=0
  31. include $(INCLUDE_DIR)/package.mk
  32. include $(INCLUDE_DIR)/host-build.mk
  33. include $(INCLUDE_DIR)/kernel.mk
  34. include $(INCLUDE_DIR)/version.mk
  35. include ../../lang/python/python3-host.mk
  36. include ../../lang/python/python3-package.mk
  37. include ../../lang/perl/perlver.mk
  38. define Package/samba4/Default
  39. SECTION:=net
  40. CATEGORY:=Network
  41. TITLE:=Samba $(PKG_VERSION)
  42. URL:=https://www.samba.org/
  43. endef
  44. define Package/samba4/Default/description
  45. The Samba software suite is a collection of programs that implements the
  46. SMB/CIFS protocol for UNIX systems, allowing you to serve files and printers.
  47. Samba 4 implements up-to protocol version SMB v3.1.1 (Win10), supports mDNS via AVAHI and a AD-DC setup via krb5.
  48. NOTE: No cluster and printer support.
  49. endef
  50. define Package/samba4-libs
  51. $(call Package/samba4/Default)
  52. TITLE+= libs
  53. DEPENDS:= +libtirpc +libreadline +libpopt +libcap +zlib +libgnutls +libtasn1 +libuuid +libopenssl +USE_GLIBC:libpthread \
  54. +PACKAGE_libpam:libpam \
  55. +SAMBA4_SERVER_VFS:attr \
  56. +SAMBA4_SERVER_VFSX:libaio \
  57. +SAMBA4_SERVER_AVAHI:libavahi-client \
  58. +SAMBA4_SERVER_AD_DC:python3-cryptodome +SAMBA4_SERVER_AD_DC:libopenldap +SAMBA4_SERVER_AD_DC:jansson +SAMBA4_SERVER_AD_DC:libarchive +SAMBA4_SERVER_AD_DC:acl +SAMBA4_SERVER_AD_DC:attr
  59. endef
  60. define Package/samba4-server
  61. $(call Package/samba4/Default)
  62. TITLE+= server
  63. DEPENDS:= +samba4-libs
  64. CONFLICTS:=samba36-server
  65. endef
  66. define Package/samba4-server/description
  67. installs: smbd (nmbd) smbpasswd pdbedit testparm (nmblookup) (smbcacls sharesec)
  68. (samba samba-tool ntlm_auth samba-gpupdate samba_dnsupdate samba_kcc samba_spnupdate samba_upgradedns samba_downgrade_db)
  69. This provides the basic fileserver service and is the minimum needed to serve file shares.
  70. HINT: https://fitzcarraldoblog.wordpress.com/2016/10/17/a-correct-method-of-configuring-samba-for-browsing-smb-shares-in-a-home-network/
  71. endef
  72. define Package/samba4-server/config
  73. select PACKAGE_wsdd2
  74. source "$(SOURCE)/Config.in"
  75. endef
  76. define Package/samba4-client
  77. $(call Package/samba4/Default)
  78. TITLE+= client
  79. DEPENDS:= +samba4-libs
  80. endef
  81. define Package/samba4-client/description
  82. installs: cifsdd smbclient smbget
  83. The smbclient program implements a simple ftp-like client for accessing SMB shares
  84. endef
  85. define Package/samba4-admin
  86. $(call Package/samba4/Default)
  87. TITLE+= admin tools
  88. DEPENDS:= +samba4-libs
  89. endef
  90. define Package/samba4-admin/description
  91. installs: net smbcontrol profiles rpcclient dbwrap_tool eventlogadm
  92. ldbadd ldbdel ldbedit ldbmodify ldbrename ldbsearch
  93. tdbbackup tdbdump tdbrestore tdbtool
  94. Administration tools collection
  95. endef
  96. define Package/samba4-utils
  97. $(call Package/samba4/Default)
  98. TITLE+= utils
  99. DEPENDS:= +samba4-libs
  100. endef
  101. define Package/samba4-utils/description
  102. installs: smbstatus smbtree mvxattr smbtar smbcquotas
  103. Utilities collection
  104. endef
  105. TARGET_CFLAGS += $(FPIC) -ffunction-sections -fdata-sections -I$(STAGING_DIR)/usr/include/tirpc
  106. TARGET_LDFLAGS += -Wl,--gc-sections,--as-needed
  107. # dont mess with sambas private rpath!
  108. RSTRIP:=:
  109. CONFIGURE_VARS += \
  110. CPP="$(TARGET_CROSS)cpp"
  111. CONFIGURE_CMD = ./buildtools/bin/waf
  112. HOST_CONFIGURE_CMD = ./buildtools/bin/waf
  113. # Strip options that WAF configure script does not recognize
  114. CONFIGURE_ARGS:=$(filter-out \
  115. --target=% \
  116. --host=% \
  117. --build=% \
  118. --program-prefix=% \
  119. --program-suffix=% \
  120. --disable-nls \
  121. --disable-ipv6 \
  122. , $(CONFIGURE_ARGS))
  123. HOST_CONFIGURE_ARGS:=$(filter-out \
  124. --target=% \
  125. --host=% \
  126. --build=% \
  127. --program-prefix=% \
  128. --program-suffix=% \
  129. --disable-nls \
  130. --disable-ipv6 \
  131. , $(HOST_CONFIGURE_ARGS))
  132. # Waf needs the "configure" argument
  133. CONFIGURE_ARGS:=configure $(CONFIGURE_ARGS)
  134. HOST_CONFIGURE_ARGS:=configure $(HOST_CONFIGURE_ARGS)
  135. CONFIGURE_ARGS += \
  136. --hostcc="$(HOSTCC)" \
  137. --cross-compile \
  138. --cross-answers=cross-answers.txt \
  139. --disable-cups \
  140. --disable-iprint \
  141. --disable-cephfs \
  142. --disable-fault-handling \
  143. --disable-glusterfs \
  144. --disable-spotlight \
  145. --enable-fhs \
  146. --without-automount \
  147. --without-iconv \
  148. --without-lttng \
  149. --without-ntvfs-fileserver \
  150. --without-pam \
  151. --without-systemd \
  152. --without-utmp \
  153. --without-dmapi \
  154. --without-fam \
  155. --without-gettext \
  156. --without-regedit \
  157. --without-gpgme
  158. HOST_CONFIGURE_ARGS += \
  159. --hostcc="$(HOSTCC)" \
  160. --disable-cups \
  161. --disable-iprint \
  162. --disable-cephfs \
  163. --disable-fault-handling \
  164. --disable-glusterfs \
  165. --disable-spotlight \
  166. --disable-rpath \
  167. --disable-rpath-install \
  168. --disable-rpath-private-install \
  169. --enable-fhs \
  170. --without-automount \
  171. --without-iconv \
  172. --without-lttng \
  173. --without-ntvfs-fileserver \
  174. --without-pam \
  175. --without-systemd \
  176. --without-utmp \
  177. --without-dmapi \
  178. --without-fam \
  179. --without-gettext \
  180. --without-regedit \
  181. --without-gpgme
  182. HOST_CONFIGURE_ARGS += --disable-avahi --without-quotas --without-acl-support --without-winbind \
  183. --without-ad-dc --without-json --without-libarchive --disable-python --nopyc --nopyo \
  184. --without-dnsupdate --without-ads --without-ldap --without-ldb-lmdb
  185. HOST_CONFIGURE_VARS += python_LDFLAGS="" python_LIBDIR=""
  186. # Optional AES-NI support - https://lists.samba.org/archive/samba-technical/2017-September/122738.html
  187. # Support for Nettle wasn't comitted
  188. ifdef CONFIG_TARGET_x86_64
  189. CONFIGURE_ARGS += --accel-aes=intelaesni
  190. else
  191. CONFIGURE_ARGS += --accel-aes=none
  192. endif
  193. CONFIGURE_ARGS += \
  194. --with-lockdir=/var/lock \
  195. --with-logfilebase=/var/log \
  196. --with-piddir=/var/run \
  197. --with-privatedir=/etc/samba
  198. # features
  199. ifeq ($(CONFIG_SAMBA4_SERVER_VFS),y)
  200. CONFIGURE_ARGS += --with-quotas
  201. else
  202. CONFIGURE_ARGS += --without-quotas
  203. endif
  204. ifeq ($(CONFIG_SAMBA4_SERVER_AVAHI),y)
  205. CONFIGURE_ARGS += --enable-avahi
  206. else
  207. CONFIGURE_ARGS += --disable-avahi
  208. endif
  209. CONFIGURE_VARS += \
  210. PERL="$(STAGING_DIR_HOSTPKG)/usr/bin/perl$(PERL_VERSION3)"
  211. # NOTE: We need host python-bin, but target python-config here!
  212. CONFIGURE_VARS += python_LDFLAGS="" python_LIBDIR=""
  213. ifeq ($(CONFIG_SAMBA4_SERVER_AD_DC),y)
  214. CONFIGURE_ARGS += --without-winbind --without-ldb-lmdb --with-acl-support
  215. CONFIGURE_VARS += \
  216. PYTHON="$(HOST_PYTHON3_BIN)" \
  217. PYTHON_CONFIG="$(STAGING_DIR)/host/bin/$(PYTHON3)-config"
  218. else
  219. CONFIGURE_ARGS += --without-winbind --without-ads --without-ldap --without-ldb-lmdb --without-ad-dc \
  220. --without-json --without-libarchive --disable-python --nopyc --nopyo --without-dnsupdate --without-acl-support
  221. endif
  222. SAMBA4_PDB_MODULES :=pdb_smbpasswd,pdb_tdbsam,
  223. SAMBA4_AUTH_MODULES :=auth_builtin,auth_sam,auth_unix,
  224. SAMBA4_VFS_MODULES :=vfs_default,
  225. SAMBA4_VFS_MODULES_SHARED :=auth_script,
  226. ifeq ($(CONFIG_SAMBA4_SERVER_VFS),y)
  227. SAMBA4_VFS_MODULES_SHARED :=$(SAMBA4_VFS_MODULES_SHARED)vfs_fruit,vfs_shadow_copy2,vfs_recycle,vfs_fake_perms,vfs_readonly,vfs_cap,vfs_offline,vfs_crossrename,vfs_catia,vfs_streams_xattr,vfs_xattr_tdb,vfs_default_quota,
  228. ifeq ($(CONFIG_PACKAGE_kmod-fs-btrfs),y)
  229. SAMBA4_VFS_MODULES_SHARED :=$(SAMBA4_VFS_MODULES_SHARED)vfs_btrfs,
  230. endif
  231. endif
  232. ifeq ($(CONFIG_SAMBA4_SERVER_VFSX),y)
  233. SAMBA4_VFS_MODULES_SHARED :=$(SAMBA4_VFS_MODULES_SHARED)vfs_virusfilter,vfs_shell_snap,vfs_commit,vfs_worm,vfs_aio_fork,vfs_aio_pthread,vfs_netatalk,vfs_dirsort,vfs_fileid,
  234. ifeq ($(CONFIG_PACKAGE_kmod-fs-xfs),y)
  235. SAMBA4_VFS_MODULES_SHARED :=$(SAMBA4_VFS_MODULES_SHARED)vfs_linux_xfs_sgid,
  236. endif
  237. endif
  238. ifeq ($(CONFIG_SAMBA4_SERVER_AD_DC),y)
  239. SAMBA4_PDB_MODULES :=$(SAMBA4_PDB_MODULES)pdb_samba_dsdb,pdb_ldapsam,
  240. SAMBA4_AUTH_MODULES :=$(SAMBA4_AUTH_MODULES)auth_samba4,
  241. SAMBA4_VFS_MODULES :=$(SAMBA4_VFS_MODULES)vfs_posixacl,
  242. SAMBA4_VFS_MODULES_SHARED :=$(SAMBA4_VFS_MODULES_SHARED)vfs_audit,vfs_extd_audit,vfs_full_audit,vfs_acl_xattr,vfs_acl_tdb,
  243. # vfs_zfsacl needs https://github.com/zfsonlinux/zfs/tree/master/include/sys/zfs_acl.h
  244. # vfs_nfs4acl_xattr needs https://github.com/notriddle/libdrpc/blob/master/rpc/xdr.h
  245. endif
  246. SAMBA4_MODULES :=${SAMBA4_VFS_MODULES}${SAMBA4_AUTH_MODULES}${SAMBA4_PDB_MODULES}
  247. SAMBA4_MODULES_SHARDED :=${SAMBA4_VFS_MODULES_SHARED}
  248. CONFIGURE_ARGS += \
  249. --with-static-modules=$(SAMBA4_MODULES)!DEFAULT,!FORCED \
  250. --with-shared-modules=$(SAMBA4_MODULES_SHARDED)!DEFAULT,!FORCED
  251. HOST_CONFIGURE_ARGS += \
  252. --with-static-modules=!DEFAULT,!FORCED \
  253. --with-shared-modules=!DEFAULT,!FORCED
  254. # lib bundling
  255. PY_VER:=$(PYTHON3_VERSION_MAJOR)$(PYTHON3_VERSION_MINOR)
  256. # NOTE: bundle + make private, we want to avoid version configuration (build, link) conflicts
  257. HOST_CONFIGURE_ARGS += --builtin-libraries=replace --nonshared-binary=asn1_compile,compile_et
  258. SYSTEM_BUNDLED_LIBS:=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,replace,com_err
  259. PYTHON_BUNDLED_LIBS:=pytalloc-util.cpython-$(PY_VER),pyldb-util.cpython-$(PY_VER)
  260. # CONFIGURE_ARGS += --builtin-libraries=talloc,tevent,tevent-util,texpect,tdb,ldb,tdr,cmocka,com_err
  261. ifeq ($(CONFIG_SAMBA4_SERVER_AD_DC),y)
  262. CONFIGURE_ARGS += --bundled-libraries=NONE,$(SYSTEM_BUNDLED_LIBS),$(PYTHON_BUNDLED_LIBS)
  263. else
  264. CONFIGURE_ARGS += --bundled-libraries=NONE,$(SYSTEM_BUNDLED_LIBS)
  265. endif
  266. CONFIGURE_ARGS += --private-libraries=$(SYSTEM_BUNDLED_LIBS)
  267. export COMPILE_ET=$(STAGING_DIR_HOSTPKG)/bin/compile_et_samba
  268. export ASN1_COMPILE=$(STAGING_DIR_HOSTPKG)/bin/asn1_compile_samba
  269. # need to find host 'yapp'
  270. HOST_CONFIGURE_VARS+= \
  271. PATH="$(STAGING_DIR_HOSTPKG)/usr/bin:$(PATH)"
  272. CONFIGURE_VARS += \
  273. PATH="$(PATH):$(STAGING_DIR_HOSTPKG)/usr/bin"
  274. # we dont need GnuTLS/Yapp for the host helpers
  275. define Host/Prepare
  276. $(call Host/Prepare/Default)
  277. $(SED) 's,mandatory=True,mandatory=False,g' $(HOST_BUILD_DIR)/wscript_configure_system_gnutls
  278. $(SED) 's,gnutls_version =.*,gnutls_version = gnutls_min_required_version,g' $(HOST_BUILD_DIR)/wscript_configure_system_gnutls
  279. endef
  280. define Host/Compile
  281. (cd $(HOST_BUILD_DIR); \
  282. ./buildtools/bin/waf build \
  283. --targets=asn1_compile,compile_et \
  284. )
  285. endef
  286. define Host/Install
  287. $(INSTALL_DIR) $(STAGING_DIR_HOSTPKG)/bin/
  288. # add host tools suffix, prevent conflicts with krb5
  289. $(INSTALL_BIN) $(HOST_BUILD_DIR)/bin/asn1_compile $(STAGING_DIR_HOSTPKG)/bin/asn1_compile_samba
  290. $(INSTALL_BIN) $(HOST_BUILD_DIR)/bin/compile_et $(STAGING_DIR_HOSTPKG)/bin/compile_et_samba
  291. endef
  292. define Build/Prepare
  293. $(Build/Prepare/Default)
  294. ifeq ($(CONFIG_SAMBA4_SERVER_AD_DC),)
  295. # un-bundle dnspython
  296. $(SED) '/"dns.resolver":/d' $(PKG_BUILD_DIR)/third_party/wscript
  297. # unbundle iso8601
  298. $(SED) '/"iso8601":/d' $(PKG_BUILD_DIR)/third_party/wscript
  299. endif
  300. endef
  301. define Build/Configure
  302. $(CP) ./waf-cross-answers/$(ARCH).txt $(PKG_BUILD_DIR)/cross-answers.txt
  303. echo 'Checking uname sysname type: "$(VERSION_DIST)"' >> $(PKG_BUILD_DIR)/cross-answers.txt
  304. echo 'Checking uname machine type: "$(ARCH)"' >> $(PKG_BUILD_DIR)/cross-answers.txt
  305. echo 'Checking uname release type: "$(LINUX_VERSION)"' >> $(PKG_BUILD_DIR)/cross-answers.txt
  306. echo 'Checking uname version type: "$(VERSION_DIST) Linux-$(LINUX_VERSION) $(shell date +%Y-%m-%d)"' >> $(PKG_BUILD_DIR)/cross-answers.txt
  307. # NOTE: special answers for freeBSD/CircleCI
  308. echo 'Checking whether POSIX capabilities are available: OK' >> $(PKG_BUILD_DIR)/cross-answers.txt
  309. echo 'checking for clnt_create(): OK' >> $(PKG_BUILD_DIR)/cross-answers.txt
  310. # HACK: need to update WAF/qemu values (set to NO for now)
  311. echo 'Checking value of GNUTLS_CIPHER_AES_128_CFB8: NO' >> $(PKG_BUILD_DIR)/cross-answers.txt
  312. echo 'Checking value of GNUTLS_MAC_AES_CMAC_128: NO' >> $(PKG_BUILD_DIR)/cross-answers.txt
  313. echo 'Checking whether fcntl supports flags to send direct I/O availability signals: NO' >> $(PKG_BUILD_DIR)/cross-answers.txt
  314. echo 'Checking whether fcntl supports setting/geting hints: NO' >> $(PKG_BUILD_DIR)/cross-answers.txt
  315. $(call Build/Configure/Default)
  316. endef
  317. # Build via "waf install", avoid the make wrapper. (Samba logic is 'waf install' = build + install)
  318. define Build/Compile
  319. (cd $(PKG_BUILD_DIR); \
  320. ./buildtools/bin/waf install \
  321. --jobs=$(shell nproc) \
  322. --destdir="$(PKG_INSTALL_DIR)" \
  323. )
  324. endef
  325. # No default install see above
  326. define Build/Install
  327. endef
  328. define Package/samba4-libs/install
  329. $(INSTALL_DIR) $(1)/usr/lib
  330. $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so* $(1)/usr/lib/
  331. # rpath-install
  332. $(CP) $(PKG_INSTALL_DIR)/usr/lib/samba $(1)/usr/lib/
  333. endef
  334. define Package/samba4-client/install
  335. $(INSTALL_DIR) $(1)/usr/bin
  336. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{cifsdd,smbclient,smbget} $(1)/usr/bin/
  337. endef
  338. define Package/samba4-admin/install
  339. $(INSTALL_DIR) $(1)/usr/bin
  340. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{net,smbcontrol,profiles,rpcclient,dbwrap_tool} $(1)/usr/bin/
  341. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{ldbadd,ldbdel,ldbedit,ldbmodify,ldbrename,ldbsearch} $(1)/usr/bin/
  342. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{tdbbackup,tdbdump,tdbrestore,tdbtool} $(1)/usr/bin/
  343. $(INSTALL_DIR) $(1)/usr/sbin
  344. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/eventlogadm $(1)/usr/sbin/
  345. endef
  346. define Package/samba4-utils/install
  347. $(INSTALL_DIR) $(1)/usr/bin
  348. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{smbstatus,smbtree,mvxattr,smbtar} $(1)/usr/bin/
  349. ifeq ($(CONFIG_SAMBA4_SERVER_VFS),y)
  350. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/smbcquotas $(1)/usr/bin/
  351. endif
  352. endef
  353. define Package/samba4-server/install
  354. $(INSTALL_DIR) $(1)/usr/bin
  355. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{smbpasswd,pdbedit,testparm} $(1)/usr/bin/
  356. $(INSTALL_DIR) $(1)/usr/sbin
  357. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/smbd $(1)/usr/sbin/
  358. ifeq ($(CONFIG_SAMBA4_SERVER_NETBIOS),y)
  359. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/nmbd $(1)/usr/sbin/
  360. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/nmblookup $(1)/usr/bin/
  361. endif
  362. ifeq ($(CONFIG_SAMBA4_SERVER_AD_DC),y)
  363. $(INSTALL_DIR) $(1)/usr/lib
  364. $(CP) $(PKG_INSTALL_DIR)/usr/lib/$(PYTHON3) $(1)/usr/lib/
  365. $(INSTALL_DIR) $(1)/usr/share/
  366. $(CP) $(PKG_INSTALL_DIR)/usr/share/samba $(1)/usr/share/
  367. # fix wrong hardcoded python3 location
  368. $(SED) '1s,^#!/.*python3.*,#!/usr/bin/python3,' $(PKG_INSTALL_DIR)/usr/bin/samba-tool
  369. $(SED) '1s,^#!/.*python3.*,#!/usr/bin/python3,' $(PKG_INSTALL_DIR)/usr/sbin/{samba-gpupdate,samba_dnsupdate,samba_kcc,samba_spnupdate,samba_upgradedns,samba_downgrade_db}
  370. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{samba-tool,ntlm_auth,oLschema2ldif} $(1)/usr/bin/
  371. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{sharesec,smbcacls} $(1)/usr/bin/
  372. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/{samba,samba-gpupdate,samba_dnsupdate,samba_kcc,samba_spnupdate,samba_upgradedns,samba_downgrade_db} $(1)/usr/sbin/
  373. endif
  374. $(INSTALL_DIR) $(1)/etc/config $(1)/etc/samba $(1)/etc/init.d
  375. $(INSTALL_CONF) ./files/samba.config $(1)/etc/config/samba4
  376. $(INSTALL_DATA) ./files/smb.conf.template $(1)/etc/samba
  377. $(INSTALL_BIN) ./files/samba.init $(1)/etc/init.d/samba4
  378. endef
  379. define Package/samba4-server/conffiles
  380. /etc/config/samba4
  381. /etc/samba/smb.conf.template
  382. /etc/samba/smb.conf
  383. /etc/samba/smbpasswd
  384. /etc/samba/secrets.tdb
  385. /etc/samba/passdb.tdb
  386. /etc/samba/lmhosts
  387. /etc/nsswitch.conf
  388. /etc/krb5.conf
  389. endef
  390. $(eval $(call HostBuild))
  391. $(eval $(call BuildPackage,samba4-libs))
  392. $(eval $(call BuildPackage,samba4-server))
  393. $(eval $(call BuildPackage,samba4-client))
  394. $(eval $(call BuildPackage,samba4-admin))
  395. $(eval $(call BuildPackage,samba4-utils))