I'm trying to port some software that keeps failing when it tries to find a
config.h.

I know the config.h file is there but I think the compilation is failing
because it's trying to build ltdl and freebsd doesn't need that since
freebsd already has dlopen in libc.

Which configure flag could I try to get rid of building that lib? The full
configure --help file is below.

My current makefile has these settings:
HAS_CONFIGURE=   yes
CONFIGURE_ARGS=  --without-included-ltdl --disable-ltdl-install
USES=            autoreconf gmake

the compilation fails with these errors:
Making all in upstream/ltdl
gmake[3]: Entering directory
'/usr/ports/dev/tmp/work/tmp-c590592/upstream/ltdl'
  GEN      libltdl/lt__argz.h
gmake  all-am
gmake[4]: Entering directory
'/usr/ports/dev/tmp/work/tmp-c590592/upstream/ltdl'
  CC       loaders/dlopen.lo
In file included from loaders/dlopen.c:32:
libltdl/lt__private.h:35:12: fatal error: 'config.h' file not found
#  include LT_CONFIG_H
           ^
<command line>:2:21: note: expanded from here
#define LT_CONFIG_H <config.h>
                    ^~~~~~~~~~
1 error generated.
gmake[4]: *** [Makefile:731: loaders/dlopen.lo] Error 1
gmake[4]: Leaving directory
'/usr/ports/dev/tmp/work/tmp-c590592/upstream/ltdl'
gmake[3]: *** [Makefile:561: all] Error 2
gmake[3]: Leaving directory
'/usr/ports/dev/tmp/work/tmp-c590592/upstream/ltdl'
gmake[2]: *** [Makefile:605: all-recursive] Error 1
gmake[2]: Leaving directory '/usr/ports/dev/tmp/work/tmp-c590592'
gmake[1]: *** [Makefile:513: all] Error 2
gmake[1]: Leaving directory '/usr/ports/dev/tmp/work/tmp-c590592'
*** Error code 1

Stop.
make: stopped in /usr/ports/dev/tmp


To assign environment variables (e.g., CC, CFLAGS...), specify them as
VAR=VALUE.  See below for descriptions of some of the useful variables.

Defaults for the options are specified in brackets.

Configuration:
  -h, --help              display this help and exit
      --help=short        display options specific to this package
      --help=recursive    display the short help of all the included
