Blob Blame History Raw
From 042675755d1ec2446105af700cd9cfb1bace905c Mon Sep 17 00:00:00 2001
From: Masanori Misono <m.misono760@gmail.com>
Date: Wed, 27 May 2020 17:54:52 +0900
Subject: [PATCH] Fix KBUILD_MODNAME

Use "bpftrace" instead of '"bpftrace"'. Previously this causes build
error if included header files use KBUILD_MODNAME.
---
 src/utils.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/utils.cpp b/src/utils.cpp
index dc82689..cec77cf 100644
--- a/src/utils.cpp
+++ b/src/utils.cpp
@@ -363,7 +363,7 @@ std::vector<std::string> get_kernel_cflags(
   cflags.push_back("-D__HAVE_BUILTIN_BSWAP16__");
   cflags.push_back("-D__HAVE_BUILTIN_BSWAP32__");
   cflags.push_back("-D__HAVE_BUILTIN_BSWAP64__");
-  cflags.push_back("-DKBUILD_MODNAME='\"bpftrace\"'");
+  cflags.push_back("-DKBUILD_MODNAME=\"bpftrace\"");
 
   // If ARCH env variable is set, pass this along.
   if (archenv)
-- 
2.25.4