添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement . We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expected behavior and actual behavior.

I expected to be able to compel gdal 3.0 with vs2015 by nmake(I set PROJ_INCLUDE and PROJ_LIBRARY path in nmake.opt already), but I get this:

cl: 命令行 warning D9024 :无法识别的源文件类型“D:\OSGeo4W\include”,假定为对象文件
cl: 命令行 warning D9027 :源文件“D:\OSGeo4W\include”被忽略
cl: 命令行 warning D9024 :无法识别的源文件类型“D:\OSGeo4W\include”,假定为对象文件
cl: 命令行 warning D9024 :无法识别的源文件类型“D:\OSGeo4W\include”,假定为对象文件
cl: 命令行 warning D9027 :源文件“D:\OSGeo4W\include”被忽略
cl: 命令行 warning D9027 :源文件“D:\OSGeo4W\include”被忽略
gdalapplyverticalshiftgrid.cpp
f:\opensourceproject\gdal-3.0.0\alg\gdalapplyverticalshiftgrid.cpp(39): fatal error C1083: 无法打开包括文件: “proj.h”: No such file or directory

Does anyone know what is going on or who can tell me where the problem is if I'm doing wrong?

Thank you very much.

Steps to reproduce the problem.

gdal-3.0.0\alg\gdalapplyverticalshiftgrid.cpp(39)

Operating system

Win 10 64 bit

GDAL version and provenance

The 3.0.0 version from https://gdal.org/download.html

You need to build against PROJ 6, which OSGeo4W delivers in \apps\proj-dev subdirectory of its install

Yeah, I know and I have built it. The version is proj-6.1.0 from https://proj.org/download.html.

Do you have any clue?

You need to build against PROJ 6, which OSGeo4W delivers in \apps\proj-dev subdirectory of its install

Yeah, I know and I have built it. The version is proj-6.1.0 from https://proj.org/download.html.

Do you have any clue?

你要先编译PROJ,然后修改gdal里面的nmake.opt文件,将里面的proj的路径改成你编译的proj的路径。

You need to build against PROJ 6, which OSGeo4W delivers in \apps\proj-dev subdirectory of its install

Yeah, I know and I have built it. The version is proj-6.1.0 from https://proj.org/download.html.
Do you have any clue?

你要先编译PROJ,然后修改gdal里面的nmake.opt文件,将里面的proj的路径改成你编译的proj的路径。

# PROJ stuff (required dependency: PROJ >= 6)
PROJ_INCLUDE = "F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\include"
PROJ_LIBRARY = "F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\lib\proj_6_2.lib"

我这样修改之后还是报错

cl: 命令行 warning D9024 :无法识别的源文件类型“F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\include”,假定为对象文件
cl: 命令行 warning D9027 :源文件“F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\include”被忽略
cl: 命令行 warning D9024 :无法识别的源文件类型“F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\include”,假定为对象文件
cl: 命令行 warning D9024 :无法识别的源文件类型“F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\include”,假定为对象文件
cl: 命令行 warning D9027 :源文件“F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\include”被忽略
cl: 命令行 warning D9027 :源文件“F:\02_Projects\03_osgearth2.10.1VS2017X64\03_proj\include”被忽略
gdalapplyverticalshiftgrid.cpp
f:\02_projects\03_osgearth2.10.1vs2017x64\00_sourcecodes\gdal301\alg\gdalapplyverticalshiftgrid.cpp(39): fatal error C1083: 无法打开包括文件: “proj.h”: No such file or directory
NMAKE : fatal error U1077: “"D:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64\cl.EXE"”: 返回代码“0x2”
Stop.
NMAKE : fatal error U1077: “"D:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\HostX64\x64\nmake.EXE"”: 返回代码“0x2”
Stop.