diff --git a/src/bitutils.h b/src/bitutils.h index 0be6b71..bbebfd1 100644 --- a/src/bitutils.h +++ b/src/bitutils.h @@ -1,6 +1,12 @@ #ifndef BITUTILS_H #define BITUTILS_H +#include "postgres.h" + +#if PG_VERSION_NUM < 120000 +#error "Requires PostgreSQL 12+" +#endif + /* We use two types of dispatching: intrinsics and target_clones */ /* TODO Move to better place */ #ifndef DISABLE_DISPATCH diff --git a/src/hnsw.h b/src/hnsw.h index 7ec79ce..2f11137 100644 --- a/src/hnsw.h +++ b/src/hnsw.h @@ -12,10 +12,6 @@ #include "utils/sampling.h" #include "vector.h" -#if PG_VERSION_NUM < 120000 -#error "Requires PostgreSQL 12+" -#endif - #define HNSW_MAX_DIM 2000 #define HNSW_MAX_NNZ 1000