66911451ce50d57b7c86559e0dc9b0aeeac696b2
[vuplus_openembedded] / appweb / appweb_1.0.2.oe
1 DEPENDS = "virtual/libc"
2 RDEPENDS = "libc6"
3 DESCRIPTION = "AppWeb is an embedded HTTP Web server that has been designed with security in mind."
4 SRC_URI = "http://www.mbedthis.com/software/appWeb-${PV}.LINUX-i386.self.tar.gz"
5 SRC_URI_EXTRA = 'file://${WORKDIR}/appWeb-src-${PV}-12.tar.gz \
6                  file://${FILESDIR}/charsignedness.patch;patch=1 \
7                  file://${FILESDIR}/makerules.patch;patch=1'
8 S = "${WORKDIR}/appWeb-${PV}"
9
10 python do_unpack () {
11         oe.build.exec_func('base_do_unpack', d)
12         src_uri = oe.data.getVar('SRC_URI', d)
13         oe.data.setVar('SRC_URI', '${SRC_URI_EXTRA}', d)
14         oe.build.exec_func('base_do_unpack', d)
15         oe.data.setVar('SRC_URI', src_uri, d)
16         oe.build.exec_func('do_unpack_cleanup', d)
17 }
18
19 do_unpack_cleanup () {
20         (
21                 set -e
22                 cd ${WORKDIR}
23                 rm -f README.HTML install remove
24         )
25 }
26
27 python do_patch () {
28         oe.build.exec_func('base_do_patch', d)
29         src_uri = oe.data.getVar('SRC_URI', d)
30         oe.data.setVar('SRC_URI', '${SRC_URI_EXTRA}', d)
31         oe.build.exec_func('base_do_patch', d)
32         oe.data.setVar('SRC_URI', src_uri, d)
33 }
34 #       --enable-access-log
35 #       --enable-admin
36 #       --enable-all-static
37 #       --enable-assert
38 #       --enable-c-api
39 #       --enable-dll
40 #       --enable-fast-malloc
41 #       --enable-goahead-compat
42 #       --enable-if-modified
43 #       --enable-log
44 #       --enable-rom-fs
45 #       --enable-run-as-service
46 #       --enable-safe-strings
47 #       --enable-squeeze
48 #       --enable-ssl
49 #       --enable-session
50
51 APPWEB_TARGET = "${TARGET_ARCH}"
52 APPWEB_OS = "${TARGET_OS}"
53 APPWEB_OS_linux = "LINUX"
54 EXTRA_OECONF = "--os ${APPWEB_OS} --target ${APPWEB_TARGET} \
55                 --enable-keep-alive \
56                 --enable-multi-thread \
57                 --enable-cgi \
58                 --enable-cookie \
59                 --enable-config \
60                 --enable-digest-auth \
61                 --disable-ssl"
62 EXTRA_OEMAKE = "'CC=${CC}' 'AR=${AR}' 'CPP=${CXX}' 'LD=${CC}'"
63
64 LD_LIBRARY_PATH_prepend = "${S}/lib:"
65 LD_LIBRARY_PATH[export] = "1"
66 do_configure () {
67         ./configure ${EXTRA_OECONF}
68 }
69
70 do_compile () {
71         oe_runmake build
72         oe_runmake compile
73 }
74
75 do_stage () {
76         :
77 }
78
79 do_install () {
80         install -d ${D}/${sbindir} ${D}/${sysconfdir}/appWeb/lib \
81                    ${D}/${libexecdir}/appWeb ${D}/${libdir}
82         install -m 0755 appWeb/appWeb ${D}/${sbindir}/
83         install -m 0644 appWeb/appWeb.conf ${D}/${sysconfdir}/appWeb/
84         install -m 0755 bin/${APPWEB_OS}/* ${D}/${libexecdir}/appWeb/
85         install -m 0755 lib/lib*.so* ${D}/${sysconfdir}/appWeb/lib/
86 }