commit 5a550eafbe67f6ba1084121fb0875c8f01c4efa6 Author: Neil Hanlon Date: Wed Mar 13 00:04:43 2024 -0400 initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..f2aefab --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +/wyrd-2037af4.tar.gz diff --git a/0001-add-camlp-streams-to-dune-config.patch b/0001-add-camlp-streams-to-dune-config.patch new file mode 100644 index 0000000..de81e23 --- /dev/null +++ b/0001-add-camlp-streams-to-dune-config.patch @@ -0,0 +1,25 @@ +From 9f78603d18376e83205c28a597a369fdfcfea0d9 Mon Sep 17 00:00:00 2001 +From: Neil Hanlon +Date: Tue, 12 Mar 2024 23:25:12 -0400 +Subject: [PATCH] add camlp-streams to dune config + +--- + dune | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/dune b/dune +index 73ff625..92f34e1 100644 +--- a/dune ++++ b/dune +@@ -5,7 +5,7 @@ + (modules (:standard \ locale)) + (flags (:standard -w -3-32)) + (ocamlopt_flags (:include ocamlopt_flags.sexp)) +- (libraries unix str curses locale yojson)) ++ (libraries unix str curses locale yojson camlp-streams)) + + (library + (name locale) +-- +2.44.0 + diff --git a/sources b/sources new file mode 100644 index 0000000..ddd0095 --- /dev/null +++ b/sources @@ -0,0 +1 @@ +SHA512 (wyrd-2037af4.tar.gz) = 3a6f144778bd51454184bda8c4c55fc75280f72693d769ef0d61943bf240263f344adce3f73e4ecbd815cc49062832b7c7f4406ac7573401bcc98138010daac6 diff --git a/wyrd.spec b/wyrd.spec new file mode 100644 index 0000000..3a725df --- /dev/null +++ b/wyrd.spec @@ -0,0 +1,100 @@ +%ifnarch %{ocaml_native_compiler} +%global debug_package %{nil} +%endif + +%if 0%{?fedora} +%bcond doc 1 +%endif + +%global commit 2037af4ed09a0c2cc80168659542ecba9828a40a +%global shortcommit %(c=%{commit}; echo ${c:0:7}) + +Name: wyrd +Version: 1.7.1 +Release: 1 +Summary: A text-based frontend to Remind + +License: GPL-2.0-or-later +URL: https://gitlab.com/wyrd-calendar/wyrd +Source: https://gitlab.com/wyrd-calendar/wyrd/-/archive/%{commit}/%{name}-%{shortcommit}.tar.gz + +Patch: 0001-add-camlp-streams-to-dune-config.patch + +BuildRequires: ocaml +BuildRequires: ocaml-camlp-streams-devel +BuildRequires: ocaml-curses-devel +BuildRequires: ocaml-dune +BuildRequires: ocaml-odoc +BuildRequires: ocaml-yojson-devel +BuildRequires: remind + +Requires: remind + +%global _description %{expand: +Wyrd is a text-based front-end to Remind, a sophisticated calendaring +and alarm program. Wyrd requires only a fraction of the resources of +most calendar programs available today.} + +%description %{_description} +Wyrd does not hide Remind's textfile programmability, for this is what +makes Remind a truly powerful calendaring system. + + +%package devel +Summary: Development files for %{name} +Requires: %{name}%{?_isa} = %{version}-%{release} + + +%description devel +The %{name}-devel package contains libraries and signature files for +developing applications that use %{name}. + + +%package doc +Summary: Documentation files for %{name} + + +%description doc +The %{name}-doc package contains documentation for using %{name}. + + +%prep +%autosetup -n wyrd-%{commit} + + +%build +%dune_build + +%if %{with doc} +pushd doc || exit 1 +make all +popd || exit 1 +%endif + +%install +%dune_install + +%if %{with doc} +pushd doc || exit 1 +PREFIX=%{buildroot}%{_prefix} make install +popd || exit 1 +%endif + +install -p -D -m 0644 wyrdrc %{buildroot}%{_sysconfdir}/wyrdrc + +%check +%dune_check + + +%files -f .ofiles +%license COPYING +%config(noreplace) %{_sysconfdir}/wyrdrc + +%files devel -f .ofiles-devel + +%files doc +%{_mandir}/man*/wyrd* + +%changelog +* Tue Mar 12 2024 Neil Hanlon - 1.7.1-1 +- Initial package