Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#3631 closed task (invalid)

Undefined GDAL references on compile

Reported by: firani41 Owned by: warmerdam
Priority: normal Milestone:
Component: ConfigBuild Version: 1.7.1
Severity: normal Keywords:
Cc:

Description

I'm attempting to compile and link an example from: http://www.gdal.org/gdal_tutorial.html using g++ test.cpp >& fmistderr Strange: Compiler seems to recognize GDALDataset but not GDALAllRegister or GDALOpen (see attached files.)

Anyway, I am a very new user: Managed to build and install GDAL, but now trying to incorporate I/O into existing C and C++ code.

Is there something very basic that I'm missing here?

Attachments (2)

fmistderr (212 bytes ) - added by firani41 14 years ago.
test.cpp (210 bytes ) - added by firani41 14 years ago.

Download all attachments as: .zip

Change History (5)

by firani41, 14 years ago

Attachment: fmistderr added

by firani41, 14 years ago

Attachment: test.cpp added

comment:1 by firani41, 14 years ago

Version: unspecified1.7.1

comment:2 by Even Rouault, 14 years ago

Resolution: invalid
Status: newclosed

Please do not use Trac for such basic questions about how to use GDAL. They belong to the mailing list.

It seems that you didn't link to the GDAL library. Add -L/path/to/gdal/lib -lgdal to your command line

comment:3 by warmerdam, 14 years ago

Component: defaultConfigBuild
Note: See TracTickets for help on using tickets.