Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 1 | SUMMARY = "CrowdSec is a free, modern & collaborative behavior detection engine, coupled with a global IP reputation network." |
| 2 | |
| 3 | LICENSE = "MIT" |
| 4 | LIC_FILES_CHKSUM = "file://src/import/LICENSE;md5=105e75b680b2ab82fa5718661b41f3bf" |
| 5 | |
Patrick Williams | 53961c2 | 2022-01-20 11:06:23 -0600 | [diff] [blame] | 6 | SRC_URI = "git://github.com/crowdsecurity/crowdsec.git;branch=master;protocol=https" |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 7 | SRCREV = "73e0bbaf93070f4a640eb5a22212b5dcf26699de" |
| 8 | |
| 9 | DEPENDS = "jq-native" |
| 10 | |
| 11 | GO_IMPORT = "import" |
| 12 | |
| 13 | inherit go |
| 14 | |
| 15 | S = "${WORKDIR}/git" |
| 16 | |
| 17 | do_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 | |
| 33 | do_install_ () { |
| 34 | chmod +x -R --silent ${B}/pkg |
| 35 | } |
| 36 | |
| 37 | |
| 38 | INSANE_SKIP:${PN} = "already-stripped" |
| 39 | INSANE_SKIP:${PN}-dev = "ldflags" |
| 40 | |
| 41 | RDEPENDS:${PN} = "go" |
| 42 | RDEPENDS:${PN}-dev = "bash" |