diff options
author | Thomas White <taw@physics.org> | 2020-07-27 15:44:40 +0200 |
---|---|---|
committer | Thomas White <taw@physics.org> | 2020-07-29 18:53:45 +0200 |
commit | 55df542018664cb519e846b4db63281867be24a0 (patch) | |
tree | fb2ad88c854aed521618afc676fe35ead4231f39 /libcrystfel/src | |
parent | 7680ae24a77a48ae8ebe025a9f6fc3564aa744a7 (diff) |
Remove config.h from libcrystfel headers
Same reason as removing them from tests. Also, libcrystfel might be
used in projects which have HAVE_CONFIG_H defined.
Diffstat (limited to 'libcrystfel/src')
33 files changed, 31 insertions, 166 deletions
diff --git a/libcrystfel/src/asdf.c b/libcrystfel/src/asdf.c index 7185172d..e583aae3 100644 --- a/libcrystfel/src/asdf.c +++ b/libcrystfel/src/asdf.c @@ -55,6 +55,8 @@ * \file asdf.h */ +#ifdef HAVE_FFTW + struct fftw_vars { int N; fftw_plan p; @@ -1200,3 +1202,32 @@ const char *asdf_probe(UnitCell *cell) { return "asdf"; } + +#else /* HAVE_FFTW */ + +int run_asdf(struct image *image, void *ipriv) +{ + ERROR("This copy of CrystFEL was compiled without FFTW support.\n"); + return 0; +} + + +void *asdf_prepare(IndexingMethod *indm, UnitCell *cell) +{ + ERROR("This copy of CrystFEL was compiled without FFTW support.\n"); + ERROR("To use asdf indexing, recompile with FFTW.\n"); + return NULL; +} + + +const char *asdf_probe(UnitCell *cell) +{ + return NULL; +} + + +void asdf_cleanup(void *pp) +{ +} + +#endif /* HAVE_FFTW */ diff --git a/libcrystfel/src/asdf.h b/libcrystfel/src/asdf.h index d900c192..b3ccffcc 100644 --- a/libcrystfel/src/asdf.h +++ b/libcrystfel/src/asdf.h @@ -31,10 +31,6 @@ #ifndef ASDF_H #define ASDF_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "index.h" #ifdef __cplusplus @@ -46,8 +42,6 @@ extern "C" { * The ASDF indexing algorithm. */ -#ifdef HAVE_FFTW - extern int run_asdf(struct image *image, void *ipriv); extern void *asdf_prepare(IndexingMethod *indm, UnitCell *cell); @@ -55,37 +49,6 @@ extern const char *asdf_probe(UnitCell *cell); extern void asdf_cleanup(void *pp); -#else /* HAVE_FFTW */ - -int run_asdf(struct image *image, void *ipriv) -{ - ERROR("This copy of CrystFEL was compiled without FFTW support.\n"); - return 0; -} - - -void *asdf_prepare(IndexingMethod *indm, UnitCell *cell) -{ - ERROR("This copy of CrystFEL was compiled without FFTW support.\n"); - ERROR("To use asdf indexing, recompile with FFTW.\n"); - return NULL; -} - - -const char *asdf_probe(UnitCell *cell) -{ - return NULL; -} - - -void asdf_cleanup(void *pp) -{ -} - - -#endif /* HAVE_FFTW */ - - #ifdef __cplusplus } #endif diff --git a/libcrystfel/src/cell-utils.h b/libcrystfel/src/cell-utils.h index e98c8da2..00563ee6 100644 --- a/libcrystfel/src/cell-utils.h +++ b/libcrystfel/src/cell-utils.h @@ -31,10 +31,6 @@ #ifndef CELL_UTILS_H #define CELL_UTILS_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <gsl/gsl_matrix.h> #include "cell.h" diff --git a/libcrystfel/src/cell.h b/libcrystfel/src/cell.h index d201d059..bf5d689c 100644 --- a/libcrystfel/src/cell.h +++ b/libcrystfel/src/cell.h @@ -33,10 +33,6 @@ #ifndef CELL_H #define CELL_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "utils.h" #include "integer_matrix.h" diff --git a/libcrystfel/src/colscale.h b/libcrystfel/src/colscale.h index 7fec2154..21a24356 100644 --- a/libcrystfel/src/colscale.h +++ b/libcrystfel/src/colscale.h @@ -26,10 +26,6 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #ifndef COLSCALE_H #define COLSCALE_H diff --git a/libcrystfel/src/crystal.h b/libcrystfel/src/crystal.h index 592a4b43..209cf211 100644 --- a/libcrystfel/src/crystal.h +++ b/libcrystfel/src/crystal.h @@ -30,11 +30,6 @@ #ifndef CRYSTAL_H #define CRYSTAL_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - - #include "cell.h" /** diff --git a/libcrystfel/src/datatemplate.h b/libcrystfel/src/datatemplate.h index 939572e2..c6054409 100644 --- a/libcrystfel/src/datatemplate.h +++ b/libcrystfel/src/datatemplate.h @@ -29,10 +29,6 @@ #ifndef DATATEMPLATE_H #define DATATEMPLATE_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "detgeom.h" /** diff --git a/libcrystfel/src/detgeom.h b/libcrystfel/src/detgeom.h index 19fa9019..99355a38 100644 --- a/libcrystfel/src/detgeom.h +++ b/libcrystfel/src/detgeom.h @@ -30,10 +30,6 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #ifndef DETGEOM_H #define DETGEOM_H diff --git a/libcrystfel/src/dirax.h b/libcrystfel/src/dirax.h index 33dc1189..da4ae3d5 100644 --- a/libcrystfel/src/dirax.h +++ b/libcrystfel/src/dirax.h @@ -29,10 +29,6 @@ #ifndef DIRAX_H #define DIRAX_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "index.h" #ifdef __cplusplus diff --git a/libcrystfel/src/felix.h b/libcrystfel/src/felix.h index 4a992548..f7e4d26a 100644 --- a/libcrystfel/src/felix.h +++ b/libcrystfel/src/felix.h @@ -30,10 +30,6 @@ #ifndef FELIX_H #define FELIX_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <argp.h> #include "cell.h" diff --git a/libcrystfel/src/filters.h b/libcrystfel/src/filters.h index 17c235b1..b3e3d609 100644 --- a/libcrystfel/src/filters.h +++ b/libcrystfel/src/filters.h @@ -29,10 +29,6 @@ #ifndef FILTERS_H #define FILTERS_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #ifdef __cplusplus extern "C" { #endif diff --git a/libcrystfel/src/geometry.h b/libcrystfel/src/geometry.h index eb991a27..0e369860 100644 --- a/libcrystfel/src/geometry.h +++ b/libcrystfel/src/geometry.h @@ -31,11 +31,6 @@ #ifndef GEOMETRY_H #define GEOMETRY_H - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "reflist.h" #include "cell.h" #include "crystal.h" diff --git a/libcrystfel/src/image-cbf.h b/libcrystfel/src/image-cbf.h index bfcbe6d2..a355ea23 100644 --- a/libcrystfel/src/image-cbf.h +++ b/libcrystfel/src/image-cbf.h @@ -26,10 +26,6 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - /* NB This file is NOT part of the public API, and should NOT * be installed, but rather stays in the libcrystfel source folder. */ diff --git a/libcrystfel/src/image-hdf5.h b/libcrystfel/src/image-hdf5.h index 05f87858..07cdf96e 100644 --- a/libcrystfel/src/image-hdf5.h +++ b/libcrystfel/src/image-hdf5.h @@ -26,10 +26,6 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - /* NB This file is NOT part of the public API, and should NOT * be installed, but rather stays in the libcrystfel source folder. */ diff --git a/libcrystfel/src/image-msgpack.h b/libcrystfel/src/image-msgpack.h index 5321b06c..9ad80884 100644 --- a/libcrystfel/src/image-msgpack.h +++ b/libcrystfel/src/image-msgpack.h @@ -26,10 +26,6 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #ifndef IMAGE_MSGPACK_H #define IMAGE_MSGPACK_H diff --git a/libcrystfel/src/image.h b/libcrystfel/src/image.h index 9bb6f1bd..9f88d0e7 100644 --- a/libcrystfel/src/image.h +++ b/libcrystfel/src/image.h @@ -28,10 +28,6 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #ifndef IMAGE_H #define IMAGE_H diff --git a/libcrystfel/src/index.h b/libcrystfel/src/index.h index 3331a4ef..58fe64b7 100644 --- a/libcrystfel/src/index.h +++ b/libcrystfel/src/index.h @@ -34,10 +34,6 @@ #ifndef INDEX_H #define INDEX_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - /** * \file index.h * The indexing subsystem diff --git a/libcrystfel/src/integer_matrix.h b/libcrystfel/src/integer_matrix.h index 024480c3..66b3fb4c 100644 --- a/libcrystfel/src/integer_matrix.h +++ b/libcrystfel/src/integer_matrix.h @@ -29,10 +29,6 @@ #ifndef INTEGER_MATRIX_H #define INTEGER_MATRIX_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - /** * \file integer_matrix.h * Matrix type containing only integers diff --git a/libcrystfel/src/integration.h b/libcrystfel/src/integration.h index 11e67dbe..629cd9ee 100644 --- a/libcrystfel/src/integration.h +++ b/libcrystfel/src/integration.h @@ -29,10 +29,6 @@ #ifndef INTEGRATION_H #define INTEGRATION_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "geometry.h" /** diff --git a/libcrystfel/src/mosflm.h b/libcrystfel/src/mosflm.h index b6d708f5..9e956066 100644 --- a/libcrystfel/src/mosflm.h +++ b/libcrystfel/src/mosflm.h @@ -31,10 +31,6 @@ #ifndef MOSFLM_H #define MOSFLM_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "index.h" #ifdef __cplusplus diff --git a/libcrystfel/src/peaks.h b/libcrystfel/src/peaks.h index 1b949e31..ad4d5705 100644 --- a/libcrystfel/src/peaks.h +++ b/libcrystfel/src/peaks.h @@ -31,10 +31,6 @@ #ifndef PEAKS_H #define PEAKS_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <pthread.h> #include "reflist.h" diff --git a/libcrystfel/src/pinkindexer.h b/libcrystfel/src/pinkindexer.h index 9d3e2496..83e879db 100644 --- a/libcrystfel/src/pinkindexer.h +++ b/libcrystfel/src/pinkindexer.h @@ -29,10 +29,6 @@ #ifndef LIBCRYSTFEL_SRC_PINKINDEXER_H_ #define LIBCRYSTFEL_SRC_PINKINDEXER_H_ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - typedef struct pinkIndexer_options PinkIndexerOptions; extern struct argp pinkIndexer_argp; diff --git a/libcrystfel/src/predict-refine.h b/libcrystfel/src/predict-refine.h index 6396df8a..78f0d4f3 100644 --- a/libcrystfel/src/predict-refine.h +++ b/libcrystfel/src/predict-refine.h @@ -29,11 +29,6 @@ #ifndef PREDICT_REFINE_H #define PREDICT_REFINE_H - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "crystal.h" struct image; diff --git a/libcrystfel/src/rational.h b/libcrystfel/src/rational.h index f8aaa537..89b29aa8 100644 --- a/libcrystfel/src/rational.h +++ b/libcrystfel/src/rational.h @@ -29,10 +29,6 @@ #ifndef RATIONAL_H #define RATIONAL_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - /** * \file rational.h * %Rational numbers (including rational matrices) diff --git a/libcrystfel/src/reflist-utils.h b/libcrystfel/src/reflist-utils.h index 9eb21ecb..4830e625 100644 --- a/libcrystfel/src/reflist-utils.h +++ b/libcrystfel/src/reflist-utils.h @@ -27,10 +27,6 @@ * */ -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - /** @cond */ #ifndef REFLIST_UTILS_H #define REFLIST_UTILS_H diff --git a/libcrystfel/src/reflist.h b/libcrystfel/src/reflist.h index 91f740a5..e0b59bff 100644 --- a/libcrystfel/src/reflist.h +++ b/libcrystfel/src/reflist.h @@ -29,10 +29,6 @@ #ifndef REFLIST_H #define REFLIST_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #define SERIAL(h, k, l) ((((h)+512)<<20) + (((k)+512)<<10) + ((l)+512)) #define GET_H(serial) ((((serial) & 0x3ff00000)>>20)-512) #define GET_K(serial) ((((serial) & 0x000ffc00)>>10)-512) diff --git a/libcrystfel/src/spectrum.h b/libcrystfel/src/spectrum.h index 55578974..651f6e2f 100644 --- a/libcrystfel/src/spectrum.h +++ b/libcrystfel/src/spectrum.h @@ -29,10 +29,6 @@ #ifndef SPECTRUM_H #define SPECTRUM_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <gsl/gsl_rng.h> /** diff --git a/libcrystfel/src/stream.h b/libcrystfel/src/stream.h index a575cedb..ab98f3f9 100644 --- a/libcrystfel/src/stream.h +++ b/libcrystfel/src/stream.h @@ -31,10 +31,6 @@ #ifndef STREAM_H #define STREAM_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - /** * \file stream.h * Stream functions (for indexing results) diff --git a/libcrystfel/src/symmetry.h b/libcrystfel/src/symmetry.h index f71cadb9..a8dde9dd 100644 --- a/libcrystfel/src/symmetry.h +++ b/libcrystfel/src/symmetry.h @@ -30,11 +30,6 @@ #ifndef SYMMETRY_H #define SYMMETRY_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - - #include "integer_matrix.h" #include "rational.h" diff --git a/libcrystfel/src/thread-pool.h b/libcrystfel/src/thread-pool.h index a62dd08a..2f159d7c 100644 --- a/libcrystfel/src/thread-pool.h +++ b/libcrystfel/src/thread-pool.h @@ -29,11 +29,6 @@ #ifndef THREAD_POOL_H #define THREAD_POOL_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - - #include <pthread.h> #ifdef __cplusplus diff --git a/libcrystfel/src/utils.h b/libcrystfel/src/utils.h index 04208530..be252672 100644 --- a/libcrystfel/src/utils.h +++ b/libcrystfel/src/utils.h @@ -29,10 +29,6 @@ #ifndef UTILS_H #define UTILS_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <math.h> #include <complex.h> #include <float.h> diff --git a/libcrystfel/src/xds.h b/libcrystfel/src/xds.h index bb96feca..8c4dc6d0 100644 --- a/libcrystfel/src/xds.h +++ b/libcrystfel/src/xds.h @@ -31,10 +31,6 @@ #ifndef XDS_H #define XDS_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include "cell.h" #include "index.h" diff --git a/libcrystfel/src/xgandalf.h b/libcrystfel/src/xgandalf.h index 07fcba01..86294354 100644 --- a/libcrystfel/src/xgandalf.h +++ b/libcrystfel/src/xgandalf.h @@ -29,10 +29,6 @@ #ifndef LIBCRYSTFEL_SRC_XGANDALF_H #define LIBCRYSTFEL_SRC_XGANDALF_H -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - #include <stddef.h> #include <argp.h> |