Andrew Geissler | 8fc454f | 2020-12-11 16:27:59 -0600 | [diff] [blame] | 1 | SUMMARY = "Canonical libwebsockets.org websocket library" |
| 2 | HOMEPAGE = "https://libwebsockets.org/" |
Andrew Geissler | 6972109 | 2021-07-23 12:57:00 -0400 | [diff] [blame] | 3 | LICENSE = "MIT & Zlib & BSD-3-Clause & Apache-2.0" |
Patrick Williams | db4c27e | 2022-08-05 08:10:29 -0500 | [diff] [blame] | 4 | LIC_FILES_CHKSUM = "file://LICENSE;md5=382bfdf329e774859fd401eaf850d29b" |
Andrew Geissler | 8fc454f | 2020-12-11 16:27:59 -0600 | [diff] [blame] | 5 | |
| 6 | DEPENDS = "zlib" |
| 7 | |
| 8 | S = "${WORKDIR}/git" |
Patrick Williams | db4c27e | 2022-08-05 08:10:29 -0500 | [diff] [blame] | 9 | SRCREV = "b0a749c8e7a8294b68581ce4feac0e55045eb00b" |
| 10 | SRC_URI = "git://github.com/warmcat/libwebsockets.git;protocol=https;branch=v4.3-stable" |
Andrew Geissler | 8fc454f | 2020-12-11 16:27:59 -0600 | [diff] [blame] | 11 | |
| 12 | UPSTREAM_CHECK_URI = "https://github.com/warmcat/${BPN}/releases" |
| 13 | UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)" |
| 14 | |
| 15 | inherit cmake pkgconfig |
| 16 | |
| 17 | PACKAGECONFIG ?= "libuv client server http2 ssl" |
| 18 | PACKAGECONFIG[client] = "-DLWS_WITHOUT_CLIENT=OFF,-DLWS_WITHOUT_CLIENT=ON," |
| 19 | PACKAGECONFIG[http2] = "-DLWS_WITH_HTTP2=ON,-DLWS_WITH_HTTP2=OFF," |
| 20 | PACKAGECONFIG[ipv6] = "-DLWS_IPV6=ON,-DLWS_IPV6=OFF," |
| 21 | PACKAGECONFIG[libevent] = "-DLWS_WITH_LIBEVENT=ON,-DLWS_WITH_LIBEVENT=OFF,libevent" |
| 22 | PACKAGECONFIG[libev] = "-DLWS_WITH_LIBEV=ON,-DLWS_WITH_LIBEV=OFF,libev" |
| 23 | PACKAGECONFIG[libuv] = "-DLWS_WITH_LIBUV=ON,-DLWS_WITH_LIBUV=OFF,libuv" |
| 24 | PACKAGECONFIG[server] = "-DLWS_WITHOUT_SERVER=OFF,-DLWS_WITHOUT_SERVER=ON," |
| 25 | PACKAGECONFIG[ssl] = "-DLWS_WITH_SSL=ON,-DLWS_WITH_SSL=OFF,openssl" |
| 26 | PACKAGECONFIG[static] = "-DLWS_WITH_STATIC=ON,-DLWS_WITH_STATIC=OFF -DLWS_LINK_TESTAPPS_DYNAMIC=ON," |
| 27 | |
| 28 | EXTRA_OECMAKE += " \ |
| 29 | -DLIB_SUFFIX=${@d.getVar('baselib').replace('lib', '')} \ |
| 30 | " |
| 31 | |
| 32 | PACKAGES =+ "${PN}-testapps ${PN}-evlib-event ${PN}-evlib-uv ${PN}-evlib-ev" |
| 33 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 34 | FILES:${PN}-testapps += "${datadir}/libwebsockets-test-server/* ${bindir}/libwebsockets-test-*" |
| 35 | FILES:${PN}-evlib-event += "${libdir}/libwebsockets-evlib_event.so" |
| 36 | FILES:${PN}-evlib-uv += "${libdir}/libwebsockets-evlib_uv.so" |
| 37 | FILES:${PN}-evlib-ev += "${libdir}/libwebsockets-evlib_ev.so" |
Andrew Geissler | 8fc454f | 2020-12-11 16:27:59 -0600 | [diff] [blame] | 38 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 39 | RDEPENDS:${PN} += " ${@bb.utils.contains('PACKAGECONFIG', 'libevent', '${PN}-evlib-event', '', d)}" |
| 40 | RDEPENDS:${PN} += " ${@bb.utils.contains('PACKAGECONFIG', 'libuv', '${PN}-evlib-uv', '', d)}" |
| 41 | RDEPENDS:${PN} += " ${@bb.utils.contains('PACKAGECONFIG', 'libev', '${PN}-evlib-ev', '', d)}" |
Andrew Geissler | 8fc454f | 2020-12-11 16:27:59 -0600 | [diff] [blame] | 42 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 43 | RDEPENDS:${PN}-dev += " ${@bb.utils.contains('PACKAGECONFIG', 'static', '${PN}-staticdev', '', d)}" |
Andrew Geissler | d583833 | 2022-05-27 11:33:10 -0500 | [diff] [blame] | 44 | |
| 45 | # Avoid absolute paths to end up in the sysroot. |
| 46 | SSTATE_SCAN_FILES += "*.cmake" |