add setpwc package
[openwrt.git] / obsolete-buildroot / make / matrixssl.mk
1 ## matrixssl
2
3 MATRIXSSL_VERSION := 1.2.1
4 MATRIXSSL_RELEASE := 1
5
6 MATRIXSSL_SOURCE := matrixssl-1-2-1.tar.gz
7 #MATRIXSSL_SITE := http://www.matrixssl.org/
8 MATRIXSSL_SITE := http://nthill.free.fr/openwrt/sources/
9 MATRIXSSL_DIR := $(BUILD_DIR)/matrixssl
10 MATRIXSSL_CAT := zcat
11
12 MATRIXSSL_PATCH_DIR := $(SOURCE_DIR)/openwrt/patches/matrixssl
13
14 MATRIXSSL_BUILD_DIR := $(BUILD_DIR)/libmatrixssl_$(MATRIXSSL_VERSION)-$(MATRIXSSL_RELEASE)
15 MATRIXSSL_IPK_DIR := $(OPENWRT_IPK_DIR)/libmatrixssl
16 MATRIXSSL_IPK := $(MATRIXSSL_BUILD_DIR)_$(ARCH).ipk
17
18
19 $(DL_DIR)/$(MATRIXSSL_SOURCE):
20 $(WGET) -P $(DL_DIR) $(MATRIXSSL_SITE)/$(MATRIXSSL_SOURCE)
21
22
23 $(MATRIXSSL_DIR)/.stamp-unpacked: $(DL_DIR)/$(MATRIXSSL_SOURCE)
24 $(MATRIXSSL_CAT) $(DL_DIR)/$(MATRIXSSL_SOURCE) | tar -C $(BUILD_DIR) -xvf -
25
26 touch $(MATRIXSSL_DIR)/.stamp-unpacked
27
28
29 $(MATRIXSSL_DIR)/.stamp-patched: $(MATRIXSSL_DIR)/.stamp-unpacked
30 $(SOURCE_DIR)/patch-kernel.sh $(MATRIXSSL_DIR) $(MATRIXSSL_PATCH_DIR)
31
32 touch $(MATRIXSSL_DIR)/.stamp-patched
33
34
35 $(MATRIXSSL_DIR)/.stamp-built: $(MATRIXSSL_DIR)/.stamp-patched
36 cd $(MATRIXSSL_DIR) ; \
37 $(MAKE) -C src \
38 CC=$(TARGET_CC) \
39 DFLAGS="$(TARGET_CFLAGS)" \
40 STRIP=/bin/true \
41 all
42
43 touch $(MATRIXSSL_DIR)/.stamp-built
44
45
46 $(MATRIXSSL_BUILD_DIR): $(MATRIXSSL_DIR)/.stamp-built
47 mkdir -p $(MATRIXSSL_BUILD_DIR)
48
49 install -m0755 -d $(STAGING_DIR)/include/matrixSsl
50 install -m0644 $(MATRIXSSL_DIR)/matrixSsl.h $(STAGING_DIR)/include/matrixSsl/
51 ln -fs matrixSsl/matrixSsl.h $(STAGING_DIR)/include/
52 install -m0755 $(MATRIXSSL_DIR)/src/libmatrixssl.so $(STAGING_DIR)/lib/libmatrixssl.so.$(MATRIXSSL_VERSION)
53 ln -fs libmatrixssl.so.$(MATRIXSSL_VERSION) $(STAGING_DIR)/lib/libmatrixssl.so.1.2
54 ln -fs libmatrixssl.so.1.2 $(STAGING_DIR)/lib/libmatrixssl.so
55
56 mkdir -p $(MATRIXSSL_BUILD_DIR)/usr/lib
57 cp -a $(STAGING_DIR)/lib/libmatrixssl.so.* $(MATRIXSSL_BUILD_DIR)/usr/lib/
58
59 $(STRIP) $(MATRIXSSL_BUILD_DIR)/usr/lib/libmatrixssl.so.*
60
61
62 $(MATRIXSSL_IPK): $(MATRIXSSL_BUILD_DIR)
63 cp -a $(MATRIXSSL_IPK_DIR)/CONTROL $(MATRIXSSL_BUILD_DIR)/
64 perl -pi -e "s/^Vers.*:.*$$/Version: $(MATRIXSSL_VERSION)-$(MATRIXSSL_RELEASE)/" $(MATRIXSSL_BUILD_DIR)/CONTROL/control
65 perl -pi -e "s/^Arch.*:.*$$/Architecture: $(ARCH)/" $(MATRIXSSL_BUILD_DIR)/CONTROL/control
66 cd $(BUILD_DIR); $(IPKG_BUILD) $(MATRIXSSL_BUILD_DIR)
67
68
69 matrixssl-ipk: ipkg-utils libpthread-ipk $(MATRIXSSL_IPK)
70
71 matrixssl-clean:
72 $(MAKE) -C $(MATRIXSSL_DIR) clean
73
74 matrixssl-clean-all:
75 rm -rf $(MATRIXSSL_DIR)
76 rm -rf $(MATRIXSSL_BUILD_DIR)
77 rm -rf $(MATRIXSSL_IPK)
78 rm -rf $(STAGING_DIR)/include/pcap*.h
79 rm -rf $(STAGING_DIR)/lib/libpcap.a
80 rm -rf $(STAGING_DIR)/lib/libpcap.so*
This page took 0.055586 seconds and 5 git commands to generate.