39 lines
1.2 KiB
Diff
39 lines
1.2 KiB
Diff
From 4f467c68ee190d2f8094b0342f6c76be15071046 Mon Sep 17 00:00:00 2001
|
|
From: misaka00251 <liuxin@iscas.ac.cn>
|
|
Date: Fri, 15 Sep 2023 20:46:15 +0800
|
|
Subject: [PATCH] Fix build on riscv64
|
|
|
|
---
|
|
Makefile | 2 +-
|
|
cmd/plugin/selinux/selinux.go | 3 +++
|
|
2 files changed, 4 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/Makefile b/Makefile
|
|
index 858346a..6e88e24 100644
|
|
--- a/Makefile
|
|
+++ b/Makefile
|
|
@@ -35,7 +35,7 @@ all: pav pavd
|
|
selinux:
|
|
CGO_CFLAGS_ALLOW="-ftrapv -D_FORTIFY_SOURCE=2 -O2" CGO_CFLAGS="-fstack-protector-strong -ftrapv -D_FORTIFY_SOURCE=2 -O2" \
|
|
CGO_LDFALGS_ALLOW="-Wl,-z,-s,relro,now,noexecstack" CGO_LDFALGS="-Wl,-z,-s,relro,now,noexecstack" \
|
|
- go build -buildmode=plugin $(BUILDFLAGS) -ldflags '$(LDFLAGS)' -o $(BUILD_DIR)/selinux.so cmd/plugin/selinux/*.go
|
|
+ go build $(BUILDFLAGS) -ldflags '$(LDFLAGS)' -o $(BUILD_DIR)/selinux.so cmd/plugin/selinux/*.go
|
|
strip $(BUILD_DIR)/selinux.so
|
|
|
|
pav:
|
|
diff --git a/cmd/plugin/selinux/selinux.go b/cmd/plugin/selinux/selinux.go
|
|
index 819963b..94ca4ec 100644
|
|
--- a/cmd/plugin/selinux/selinux.go
|
|
+++ b/cmd/plugin/selinux/selinux.go
|
|
@@ -32,3 +32,6 @@ func GetEngine() engine.Engine {
|
|
|
|
return e
|
|
}
|
|
+
|
|
+func main() {
|
|
+}
|
|
\ No newline at end of file
|
|
--
|
|
2.39.2 (Apple Git-143)
|
|
|