Andrew Geissler | 615f2f1 | 2022-07-15 14:00:58 -0500 | [diff] [blame] | 1 | # |
| 2 | # Copyright 2022 Armin Kuster <akuster808@gmail.com> |
| 3 | # |
| 4 | SUMMARY = "Linux namespaces and seccomp-bpf sandbox" |
| 5 | DESCRIPTION = "Firejail is a SUID sandbox program that reduces the risk of security breaches \ |
| 6 | by restricting the running environment of untrusted applications using Linux namespaces, \ |
| 7 | seccomp-bpf and Linux capabilities." |
| 8 | |
| 9 | LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263" |
| 10 | LICENSE = "GPL-2.0-only" |
| 11 | |
Andrew Geissler | 2daf84b | 2023-03-31 09:57:23 -0500 | [diff] [blame] | 12 | SRCREV = "2551bc71f14052344666f3ca2ad67f5b798020b9" |
Andrew Geissler | 615f2f1 | 2022-07-15 14:00:58 -0500 | [diff] [blame] | 13 | SRC_URI = "git://github.com/netblue30/firejail.git;protocol=https;branch=master \ |
| 14 | file://exclude_seccomp_util_compiles.patch \ |
| 15 | " |
| 16 | |
| 17 | DEPENDS = "libseccomp" |
| 18 | |
| 19 | S = "${WORKDIR}/git" |
| 20 | |
| 21 | inherit autotools-brokensep pkgconfig bash-completion features_check |
| 22 | |
| 23 | REQUIRED_DISTRO_FEATURES = "seccomp" |
| 24 | |
| 25 | PACKAGECONFIG ?= "" |
| 26 | PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'apparmor', 'apparmor', '', d)}" |
| 27 | PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'selinux', '', d)}" |
| 28 | PACKAGECONFIG += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', d)}" |
| 29 | |
| 30 | PACKAGECONFIG[apparmor] = "--enable-apparmor, --disable-apparmor, apparmor, apparmor" |
| 31 | PACKAGECONFIG[selinux] = "--enable-selinux, --disable-selinux, libselinux" |
| 32 | PACKAGECONFIG[x11] = " --enable-x11, --disable-x11, " |
| 33 | PACKAGECONFIG[dbusproxy] = ", --disable-dbusproxy, " |
| 34 | PACKAGECONFIG[notmpfs] = ", --disable-usertmpfs ," |
| 35 | PACKAGECONFIG[nofiretunnel] = ", --disable-firetunnel , " |
| 36 | PACKAGECONFIG[noprivatehome] = ", --disable-private-home, " |
| 37 | PACKAGECONFIG[nochroot] = ", --disable-chroot, " |
| 38 | PACKAGECONFIG[nonetwork] = ", --disable-network, " |
| 39 | PACKAGECONFIG[nouserns] = ", --disable-userns, " |
| 40 | PACKAGECONFIG[nofiletransfer] = ", --disable-file-transfer, " |
| 41 | PACKAGECONFIG[nosuid] = ", --disable-suid, " |
| 42 | |
| 43 | EXTRA_OECONF = "--disable-man --enable-busybox-workaround" |
| 44 | |
| 45 | PACKAGES:append = " ${PN}-vim ${PN}-zsh" |
| 46 | |
| 47 | FILES:${PN}-vim = "${datadir}/vim/" |
| 48 | FILES:${PN}-zsh = "${datadir}/zsh/" |
Andrew Geissler | 2daf84b | 2023-03-31 09:57:23 -0500 | [diff] [blame] | 49 | FILES:${PN}-dev = "${datadir}/gtksourceview-5/" |
Andrew Geissler | 615f2f1 | 2022-07-15 14:00:58 -0500 | [diff] [blame] | 50 | |
| 51 | pkg_postinst_ontarget:${PN} () { |
| 52 | ${libdir}/${BPN}/fseccomp default ${libdir}/${BPN}/seccomp |
| 53 | ${libdir}/${BPN}/fsec-optimize ${libdir}/${BPN}/seccomp |
| 54 | ${libdir}/${BPN}/fseccomp default ${libdir}/${BPN}/seccomp.debug allow-debuggers |
| 55 | ${libdir}/${BPN}/fsec-optimize ${libdir}/${BPN}/seccomp.debug |
| 56 | ${libdir}/${BPN}/fseccomp secondary 32 ${libdir}/${BPN}/seccomp.32 |
| 57 | ${libdir}/${BPN}/fsec-optimize ${libdir}/${BPN}/seccomp.32 |
| 58 | ${libdir}/${BPN}/fseccomp secondary block ${libdir}/${BPN}/seccomp.block_secondary |
| 59 | ${libdir}/${BPN}/fseccomp memory-deny-write-execute ${libdir}/${BPN}/seccomp.mdwx |
| 60 | } |
| 61 | |
Patrick Williams | 2a25492 | 2023-08-11 09:48:11 -0500 | [diff] [blame] | 62 | COMPATIBLE_MACHINE:x86_64 = "x86_64" |
| 63 | COMPATIBLE_MACHINE:arm64 = "arch64" |
Andrew Geissler | 615f2f1 | 2022-07-15 14:00:58 -0500 | [diff] [blame] | 64 | |
| 65 | RDEPENDS:${PN} = "bash" |