Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@ SUBDIRS = src include testsuite doc bindings tools

EXTRA_DIST = configure.ac CHANGES libemu.pc.in

pkgconfigdir = @pkgconfigdir@
pkgconfigdir = @PKGCONFIGDIR@
pkgconfig_DATA = libemu.pc

15 changes: 8 additions & 7 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -22,24 +22,25 @@ case "$host" in
*-*-freebsd*)
CPPFLAGS="$CPPFLAGS -I/usr/local/include -I/usr/src/contrib/file/ -Wno-unused-local-typedefs"
LDFLAGS="$LDFLAGS -L/usr/local/lib -Wl,-rpath,/usr/local/lib"
pkgconfigdir="/usr/lib/pkgconfig"
PKGCONFIGDIR="/usr/lib/pkgconfig"
;;
*-*-linux*)
CPPFLAGS="$CPPFLAGS -D _GNU_SOURCE -I/usr/local/include -Wno-unused-local-typedefs"
LDFLAGS="$LDFLAGS -L/usr/local/lib -Wl,-rpath,/usr/local/lib"
pkgconfigdir="/usr/lib/pkgconfig"
# CPPFLAGS="$CPPFLAGS -D _GNU_SOURCE -I/usr/local/include -Wno-unused-local-typedefs"
CPPFLAGS="$CPPFLAGS -D _GNU_SOURCE -Wno-unused-local-typedefs"
# LDFLAGS="$LDFLAGS -L/usr/local/lib -Wl,-rpath,/usr/local/lib"
PKGCONFIGDIR="/usr/lib/pkgconfig"
;;
*-*-darwin*)
CPPFLAGS="$CPPFLAGS -I/opt/local/include -Wno-unused-local-typedefs"
LDFLAGS="$LDFLAGS -L/opt/local/lib"
pkgconfigdir="/usr/local/lib/pkgconfig"
PKGCONFIGDIR="/usr/local/lib/pkgconfig"
if test "$GCC" = "yes"; then
CFLAGS="$CFLAGS -Wno-unused-local-typedefs -Wno-tautological-compare"
fi
;;
esac

AC_SUBST([pkgconfigdir])
AC_SUBST([PKGCONFIGDIR])

# Checks for programs.
AC_PROG_CC
Expand Down Expand Up @@ -175,14 +176,14 @@ AC_ARG_WITH(cargos-lib,

if test x$enable_cargos = "xyes" ; then
OLD_CPPFLAGS=${CPPFLAGS};
OLD_LDFLAGS=${LDFLAGS}
if test x$cargos_inc != "xno"; then
CPPFLAGS="${CPPFLAGS} -I${cargos_inc}"
fi

AC_CHECK_HEADER(cargos-lib.h,[enable_cargos=yes],[enable_cargos=no])

if test x$enable_cargos = "xyes" ; then
OLD_LDFLAGS=${LDFLAGS}
if test x$cargos_lib != "xno"; then
LDFLAGS="${LDFLAGS} -L${cargos_lib}"
fi
Expand Down