From 14c1eea77cdd78637d6d42f1eaaf16d14faa6ca4 Mon Sep 17 00:00:00 2001 From: Ernestas Kulik Date: Feb 07 2020 09:05:34 +0000 Subject: Set CMake project language to C --- diff --git a/0001-CMakeLists.txt-Complete-project-call.patch b/0001-CMakeLists.txt-Complete-project-call.patch new file mode 100644 index 0000000..c81ed1a --- /dev/null +++ b/0001-CMakeLists.txt-Complete-project-call.patch @@ -0,0 +1,38 @@ +From 18454b71170605b1a55ae13eca73fb8170b036a2 Mon Sep 17 00:00:00 2001 +From: Ernestas Kulik +Date: Fri, 7 Feb 2020 10:00:49 +0100 +Subject: [PATCH] CMakeLists.txt: Complete project() call +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +This means setting the version there (requiring CMP0048 to be set to +NEW) and setting LANGUAGES to C, since we don’t need a C++ compiler. +--- + CMakeLists.txt | 10 ++++++---- + 1 file changed, 6 insertions(+), 4 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index b1a6bf0..679cae9 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1,10 +1,12 @@ + cmake_minimum_required(VERSION 2.8) +- +-project(abrt-java-connector) +-enable_testing() ++cmake_policy(SET CMP0048 NEW) + + # Beware, PROJECT_VERSION will be overridden by information from git +-set(PROJECT_VERSION "1.1.3") ++project( ++ abrt-java-connector ++ VERSION 1.1.3 ++ LANGUAGES C) ++enable_testing() + + message("Configuring ${PROJECT_NAME}-${PROJECT_VERSION} on ${CMAKE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}") + +-- +2.24.1 + diff --git a/abrt-java-connector.spec b/abrt-java-connector.spec index 96d7efe..2678ec2 100644 --- a/abrt-java-connector.spec +++ b/abrt-java-connector.spec @@ -16,6 +16,7 @@ BuildRequires: check-devel BuildRequires: cmake BuildRequires: gcc BuildRequires: gettext +BuildRequires: git-core BuildRequires: java-devel BuildRequires: libreport-devel BuildRequires: rpm-devel @@ -24,6 +25,8 @@ BuildRequires: systemd-devel Requires: abrt +Patch0001: 0001-CMakeLists.txt-Complete-project-call.patch + %description JNI library providing an agent capable to process both caught and uncaught exceptions and transform them to ABRT problems. @@ -41,7 +44,7 @@ This package contains only minimal set of files needed for container exception logging. %prep -%setup -qn %{name}-%{commit} +%autosetup -n %{name}-%{commit} %build @@ -94,6 +97,7 @@ make test || { %changelog * Fri Feb 07 2020 Ernestas Kulik - 1.1.3-1 - Fix stack traces not being logged in journald +- Set project language to C to avoid looking for a C++ compiler * Fri Feb 07 2020 Igor Raits - 1.1.2-4 - Rebuild for satyr 0.30