Closed elzii closed 7 years ago
Update:
Compiling manually with
make install PREFIX=/usr/local
succeeded. I have no experience with asciidoc
or a2x
but the process took a long time when running them. Ex:
a2x --no-xmllint -f manpage ../doc/manpages/commands.asciidoc
sed -i -r -e "s,^\.TH .+,.TH KAKOUNE 1 \"\" \"\" \"commands\"," \
-e "/^\.SH \"NAME\"/{N;d;}" ../doc/manpages/commands.1
gzip -f ../doc/manpages/commands.1
mv -f ../doc/manpages/commands.1.gz ../doc/manpages/commands.gz
a2x --no-xmllint -f manpage ../doc/manpages/execeval.asciidoc
sed -i -r -e "s,^\.TH .+,.TH KAKOUNE 1 \"\" \"\" \"execeval\"," \
-e "/^\.SH \"NAME\"/{N;d;}" ../doc/manpages/execeval.1
gzip -f ../doc/manpages/execeval.1
Unsure how that might relate to a2x
failing via brew install
Could you try installing Kakoune using contrib/kakoune.rb
, with the following patch applied:
diff --git a/contrib/kakoune.rb b/contrib/kakoune.rb
index 018774d..260b74f 100644
--- a/contrib/kakoune.rb
+++ b/contrib/kakoune.rb
@@ -6,6 +6,7 @@ class Kakoune < Formula
depends_on 'boost'
depends_on 'asciidoc' => :build
+ depends_on 'docbook-xsl' => :build
def install
cd 'src' do
Also the xml catalog path is not set by default, you have to export XML_CATALOG_FILES=/usr/local/etc/xml/catalog
to build the doc without problem.
% brew info asciidoc
asciidoc: stable 8.6.9 (bottled), HEAD
Formatter/translator for text files to numerous formats. Includes a2x.
http://asciidoc.org/
/usr/local/Cellar/asciidoc/8.6.9_1 (217 files, 2.6M) *
Built from source on 2016-09-26 at 13:24:19 with: --with-docbook-xsl
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/asciidoc.rb
==> Dependencies
Required: docbook ✔
Optional: docbook-xsl ✔
==> Options
--with-docbook-xsl
Install DTDs to generate manpages
--HEAD
Install HEAD version
==> Caveats
If you intend to process AsciiDoc files through an XML stage
(such as a2x for manpage generation) you need to add something
like:
export XML_CATALOG_FILES=/usr/local/etc/xml/catalog
to your shell rc file so that xmllint can find AsciiDoc's
catalog files.
See `man 1 xmllint' for more.
@casimir would something like the following work?
diff --git a/contrib/kakoune.rb b/contrib/kakoune.rb
index 018774d..260b74f 100644
--- a/contrib/kakoune.rb
+++ b/contrib/kakoune.rb
@@ -6,6 +6,7 @@ class Kakoune < Formula
depends_on 'boost'
depends_on 'asciidoc' => :build
+ depends_on 'docbook-xsl' => :build
def install
cd 'src' do
diff --git a/src/Makefile b/src/Makefile
index 966582d..87dfa4d 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -37,6 +37,7 @@ mandir := $(DESTDIR)$(PREFIX)/share/man/man1
os := $(shell uname)
ifeq ($(os),Darwin)
+ XML_CATALOG_FILES=/usr/local/etc/xml/catalog
LIBS += -lncurses -lboost_regex-mt
CPPFLAGS += -I/usr/local/opt/ncurses/include
LDFLAGS += -L/usr/local/opt/ncurses/lib
It will if you use the brew version of asciidoc (with --with-docbook-xsl
) at least. This could be a sensible default.
The command I use to reinstall kakoune every day is this one:
XML_CATALOG_FILES=/usr/local/etc/xml/catalog \
PKG_CONFIG_PATH=/usr/local/opt/ncurses/lib/pkgconfig \
brew reinstall --HEAD https://raw.githubusercontent.com/mawww/kakoune/master/contrib/kakoune.rb
User @jjthrash reportedly managed to install Kakoune using the following patch (the asciidoc
might have to be removed beforehand):
diff --git a/contrib/kakoune.rb b/contrib/kakoune.rb
index 018774d..326b89d 100644
--- a/contrib/kakoune.rb
+++ b/contrib/kakoune.rb
@@ -5,7 +5,8 @@ class Kakoune < Formula
head "https://github.com/mawww/kakoune.git"
depends_on 'boost'
- depends_on 'asciidoc' => :build
+ depends_on 'docbook-xsl' => :build
+ depends_on 'asciidoc' => [:build, 'with-docbook-xsl']
def install
cd 'src' do
I'm having issues on Sierra even after the patch:
==> make install PREFIX=/usr/local/Cellar/kakoune/HEAD-e441295
Last 15 lines from /Users/xxxxx/Library/Logs/Homebrew/kakoune/01.make:
a2x: ERROR: "xsltproc" --stringparam callout.graphics 0 --stringparam navig.graphics 0 --stringparam admon.textlabel 1 --stringparam admon.graphics 0 "/usr/local/Cellar/asciidoc/8.6.9_1/etc/asciidoc/docbook-xsl/manpage.xsl" "/private/tmp/kakoune-20161212-53682-1wc7llx/doc/manpages/faq.xml" returned non-zero exit status 5
make: *** [../doc/manpages/faq.gz] Error 1
make: *** Waiting for unfinished jobs....
a2x: ERROR: "xsltproc" --stringparam callout.graphics 0 --stringparam navig.graphics 0 --stringparam admon.textlabel 1 --stringparam admon.graphics 0 "/usr/local/Cellar/asciidoc/8.6.9_1/etc/asciidoc/docbook-xsl/manpage.xsl" "/private/tmp/kakoune-20161212-53682-1wc7llx/doc/manpages/highlighters.xml" returned non-zero exit status 5
make: *** [../doc/manpages/highlighters.gz] Error 1
a2x: ERROR: "xsltproc" --stringparam callout.graphics 0 --stringparam navig.graphics 0 --stringparam admon.textlabel 1 --stringparam admon.graphics 0 "/usr/local/Cellar/asciidoc/8.6.9_1/etc/asciidoc/docbook-xsl/manpage.xsl" "/private/tmp/kakoune-20161212-53682-1wc7llx/doc/manpages/execeval.xml" returned non-zero exit status 5
make: *** [../doc/manpages/execeval.gz] Error 1
a2x: ERROR: "xsltproc" --stringparam callout.graphics 0 --stringparam navig.graphics 0 --stringparam admon.textlabel 1 --stringparam admon.graphics 0 "/usr/local/Cellar/asciidoc/8.6.9_1/etc/asciidoc/docbook-xsl/manpage.xsl" "/private/tmp/kakoune-20161212-53682-1wc7llx/doc/manpages/commands.xml" returned non-zero exit status 5
make: *** [../doc/manpages/commands.gz] Error 1
a2x: ERROR: "xsltproc" --stringparam callout.graphics 0 --stringparam navig.graphics 0 --stringparam admon.textlabel 1 --stringparam admon.graphics 0 "/usr/local/Cellar/asciidoc/8.6.9_1/etc/asciidoc/docbook-xsl/manpage.xsl" "/private/tmp/kakoune-20161212-53682-1wc7llx/doc/manpages/expansions.xml" returned non-zero exit status 5
make: *** [../doc/manpages/expansions.gz] Error 1
a2x: ERROR: "xsltproc" --stringparam callout.graphics 0 --stringparam navig.graphics 0 --stringparam admon.textlabel 1 --stringparam admon.graphics 0 "/usr/local/Cellar/asciidoc/8.6.9_1/etc/asciidoc/docbook-xsl/manpage.xsl" "/private/tmp/kakoune-20161212-53682-1wc7llx/doc/kak.1.xml" returned non-zero exit status 5
make: *** [../doc/kak.1.gz] Error 1
a2x: ERROR: "xsltproc" --stringparam callout.graphics 0 --stringparam navig.graphics 0 --stringparam admon.textlabel 1 --stringparam admon.graphics 0 "/usr/local/Cellar/asciidoc/8.6.9_1/etc/asciidoc/docbook-xsl/manpage.xsl" "/private/tmp/kakoune-20161212-53682-1wc7llx/doc/manpages/faces.xml" returned non-zero exit status 5
make: *** [../doc/manpages/faces.gz] Error 1
Building manually from the repository does not succeed either:
In file included from color.cc:5:
./regex.hh:8:10: fatal error: 'boost/regex.hpp' file not found
#include <boost/regex.hpp>
^
Boost is installed with Homebrew:
boost: stable 1.62.0 (bottled), HEAD
Collection of portable C++ source libraries
https://www.boost.org/
/usr/local/Cellar/boost/1.62.0 (12,405 files, 396.4M) *
Poured from bottle on 2016-12-12 at 19:49:33
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/boost.rb
==> Dependencies
Optional: icu4c ✔
==> Requirements
Optional: mpi ✘
==> Options
--c++11
Build using C++11 mode
--universal
Build a universal binary
--with-icu4c
Build regexp engine with icu support
--with-mpi
Build with MPI support
--without-single
Disable building single-threading variant
--without-static
Disable building static library variant
--HEAD
Install HEAD version
Similar issue:
In file included from color.cc:5:
./regex.hh:8:10: fatal error: 'boost/regex.hpp' file not found
#include <boost/regex.hpp>
^
1 warning and 1 error generated.
make: *** [.color.debug.o] Error 1
➜ brew info boost
boost: stable 1.62.0 (bottled), HEAD
Collection of portable C++ source libraries
https://www.boost.org/
/usr/local/Cellar/boost/1.62.0 (12,405 files, 396.4M) *
Poured from bottle on 2016-12-13 at 09:14:16
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/boost.rb
==> Dependencies
Optional: icu4c ✘
==> Requirements
Optional: mpi ✘
==> Options
--c++11
Build using C++11 mode
--universal
Build a universal binary
--with-icu4c
Build regexp engine with icu support
--with-mpi
Build with MPI support
--without-single
Disable building single-threading variant
--without-static
Disable building static library variant
--HEAD
Install HEAD version
Please forward your comments on #954, the newly created issue about this problem.
@nonphoto yes please, the environment variable needs to be exported into the Makefile
as well.
@lenormf FYI, I just tested on the latest and #954 (and the #966 fix) did not fix the boost
issue above.
Unfortunately the fixes regarding those issues are not related, maybe we need to declare boost
as a build dependency as well ?
diff --git a/kakoune.rb b/kakoune.rb
index 6c6860f..e4b5f44 100644
--- a/kakoune.rb
+++ b/kakoune.rb
@@ -4,7 +4,7 @@ class Kakoune < Formula
homepage "https://github.com/mawww/kakoune"
head "https://github.com/mawww/kakoune.git"
- depends_on 'boost'
+ depends_on 'boost' => :build
depends_on 'docbook-xsl' => :build
depends_on 'asciidoc' => [:build, 'with-docbook-xsl']
I created #987 for the Boost-related errors.
Here is a full log from brew
Relevant bit (I think):
As per #579 here are some of the outputs requested: