当前位置: 代码迷 >> GIS >> Linux下怎么使用gdal库开发
  详细解决方案

Linux下怎么使用gdal库开发

热度:735   发布时间:2016-05-05 06:41:26.0
Linux下如何使用gdal库开发?
开发环境是ubuntu。
代码里面用到gdal库读写图像文件。
make的时候,出现一堆
main.cpp:(.text+0x71): undefined reference to `GDALAllRegister'
main.cpp:(.text+0x81): undefined reference to `GDALOpen'
main.cpp:(.text+0x97): undefined reference to `GDALDataset::GetRasterCount()'
main.cpp:(.text+0xa5): undefined reference to `GDALDataset::GetRasterXSize()'
main.cpp:(.text+0xb3): undefined reference to `GDALDataset::GetRasterYSize()'
main.cpp:(.text+0xf1): undefined reference to `GDALDataset::GetRasterBand(int)
这样的错误。
应该是没有找到头文件所致。
我在windows下面编译正常。
gdal在linux下也通过congfigure,make,make install安装正常。
是否在编译自己利用gdal库开发的程序的时候需要设置什么?在哪里设?

------解决方案--------------------
对linux不熟
官网上有说明或教程的吧