Rocky Linux 9へxlhtmlのインストール

スポンサーリンク
Linux
スポンサーリンク

namazuでexcelの解析をするためxlhtmlをインストールする。
簡単にインストールできないので、記録を残す。

スポンサーリンク

make失敗

一般的なインストール手順でmakeする。
エラーとなった。

# tar xfv xlhtml-0.5.1.5.tar 
xlhtml/
xlhtml/aclocal.m4
   :
xlhtml/xlhtml/xml.c
xlhtml/xlhtml.spec
[root@lifebook namazu]# 

# cd xlhtml/

# ./configure
creating cache ./config.cache
checking host system type... Invalid configuration x86_64-unknown-linux-gnu': machine x86_64-unknown' not recognized
checking for a BSD compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking whether make sets ${MAKE}... yes
checking for working aclocal... found
    :
creating cole/cole.h
creating xlhtml/Makefile
creating ppthtml/Makefile
creating config.h
#
# make
cd . && aclocal
aclocal: warning: autoconf input should be named 'configure.ac', not 'configure.in'
cd . && automake --gnu --include-deps Makefile
automake: warning: autoconf input should be named 'configure.ac', not 'configure.in'
configure.in:16: warning: AM_INIT_AUTOMAKE: two- and three-arguments forms are deprecated.  For more info, see:
configure.in:16: https://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_005fINIT_005fAUTOMAKE-invocation
configure.in:19: error: required file './compile' not found
configure.in:19:   'automake --add-missing' can install 'compile'
Makefile.am: error: required file './ChangeLog' not found
make: *** [Makefile:95: Makefile.in] エラー 1
#

 

再度makeする

configureのパラメータを与えて、configure再作成を行う。

configure実行

# ./configure --build=i686-linux
loading cache ./config.cache
checking host system type... Invalid configuration x86_64-unknown-linux-gnu': machine x86_64-unknown' not recognized

checking for a BSD compatible install... (cached) /usr/bin/install -c
checking whether build environment is sane... yes
checking whether make sets ${MAKE}... (cached) yes
checking for working aclocal... found
     :
creating cole/cole.h
creating xlhtml/Makefile
creating ppthtml/Makefile
creating config.h
config.h is unchanged
# 

automake実行

エラーが表示されるため、ChangeLogのからファイルを作成する。

# automake -a -c
automake: warning: autoconf input should be named 'configure.ac', not 'configure.in'
configure.in:16: warning: AM_INIT_AUTOMAKE: two- and three-arguments forms are deprecated.  For more info, see:
configure.in:16: https://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_005fINIT_005fAUTOMAKE-invocation
configure.in:19: installing './compile'
Makefile.am: error: required file './ChangeLog' not found
automake: warning: autoconf input should be named 'configure.ac', not 'configure.in'
cole/Makefile.am: installing './depcomp'
ppthtml/Makefile.am:5: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
xlhtml/Makefile.am:5: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
#
# touch ChangeLog
# 

再度automakeを実行

# automake -a -c
automake: warning: autoconf input should be named 'configure.ac', not 'configure.in'
configure.in:16: warning: AM_INIT_AUTOMAKE: two- and three-arguments forms are deprecated.  For more info, see:
configure.in:16: https://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_005fINIT_005fAUTOMAKE-invocation
automake: warning: autoconf input should be named 'configure.ac', not 'configure.in'
ppthtml/Makefile.am:5: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
xlhtml/Makefile.am:5: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS' (or '*_CPPFLAGS')
# 

再度configureを実行

# ./configure --build=i686-linux
loading cache ./config.cache
checking host system type... Invalid configuration x86_64-unknown-linux-gnu': machine x86_64-unknown' not recognized
checking for a BSD compatible install... (cached) /usr/bin/install -c
checking whether build environment is sane... yes
checking whether make sets ${MAKE}... (cached) yes
checking for working aclocal... found
     :