packages
  -V, --version           display version information and exit
  -q, --quiet, --silent   do not print `checking ...' messages
      --cache-file=FILE   cache test results in FILE [disabled]
  -C, --config-cache      alias for `--cache-file=config.cache'
  -n, --no-create         do not create output files
      --srcdir=DIR        find the sources in DIR [configure dir or `..']

Installation directories:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [/usr/local]
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                          [PREFIX]

By default, `make install' will install all the files in
`/usr/local/bin', `/usr/local/lib' etc.  You can specify
an installation prefix other than `/usr/local' using `--prefix',
for instance `--prefix=$HOME'.

For better control, use the options below.

Fine tuning of the installation directories:
  --bindir=DIR            user executables [EPREFIX/bin]
  --sbindir=DIR           system admin executables [EPREFIX/sbin]
  --libexecdir=DIR        program executables [EPREFIX/libexec]
  --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
  --sharedstatedir=DIR    modifiable architecture-independent data
[PREFIX/com]
  --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
  --libdir=DIR            object code libraries [EPREFIX/lib]
  --includedir=DIR        C header files [PREFIX/include]
  --oldincludedir=DIR     C header files for non-gcc [/usr/include]
  --datarootdir=DIR       read-only arch.-independent data root
[PREFIX/share]
  --datadir=DIR           read-only architecture-independent data
[DATAROOTDIR]
  --infodir=DIR           info documentation [DATAROOTDIR/info]
  --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
  --mandir=DIR            man documentation [DATAROOTDIR/man]
  --docdir=DIR            documentation root [DATAROOTDIR/doc/tmp]
  --htmldir=DIR           html documentation [DOCDIR]
  --dvidir=DIR            dvi documentation [DOCDIR]
  --pdfdir=DIR            pdf documentation [DOCDIR]
  --psdir=DIR             ps documentation [DOCDIR]

Program names:
  --program-prefix=PREFIX            prepend PREFIX to installed program
names
  --program-suffix=SUFFIX            append SUFFIX to installed program
names
  --program-transform-name=PROGRAM   run sed PROGRAM on installed program
names

System types:
  --build=BUILD     configure for building on BUILD [guessed]
  --host=HOST       cross-compile to build programs to run on HOST [BUILD]

Optional Features:
  --disable-option-checking  ignore unrecognized --enable/--with options
  --disable-FEATURE       do not include FEATURE (same as
--enable-FEATURE=no)
  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
  --enable-test-reports   generate XML test reports [no]. Implies
                          --with-boost-unit-test-framework. XML test reports
                          can be post-processed with
tools/boost-test-report.
  --enable-code-coverage  collect run-time code coverage statistics [no].
                          Implies --with-boost-unit-test-framework and
                          --disable-shared. This requires a GNU C/C++
compiler
                          and turns off optimization for best results.
  --enable-sane-config    activate SANE compatibility component [yes].
Disable
                          this if you do not want the install step to touch
                          your system's SANE configuration. This is useful
if
                          you do not have the privileges needed to make
these
                          changes. For example when you configure with
                          --prefix=$HOME.
  --enable-udev-config    integrate udev activated device set up [yes].
                          Disable this if you do not want the install step
to
                          touch your system's udev configuration. This is
                          useful if you do not have the privileges needed to
                          make these changes. For example when you configure
                          with --prefix=$HOME.
  --enable-silent-rules   less verbose build output (undo: "make V=1")
  --disable-silent-rules  verbose build output (undo: "make V=0")
  --disable-maintainer-mode
                          disable make rules and dependencies not useful
(and
                          sometimes confusing) to the casual installer
  --enable-dependency-tracking
                          do not reject slow dependency extractors
  --disable-dependency-tracking
                          speeds up one-time build
  --disable-openmp        do not use OpenMP
  --disable-nls           do not use Native Language Support
  --disable-rpath         do not hardcode runtime library paths
  --enable-static[=PKGS]  build static libraries [default=no]
  --enable-shared[=PKGS]  build shared libraries [default=yes]
  --enable-fast-install[=PKGS]
                          optimize for fast installation [default=yes]
  --disable-libtool-lock  avoid locking (might break parallel builds)
  --enable-ltdl-install   install libltdl

Optional Packages:
  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
  --with-gtkmm            build a gtkmm based graphical user interface
[check]
  --with-jpeg             include JPEG image format related filters [check]
  --with-magick           include image processing with convert [check].
Both
                          GraphicsMagick and ImageMagick are supported but
the
                          latter provides somewhat more functionality.
  --with-magick-pp        include autocrop and deskew support [check]. Both
                          the GraphicsMagick and ImageMagick C++ libraries
are
                          supported.
  --with-tiff             include TIFF image format related support [check]
  --with-sane             build SANE compatibility components [check]
  --with-sane-confdir[=DIR]
                          where to find the SANE configuration directory
                          [guess]. Only use this if the guess is incorrect
and
                          you know exactly where your SANE configuration
                          directory is.
  --with-included-boost   use the Boost sources included here, if any
[check].
                          Directory locations for other --with-boost-*
options
                          will be overridden.
  --with-udev-confdir[=DIR]
                          udev configuration directory [guess]. Only use
this
                          if the guess is incorrect and you know exactly
where
                          your udev configuration directory is.
  --with-download-dir[=ABS_DIR]
                          where to cache upstream source downloads
                          [/path/to/upstream/downloads]. Distributable
                          creation may include upstream sources in a way
that
                          depends on our own distributed sources. For that
to
                          work as intended, it attempts to download upstream
                          archives into this location.
  --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
  --with-libiconv-prefix[=DIR]  search for libiconv in DIR/include and
DIR/lib
  --without-libiconv-prefix     don't search for libiconv in includedir and
libdir
  --with-libintl-prefix[=DIR]  search for libintl in DIR/include and DIR/lib
  --without-libintl-prefix     don't search for libintl in includedir and
libdir
  --with-pic[=PKGS]       try to use only PIC/non-PIC objects [default=use
                          both]
  --with-aix-soname=aix|svr4|both
                          shared library versioning (aka "SONAME") variant
to
                          provide on AIX, [default=aix].
  --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
  --with-sysroot[=DIR]    Search for dependent libraries within DIR (or the
                          compiler's sysroot if not specified).
  --with-included-ltdl    use the GNU ltdl sources included here
  --with-ltdl-include=DIR use the ltdl headers installed in DIR
  --with-ltdl-lib=DIR     use the libltdl.la installed in DIR
  --with-boost[=ARG]      use Boost library from a standard location
                          (ARG=yes), from the specified location
(ARG=<path>),
                          or disable it (ARG=no) [ARG=yes]
  --with-boost-libdir=LIB_DIR
                          Force given directory for boost libraries. Note
that
                          this will override library path detection, so use
                          this parameter only if default library detection
                          fails and you know exactly where your boost
                          libraries are located.
  --with-boost-system[=special-lib]
                          use the System library from boost - it is possible
                          to specify a certain library for the linker e.g.
                          --with-boost-system=boost_system-gcc-mt
  --with-boost-filesystem[=special-lib]
                          use the Filesystem library from boost - it is
                          possible to specify a certain library for the
linker
                          e.g.
--with-boost-filesystem=boost_filesystem-gcc-mt
  --with-boost-iostreams[=special-lib]
                          use the IOStreams library from boost - it is
                          possible to specify a certain library for the
linker
                          e.g.

--with-boost-iostreams=boost_iostreams-gcc-mt-d-1_33_1
  --with-boost-program-options[=special-lib]
                          use the program options library from boost - it is
                          possible to specify a certain library for the
linker
                          e.g.

--with-boost-program-options=boost_program_options-gcc-mt-1_33_1
  --with-boost-regex[=special-lib]
                          use the Regex library from boost - it is possible
to
                          specify a certain library for the linker e.g.
                          --with-boost-regex=boost_regex-gcc-mt-d-1_33_1
  --with-boost-thread[=special-lib]
                          use the Thread library from boost - it is possible
                          to specify a certain library for the linker e.g.
                          --with-boost-thread=boost_thread-gcc-mt
  --with-boost-unit-test-framework[=special-lib]
                          use the Unit_Test_Framework library from boost -
it
                          is possible to specify a certain library for the
                          linker e.g.

--with-boost-unit-test-framework=boost_unit_test_framework-gcc

Some influential environment variables:
  CC          C compiler command
  CFLAGS      C compiler flags
  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
              nonstandard directory <lib dir>
  LIBS        libraries to pass to the linker, e.g. -l<library>
  CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
              you have headers in a nonstandard directory <include dir>
  CXX         C++ compiler command
  CXXFLAGS    C++ compiler flags
  PKG_CONFIG  path to pkg-config utility
  PKG_CONFIG_PATH
              directories to add to pkg-config's search path
  PKG_CONFIG_LIBDIR
              path overriding pkg-config's built-in search path
  CPP         C preprocessor
  LT_SYS_LIBRARY_PATH
              User-defined run-time library search path.
  CXXCPP      C++ preprocessor
  LIBUDEV_CFLAGS
              C compiler flags for LIBUDEV, overriding pkg-config
  LIBUDEV_LIBS
              linker flags for LIBUDEV, overriding pkg-config
  LIBUSB_CFLAGS
              C compiler flags for LIBUSB, overriding pkg-config
  LIBUSB_LIBS linker flags for LIBUSB, overriding pkg-config
  LIBGTKMM_CFLAGS
              C compiler flags for LIBGTKMM, overriding pkg-config
  LIBGTKMM_LIBS
              linker flags for LIBGTKMM, overriding pkg-config

Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.
_______________________________________________
freebsd-ports@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-ports
To unsubscribe, send any mail to "freebsd-ports-unsubscr...@freebsd.org"

Reply via email to