samba36: add a stripped-down multicall samba 3.6, including smbd, nmbd and smbpasswd...
[openwrt/svn-archive/archive.git] / net / samba36 / Makefile
1 #
2 # Copyright (C) 2007 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=samba
12 PKG_VERSION:=3.6.3
13 PKG_RELEASE:=1
14
15 PKG_SOURCE_URL_SUBDIR:=/
16 PKG_SOURCE_URL:=http://ftp.samba.org/pub/samba$(PKG_SOURCE_URL_SUBDIR)
17 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
18 PKG_MD5SUM:=98ac9db9f4b6ebfc3f013aa193ffb0d1
19
20 include $(INCLUDE_DIR)/package.mk
21
22 MAKE_PATH:=source3
23 CONFIGURE_PATH:=source3
24
25 PKG_BUILD_BIN:=$(PKG_BUILD_DIR)/$(MAKE_PATH)/bin
26
27 define Package/samba36-server
28 SECTION:=net
29 CATEGORY:=Network
30 TITLE:=Samba 3.6 SMB/CIFS server
31 URL:=http://www.samba.org/
32 endef
33
34 define Package/samba36-server/description
35 The Samba software suite is a collection of programs that implements the
36 SMB protocol for UNIX systems, allowing you to serve files and printers to
37 Windows, NT, OS/2 and DOS clients. This protocol is sometimes also referred
38 to as the LanManager or Netbios protocol.
39 endef
40
41 TARGET_CFLAGS += -DMAX_DEBUG_LEVEL=2 -ffunction-sections -fdata-sections
42 TARGET_LDFLAGS += -Wl,--gc-sections
43
44 CONFIGURE_VARS += \
45 ac_cv_file__proc_sys_kernel_core_pattern=yes \
46 libreplace_cv_HAVE_C99_VSNPRINTF=yes \
47 libreplace_cv_HAVE_GETADDRINFO=yes \
48 libreplace_cv_HAVE_IFACE_IFCONF=yes \
49 LINUX_LFS_SUPPORT=yes \
50 samba_cv_CC_NEGATIVE_ENUM_VALUES=yes \
51 samba_cv_HAVE_GETTIMEOFDAY_TZ=yes \
52 samba_cv_HAVE_IFACE_IFCONF=yes \
53 samba_cv_HAVE_KERNEL_OPLOCKS_LINUX=yes \
54 samba_cv_HAVE_SECURE_MKSTEMP=yes \
55 samba_cv_HAVE_WRFILE_KEYTAB=no \
56 samba_cv_USE_SETREUID=yes \
57 samba_cv_USE_SETRESUID=yes \
58 samba_cv_have_setreuid=yes \
59 samba_cv_have_setresuid=yes
60
61 CONFIGURE_ARGS += \
62 --exec-prefix=/usr \
63 --prefix=/ \
64 --disable-avahi \
65 --disable-cups \
66 --disable-pie \
67 --disable-relro \
68 --disable-static \
69 --disable-swat \
70 --with-codepagedir=/etc/samba \
71 --with-configdir=/etc/samba \
72 --with-included-iniparser \
73 --with-included-popt \
74 --with-lockdir=/var/lock \
75 --with-logfilebase=/var/log \
76 --with-nmbdsocketdir=/var/nmbd \
77 --with-piddir=/var/run \
78 --with-privatedir=/etc/samba \
79 --with-sendfile-support \
80 --without-cluster-support \
81 --without-ads \
82 --without-krb5 \
83 --without-ldap \
84 --without-pam \
85 --without-winbind
86
87 MAKE_FLAGS += DYNEXP=
88
89 define Package/samba36-server/install
90 $(INSTALL_DIR) $(1)/etc/config
91 $(INSTALL_DATA) ./files/samba.config $(1)/etc/config/samba
92 $(INSTALL_DIR) $(1)/etc/samba
93 $(INSTALL_DATA) ./files/smb.conf.template $(1)/etc/samba
94 $(INSTALL_DATA) $(PKG_BUILD_DIR)/codepages/lowcase.dat $(1)/etc/samba
95 $(INSTALL_DATA) $(PKG_BUILD_DIR)/codepages/upcase.dat $(1)/etc/samba
96 $(INSTALL_DATA) $(PKG_BUILD_DIR)/codepages/valid.dat $(1)/etc/samba
97 $(INSTALL_DIR) $(1)/usr/lib
98 $(INSTALL_BIN) $(PKG_BUILD_BIN)/libtalloc.so.2 $(1)/usr/lib
99 $(INSTALL_BIN) $(PKG_BUILD_BIN)/libtdb.so.1 $(1)/usr/lib
100 $(INSTALL_DIR) $(1)/etc/init.d
101 $(INSTALL_BIN) ./files/samba.init $(1)/etc/init.d/samba
102 $(INSTALL_DIR) $(1)/usr/sbin
103 $(INSTALL_BIN) $(PKG_BUILD_BIN)/samba_multicall $(1)/usr/sbin
104 ln -sf samba_multicall $(1)/usr/sbin/smbd
105 ln -sf samba_multicall $(1)/usr/sbin/nmbd
106 endef
107
108 $(eval $(call BuildPackage,samba36-server))
109