blob: a394e6835b3b9ee15a4af6a771b7f8fd5e90d5a9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
|
#############################################################
#
# lzo
#
# Note: this builds only a static library, it does not provide
# anything to be installed into the target system.
#
#############################################################
LZO_VERSION:=1.08
LZO_SOURCE:=lzo_$(LZO_VERSION).orig.tar.gz
LZO_SITE:=$(BR2_DEBIAN_MIRROR)/debian/pool/main/l/lzo
#LZO_SOURCE:=lzo-$(LZO_VERSION).tar.bz2
#LZO_SITE:=http://www.oberhumer.com/opensource/lzo/download
LZO_DIR:=$(BUILD_DIR)/lzo-$(LZO_VERSION)
LZO_CAT:=$(ZCAT)
$(DL_DIR)/$(LZO_SOURCE):
$(WGET) -P $(DL_DIR) $(LZO_SITE)/$(LZO_SOURCE)
lzo-source: $(DL_DIR)/$(LZO_SOURCE)
$(LZO_DIR)/.unpacked: $(DL_DIR)/$(LZO_SOURCE)
$(LZO_CAT) $(DL_DIR)/$(LZO_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
toolchain/patch-kernel.sh $(LZO_DIR) package/lzo/ lzo\*.patch
$(CONFIG_UPDATE) $(LZO_DIR)/acconfig
touch $@
LZO_CONFIG_SHARED:=--disable-shared
#LZO_CONFIG_SHARED:=--enable-shared
$(LZO_DIR)/.configured: $(LZO_DIR)/.unpacked
(cd $(LZO_DIR); rm -rf config.cache; \
$(TARGET_CONFIGURE_OPTS) \
$(TARGET_CONFIGURE_ARGS) \
./configure \
--target=$(GNU_TARGET_NAME) \
--host=$(GNU_TARGET_NAME) \
--build=$(GNU_HOST_NAME) \
--prefix=/usr \
--includedir=/usr/include \
--libdir=/usr/lib \
$(LZO_CONFIG_SHARED) \
)
touch $@
$(LZO_DIR)/src/liblzo.la: $(LZO_DIR)/.configured
$(MAKE) -C $(LZO_DIR)
$(STAGING_DIR)/usr/lib/liblzo.a: $(LZO_DIR)/src/liblzo.la
$(MAKE) CC="$(TARGET_CC)" DESTDIR=$(STAGING_DIR) -C $(LZO_DIR) install
$(SED) "s,^libdir=.*,libdir=\'$(STAGING_DIR)/usr/lib\',g" $(STAGING_DIR)/usr/lib/liblzo.la
touch -c $@
lzo: uclibc $(STAGING_DIR)/usr/lib/liblzo.a
lzo-clean:
-$(MAKE) DESTDIR=$(STAGING_DIR) -C $(LZO_DIR) uninstall
-$(MAKE) -C $(LZO_DIR) clean
lzo-dirclean:
rm -rf $(LZO_DIR)
#############################################################
#
# Toplevel Makefile options
#
#############################################################
ifeq ($(strip $(BR2_PACKAGE_LZO)),y)
TARGETS+=lzo
endif
|