I'm stuck on installing the dvipng package. As I encounter the problem of not finding libkpathsea even after I have installed it, I tried to followed in the instruction (http://www.nongnu.org/dvipng/dvipng_2.html#Build_002finstall):
On some machines, the libraries will be installed in directories that are not in the linker’s search path. This will generate an error when running ‘./configure’, indicating that it cannot find libgd or libkpathsea (most likely). You then need to specify the path to the respective library’s object files. They are typically called e.g., ‘libgd.a’ or ‘libgd.so’. If they are located in e.g., ‘/usr/local/lib’, do
./configure LDFLAGS=-L/usr/local/lib
If the library is available as a shared object file (‘.so’), the runtime linker may also need to be told where to find the library, then use
./configure LDFLAGS='-L/usr/local/lib -R/usr/local/lib'
That's exactly my situation: I have installed the libraries of Latex and have ‘libgd.a’ or ‘libgd.so’ in my lib folder. However, when I try to run the code he mentioned, it's reported that:
checking for C compiler default output file name... configure: error: C compiler cannot create executables
and my config.log is:
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by dvipng configure 1.9, which was
generated by GNU Autoconf 2.60. Invocation command line was
$ ./configure LDFLAGS=-L/usr/local/lib -R/usr/local/lib
## --------- ##
## Platform. ##
## --------- ##
hostname = dingshan-virtual-machine
uname -m = x86_64
uname -r = 5.4.0-29-generic
uname -s = Linux
uname -v = #33-Ubuntu SMP Wed Apr 29 14:32:27 UTC 2020
/usr/bin/uname -p = x86_64
/bin/uname -X = unknown
/bin/arch = x86_64
/usr/bin/arch -k = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo = unknown
/bin/machine = unknown
/usr/bin/oslevel = unknown
/bin/universe = unknown
PATH: /usr/local/texlive/2018/bin/x86_64-linux
PATH: /usr/local/sbin
PATH: /usr/local/bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /sbin
PATH: /bin
PATH: /usr/games
PATH: /usr/local/games
PATH: /snap/bin
## ----------- ##
## Core tests. ##
## ----------- ##
configure:1739: checking whether make sets $(MAKE)
configure:1760: result: yes
configure:1817: checking for gcc
configure:1833: found /usr/bin/gcc
configure:1844: result: gcc
configure:2082: checking for C compiler version
configure:2089: gcc --version >&5
gcc (Ubuntu 9.3.0-10ubuntu2) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
configure:2092: $? = 0
configure:2099: gcc -v >&5
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/9/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none:hsa
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 9.3.0-10ubuntu2' --with-bugurl=file:///usr/share/doc/gcc-9/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++,gm2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-9 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none,hsa --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 9.3.0 (Ubuntu 9.3.0-10ubuntu2)
configure:2102: $? = 0
configure:2109: gcc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:2112: $? = 1
configure:2135: checking for C compiler default output file name
configure:2162: gcc -L/usr/local/lib -R/usr/local/lib conftest.c >&5
gcc: error: unrecognized command line option '-R'
configure:2165: $? = 1
configure: failed program was:
| /* confdefs.h. */
| #define PACKAGE_NAME "dvipng"
| #define PACKAGE_TARNAME "dvipng"
| #define PACKAGE_VERSION "1.9"
| #define PACKAGE_STRING "dvipng 1.9"
| #define PACKAGE_BUGREPORT "[email protected]"
| #define DEBUG 1
| /* end confdefs.h. */
|
| int
| main ()
| {
|
| ;
| return 0;
| }
configure:2204: error: C compiler cannot create executables
See `config.log' for more details.
## ---------------- ##
## Cache variables. ##
## ---------------- ##
ac_cv_env_CC_set=
ac_cv_env_CC_value=
ac_cv_env_CFLAGS_set=
ac_cv_env_CFLAGS_value=
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_LDFLAGS_set=set
ac_cv_env_LDFLAGS_value='-L/usr/local/lib -R/usr/local/lib'
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_prog_ac_ct_CC=gcc
ac_cv_prog_make_make_set=yes
## ----------------- ##
## Output variables. ##
## ----------------- ##
ALLOCA=''
CC='gcc'
CFLAGS=''
CPP=''
CPPFLAGS=''
DEFS=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EGREP=''
EXEEXT=''
FT2_CFLAGS=''
FT2_CONFIG=''
FT2_LIBS=''
GREP=''
GS=''
INSTALL_BIN_TARGET=''
INSTALL_DATA=''
INSTALL_INFO=''
INSTALL_PROGRAM=''
INSTALL_SCRIPT=''
KPSEWHICH=''
LDFLAGS='-L/usr/local/lib -R/usr/local/lib'
LIBOBJS=''
LIBS=''
LN_S=''
LTLIBOBJS=''
MAKEINFO=''
MAKEINFO_MACROS=''
OBJEXT=''
PACKAGE_BUGREPORT='[email protected]'
PACKAGE_NAME='dvipng'
PACKAGE_STRING='dvipng 1.9'
PACKAGE_TARNAME='dvipng'
PACKAGE_VERSION='1.9'
PATH_SEPARATOR=':'
POW_LIB=''
PSFONTS_O=''
SET_MAKE=''
SHELL='/bin/bash'
ac_ct_CC='gcc'
bindir='${exec_prefix}/bin'
build_alias=''
datadir='${datarootdir}'
datarootdir='${prefix}/share'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
dvidir='${docdir}'
exec_prefix='NONE'
host_alias=''
htmldir='${docdir}'
includedir='${prefix}/include'
infodir='${datarootdir}/info'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localedir='${datarootdir}/locale'
localstatedir='${prefix}/var'
mandir='${datarootdir}/man'
oldincludedir='/usr/include'
pdfdir='${docdir}'
prefix='NONE'
program_transform_name='s,x,x,'
psdir='${docdir}'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
sysconfdir='${prefix}/etc'
target_alias=''
## ----------- ##
## confdefs.h. ##
## ----------- ##
#define PACKAGE_NAME "dvipng"
#define PACKAGE_TARNAME "dvipng"
#define PACKAGE_VERSION "1.9"
#define PACKAGE_STRING "dvipng 1.9"
#define PACKAGE_BUGREPORT "[email protected]"
#define DEBUG 1
configure: exit 77
Can somebody help me out?