[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH 2/2] Add scripts/oss-fuzz/build.sh


  • To: xen-devel@xxxxxxxxxxxxxxxxxxxx
  • From: Tamas K Lengyel <tamas@xxxxxxxxxxxxx>
  • Date: Fri, 21 Jun 2024 15:14:34 -0400
  • Arc-authentication-results: i=1; mx.zohomail.com; dkim=pass header.i=tklengyel.com; spf=pass smtp.mailfrom=tamas@xxxxxxxxxxxxx; dmarc=pass header.from=<tamas@xxxxxxxxxxxxx>
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1718997297; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:MIME-Version:Message-ID:References:Subject:Subject:To:To:Message-Id:Reply-To; bh=az0Awjr8iknR6afX3DlNO8NfaAjpi0YMFq021oOMFmo=; b=IWRfIBJ4pshWHRZQW2gx5RyYOpZTeWdoxmXya1Kl6AQHFC+TrtZDjynbbD+ACXc2lMBzPKEBBuTeJuIkm4sPpz7CUvN+D+2Z7HSDuofK+9CnDh0+fdVDDds9hzkUFrj9fCRFeZoPCp8MTc7A2RHW6b2lUI8YsNzFIpRxPuuH4aQ=
  • Arc-seal: i=1; a=rsa-sha256; t=1718997297; cv=none; d=zohomail.com; s=zohoarc; b=lmBCt5pBbNYjFmZyPlSRLuMAFEqEphvoDur25CfuXdCjCoFPezjyY+Yh2w+fxHeixaMJ/u1lDuCAg3uBCcdKt6F68EmPCuf70uRXzcaFB+hUey8KvER50Hql2p4bFqANN0TZuBMUu14v3DPla0UFCMkrqOfAPVsJGUMz+8Z6RWI=
  • Cc: Tamas K Lengyel <tamas@xxxxxxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>
  • Delivered-to: tamas@xxxxxxxxxxxxx
  • Delivery-date: Fri, 21 Jun 2024 19:15:19 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

The build integration script for oss-fuzz targets.

Signed-off-by: Tamas K Lengyel <tamas@xxxxxxxxxxxxx>
---
 scripts/oss-fuzz/build.sh | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100755 scripts/oss-fuzz/build.sh

diff --git a/scripts/oss-fuzz/build.sh b/scripts/oss-fuzz/build.sh
new file mode 100755
index 0000000000..48528bbfc2
--- /dev/null
+++ b/scripts/oss-fuzz/build.sh
@@ -0,0 +1,22 @@
+#!/bin/bash -eu
+# Copyright 2024 Google LLC
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#      http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+#
+################################################################################
+
+cd xen
+./configure clang=y --disable-stubdom --disable-pvshim --disable-docs 
--disable-xen
+make clang=y -C tools/include
+make clang=y -C tools/fuzz/x86_instruction_emulator libfuzzer-harness
+cp tools/fuzz/x86_instruction_emulator/libfuzzer-harness 
$OUT/x86_instruction_emulator
-- 
2.34.1




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.