Skip to content

Commit

Permalink
Merge pull request #457 from apache/3329-kill-pdf-texinfo
Browse files Browse the repository at this point in the history
Remove PDF, TeX/LaTeX and texinfo from the build chain.

Note if you are still looking for PDF (or epub!) versions of
our documentation, you can get these auto-built at 
https://docs.couchdb.org/ .
  • Loading branch information
wohali committed Mar 19, 2017
2 parents 112501c + 942f33e commit 80928ab
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 135 deletions.
10 changes: 0 additions & 10 deletions Makefile
Expand Up @@ -219,13 +219,9 @@ dist: all
@cp -r share/www apache-couchdb-$(COUCHDB_VERSION)/share/
@mkdir -p apache-couchdb-$(COUCHDB_VERSION)/share/docs/html
@cp -r src/docs/build/html apache-couchdb-$(COUCHDB_VERSION)/share/docs/
@mkdir -p apache-couchdb-$(COUCHDB_VERSION)/share/docs/pdf
@cp src/docs/build/latex/CouchDB.pdf apache-couchdb-$(COUCHDB_VERSION)/share/docs/pdf/

@mkdir -p apache-couchdb-$(COUCHDB_VERSION)/share/docs/man
@cp src/docs/build/man/apachecouchdb.1 apache-couchdb-$(COUCHDB_VERSION)/share/docs/man/
@mkdir -p apache-couchdb-$(COUCHDB_VERSION)/share/docs/info
@cp src/docs/build/texinfo/CouchDB.info apache-couchdb-$(COUCHDB_VERSION)/share/docs/info/

