source: trunk/make/tinc/tinc.mk @ 14411

Letzte Änderung dieser Datei seit 14411 war 14411, erstellt von er13 vor 3 Monaten

package Makefiles:

  • use PKG_ADD_EXTRA_FLAGS macro introduced in r14374 as much as possible
Dateigröße: 2.3 KB
Zeile 
1$(call PKG_INIT_BIN, $(if $(FREETZ_PACKAGE_TINC_VERSION_1_1),1.1pre14,1.0.31))
2$(PKG)_SOURCE:=$(pkg)-$($(PKG)_VERSION).tar.gz
3$(PKG)_SOURCE_MD5_1.0.31  :=7a96f7eb12dfd43b21852b4207d860f2
4$(PKG)_SOURCE_MD5_1.1pre14:=401ad9b0610dc4da233d6edb1f463cb8
5$(PKG)_SOURCE_MD5:=$($(PKG)_SOURCE_MD5_$($(PKG)_VERSION))
6$(PKG)_SITE:=http://www.tinc-vpn.org/packages
7
8$(PKG)_CONDITIONAL_PATCHES+=$(if $(FREETZ_PACKAGE_TINC_VERSION_1_1),1.1,1.0)
9
10$(PKG)_PATCH_POST_CMDS += $(call PKG_ADD_EXTRA_FLAGS,(C|LD)FLAGS,src)
11
12$(PKG)_BINARY:=$($(PKG)_DIR)/src/tincd
13$(PKG)_TARGET_BINARY:=$($(PKG)_DEST_DIR)/usr/sbin/tincd
14
15$(PKG)_BINARY_CTL:=$($(PKG)_DIR)/src/tinc
16$(PKG)_TARGET_BINARY_CTL:=$($(PKG)_DEST_DIR)/usr/sbin/tinc
17
18$(PKG)_EXCLUDED += $(if $(FREETZ_PACKAGE_TINC_tinc),,$($(PKG)_TARGET_BINARY_CTL))
19
20$(PKG)_DEPENDS_ON += lzo openssl zlib
21$(PKG)_DEPENDS_ON += $(if $(FREETZ_PACKAGE_TINC_VERSION_1_1),ncurses readline)
22
23$(PKG)_REBUILD_SUBOPTS += FREETZ_PACKAGE_TINC_VERSION_1_0
24$(PKG)_REBUILD_SUBOPTS += FREETZ_PACKAGE_TINC_VERSION_1_1
25$(PKG)_REBUILD_SUBOPTS += FREETZ_PACKAGE_TINC_STATIC
26$(PKG)_REBUILD_SUBOPTS += FREETZ_OPENSSL_SHLIB_VERSION
27
28$(PKG)_HARDENING_OPTS := check_cflags___fPIE check_ldflags___pie
29#$(PKG)_HARDENING_OPTS += check_ldflags___Wl__z_relro check_ldflags___Wl__z_now
30$(PKG)_CONFIGURE_PRE_CMDS += $(call PKG_MAKE_AC_VARIABLES_PACKAGE_SPECIFIC,$($(PKG)_HARDENING_OPTS),,ax)
31$(PKG)_CONFIGURE_ENV += $(foreach opt,$($(PKG)_HARDENING_OPTS),$(pkg)_$(opt)=no)
32
33$(PKG)_EXTRA_CFLAGS  += -ffunction-sections -fdata-sections
34$(PKG)_EXTRA_LDFLAGS += -Wl,--gc-sections
35ifeq ($(strip $(FREETZ_PACKAGE_TINC_STATIC)),y)
36$(PKG)_EXTRA_LDFLAGS += -static
37endif
38
39$(PKG_SOURCE_DOWNLOAD)
40$(PKG_UNPACKED)
41$(PKG_CONFIGURED_CONFIGURE)
42
43$($(PKG)_BINARY) $($(PKG)_BINARY_CTL): $($(PKG)_DIR)/.configured
44    $(SUBMAKE) -C $(TINC_DIR) \
45        EXTRA_CFLAGS="$(TINC_EXTRA_CFLAGS)" \
46        EXTRA_LDFLAGS="$(TINC_EXTRA_LDFLAGS)"
47
48$($(PKG)_TARGET_BINARY): $($(PKG)_BINARY)
49    $(INSTALL_BINARY_STRIP)
50
51$($(PKG)_TARGET_BINARY_CTL): $($(PKG)_BINARY_CTL)
52    $(INSTALL_BINARY_STRIP)
53
54$(pkg)-precompiled: $($(PKG)_TARGET_BINARY) $(if $(FREETZ_PACKAGE_TINC_tinc),$($(PKG)_TARGET_BINARY_CTL))
55
56$(pkg)-clean:
57    -$(SUBMAKE) -C $(TINC_DIR) clean
58    $(RM) $(TINC_FREETZ_CONFIG_FILE)
59
60$(pkg)-uninstall:
61    $(RM) $(TINC_TARGET_BINARY) $(TINC_TARGET_BINARY_CTL)
62
63$(PKG_FINISH)
Hinweis: Hilfe zum Repository-Browser finden Sie in TracBrowser.