Skip to content

Commit

Permalink
Quiet pkgconfig warnings?
Browse files Browse the repository at this point in the history
  • Loading branch information
pramsey committed Mar 26, 2019
1 parent f918d00 commit 55b26f6
Showing 1 changed file with 31 additions and 3 deletions.
34 changes: 31 additions & 3 deletions ogr_fdw_gdal.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,34 @@
#ifndef _OGR_FDW_GDAL_H
#define _OGR_FDW_GDAL_H 1

/*
* Quiet warnings due to double use of
* pkgconfig macros in GDAL and PgSQL
*/
#ifdef PACKAGE_VERSION
#undef PACKAGE_VERSION
#endif

#ifdef PACKAGE_TARNAME
#undef PACKAGE_TARNAME
#endif

#ifdef PACKAGE_STRING
#undef PACKAGE_STRING
#endif

#ifdef PACKAGE_NAME
#undef PACKAGE_NAME
#endif

#ifdef PACKAGE_BUGREPORT
#undef PACKAGE_BUGREPORT
#endif

#ifdef PACKAGE_VERSION
#undef PACKAGE_VERSION
#endif

/*
* OGR library API
*/
Expand All @@ -11,11 +39,11 @@
#include "cpl_error.h"
#include "cpl_string.h"

/*
/*
* As far as possible code is GDAL2 compliant, and these
* mappings are used to convert to GDAL1-style function
* names. For GDALDatasetH opening, there are specific
* code blocks to handle version differences between
* code blocks to handle version differences between
* GDALOpenEx() and OGROpen()
*/
#if GDAL_VERSION_MAJOR < 2
Expand All @@ -39,4 +67,4 @@

#endif /* GDAL 1 support */

#endif /* _OGR_FDW_GDAL_H */
#endif /* _OGR_FDW_GDAL_H */

0 comments on commit 55b26f6

Please sign in to comment.