🎉
gmdb2 を ubuntu24.04 で動かす
ubuntu16 に存在してた gmdb2
現行 (noble) バージョンでは、バイナリがない模様・・・
じゃあコンパイルで
ちょっと修正が必要だったので fork した。
configure ... 通らない。
strnh@ubuntu-pc:~/workdir/gmdb2$ ./configure
bash: ./configure: そのようなファイルやディレクトリはありません
- 仕方ない。README.md を読む。
autoreconf -v -f
autoreconfというのは,autoheader aclocal automake autoconf等をまとめてやってくれるコマンドです.
- 早速
豆乳投入する。
$ autoreconf -i -v
autoreconf: export WARNINGS=
autoreconf: Entering directory '.'
autoreconf: configure.ac: not using Gettext
autoreconf: running: aclocal -I m4
aclocal: warning: couldn't open directory 'm4': No such file or directory
autoreconf: configure.ac: tracing
autoreconf: running: libtoolize --copy
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, 'build-aux'.
libtoolize: copying file 'build-aux/ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
autoreconf: configure.ac: not using Intltool
autoreconf: configure.ac: not using Gtkdoc
autoreconf: running: aclocal -I m4
autoreconf: running: /usr/bin/autoconf
autoreconf: configure.ac: not using Autoheader
autoreconf: running: automake --add-missing --copy --no-force
configure.ac:11: installing 'build-aux/compile'
configure.ac:15: installing 'build-aux/config.guess'
configure.ac:15: installing 'build-aux/config.sub'
configure.ac:6: installing 'build-aux/install-sh'
configure.ac:6: installing 'build-aux/missing'
src/Makefile.am: installing 'build-aux/depcomp'
autoreconf: Leaving directory '.'
- gettext は使われてない模様。取り敢えず日本語インターフェースは要らないか。
./configure → make
strnh@ubuntu-pc:~/workdir/gmdb2$ ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a race-free mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether to enable maintainer-specific portions of Makefiles... yes
checking whether make supports nested variables... (cached) yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether the compiler supports GNU C... yes
checking whether gcc accepts -g... yes
checking for gcc option to enable C11 features... none needed
checking whether gcc understands -c and -o together... yes
checking whether make supports the include directive... yes (GNU style)
checking dependency style of gcc... gcc3
checking whether make sets $(MAKE)... (cached) yes
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1572864
checking how to convert x86_64-pc-linux-gnu file names to x86_64-pc-linux-gnu format... func_convert_file_noop
checking how to convert x86_64-pc-linux-gnu file names to toolchain format... func_convert_file_noop
checking for /usr/bin/ld option to reload object files... -r
checking for file... file
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for ar... ar
checking for archiver @FILE support... @
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for sysroot... no
checking for a working dd... /usr/bin/dd
checking how to truncate binary pipes... /usr/bin/dd bs=4096 count=1
checking for mt... mt
checking if mt is a manifest tool... no
checking for stdio.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for strings.h... yes
checking for sys/stat.h... yes
checking for sys/types.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for ld... /usr/bin/ld -m elf_x86_64
checking if the linker (/usr/bin/ld -m elf_x86_64) is GNU ld... yes
checking for shared library run path origin... done
checking 32-bit host C ABI... no
checking how to run the C preprocessor... gcc -E
checking for ELF binary format... yes
checking for the common suffixes of directories in the library search path... lib,lib,lib64
checking for iconv... yes
checking for working iconv... yes
checking for iconv declaration...
extern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
./configure: line 14431: YELP_HELP_INIT: command not found
checking whether /usr/bin/ld -m elf_x86_64 accepts --as-needed... yes
checking pkg-config m4 macros... yes
checking for pkg-config... /usr/bin/pkg-config
checking pkg-config is at least version 0.9.0... yes
checking for libmdb >= 0.9.0... yes
checking for libmdbsql >= 0.9.0... yes
checking for gtk+-3.0 >= 3.22... yes
checking for g_memdup2 in -lglib-2.0... yes
checking for pkg-config... (cached) /usr/bin/pkg-config
checking pkg-config is at least version 0.16... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating doc/Makefile
config.status: creating src/Makefile
config.status: creating src/uifiles/Makefile
config.status: creating src/pixmaps/Makefile
config.status: creating src/help/Makefile
config.status: executing depfiles commands
config.status: executing libtool commands
configure:
configure: gmdb2 0.9.1 - Configuration summary
configure:
configure: SQL : enabled
configure: man : enabled
configure:
strnh@ubuntu-pc:~/workdir/gmdb2$ make
Making all in src
make[1]: ディレクトリ '/home/hiko/workdir/gmdb2/src' に入ります
Making all in help
make[2]: ディレクトリ '/home/hiko/workdir/gmdb2/src/help' に入ります
Makefile:456: *** 分離記号を欠いています. 中止.
make[2]: ディレクトリ '/home/hiko/workdir/gmdb2/src/help' から出ます
make[1]: *** [Makefile:564: all-recursive] エラー 1
make[1]: ディレクトリ '/home/hiko/workdir/gmdb2/src' から出ます
make: *** [Makefile:407: all-recursive] エラー 1
Makefile [分離記号を欠いています] とは
「*** missing separator. Stop.」 ← こっちのほうが見慣れている。翻訳されてわかりにくかった。よーするに TABで区切られてない Makefileが出来てた。
$ vi +456 src/help/Makefile
- 修正前: 見事に削れてた。
- TAB を打った。
コンパイルできた・・・
strnh@ubuntu-pc:~/workdir/gmdb2$ make
Making all in src
make[1]: ディレクトリ '/home/strnh/workdir/gmdb2/src' に入ります
Making all in help
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src/help' に入ります
make[2]: 'all' に対して行うべき事はありません.
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src/help' から出ます
Making all in uifiles
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src/uifiles' に入ります
make[2]: 'all' に対して行うべき事はありません.
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src/uifiles' から出ます
Making all in pixmaps
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src/pixmaps' に入ります
make[2]: 'all' に対して行うべき事はありません.
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src/pixmaps' から出ます
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src' に入ります
CC main2.o
CC file.o
CC table.o
CC info.o
CC table_def.o
CC table_data.o
CC table_export.o
CC debug.o
CC sql.o
CC schema.o
CC prefs.o
CCLD gmdb2
make[2]: ディレクトリ '/home/strnh/workdir/gmdb2/src' から出ます
make[1]: ディレクトリ '/home/strnh/workdir/gmdb2/src' から出ます
Making all in doc
make[1]: ディレクトリ '/home/strnh/workdir/gmdb2/doc' に入ります
./txt2man -t gmdb2 -r "gmdb2 0.9.1" -s 1 -v "Executable programs or shell commands" ./gmdb2.txt > gmdb2.1
make[1]: ディレクトリ '/home/strnh/workdir/gmdb2/doc' から出ます
make[1]: ディレクトリ '/home/strnh/workdir/gmdb2' に入ります
GEN mdbtools.gmdb2.gschema.valid
make[1]: ディレクトリ '/home/strnh/workdir/gmdb2' から出ます
strnh@ubuntu-pc:~/workdir/gmdb2$
修正したのを githubにおいて終了。
$ git add -f src/help/Makefile
$ git commit -m "src/help/Makefile retouch"
[main ef771d5] src/help/Makefile retouch
1 file changed, 460 insertions(+)
create mode 100644 src/help/Makefile
$ git push
Enumerating objects: 8, done.
Counting objects: 100% (8/8), done.
Delta compression using up to 16 threads
Compressing objects: 100% (5/5), done.
Writing objects: 100% (5/5), 5.04 KiB | 5.04 MiB/s, done.
Total 5 (delta 2), reused 0 (delta 0), pack-reused 0
remote: Resolving deltas: 100% (2/2), completed with 2 local objects.
To github.com:strnh/gmdb2.git
60335e0..ef771d5 main -> main
Discussion