@tar czf apache-couchdb-$(COUCHDB_VERSION).tar.gz apache-couchdb-$(COUCHDB_VERSION)
@echo "Done: apache-couchdb-$(COUCHDB_VERSION).tar.gz"
Expand All @@ -249,15 +245,11 @@ ifeq ($(IN_RELEASE), true)
@mkdir -p rel/couchdb/share/www/docs/
@mkdir -p rel/couchdb/share/docs/
@cp -R share/docs/html/* rel/couchdb/share/www/docs/
@cp share/docs/pdf/CouchDB.pdf rel/couchdb/share/docs/CouchDB.pdf
@cp share/docs/man/apachecouchdb.1 rel/couchdb/share/docs/couchdb.1
@cp share/docs/info/CouchDB.info rel/couchdb/share/docs/CouchDB.info
else
@mkdir -p rel/couchdb/share/docs/
@cp -R src/docs/build/html/ rel/couchdb/share/www/docs
@cp src/docs/build/latex/CouchDB.pdf rel/couchdb/share/docs/CouchDB.pdf
@cp src/docs/build/man/apachecouchdb.1 rel/couchdb/share/docs/couchdb.1
@cp src/docs/build/texinfo/CouchDB.info rel/couchdb/share/docs/CouchDB.info
endif
endif

Expand Down Expand Up @@ -331,9 +323,7 @@ uninstall:
@rm -rf $(DESTDIR)/$(data_dir)
@rm -rf $(DESTDIR)/$(doc_dir)
@rm -rf $(DESTDIR)/$(html_dir)
@rm -rf $(DESTDIR)/$(pdf_dir)
@rm -rf $(DESTDIR)/$(man_dir)
@rm -rf $(DESTDIR)/$(info_dir)

.PHONY: rc
rc:
Expand Down
10 changes: 1 addition & 9 deletions Makefile.win
Expand Up @@ -170,13 +170,9 @@ dist: all
@copy -r share\www apache-couchdb-$(COUCHDB_VERSION)\share
@mkdir apache-couchdb-$(COUCHDB_VERSION)\share\docs\html
@copy -r src\docs\build\html apache-couchdb-$(COUCHDB_VERSION)\share\docs
@mkdir apache-couchdb-$(COUCHDB_VERSION)\share\docs\pdf
@copy src\docs\build\latex\CouchDB.pdf apache-couchdb-$(COUCHDB_VERSION)\share\docs\pdf

@mkdir apache-couchdb-$(COUCHDB_VERSION)\share\docs\man
@copy src\docs\build\man\apachecouchdb.1 apache-couchdb-$(COUCHDB_VERSION)\share\docs\man
@mkdir apache-couchdb-$(COUCHDB_VERSION)\share\docs\info
@copy src\docs\build\texinfo\CouchDB.info apache-couchdb-$(COUCHDB_VERSION)\share\docs\info

@tar czf apache-couchdb-$(COUCHDB_VERSION).tar.gz apache-couchdb-$(COUCHDB_VERSION)
@echo "Done: apache-couchdb-$(COUCHDB_VERSION).tar.gz"
Expand All @@ -202,11 +198,9 @@ ifeq ($(with_docs), 1)
ifeq ($(IN_RELEASE), true)
@xcopy share\docs\html rel\couchdb\share\www\docs /E /I
@copy share\docs\man\apachecouchdb.1 rel\couchdb\share\docs\couchdb.1
-@copy share\docs\info\CouchDB.info rel\couchdb\share\docs\CouchDB.info
else
@xcopy src\docs\build\html rel\couchdb\share\www\docs /E /I
@copy src\docs\build\man\apachecouchdb.1 rel\couchdb\share\docs\couchdb.1
-@copy src\docs\build\texinfo\CouchDB.info rel\couchdb\share\docs\CouchDB.info
endif
endif

Expand Down Expand Up @@ -284,9 +278,7 @@ uninstall:
-@rmdir /s/q $(DESTDIR)\$(data_dir)
-@rmdir /s/q $(DESTDIR)\$(doc_dir)
-@rmdir /s/q $(DESTDIR)\$(html_dir)
-@rmdir /s/q $(DESTDIR)\$(pdf_dir)
-@rmdir /s/q $(DESTDIR)\$(man_dir)
-@rmdir /s/q $(DESTDIR)\$(info_dir)


################################################################################
Expand All @@ -307,7 +299,7 @@ config.erl:
src\docs\build:
@echo Building docs...
ifeq ($(with_docs), 1)
@cd src\docs && make.bat html && make.bat texinfo && make.bat man
@cd src\docs && make.bat html && make.bat man
endif


Expand Down
18 changes: 4 additions & 14 deletions README-DEV.rst
Expand Up @@ -15,8 +15,6 @@ Dependencies
You may need:

* `Sphinx <http://sphinx.pocoo.org/>`_
* `LaTex <http://www.latex-project.org/>`_
* `GNU Texinfo <http://www.gnu.org/software/texinfo/>`_
* `GNU help2man <http://www.gnu.org/software/help2man/>`_
* `GnuPG <http://www.gnupg.org/>`_
* `md5sum <http://www.microbrew.org/tools/md5sha1sum/>`_
Expand Down Expand Up @@ -52,27 +50,22 @@ Debian-based (inc. Ubuntu) Systems

::

sudo apt-get install help2man python-sphinx \
texlive-latex-base texlive-latex-recommended \
texlive-latex-extra texlive-fonts-recommended texinfo gnupg \
nodejs npm
sudo apt-get install help2man python-sphinx gnupg nodejs npm

Gentoo-based Systems
~~~~~~~~~~~~~~~~~~~~

::

sudo emerge texinfo gnupg coreutils pkgconfig help2man
sudo USE=latex emerge sphinx
sudo emerge gnupg coreutils pkgconfig help2man sphinx

RedHat-based (Fedora, Centos, RHEL) Systems
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

::

sudo yum install help2man python-sphinx python-docutils \
python-pygments texlive-latex texlive-latex-fonts texinfo gnupg \
nodejs npm
python-pygments gnupg nodejs npm

Mac OS X
~~~~~~~~
Expand All @@ -96,15 +89,12 @@ Now, install the required Python packages::
sudo pip install docutils
sudo pip install pygments

Download `MacTeX <http://www.tug.org/mactex/>`_ and follow the instructions
to get a working LaTeX install on your system.

FreeBSD
~~~~~~~

::

pkg install help2man texinfo gnupg py27-sphinx texlive-full tex-formats node
pkg install help2man gnupg py27-sphinx node

Windows
~~~~~~~
Expand Down
6 changes: 3 additions & 3 deletions Vagrantfile
Expand Up @@ -15,18 +15,18 @@ Vagrant::Config.run do |config|
if Dir.glob("#{File.dirname(__FILE__)}/.vagrant/machines/default/*/id").empty?
# install build-essential
pkg_cmd = "apt-get update -qq; apt-get install -q -y build-essential git " \
"autoconf autoconf-archive gnu-standards help2man texinfo; "
"autoconf autoconf-archive gnu-standards help2man; "

# Install erlang
pkg_cmd << "apt-get install -q -y erlang-base-hipe erlang-dev " \
pkg_cmd << "apt-get install -q -y erlang-base erlang-dev " \
"erlang-manpages erlang-eunit erlang-nox erlang-xmerl erlang-inets; "

# couchdb developper dependencies
pkg_cmd << "apt-get install -q -y libmozjs185-dev libicu-dev " \
"curl libcurl4-gnutls-dev libtool; "

# doc dependencies
pkg_cmd << "apt-get install -q -y help2man texinfo python-sphinx python-pip; " \
pkg_cmd << "apt-get install -q -y help2man python-sphinx python-pip; " \
"pip install -U pygments; "

config.vm.provision :shell, :inline => pkg_cmd
Expand Down
33 changes: 0 additions & 33 deletions build-aux/sphinx-build
Expand Up @@ -25,39 +25,6 @@ WARNING: 'sphinx-build' is needed, and is missing on your system.
EOF
fi

if test "$2" = "texinfo"; then
if test -z "`which makeinfo`"; then
missing=yes
cat << EOF
WARNING: 'makeinfo' is needed, and is missing on your system.
You might have modified some files without having the
proper tools for further handling them.
EOF
fi
if test "$missing" != "yes"; then
sphinx-build $*
else
mkdir -p texinfo
echo "info:" > texinfo/Makefile
fi
fi

if test "$2" = "latex"; then
if test -z "`which pdflatex`"; then
missing=yes
cat << EOF
WARNING: 'pdflatex' is needed, and is missing on your system.
You might have modified some files without having the
proper tools for further handling them.
EOF
fi
if test "$missing" != "yes"; then
sphinx-build $*
else
mkdir -p latex
echo "all-pdf:" > latex/Makefile
fi
fi
if test "$2" = "html"; then
if test "$missing" != "yes"; then
sphinx-build $*
Expand Down
10 changes: 1 addition & 9 deletions configure.ps1
Expand Up @@ -29,11 +29,9 @@
-ViewindexDir DIR specify the view directory [LOCALSTATEDIR\lib]
-LogDir DIR specify the log directory [LOCALSTATEDIR\log]
-DataDir DIR read-only architecture-independent data [DATAROOTDIR]
-InfoDir DIR info documentation [DATAROOTDIR\info]
-ManDir DIR man documentation [DATAROOTDIR\man]
-DocDir DIR documentation root [DATAROOTDIR\doc\apache-couchdb]
-HTMLDir DIR html documentation [DOCDIR\html]
-PDFDir DIR pdf documentation [DOCDIR\pdf]
.LINK
http://couchdb.apache.org/
#>
Expand Down Expand Up @@ -81,16 +79,12 @@ Param(
[ValidateNotNullOrEmpty()]
[string]$DataDir = "$DataRootDir", # read-only arch.-independent data (default $DataRootDir)
[ValidateNotNullOrEmpty()]
[string]$InfoDir = "$DataRootDir\info", # info documentation (default $DataRootDir\info)
[ValidateNotNullOrEmpty()]
[string]$ManDir = "$DataRootDir\man", # man documentation (default $DataRootDir\man)
[ValidateNotNullOrEmpty()]

[string]$DocDir = "$DataRootDir\doc\apache-couchdb", # man documentation (default $DataRootDir\doc\apache-couchdb)
[ValidateNotNullOrEmpty()]
[string]$HTMLDir = "$DocDir\html", # html documentation (default $DocDir\html)
[ValidateNotNullOrEmpty()]
[string]$PDFDir = "$DocDir\pdf" # pdf documentation (default $DocDir\pdf)
)


Expand All @@ -103,7 +97,7 @@ Push-Location $rootdir
# The test script lives in test/build/test-configure.sh
If ($Test) {
Write-Output @"
"$Prefix" "$ExecPrefix" "$BinDir" "$LibExecDir" "$SysConfDir" "$DataRootDir" "$DataDir" "$LocalStateDir" "$RunStateDir" "$DocDir" "$LibDir" "$DatabaseDir" "$ViewIndexDir" "$LogDir" "$ManDir" "$InfoDir" "$HTMLDir" "$PDFDir"
"$Prefix" "$ExecPrefix" "$BinDir" "$LibExecDir" "$SysConfDir" "$DataRootDir" "$DataDir" "$LocalStateDir" "$RunStateDir" "$DocDir" "$LibDir" "$DatabaseDir" "$ViewIndexDir" "$LogDir" "$ManDir" "$HTMLDir"
"@
exit 0
}
Expand Down Expand Up @@ -175,9 +169,7 @@ view_index_dir = $ViewIndexDir
log_file = $LogFile
html_dir = $HTMLDir
pdf_dir = $PDFDir
man_dir = $ManDir
info_dir = $InfoDir
with_fauxton = $BuildFauxton
with_docs = $BuildDocs
Expand Down

0 comments on commit 80928ab

Please sign in to comment.