blob: 8a48a89fdf87bc1a5ad3ba0dbc3083b09b9ce340 (
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
|
DESCRIPTION = "Zlib Compression Library"
SECTION = "libs"
PRIORITY = "required"
MAINTAINER = "Chris Larson <kergoth@handhelds.org>"
HOMEPAGE = "http://www.gzip.org/zlib/"
LICENSE = "zlib"
SRC_URI = "http://www.zlib.net/zlib-1.2.3.tar.bz2 \
file://visibility.patch;patch=1 \
file://libtool_staging.patch;patch=1 \
file://sane-target.patch;patch=1 "
S = "${WORKDIR}/zlib-${PV}"
DEPENDS = "libtool-cross"
export LDSHARED = "${CC} -shared -Wl,-soname,libz.so.1"
LDFLAGS_append = " -L. -lz"
CFLAGS_prepend = "-fPIC -DZLIB_DLL "
AR_append = " rc"
EXTRA_OEMAKE = " LIBTOOL=${TARGET_SYS}-libtool"
# extra configure options, can be reset in the -native variant
ZLIB_EXTRA = "--target=${TARGET_OS}"
ZLIB_SHARED= "libz.so.${PV}"
do_compile() {
./configure --prefix=${prefix} --exec_prefix=${exec_prefix} --shared --libdir=${libdir} --includedir=${includedir} ${ZLIB_EXTRA}
oe_runmake -e MAKEFLAGS="" ${ZLIB_SHARED} libz.a
}
do_stage() {
install -m 0644 zlib.h ${STAGING_INCDIR}/zlib.h
install -m 0644 zconf.h ${STAGING_INCDIR}/zconf.h
mv libz.la ${STAGING_LIBDIR}/
oe_libinstall -a -so libz ${STAGING_LIBDIR}
}
do_install() {
install -d ${D}${prefix} ${D}${includedir} ${D}${libdir}
oe_runmake "prefix=${D}${prefix}" \
"exec_prefix=${D}${exec_prefix}" \
"man3dir=${D}${mandir}/man3" \
"includedir=${D}${includedir}" \
"libdir=${D}${libdir}" install
}
|