creating Makefile
creating cole/Makefile
creating cole/version.c
creating cole/cole.h
creating xlhtml/Makefile
creating ppthtml/Makefile
creating config.h
config.h is unchanged
# 

再度makeを実行

なぜかconfigureが実行されるが、makeも実行される。
makeが正常終了した。

[root@lifebook xlhtml]# make
CDPATH="${ZSH_VERSION+.}@PATH_SEPARATOR@" && cd . && autoconf
/bin/sh ./config.status --recheck
running /bin/sh ./configure  --build=i686-linux --no-create --no-recursion
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
     :
config.status: creating Makefile
config.status: creating cole/Makefile
config.status: creating cole/version.c
config.status: creating cole/cole.h
config.status: creating xlhtml/Makefile
config.status: creating ppthtml/Makefile
config.status: creating config.h
config.status: executing depfiles commands
(CDPATH="${ZSH_VERSION+.}:" && cd . && autoheader)
rm -f stamp-h1
touch config.h.in
cd . && /bin/sh ./config.status config.h
config.status: creating config.h
make  all-recursive
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml' に入ります
Making all in cole
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/cole' に入ります
gcc -DHAVE_CONFIG_H -I. -I..     -g -O2 -MT cole.o -MD -MP -MF .deps/cole.Tpo -c -o cole.o cole.c
mv -f .deps/cole.Tpo .deps/cole.Po
     :
cc  -g -O2   -o ppthtml ppthtml.o ../cole/libcole.a 
gcc -DHAVE_CONFIG_H -I. -I.. -I../cole    -g -O2 -MT pptdump.o -MD -MP -MF .deps/pptdump.Tpo -c -o pptdump.o pptdump.c
mv -f .deps/pptdump.Tpo .deps/pptdump.Po
gcc  -g -O2   -o pptdump pptdump.o ../cole/libcole.a 
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/ppthtml' から出ます
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml' に入ります
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml' から出ます
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml' から出ます
# 

インストールする

# make install
Making install in cole
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml/cole' に入ります
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/cole' に入ります
make[2]: 'install-exec-am' に対して行うべき事はありません.
make[2]: 'install-data-am' に対して行うべき事はありません.
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/cole' から出ます
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml/cole' から出ます
Making install in xlhtml
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml/xlhtml' に入ります
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/xlhtml' に入ります
 /usr/bin/mkdir -p '/usr/local/bin'
  /usr/bin/install -c xlhtml '/usr/local/bin'
 /usr/bin/mkdir -p '/usr/local/bin'
 /usr/bin/install -c nsopen nsxlview '/usr/local/bin'
 /usr/bin/mkdir -p '/usr/local/share/man/man1'
 /usr/bin/install -c -m 644 xlhtml.1 '/usr/local/share/man/man1'
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/xlhtml' から出ます
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml/xlhtml' から出ます
Making install in ppthtml
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml/ppthtml' に入ります
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/ppthtml' に入ります
 /usr/bin/mkdir -p '/usr/local/bin'
  /usr/bin/install -c ppthtml '/usr/local/bin'
 /usr/bin/mkdir -p '/usr/local/bin'
 /usr/bin/install -c nspptview '/usr/local/bin'
 /usr/bin/mkdir -p '/usr/local/share/man/man1'
 /usr/bin/install -c -m 644 ppthtml.1 '/usr/local/share/man/man1'
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml/ppthtml' から出ます
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml/ppthtml' から出ます
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml' に入ります
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml' に入ります
make[2]: 'install-exec-am' に対して行うべき事はありません.
make[2]: 'install-data-am' に対して行うべき事はありません.
make[2]: ディレクトリ '/usr/local/src/namazu/xlhtml' から出ます
make[1]: ディレクトリ '/usr/local/src/namazu/xlhtml' から出ます
# 

まもめ

パッケージが用意されていないソフトが存在するため、簡単にインストールできないアプリは、インストール情報は残す必要があると思います。