Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Add ACCEPT_USE_OF_DEPRECATED_PROJ_API_H macro for proj_api.h to work …
…with new release of proj4.
  • Loading branch information
swiss-knight authored and nyalldawson committed Nov 26, 2018
1 parent 9635c2a commit 6a7e951
Show file tree
Hide file tree
Showing 6 changed files with 19 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/app/qgisapp.cpp
Expand Up @@ -344,6 +344,9 @@ Q_GUI_EXPORT extern int qt_defaultDpiX();
#ifdef PROJ_HAS_INFO
#include <proj.h>
#endif
#ifndef ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#define ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#endif
#include <proj_api.h>

//
Expand Down
3 changes: 3 additions & 0 deletions src/app/qgscustomprojectiondialog.cpp
Expand Up @@ -40,6 +40,9 @@
//proj4 includes
extern "C"
{
#ifndef ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#define ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#endif
#include <proj_api.h>
}

Expand Down
4 changes: 4 additions & 0 deletions src/core/qgscoordinatereferencesystem.cpp
Expand Up @@ -38,6 +38,9 @@
#include "qgssettings.h"

#include <sqlite3.h>
#ifndef ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#define ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#endif
#include <proj_api.h>

//gdal and ogr includes (needed for == operator)
Expand All @@ -46,6 +49,7 @@
#include <cpl_conv.h>
#include <cpl_csv.h>


//! The length of the string "+lat_1="
const int LAT_PREFIX_LEN = 7;

Expand Down
3 changes: 3 additions & 0 deletions src/core/qgscoordinatetransform.cpp
Expand Up @@ -34,6 +34,9 @@

extern "C"
{
#ifndef ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#define ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#endif
#include <proj_api.h>
}
#include <sqlite3.h>
Expand Down
3 changes: 3 additions & 0 deletions src/core/qgscoordinatetransform_p.cpp
Expand Up @@ -21,6 +21,9 @@

extern "C"
{
#ifndef ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#define ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#endif
#include <proj_api.h>
}
#include <sqlite3.h>
Expand Down
3 changes: 3 additions & 0 deletions tests/src/core/testqgscoordinatereferencesystem.cpp
Expand Up @@ -24,6 +24,9 @@ Email : sherman at mrcc dot com
#include "qgsvectorlayer.h"
#include "qgsproject.h"

#ifndef ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#define ACCEPT_USE_OF_DEPRECATED_PROJ_API_H
#endif
#include <proj_api.h>
#include <gdal.h>
#include <cpl_conv.h>
Expand Down

0 comments on commit 6a7e951

Please sign in to comment.