blob: 887c75df87fdd08639a66486afadd8abd9e056b0 [file] [log] [blame]
Patrick Williams213cb262021-08-07 19:21:33 -05001SUMMARY = "CrowdSec is a free, modern & collaborative behavior detection engine, coupled with a global IP reputation network."
2
3LICENSE = "MIT"
4LIC_FILES_CHKSUM = "file://src/import/LICENSE;md5=105e75b680b2ab82fa5718661b41f3bf"
5
6SRC_URI = "git://github.com/crowdsecurity/crowdsec.git;branch=master"
7SRCREV = "73e0bbaf93070f4a640eb5a22212b5dcf26699de"
8
9DEPENDS = "jq-native"
10
11GO_IMPORT = "import"
12
13inherit go
14
15S = "${WORKDIR}/git"
16
17do_compile() {
18 export GOARCH="${TARGET_GOARCH}"
19 export GOROOT="${STAGING_LIBDIR_NATIVE}/${TARGET_SYS}/go"
20
21 # Pass the needed cflags/ldflags so that cgo
22 # can find the needed headers files and libraries
23 export CGO_ENABLED="1"
24 export CFLAGS=""
25 export LDFLAGS=""
26 export CGO_CFLAGS="${BUILDSDK_CFLAGS} --sysroot=${STAGING_DIR_TARGET}"
27 export CGO_LDFLAGS="${BUILDSDK_LDFLAGS} --sysroot=${STAGING_DIR_TARGET}"
28
29 cd ${S}/src/import
30 oe_runmake release
31}
32
33do_install_ () {
34 chmod +x -R --silent ${B}/pkg
35}
36
37
38INSANE_SKIP:${PN} = "already-stripped"
39INSANE_SKIP:${PN}-dev = "ldflags"
40
41RDEPENDS:${PN} = "go"
42RDEPENDS:${PN}-dev = "bash"