Runtime Enviroment:Open SUSE Linux *i385

Notice:if any command disavliable ,you can copy the parameters in to the terminal then press enter to continue your configure.

1、 Download the package :GDAL-1.9.2.tar.zg and PROJ-4.7.0.tar.zg in the following URL:

URL: http://download.osgeo.org/gdal/

URL: http://download.osgeo.org/proj/

2、 安装GDAL-1.9.2库,命令如下:

% cd gdal

% ./configure

% make

% su

Password: ********

% make install

% exit

安装成功后,会在/usr/local/include文件夹中产生一系列.h文件(cpl_config.h、gdal.h……),在/usr/local/lib文件夹中产生5个库文件,其中libgdal.a和libgdal.la为静态链接库,libgdal.so, libgdal.so.1, libgdal.so.1.13.2为动态链接库。

3、 安装PROJ-4.7.0库,命令如下:

% cd proj

% ./configure

% make

% su

Password: ********

% make install

% exit

安装成功后,会在/usr/local/include文件夹中产生4个.h文件(nad_list.h,

org_proj4_Projections.h,proj_api.h,projects.h),在/usr/local/lib文件夹中产生5个库文件,其中libproj.a和libproj.la为静态链接库,libproj.so, libproj.so.0, libproj.so.0.6.6为动态链接库。

4、 将/usr/local/lib添加到环境变量中,命令如下:

cd /etc/ld.so.conf.d

touch local.conf

vi local.conf

i

/usr/local/lib

Esc

Wq

Ldconfig -v

5、 将/usr/local/include文件夹copy到当前工程(test)目录下。

6、 test.cpp里面加载必要的头文件就可以使用GDAL和PROJ里面的函数:

#include "./include/gdal.h"

#include "./include/gdal_alg.h"

#include "./include/cpl_conv.h"

#include "./include/cpl_port.h"

#include "./include/cpl_multiproc.h"

#include "./include/ogr_srs_api.h"

#include "./include/proj_api.h"

7、 input the following command line to debug test.cpp:

g++ test.cpp –lgdal –lproj –o TEST

./TEST

8、The end.

Install GDAL in OpenSUSE 12.3 Linux的更多相关文章

  1. linux pip install gdal apyt-get install libgdal-dev export cplus_path=/usr/include/gdal export c_path=/usr/include/gdal

    apt-get install libgdal-dev pip install gdal

  2. 12个 Linux 中 grep 命令的超级用法实例

    12个 Linux 中 grep 命令的超级用法实例 你是否遇到过需要在文件中查找一个特定的字符串或者样式,但是不知道从哪儿开始?那么,就请grep来帮你吧. grep是每个Linux发行版都预装的一 ...

  3. 12个Linux进程管理命令介绍(转)

    12个Linux进程管理命令介绍 [日期:2015-06-02] 来源:Linux中国  作者:Linux [字体:大 中 小]   执行中的程序在称作进程.当程序以可执行文件存放在存储中,并且运行的 ...

  4. Install pyodbc in OpenSUSE

    Install pyodbc in OpenSUSE: Install unixODBC-2.3.2 ./configure --prefix=/usr/local/unixODBC --enable ...

  5. How to install JDK (Java Development Kit) on Linux

    This tutorial will guide you on how to install JDK (Java Development Kit) on Linux. Since I use Cent ...

  6. 玩转12款Linux开源机器人

    玩转12款Linux开源机器人 头条网2016-02-15 09:04 3DR Solo智能无人机发布于2015年中期.作为试图与大疆广受欢迎的Phantom系列无人机相抗衡的产品,它的双处理器运行L ...

  7. 实用推荐:12款Linux系统恢复工具

    12款Linux系统恢复工具 电脑死机,系统崩溃,总会给电脑使用者带来一定的损失.你是否不小心删除你的纪念图片?安装新系统时候,擦除了分区表?无法读取旧CD里面的数据?别急嘛-我们将会给您推荐一些免费 ...

  8. ./configure && make && make install 编译安装和卸载 (Linux)

    ./configure && make && make install 编译安装和卸载 (Linux) 正常的编译安装/卸载:   源码的安装一般由3个步骤组成:配置( ...

  9. oracle 12.2 linux/solaris正式发布

    oracle 12.2 linux/solaris正式发布,可以从http://www.oracle.com/technetwork/database/enterprise-edition/downl ...

随机推荐

  1. Matlab程序怎样打包

    本人安装的版本号是MATLAB(R2010b) 打包过程例如以下: MATLAB命令窗体输入deploytool,打开一个Eeployment Project的窗体: 1.在Name输入你想要打包后的 ...

  2. 对javascript this的理解

    对于this的理解,大部分时间都比较模糊,最近几天做了一些研究,记录一下 首先应该明白,this是执行上下文的一个属性,它的值取决于执行上下文,执行上下文和函数调用方式相关,定义一个function的 ...

  3. MySQL执行SHOW STATUS查询服务器状态状态之Handler_read_* 详解

    在MySQL里,我们一般使用SHOW STATUS查询服务器状态,语法一般来说如下: SHOW [GLOBAL | SESSION] STATUS [LIKE ‘pattern’ | WHERE ex ...

  4. linux 文件系统的管理 (硬盘) 工作原理

    一.系统在初始化时如何识别硬盘 1.系统初始时根据MBR的信息来识别硬盘,其中包括了一些执行文件就来载入系统,这些执行文件就是MBR里前面446bytes里的boot loader 程式,而后面的16 ...

  5. linux 安装svn最新版本

    一.安装svn yum install -y subversion-* 结果为Complete就为正确 查看svn版本号 svnserve --version 1.6.11版本 mkdir /opt/ ...

  6. iOS本机生成证书请求文件流程

    第一步:苹果机上打开“Finder”,选择“应用程序”,双击打开“实用工具” 第二步:在“实用工具”中,选“择钥匙串访问”,双击打开 第三步: “钥匙串访问”打开,看到如下页面 第四步:选择菜单中“钥 ...

  7. WPF 之 style文件的引用

    总结一下WPF中Style样式的引用方法. 一.内联样式: 直接设置控件的Height.Width.Foreground.HorizontalAlignment.VerticalAlignment等属 ...

  8. Spring mvc编码配置

    Spring3 MVC也带有自己的编码: jar包:org.springframework.web-3.0.0.RELEASE.jar 只需要在web.xml配置即可: <!-- spring ...

  9. How do you render tooltip on disabled HTML Button

    This idea's based on the following (x)html: <form><fieldset><buttondisabledtitle=&quo ...

  10. Html方式导出word 页头和页脚设置

    <html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:o ...