File cppmem.spec of Package cppmem

#
# spec file for package cppmem
#
# Copyright (c) 2025 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#


Name:           cppmem
Version:        1.0a
Release:        0
Summary:        Tool to explore the behaviour of programs in the C/C++11 memory model
License:        BSD-3-Clause AND LGPL-2.0-only AND (LGPL-2.0-only WITH OCaml-LGPL-linking-exception)
URL:            http://svr-pes20-cppmem.cl.cam.ac.uk/cppmem/
Source0:        http://svr-pes20-cppmem.cl.cam.ac.uk/cppmem/cppmem.tar.gz
# Patches are maintained at https://github.com/aaronpuchert/cppmem.
Patch1:         Add-missing-dependency-to-Num-for-OCaml-4.06.patch
Patch2:         Fix-syntax-error-by-adding-space.patch
Patch3:         Fix-usage-of-mutable-strings-for-OCaml-4.02.patch
BuildRequires:  ocaml
BuildRequires:  ocaml-findlib
BuildRequires:  ocaml-ocamlbuild
BuildRequires:  ocamlfind(num)

%description
CppMem is a tool to let one explore the behaviour of small concurrent test
programs in the relaxed memory model of the recent C11 and C++11 revisions of
C and C++, as formalised by Batty et al. [POPL 2011], which explains the model.

%prep
%autosetup -n %{name} -p1

%build
make %{?_smp_mflags} cppmem

%install
install -D bin/main.opt %{buildroot}%{_bindir}/cppmem

%files
%license LICENCE.txt
%{_bindir}/cppmem

%changelog
openSUSE Build Service is sponsored by