Commit 4c65ae05 authored by Thomas White's avatar Thomas White
Browse files

Separate CFLAGS and LIBS for libcrystfel and main

parent d3ec6617
...@@ -27,11 +27,11 @@ if HAVE_CAIRO ...@@ -27,11 +27,11 @@ if HAVE_CAIRO
bin_PROGRAMS += src/render_hkl bin_PROGRAMS += src/render_hkl
endif endif
AM_CFLAGS = -Wall AM_CFLAGS = -Wall @MAIN_CFLAGS@
AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib
AM_CPPFLAGS += -I$(top_srcdir)/lib AM_CPPFLAGS += -I$(top_srcdir)/lib
LDADD = $(top_builddir)/lib/libgnu.a @IGNORE_UNUSED_LIBRARIES_CFLAGS@ LDADD = $(top_builddir)/lib/libgnu.a @IGNORE_UNUSED_LIBRARIES_CFLAGS@
LDADD += $(top_builddir)/libcrystfel/libcrystfel.la LDADD += $(top_builddir)/libcrystfel/libcrystfel.la @MAIN_LIBS@
src_partial_sim_SOURCES = src/partial_sim.c src_partial_sim_SOURCES = src/partial_sim.c
......
...@@ -438,6 +438,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ ...@@ -438,6 +438,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@ LD = @LD@
LDFLAGS = @LDFLAGS@ LDFLAGS = @LDFLAGS@
LIBCRYSTFEL_CFLAGS = @LIBCRYSTFEL_CFLAGS@
LIBCRYSTFEL_LIBS = @LIBCRYSTFEL_LIBS@
LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@ LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@
LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@ LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@
LIBOBJS = @LIBOBJS@ LIBOBJS = @LIBOBJS@
...@@ -446,6 +448,8 @@ LIBTOOL = @LIBTOOL@ ...@@ -446,6 +448,8 @@ LIBTOOL = @LIBTOOL@
LIPO = @LIPO@ LIPO = @LIPO@
LN_S = @LN_S@ LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@ LTLIBOBJS = @LTLIBOBJS@
MAIN_CFLAGS = @MAIN_CFLAGS@
MAIN_LIBS = @MAIN_LIBS@
MAKEINFO = @MAKEINFO@ MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@ MKDIR_P = @MKDIR_P@
NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@ NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@
...@@ -573,11 +577,11 @@ EXTRA_DIST = configure m4/gnulib-cache.m4 tests/first_merge_check \ ...@@ -573,11 +577,11 @@ EXTRA_DIST = configure m4/gnulib-cache.m4 tests/first_merge_check \
scripts/indexed-filenames scripts/gen-sfs scripts/indexed-filenames scripts/gen-sfs
SUBDIRS = lib doc/reference libcrystfel SUBDIRS = lib doc/reference libcrystfel
ACLOCAL_AMFLAGS = -I m4 ACLOCAL_AMFLAGS = -I m4
AM_CFLAGS = -Wall AM_CFLAGS = -Wall @MAIN_CFLAGS@
AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib \ AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib \
-I$(top_srcdir)/lib -I$(top_srcdir)/lib
LDADD = $(top_builddir)/lib/libgnu.a @IGNORE_UNUSED_LIBRARIES_CFLAGS@ \ LDADD = $(top_builddir)/lib/libgnu.a @IGNORE_UNUSED_LIBRARIES_CFLAGS@ \
$(top_builddir)/libcrystfel/libcrystfel.la $(top_builddir)/libcrystfel/libcrystfel.la @MAIN_LIBS@
src_partial_sim_SOURCES = src/partial_sim.c src_partial_sim_SOURCES = src/partial_sim.c
src_pattern_sim_SOURCES = src/pattern_sim.c src/diffraction.c \ src_pattern_sim_SOURCES = src/pattern_sim.c src/diffraction.c \
$(am__append_3) $(am__append_3)
......
...@@ -626,6 +626,10 @@ HTML_DIR ...@@ -626,6 +626,10 @@ HTML_DIR
GTKDOC_MKPDF GTKDOC_MKPDF
GTKDOC_REBASE GTKDOC_REBASE
GTKDOC_CHECK GTKDOC_CHECK
LIBCRYSTFEL_LIBS
MAIN_LIBS
LIBCRYSTFEL_CFLAGS
MAIN_CFLAGS
HAVE_FFTW_FALSE HAVE_FFTW_FALSE
HAVE_FFTW_TRUE HAVE_FFTW_TRUE
HAVE_CAIRO_FALSE HAVE_CAIRO_FALSE
...@@ -14076,13 +14080,21 @@ $as_echo "$gl_cv_prog_c_ignore_unused_libraries" >&6; } ...@@ -14076,13 +14080,21 @@ $as_echo "$gl_cv_prog_c_ignore_unused_libraries" >&6; }
CFLAGS="$CFLAGS $HDF5_CFLAGS $GSL_CFLAGS $OPENCL_CFLAGS -pthread $GTK_CFLAGS" MAIN_CFLAGS="$CFLAGS $HDF5_CFLAGS $GSL_CFLAGS $OPENCL_CFLAGS -pthread"
CFLAGS="$CFLAGS $LIBTIFF_CFLAGS -D_GNU_SOURCE $libPNG_CFLAGS $Cairo_CFLAGS" MAIN_CFLAGS="$MAIN_CFLAGS $GTK_CFLAGS $LIBTIFF_CFLAGS -D_GNU_SOURCE "
CFLAGS="$CFLAGS $GDK_pixbuf_CFLAGS $GDK_pixbuf_2_CFLAGS $FFTW_CFLAGS" MAIN_CFLAGS="$MAIN_CFLAGS $libPNG_CFLAGS $Cairo_CFLAGS $GDK_pixbuf_CFLAGS"
MAIN_CFLAGS="$MAIN_CFLAGS $GDK_pixbuf_2_CFLAGS $FFTW_CFLAGS"
LIBS="$LIBS $HDF5_LIBS -lm -lz $GSL_LIBS $GTK_LIBS $OPENCL_LIBS -pthread"
LIBS="$LIBS $LIBTIFF_LIBS $libPNG_LIBS $Cairo_LIBS $GDK_pixbuf_LIBS" LIBCRYSTFEL_CFLAGS="$CFLAGS $HDF5_CFLAGS $GSL_CFLAGS $FFTW_CFLAGS"
LIBS="$LIBS $GDK_pixbuf_2_LIBS $TIMER_LIBS $FFTW_LIBS $LDFLAGS"
MAIN_LIBS="$LIBS $HDF5_LIBS -lm -lz $GSL_LIBS $GTK_LIBS $OPENCL_LIBS -pthread"
MAIN_LIBS="$MAIN_LIBS $LIBTIFF_LIBS $libPNG_LIBS $Cairo_LIBS $GDK_pixbuf_LIBS"
MAIN_LIBS="$MAIN_LIBS $GDK_pixbuf_2_LIBS $TIMER_LIBS $FFTW_LIBS $LDFLAGS"
LIBCRYSTFEL_LIBS="$LIBS $HDF5_LIBS $GSL_LIBS $FFTW_LIBS $LDFLAGS"
......
...@@ -253,14 +253,22 @@ AM_CONDITIONAL([HAVE_FFTW], test x$have_fftw = xtrue) ...@@ -253,14 +253,22 @@ AM_CONDITIONAL([HAVE_FFTW], test x$have_fftw = xtrue)
gl_IGNORE_UNUSED_LIBRARIES gl_IGNORE_UNUSED_LIBRARIES
CFLAGS="$CFLAGS $HDF5_CFLAGS $GSL_CFLAGS $OPENCL_CFLAGS -pthread $GTK_CFLAGS" MAIN_CFLAGS="$CFLAGS $HDF5_CFLAGS $GSL_CFLAGS $OPENCL_CFLAGS -pthread"
CFLAGS="$CFLAGS $LIBTIFF_CFLAGS -D_GNU_SOURCE $libPNG_CFLAGS $Cairo_CFLAGS" MAIN_CFLAGS="$MAIN_CFLAGS $GTK_CFLAGS $LIBTIFF_CFLAGS -D_GNU_SOURCE "
CFLAGS="$CFLAGS $GDK_pixbuf_CFLAGS $GDK_pixbuf_2_CFLAGS $FFTW_CFLAGS" MAIN_CFLAGS="$MAIN_CFLAGS $libPNG_CFLAGS $Cairo_CFLAGS $GDK_pixbuf_CFLAGS"
MAIN_CFLAGS="$MAIN_CFLAGS $GDK_pixbuf_2_CFLAGS $FFTW_CFLAGS"
LIBS="$LIBS $HDF5_LIBS -lm -lz $GSL_LIBS $GTK_LIBS $OPENCL_LIBS -pthread" AC_SUBST([MAIN_CFLAGS])
LIBS="$LIBS $LIBTIFF_LIBS $libPNG_LIBS $Cairo_LIBS $GDK_pixbuf_LIBS"
LIBS="$LIBS $GDK_pixbuf_2_LIBS $TIMER_LIBS $FFTW_LIBS $LDFLAGS" LIBCRYSTFEL_CFLAGS="$CFLAGS $HDF5_CFLAGS $GSL_CFLAGS $FFTW_CFLAGS"
AC_SUBST([LIBCRYSTFEL_CFLAGS])
MAIN_LIBS="$LIBS $HDF5_LIBS -lm -lz $GSL_LIBS $GTK_LIBS $OPENCL_LIBS -pthread"
MAIN_LIBS="$MAIN_LIBS $LIBTIFF_LIBS $libPNG_LIBS $Cairo_LIBS $GDK_pixbuf_LIBS"
MAIN_LIBS="$MAIN_LIBS $GDK_pixbuf_2_LIBS $TIMER_LIBS $FFTW_LIBS $LDFLAGS"
AC_SUBST([MAIN_LIBS])
LIBCRYSTFEL_LIBS="$LIBS $HDF5_LIBS $GSL_LIBS $FFTW_LIBS $LDFLAGS"
AC_SUBST([LIBCRYSTFEL_LIBS])
GTK_DOC_CHECK([1.11],[--flavour no-tmpl]) GTK_DOC_CHECK([1.11],[--flavour no-tmpl])
AC_CONFIG_MACRO_DIR(m4) AC_CONFIG_MACRO_DIR(m4)
......
...@@ -177,6 +177,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ ...@@ -177,6 +177,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@ LD = @LD@
LDFLAGS = @LDFLAGS@ LDFLAGS = @LDFLAGS@
LIBCRYSTFEL_CFLAGS = @LIBCRYSTFEL_CFLAGS@
LIBCRYSTFEL_LIBS = @LIBCRYSTFEL_LIBS@
LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@ LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@
LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@ LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@
LIBOBJS = @LIBOBJS@ LIBOBJS = @LIBOBJS@
...@@ -185,6 +187,8 @@ LIBTOOL = @LIBTOOL@ ...@@ -185,6 +187,8 @@ LIBTOOL = @LIBTOOL@
LIPO = @LIPO@ LIPO = @LIPO@
LN_S = @LN_S@ LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@ LTLIBOBJS = @LTLIBOBJS@
MAIN_CFLAGS = @MAIN_CFLAGS@
MAIN_LIBS = @MAIN_LIBS@
MAKEINFO = @MAKEINFO@ MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@ MKDIR_P = @MKDIR_P@
NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@ NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@
......
...@@ -259,6 +259,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ ...@@ -259,6 +259,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@ LD = @LD@
LDFLAGS = @LDFLAGS@ LDFLAGS = @LDFLAGS@
LIBCRYSTFEL_CFLAGS = @LIBCRYSTFEL_CFLAGS@
LIBCRYSTFEL_LIBS = @LIBCRYSTFEL_LIBS@
LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@ LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@
LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@ LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@
LIBOBJS = @LIBOBJS@ LIBOBJS = @LIBOBJS@
...@@ -267,6 +269,8 @@ LIBTOOL = @LIBTOOL@ ...@@ -267,6 +269,8 @@ LIBTOOL = @LIBTOOL@
LIPO = @LIPO@ LIPO = @LIPO@
LN_S = @LN_S@ LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@ LTLIBOBJS = @LTLIBOBJS@
MAIN_CFLAGS = @MAIN_CFLAGS@
MAIN_LIBS = @MAIN_LIBS@
MAKEINFO = @MAKEINFO@ MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@ MKDIR_P = @MKDIR_P@
NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@ NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@
......
lib_LTLIBRARIES = libcrystfel.la lib_LTLIBRARIES = libcrystfel.la
LDADD = $(top_builddir)/lib/libgnu.a @IGNORE_UNUSED_LIBRARIES_CFLAGS@ LDADD = $(top_builddir)/lib/libgnu.a @LIBCRYSTFEL_LIBS@
libcrystfel_la_SOURCES = src/reflist.c src/utils.c src/cell.c src/detector.c \ libcrystfel_la_SOURCES = src/reflist.c src/utils.c src/cell.c src/detector.c \
src/thread-pool.c src/image.c src/hdf5-file.c \ src/thread-pool.c src/image.c src/hdf5-file.c \
...@@ -21,4 +21,4 @@ libcrystfel_la_include_HEADERS = src/beam-parameters.h src/hdf5-file.h \ ...@@ -21,4 +21,4 @@ libcrystfel_la_include_HEADERS = src/beam-parameters.h src/hdf5-file.h \
INCLUDES = "-I$(top_srcdir)/data" INCLUDES = "-I$(top_srcdir)/data"
AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib
AM_CPPFLAGS += -I$(top_srcdir)/lib AM_CPPFLAGS += -I$(top_srcdir)/lib @LIBCRYSTFEL_CFLAGS@
...@@ -232,6 +232,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ ...@@ -232,6 +232,8 @@ INSTALL_SCRIPT = @INSTALL_SCRIPT@
INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
LD = @LD@ LD = @LD@
LDFLAGS = @LDFLAGS@ LDFLAGS = @LDFLAGS@
LIBCRYSTFEL_CFLAGS = @LIBCRYSTFEL_CFLAGS@
LIBCRYSTFEL_LIBS = @LIBCRYSTFEL_LIBS@
LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@ LIBGNU_LIBDEPS = @LIBGNU_LIBDEPS@
LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@ LIBGNU_LTLIBDEPS = @LIBGNU_LTLIBDEPS@
LIBOBJS = @LIBOBJS@ LIBOBJS = @LIBOBJS@
...@@ -240,6 +242,8 @@ LIBTOOL = @LIBTOOL@ ...@@ -240,6 +242,8 @@ LIBTOOL = @LIBTOOL@
LIPO = @LIPO@ LIPO = @LIPO@
LN_S = @LN_S@ LN_S = @LN_S@
LTLIBOBJS = @LTLIBOBJS@ LTLIBOBJS = @LTLIBOBJS@
MAIN_CFLAGS = @MAIN_CFLAGS@
MAIN_LIBS = @MAIN_LIBS@
MAKEINFO = @MAKEINFO@ MAKEINFO = @MAKEINFO@
MKDIR_P = @MKDIR_P@ MKDIR_P = @MKDIR_P@
NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@ NEXT_AS_FIRST_DIRECTIVE_STDDEF_H = @NEXT_AS_FIRST_DIRECTIVE_STDDEF_H@
...@@ -346,7 +350,7 @@ top_build_prefix = @top_build_prefix@ ...@@ -346,7 +350,7 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@ top_builddir = @top_builddir@
top_srcdir = @top_srcdir@ top_srcdir = @top_srcdir@
lib_LTLIBRARIES = libcrystfel.la lib_LTLIBRARIES = libcrystfel.la
LDADD = $(top_builddir)/lib/libgnu.a @IGNORE_UNUSED_LIBRARIES_CFLAGS@ LDADD = $(top_builddir)/lib/libgnu.a @LIBCRYSTFEL_LIBS@
libcrystfel_la_SOURCES = src/reflist.c src/utils.c src/cell.c src/detector.c \ libcrystfel_la_SOURCES = src/reflist.c src/utils.c src/cell.c src/detector.c \
src/thread-pool.c src/image.c src/hdf5-file.c \ src/thread-pool.c src/image.c src/hdf5-file.c \
src/beam-parameters.c src/geometry.c src/statistics.c \ src/beam-parameters.c src/geometry.c src/statistics.c \
...@@ -366,7 +370,7 @@ libcrystfel_la_include_HEADERS = src/beam-parameters.h src/hdf5-file.h \ ...@@ -366,7 +370,7 @@ libcrystfel_la_include_HEADERS = src/beam-parameters.h src/hdf5-file.h \
INCLUDES = "-I$(top_srcdir)/data" INCLUDES = "-I$(top_srcdir)/data"
AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib \ AM_CPPFLAGS = -DDATADIR=\""$(datadir)"\" -I$(top_builddir)/lib \
-I$(top_srcdir)/lib -I$(top_srcdir)/lib @LIBCRYSTFEL_CFLAGS@
all: all-am all: all-am
.SUFFIXES: .SUFFIXES:
......
...@@ -138,7 +138,7 @@ lock_old_archive_extraction=no ...@@ -138,7 +138,7 @@ lock_old_archive_extraction=no
LTCC="gcc" LTCC="gcc"
# LTCC compiler flags. # LTCC compiler flags.
LTCFLAGS="-g -O2 -I/usr/local/cuda/include -pthread -pthread -I/usr/include/gtk-2.0 -I/usr/lib64/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -D_GNU_SOURCE -I/usr/include/libpng12 -pthread -I/usr/include/cairo -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -pthread -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng12 -I/usr/include/glib-2.0 -I/usr/lib64/glib-2.0/include " LTCFLAGS="-g -O2"
# Take the output of nm and produce a listing of raw symbols and C names. # Take the output of nm and produce a listing of raw symbols and C names.
global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'" global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[ ][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment