hostapd: set mcast_rate in mesh mode
[oweals/openwrt.git] / package / network / services / samba36 / Makefile
1 #
2 # Copyright (C) 2007-2014 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=samba
11 PKG_VERSION:=3.6.25
12 PKG_RELEASE:=8
13
14 PKG_SOURCE_URL:=https://download.samba.org/pub/samba \
15                 https://download.samba.org/pub/samba/stable
16 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
17 PKG_HASH:=8f2c8a7f2bd89b0dfd228ed917815852f7c625b2bc0936304ac3ed63aaf83751
18
19 PKG_LICENSE:=GPL-3.0
20 PKG_LICENSE_FILES:=COPYING
21
22 PKG_BUILD_PARALLEL:=1
23
24 include $(INCLUDE_DIR)/package.mk
25
26 MAKE_PATH:=source3
27 CONFIGURE_PATH:=source3
28
29 PKG_BUILD_BIN:=$(PKG_BUILD_DIR)/$(MAKE_PATH)/bin
30
31 define Package/samba/Default
32   SECTION:=net
33   CATEGORY:=Network
34   TITLE:=Samba 3.6 SMB/CIFS
35   URL:=https://www.samba.org/
36   MAINTAINER:=Felix Fietkau <nbd@nbd.name>
37 endef
38
39 define Package/samba36-server
40   $(call Package/samba/Default)
41   TITLE+= server
42   DEPENDS:=+USE_GLIBC:librt $(ICONV_DEPENDS)
43 endef
44
45 define Package/samba36-client
46   $(call Package/samba/Default)
47   TITLE+= client
48   DEPENDS:=+libreadline +libncurses
49 endef
50
51 define Package/samba36-net
52   $(call Package/samba/Default)
53   TITLE+= net commands
54   DEPENDS:=+libreadline +libncurses
55 endef
56
57 define Package/samba36-server/config
58         config PACKAGE_SAMBA_MAX_DEBUG_LEVEL
59                 int "Maximum level of compiled-in debug messages"
60                 depends on PACKAGE_samba36-server || PACKAGE_samba36-client
61                 default -1
62 endef
63
64 define Package/samba36-server/description
65  The Samba software suite is a collection of programs that implements the
66  SMB protocol for UNIX systems, allowing you to serve files and printers to
67  Windows, NT, OS/2 and DOS clients. This protocol is sometimes also referred
68  to as the LanManager or Netbios protocol.
69 endef
70
71 TARGET_CFLAGS += -DMAX_DEBUG_LEVEL=$(CONFIG_PACKAGE_SAMBA_MAX_DEBUG_LEVEL) -D__location__=\\\"\\\" -ffunction-sections -fdata-sections
72 TARGET_LDFLAGS += -Wl,--gc-sections
73
74 CONFIGURE_VARS += \
75         ac_cv_lib_attr_getxattr=no \
76         ac_cv_search_getxattr=no \
77         ac_cv_file__proc_sys_kernel_core_pattern=yes \
78         libreplace_cv_HAVE_C99_VSNPRINTF=yes \
79         libreplace_cv_HAVE_GETADDRINFO=yes \
80         libreplace_cv_HAVE_IFACE_IFCONF=yes \
81         LINUX_LFS_SUPPORT=yes \
82         samba_cv_CC_NEGATIVE_ENUM_VALUES=yes \
83         samba_cv_HAVE_GETTIMEOFDAY_TZ=yes \
84         samba_cv_HAVE_IFACE_IFCONF=yes \
85         samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=yes \
86         samba_cv_HAVE_SECURE_MKSTEMP=yes \
87         samba_cv_HAVE_WRFILE_KEYTAB=no \
88         samba_cv_USE_SETREUID=yes \
89         samba_cv_USE_SETRESUID=yes \
90         samba_cv_have_setreuid=yes \
91         samba_cv_have_setresuid=yes \
92         ac_cv_header_libunwind_h=no \
93         ac_cv_header_zlib_h=no \
94         samba_cv_zlib_1_2_3=no \
95         ac_cv_path_PYTHON="" \
96         ac_cv_path_PYTHON_CONFIG=""
97
98 CONFIGURE_ARGS += \
99         --exec-prefix=/usr \
100         --prefix=/ \
101         --disable-avahi \
102         --disable-cups \
103         --disable-pie \
104         --disable-relro \
105         --disable-static \
106         --disable-swat \
107         --disable-shared-libs \
108         --with-libiconv="$(ICONV_PREFIX)" \
109         --with-codepagedir=/etc/samba \
110         --with-configdir=/etc/samba \
111         --with-included-iniparser \
112         --with-included-popt \
113         --with-lockdir=/var/lock \
114         --with-logfilebase=/var/log \
115         --with-nmbdsocketdir=/var/nmbd \
116         --with-piddir=/var/run \
117         --with-privatedir=/etc/samba \
118         --with-sendfile-support \
119         --without-acl-support \
120         --without-cluster-support \
121         --without-ads \
122         --without-krb5 \
123         --without-ldap \
124         --without-pam \
125         --without-winbind \
126         --without-libtdb \
127         --without-libtalloc \
128         --without-libnetapi \
129         --without-libsmbclient \
130         --without-libsmbsharemodes \
131         --without-libtevent \
132         --without-libaddns \
133         --with-shared-modules=pdb_tdbsam,pdb_wbc_sam,idmap_nss,nss_info_template,auth_winbind,auth_wbc,auth_domain
134
135 MAKE_FLAGS += DYNEXP= PICFLAG= MODULES=
136
137 define Package/samba36-server/conffiles
138 /etc/config/samba
139 /etc/samba/smb.conf.template
140 /etc/samba/smbpasswd
141 endef
142
143 define Package/samba36-server/install
144         $(INSTALL_DIR) $(1)/etc/config
145         $(INSTALL_CONF) ./files/samba.config $(1)/etc/config/samba
146         $(INSTALL_DIR) $(1)/etc/samba
147         $(INSTALL_DATA) ./files/smb.conf.template $(1)/etc/samba
148         $(INSTALL_DATA) $(PKG_BUILD_DIR)/codepages/lowcase.dat $(1)/etc/samba
149         $(INSTALL_DATA) $(PKG_BUILD_DIR)/codepages/upcase.dat $(1)/etc/samba
150         $(INSTALL_DATA) $(PKG_BUILD_DIR)/codepages/valid.dat $(1)/etc/samba
151         $(INSTALL_DIR) $(1)/etc/init.d
152         $(INSTALL_BIN) ./files/samba.init $(1)/etc/init.d/samba
153         $(INSTALL_DIR) $(1)/usr/sbin
154         $(INSTALL_BIN) $(PKG_BUILD_BIN)/samba_multicall $(1)/usr/sbin
155         $(LN) samba_multicall $(1)/usr/sbin/smbd
156         $(LN) samba_multicall $(1)/usr/sbin/nmbd
157         $(LN) samba_multicall $(1)/usr/sbin/smbpasswd
158 endef
159
160 define Package/samba36-client/install
161         $(INSTALL_DIR) $(1)/usr/sbin
162         $(INSTALL_BIN) $(PKG_BUILD_BIN)/smbclient $(1)/usr/sbin
163         $(INSTALL_BIN) $(PKG_BUILD_BIN)/nmblookup $(1)/usr/sbin
164 endef
165
166 define Package/samba36-net/install
167         $(INSTALL_DIR) $(1)/usr/sbin
168         $(INSTALL_BIN) $(PKG_BUILD_BIN)/net $(1)/usr/sbin
169 endef
170
171 $(eval $(call BuildPackage,samba36-client))
172 $(eval $(call BuildPackage,samba36-server))
173 $(eval $(call BuildPackage,samba36-net))
174