# # spec file for package cfengine-documentation-generator # # Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # # 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: cfengine-documentation-generator Summary: CFEngine documentation system License: CC-BY-SA-3.0 and MIT Group: Documentation Version: 3.16.0+git20200623.c8d0489ca00e Release: 0 Url: https://github.com/cfengine/documentation-generator Source: %{name}-%{version}.tar.xz Source1: Gemfile Source2: cached-gems.tar.xz Source3: %{name}-rpmlintrc # don't auto-provide .so libraries from GEMs AutoReqProv: no # default generator: redcarpet Patch1: 0001-plugins-plugins_dir.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %if 0%{?suse_version} > 1010 BuildRequires: fdupes %endif BuildRequires: automake BuildRequires: findutils BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: libxslt-devel BuildRequires: ruby BuildRequires: ruby-devel BuildRequires: rubygem(bundler) BuildRequires: zlib-devel Requires: ruby %description CFEngine documentation system with Jekyll (static site generator) and WeasyPrint (pdf generation) %prep %setup -q %patch1 -p1 cp %{S:1} . # extract 'vendored' gems tar xf %{S:2} mv gems vendor # install / build gems export GEM_HOME=gems export GEM_PATH=gems bundle install --local %build %install %{__install} -d %{buildroot}/%{_libdir}/%{name} cp -a gems %{buildroot}/%{_libdir}/%{name} %{__install} -d %{buildroot}/%{_datadir}/%{name} rm -rf gems _site vendor cp -a . %{buildroot}/%{_datadir}/%{name} %if 0%{?suse_version} > 1010 %fdupes %{buildroot}/%{_libdir}/%{name} %endif %files %defattr(-,root,root) %doc LICENSE README.org %dir %{_libdir}/%{name} %{_libdir}/%{name} %dir %{_datadir}/%{name} %{_datadir}/%{name} %changelog