--- /dev/null
+--- a/configure.ac
++++ b/configure.ac
+@@ -417,7 +417,6 @@
+ AC_CHECK_PROGS(AR, ar gar)
+ AC_CHECK_PROGS(AS, as gas)
+ AC_CHECK_PROGS(MAKEINFO, makeinfo)
+-AC_CHECK_PROGS(GZIP_PROGRAM, gzip)
+
+ dnl for cross build
+ AC_CHECK_PROGS(BUILD_CC, ${build}-gcc ${build_alias}-gcc gcc cc)
+--- a/doc/Makefile.in
++++ b/doc/Makefile.in
+@@ -16,7 +16,6 @@
+ INSTALL_DATA = @INSTALL_DATA@
+ MKINSTDIR = $(top_srcdir)/mkinstalldirs
+ MAKEINFO = @MAKEINFO@
+-GZIP_PROGRAM = @GZIP_PROGRAM@
+ VERSION_INFO = @PACKAGE_STRING@
+
+ MAKEDOC = $(GOSH) $(srcdir)/makedoc.scm
+@@ -58,7 +57,7 @@
+ texi html htmls dvi pdf info \
+ clean distclean maintainer-clean
+
+-.SUFFIXES: .texi .html .info.gz .pdf .dvi
++.SUFFIXES: .texi .html .info .pdf .dvi
+
+ all: info
+
+@@ -66,7 +65,7 @@
+ if test ! -d "$(DESTDIR)$(mandir)/man1"; then $(MKINSTDIR) "$(DESTDIR)$(mandir)/man1"; fi
+ $(INSTALL_DATA) $(MANPAGES) "$(DESTDIR)$(mandir)/man1"
+ if test ! -d "$(DESTDIR)$(infodir)"; then $(MKINSTDIR) "$(DESTDIR)$(infodir)"; fi
+- if test -f gauche-refe.info.gz -o -f gauche-refj.info.gz; then \
++ if test -f gauche-refe.info -o -f gauche-refj.info; then \
+ for info in *.info*; do \
+ $(INSTALL_DATA) $$info "$(DESTDIR)$(infodir)/"; \
+ done; \
+@@ -94,8 +93,8 @@
+ %/index.html : %.texi
+ $(MAKEDOC) htmls $< "$(MAKEINFO)" "$(VERSION_INFO)"
+
+-%.info.gz : %.texi
+- $(MAKEDOC) info $< "$(MAKEINFO)" "$(GZIP_PROGRAM)"
++%.info : %.texi
++ $(MAKEDOC) info $< "$(MAKEINFO)"
+
+ %.pdf : %.texi
+ $(MAKEDOC) pdf $< "$(MAKEINFO)"
+@@ -113,7 +112,7 @@
+ htmls : gauche-refe/index.html gauche-refj/index.html
+ dvi : gauche-refe.dvi gauche-refj.dvi
+ pdf : gauche-refe.pdf gauche-refj.pdf
+-info : gauche-refe.info.gz gauche-refj.info.gz
++info : gauche-refe.info gauche-refj.info
+
+ gauche-refe.texi : $(TEXIS) extract.scm
+ $(GOSH) $(srcdir)/extract.scm -en -o gauche-refe.texi $(srcdir)/gauche-ref.texi
+--- a/doc/makedoc.scm
++++ b/doc/makedoc.scm
+@@ -16,7 +16,7 @@
+ [gauche.sys.setenv (sys-putenv "LANG=C")]
+ [else])
+ (if (match (cdr args)
+- [("info" input makeinfo gzip) (do-info input makeinfo gzip)]
++ [("info" input makeinfo) (do-info input makeinfo)]
+ [("html" input makeinfo) (do-html input makeinfo)]
+ [("htmls" input makeinfo version) (do-htmls input makeinfo version)]
+ [("pdf" input makeinfo) (do-pdf input makeinfo)]
+@@ -27,7 +27,7 @@
+ (define (usage)
+ (print "Usage: gosh makedoc.scm command args ...")
+ (print "Valid commands (and args):")
+- (print " info input MAKEINFO GZIP - generate info doc")
++ (print " info input MAKEINFO - generate info doc")
+ (print " html input MAKEINFO - generate single html")
+ (print " htmls input MAKEINFO VERSION-STRING - generate html files in subdir")
+ (print " pdf input MAKEINFO - generate pdf")
+@@ -55,14 +55,11 @@
+ (warn "makeinfo version ~a or greater is required, but ~a's \
+ version is ~a. Skipping.\n" min-version makeinfo vers)))))
+
+-(define (do-info input makeinfo gzip)
++(define (do-info input makeinfo)
+ (define info (path-swap-extension input "info"))
+ (or (string-null? makeinfo)
+- (string-null? gzip)
+ (not (check-makeinfo-version makeinfo "5.0"))
+- (and (do-process (make-cmd `(,makeinfo ,input)))
+- (begin (remove-files (glob #"~|info|*.gz"))
+- (do-process (make-cmd `(,gzip ,info ,@(glob #"~|info|-[0-9]*"))))))))
++ (and (do-process (make-cmd `(,makeinfo ,input))))))
+
+ (define (do-html input makeinfo)
+ (or (string-null? makeinfo)
--- /dev/null
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI="6"
+
+inherit autotools eapi7-ver
+
+MY_P="${P^g}"
+
+DESCRIPTION="A Unix system friendly Scheme Interpreter"
+HOMEPAGE="http://practical-scheme.net/gauche/"
+SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tgz"
+
+LICENSE="BSD"
+SLOT="0/$(ver_cut 1-2)7"
+KEYWORDS="~alpha ~amd64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~x86-macos"
+IUSE="ipv6 libressl mbedtls test"
+
+RDEPEND="sys-libs/gdbm
+ mbedtls? ( net-libs/mbedtls:= )"
+DEPEND="${RDEPEND}
+ test? (
+ !libressl? ( dev-libs/openssl:0 )
+ libressl? ( dev-libs/libressl:0 )
+ )"
+S="${WORKDIR}/${MY_P}"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-ext-ldflags.patch
+ "${FILESDIR}"/${PN}-gauche.m4.patch
+ "${FILESDIR}"/${PN}-info.patch
+ "${FILESDIR}"/${PN}-rfc.tls.patch
+ "${FILESDIR}"/${PN}-xz-info.patch
+)
+DOCS=( AUTHORS ChangeLog HACKING.adoc README.adoc )
+
+src_prepare() {
+ default
+ use ipv6 && sed -i "s/ -4//" ext/tls/ssltest-mod.scm
+
+ eautoconf
+}
+
+src_configure() {
+ econf \
+ $(use_enable ipv6) \
+ --with-ca-bundle="${EPREFIX}"/etc/ssl/certs/ca-certificates.crt \
+ --with-libatomic-ops=no \
+ --with-slib="${EPREFIX}"/usr/share/slib \
+ --with-tls=axtls$(usex mbedtls ',mbedtls' '')
+}
+
+src_test() {
+ emake -j1 -s check
+}
+
+src_install() {
+ emake DESTDIR="${D}" install-pkg install-doc
+ einstalldocs
+}