source: trunk/make/openssh/openssh.mk @ 13855

Letzte Änderung dieser Datei seit 13855 war 13855, erstellt von er13 vor 2 Jahren

openssh:

Dateigröße: 4.2 KB
Zeile 
1$(call PKG_INIT_BIN, 7.3p1)
2$(PKG)_SOURCE:=$(pkg)-$($(PKG)_VERSION).tar.gz
3$(PKG)_SOURCE_SHA1:=bfade84283fcba885e2084343ab19a08c7d123a5
4$(PKG)_SITE:=http://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable,ftp://ftp.openbsd.org/pub/OpenBSD/OpenSSH/portable
5
6$(PKG)_BIN_BINARIES             := ssh scp ssh-add ssh-agent ssh-keygen ssh-keysign ssh-keyscan sftp
7$(PKG)_BIN_BINARIES_INCLUDED    := $(call PKG_SELECTED_SUBOPTIONS,$($(PKG)_BIN_BINARIES))
8$(PKG)_BIN_BINARIES_BUILD_DIR   := $(addprefix $($(PKG)_DIR)/,$($(PKG)_BIN_BINARIES))
9$(PKG)_BIN_BINARIES_TARGET_DIR  := $(addprefix $($(PKG)_DEST_DIR)/usr/bin/,$($(PKG)_BIN_BINARIES))
10
11$(PKG)_SBIN_BINARIES            := sshd
12$(PKG)_SBIN_BINARIES_INCLUDED   := $(call PKG_SELECTED_SUBOPTIONS,$($(PKG)_SBIN_BINARIES))
13$(PKG)_SBIN_BINARIES_BUILD_DIR  := $(addprefix $($(PKG)_DIR)/,$($(PKG)_SBIN_BINARIES))
14$(PKG)_SBIN_BINARIES_TARGET_DIR := $(addprefix $($(PKG)_DEST_DIR)/usr/sbin/,$($(PKG)_SBIN_BINARIES))
15
16$(PKG)_LIB_BINARIES             := sftp-server
17$(PKG)_LIB_BINARIES_INCLUDED    := $(call PKG_SELECTED_SUBOPTIONS,$($(PKG)_LIB_BINARIES))
18$(PKG)_LIB_BINARIES_BUILD_DIR   := $(addprefix $($(PKG)_DIR)/,$($(PKG)_LIB_BINARIES))
19$(PKG)_LIB_BINARIES_TARGET_DIR  := $(addprefix $($(PKG)_DEST_DIR)/usr/lib/,$($(PKG)_LIB_BINARIES))
20
21$(PKG)_DEPENDS_ON += zlib
22
23# even in '--without-openssl'-mode OpenSSL is still a compile-time
24# dependency as some types from it are used throughout the OpenSSH code
25$(PKG)_CONFIGURE_OPTIONS += $(if $(FREETZ_PACKAGE_OPENSSH_INTERNAL_CRYPTO),--without-openssl)
26$(PKG)_DEPENDS_ON += openssl
27$(PKG)_REBUILD_SUBOPTS += FREETZ_OPENSSL_SHLIB_VERSION
28$(PKG)_REBUILD_SUBOPTS += FREETZ_PACKAGE_OPENSSH_INTERNAL_CRYPTO
29
30$(PKG)_REBUILD_SUBOPTS += FREETZ_PACKAGE_OPENSSH_STATIC
31
32$(PKG)_EXCLUDED += $(addprefix usr/bin/,$(filter-out $($(PKG)_BIN_BINARIES_INCLUDED),$($(PKG)_BIN_BINARIES)))
33$(PKG)_EXCLUDED += $(addprefix usr/sbin/,$(filter-out $($(PKG)_SBIN_BINARIES_INCLUDED),$($(PKG)_SBIN_BINARIES)))
34$(PKG)_EXCLUDED += $(addprefix usr/lib/,$(filter-out $($(PKG)_LIB_BINARIES_INCLUDED),$($(PKG)_LIB_BINARIES)))
35$(PKG)_EXCLUDED += $(if $(FREETZ_PACKAGE_OPENSSH_sshd),,etc/default.openssh etc/init.d/rc.openssh usr/lib/cgi-bin/openssh.cgi)
36$(PKG)_EXCLUDED += $(if $(FREETZ_PACKAGE_OPENSSH_INTERNAL_CRYPTO),etc/default.openssh/rsa_key.def etc/default.openssh/dsa_key.def)
37
38$(PKG)_AC_VARIABLES := have_decl_LLONG_MAX search_logout search_openpty
39$(PKG)_CONFIGURE_PRE_CMDS += $(call PKG_MAKE_AC_VARIABLES_PACKAGE_SPECIFIC,$($(PKG)_AC_VARIABLES))
40
41$(PKG)_CONFIGURE_OPTIONS += $(if $(FREETZ_PACKAGE_OPENSSH_STATIC),--disable-shared,--enable-shared)
42$(PKG)_CONFIGURE_OPTIONS += $(if $(FREETZ_PACKAGE_OPENSSH_STATIC),--enable-static,--disable-static)
43$(PKG)_CONFIGURE_OPTIONS += --disable-debug
44$(PKG)_CONFIGURE_OPTIONS += --disable-etc-default-login
45$(PKG)_CONFIGURE_OPTIONS += --disable-lastlog
46$(PKG)_CONFIGURE_OPTIONS += --disable-utmp
47$(PKG)_CONFIGURE_OPTIONS += --disable-utmpx
48$(PKG)_CONFIGURE_OPTIONS += --disable-wtmp
49$(PKG)_CONFIGURE_OPTIONS += --disable-wtmpx
50$(PKG)_CONFIGURE_OPTIONS += --without-bsd-auth
51$(PKG)_CONFIGURE_OPTIONS += --without-kerberos5
52$(PKG)_CONFIGURE_OPTIONS += --without-pie
53
54$(PKG)_EXTRA_CFLAGS  += -ffunction-sections -fdata-sections
55$(PKG)_EXTRA_LDFLAGS += -Wl,--gc-sections
56$(PKG)_EXTRA_LDFLAGS += $(if $(FREETZ_PACKAGE_OPENSSH_STATIC),-static)
57
58$(PKG_SOURCE_DOWNLOAD)
59$(PKG_UNPACKED)
60$(PKG_CONFIGURED_CONFIGURE)
61
62$($(PKG)_BIN_BINARIES_BUILD_DIR) $($(PKG)_SBIN_BINARIES_BUILD_DIR) $($(PKG)_LIB_BINARIES_BUILD_DIR): $($(PKG)_DIR)/.configured
63    $(SUBMAKE) -C $(OPENSSH_DIR) \
64        EXTRA_CFLAGS="$(OPENSSH_EXTRA_CFLAGS)" \
65        EXTRA_LDFLAGS="$(OPENSSH_EXTRA_LDFLAGS)" \
66        all
67
68$(foreach binary,$($(PKG)_BIN_BINARIES_BUILD_DIR),$(eval $(call INSTALL_BINARY_STRIP_RULE,$(binary),/usr/bin)))
69$(foreach binary,$($(PKG)_SBIN_BINARIES_BUILD_DIR),$(eval $(call INSTALL_BINARY_STRIP_RULE,$(binary),/usr/sbin)))
70$(foreach binary,$($(PKG)_LIB_BINARIES_BUILD_DIR),$(eval $(call INSTALL_BINARY_STRIP_RULE,$(binary),/usr/lib)))
71
72$(pkg):
73
74$(pkg)-precompiled: $($(PKG)_BIN_BINARIES_TARGET_DIR) $($(PKG)_SBIN_BINARIES_TARGET_DIR) $($(PKG)_LIB_BINARIES_TARGET_DIR)
75
76$(pkg)-clean:
77    -$(SUBMAKE) -C $(OPENSSH_DIR) clean
78
79$(pkg)-uninstall:
80    $(RM) $(OPENSSH_BIN_BINARIES_TARGET_DIR) $(OPENSSH_SBIN_BINARIES_TARGET_DIR) $(OPENSSH_LIB_BINARIES_TARGET_DIR)
81
82$(PKG_FINISH)
Hinweis: Hilfe zum Repository-Browser finden Sie in TracBrowser.