File mingw64-cJSON.spec of Package mingw64-cJSON
#
# spec file for package mingw64-cJSON
#
# Copyright (c) 2023-2024, Martin Hauke <mardnh@gmx.de>
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
Name: mingw64-cJSON
Version: 1.7.17
Release: 0
Summary: JSON parser library written in ANSI C
License: MIT
Group: System/Libraries
URL: https://github.com/DaveGamble/cJSON
Source: https://github.com/DaveGamble/cJSON/archive/v%{version}.tar.gz#/cJSON-%{version}.tar.gz
Patch0: cJSON-fix-cmake-include-path.patch
Patch1: x.patch
BuildRequires: mingw64-cross-cmake
BuildRequires: mingw64-cross-gcc
BuildRequires: mingw64-filesystem
#!BuildIgnore: post-build-checks
%_mingw64_package_header_debug
BuildArch: noarch
%description
A simple JSON parser library written in ANSI C.
%package -n mingw64-cJSON-devel
Summary: MinGW development files for the cJSON library
Group: Development/Libraries/C and C++
Requires: mingw64-cJSON = %{version}
%description -n mingw64-cJSON-devel
A simple JSON parser library written in ANSI C.
This package contains development tools and libraries for use when
cross-compiling Windows software.
%_mingw64_debug_package
%prep
%setup -q -n cJSON-%{version}
%patch -P 0 -p1
%patch -P 1 -p1
%build
%{_mingw64_cmake} -DENABLE_CJSON_TEST=OFF
%{_mingw64_make} %{?_smp_mflags}
%install
%{_mingw64_cmake_install}
%files -n mingw64-cJSON
%license LICENSE
%doc CHANGELOG.md CONTRIBUTORS.md README.md
%{_mingw64_bindir}/libcjson.dll
%files -n mingw64-cJSON-devel
%{_mingw64_includedir}/cjson
%{_mingw64_libdir}/libcjson.dll.a
%{_mingw64_libdir}/cmake/cJSON
%{_mingw64_libdir}/pkgconfig/libcjson.pc
%changelog