From 296d108701e346851f851b918cce1e24272f47b7 Mon Sep 17 00:00:00 2001 From: Jens Lody Date: Sun, 24 Sep 2017 13:06:23 +0200 Subject: [PATCH] Fix #1493473 (astyle --html does not find documentation). --- astyle-html-help.patch | 11 +++++++++++ astyle.spec | 8 +++++++- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 astyle-html-help.patch diff --git a/astyle-html-help.patch b/astyle-html-help.patch new file mode 100644 index 0000000..34f3640 --- /dev/null +++ b/astyle-html-help.patch @@ -0,0 +1,11 @@ +--- a/src/astyle_main.cpp 2017-09-24 11:46:50.008331032 +0200 ++++ b/src/astyle_main.cpp 2017-09-24 11:47:05.826623047 +0200 +@@ -1314,7 +1314,7 @@ + void ASConsole::launchDefaultBrowser(const char* filePathIn /*nullptr*/) const + { + struct stat statbuf; +- string htmlDefaultPath = "/usr/share/doc/astyle/html/"; ++ string htmlDefaultPath = "/usr/share/doc/astyle/"; + string htmlDefaultFile = "astyle.html"; + + // build file path diff --git a/astyle.spec b/astyle.spec index 2a53131..bfc01b4 100644 --- a/astyle.spec +++ b/astyle.spec @@ -1,6 +1,6 @@ Name: astyle Version: 3.0.1 -Release: 3%{?dist} +Release: 4%{?dist} Summary: Source code formatter for C-like programming languages %global majorversion 3 @@ -17,6 +17,8 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) # Make the astyle-lib usable for arduino Patch0: astyle-arduino.patch +# Fix (hardcoded) path to html-help +Patch1: astyle-html-help.patch %description Artistic Style is a source code indenter, source code formatter, and @@ -38,6 +40,7 @@ This package contains the shared library. %prep %setup -q -n %{name} %patch0 -p1 +%patch1 -p1 %build chmod a-x src/* @@ -76,6 +79,9 @@ popd %{_includedir}/astyle.h %changelog +* Sun Sep 24 2017 Jens Lody - 3.0.1-4 +- Fix #1493473 (astyle --html does not find documentation). + * Wed Aug 02 2017 Fedora Release Engineering - 3.0.1-3 - Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild