0
0
mirror of https://github.com/termux/termux-packages.git synced 2025-08-18 03:02:57 +00:00
Files
termux-packages/packages/erlang/disable-docs-of-disabled-features.patch.beforehostbuild
Robert Kirkman b192aa1093 fix(main/erlang): enable building manpages and HTML docs
- Fixes https://github.com/termux/termux-packages/issues/24624

- This is able to make the commands `man erl` and `erl -man erl` both work, and also, several others
  like `man run_erl`, `erl -man run_erl`, and more. Unfortunately,
  it is **not** possible to get the `erl -man io` to fully work, but the erlang command
  `h(io).` inside the interactive `erl` shell already provides a help page for `io`,
  and also, **both Arch Linux and Debian also cannot currently run the command `erl -man io`**
  **successfully, even while all their erlang packages are installed**.
  The reason this happened is because Erlang version 27 upstream no
  longer supports the `erl -man io` command, so all implementations of
  it will be at best stuck at the manpage content from Erlang version
  26.

- building docs requires using the hostbuilt `erlang`, and that hostbuilt
  `erlang` must be a full build with ssl and termcap enabled to avoid errors
  and build all docs matching the featureset of the Android build.
  The `Makefile` automatically detects and uses this hostbuilt `erlang`
  to build the docs if it was the last `erlang` built.

- Unlike the `-DCMAKE_INSTALL_PREFIX` argument that CMake users might be familiar with,
  the `--prefix` argument of autotools `configure` does not seem to typically cause the configure step to
  attempt to find and import dependencies in that prefix, only sets the installation destination,
  so unlike the configure step of CMake projects, it is safe to use with `$TERMUX_PREFIX` during
  `termux_step_host_build()`. This message is written so that this example is not accidentally
  used as a reference to attempt a similar technique for any CMake-based package.
2025-05-16 04:27:21 -05:00

25 lines
992 B
Diff

erlang for Termux does not currently seem to support the odbc or jinterface
features, so to avoid errors when building docs, they must be disabled
from the docs Makefile. If the enabled features change in the future, this
patch should be changed to match.
Configure log summary report of these features being disabled
(both in hostbuild and main build):
jinterface : Java compiler disabled by user
odbc : ODBC library - link check failed
--- a/system/doc/top/Makefile
+++ b/system/doc/top/Makefile
@@ -32,9 +32,9 @@ HTMLDIR=../../../doc
RELSYS_HTMLDIR=$(RELEASE_PATH)/doc
CORE=compiler erts kernel sasl stdlib
-DATABASE=mnesia odbc
+DATABASE=mnesia
OAM=os_mon snmp
-INTERFACES=asn1 crypto diameter eldap erl_interface ftp inets jinterface megaco \
+INTERFACES=asn1 crypto diameter eldap erl_interface ftp inets megaco \
public_key ssh ssl tftp wx xmerl
TOOLS=debugger dialyzer et observer parsetools reltool runtime_tools syntax_tools tools
TESTING=common_test eunit