• Welcome to Vampyre Imaging Library Forum. Please login or sign up.
 

[help] Using the library with lazarus on linux

Started by Alejandro, 21 March 2008, 16:20:20

Previous topic - Next topic

Alejandro

Hi!, ive been using Vampyre Imaging Library with delphi7 on windows and
worked perfect. no i want to migrate my project to linux, so i decided
to use lazarus. i cant compile my project when i use the library. i get

"project1.lpr(17,1) Error: Error while linking"

i have set on fpc.cfg the following lines

-Fi/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Source
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Source/JpegLib
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Source/ZLib
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Source/Projects
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Source/Extensions
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Source/Wrappers/*
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Demos/ObjectPascal/Common
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Extras/Extensions
-Fl/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Extras/Extensions/J2KObjects
-Fu/home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Extras/Extensions/LibTiff

-Sgi2dh

if i run ./BuildLibraryFPC.sh i get:

Building libVampyreImaging.so using Free Pascal
Warning: You are using the obsolete switch -OG
Free Pascal Compiler version 2.2.0 [2007/08/30] for i386
Copyright (c) 1993-2007 by Florian Klaempfl
Target OS: Linux for i386
Compiling ../Source/Projects/VampyreImaging.dpr
Compiling /home/alejandro/G_IMAGE_X_1.3_linux/Imaging/Source/ImagingExport.pas
Linking ../Bin/VampyreImaging.so
/usr/bin/ld: cannot find -lstdc++
Error: Error while linking
Fatal: There were 1 errors compiling module, stopping
Fatal: Compilation aborted
Error: /usr/bin/ppc386 returned an error exitcode (normal if you did not
specify a source file to be compiled)
Error when building library!


i have tried the same configuration (fpc.cfg) on windows with lazarus
and it worked perfect! can you please help me?  i cant make it work and
i want to use this great library

Thanks!

Galfar

Looks like linker could not find stdc++ library (/usr/bin/ld: cannot find -lstdc++).
I have mine in /usr/lib so try to add it to your FPC library search path (-Fl) in fpc.cfg.

This library is used by JPEG 2000 only so if you don't need support for this format you can disable it in ImagingExtras.pas unit.

Alejandro

Thanks man! i have disabled the JPEG 2000 extension and it worked perfect. if i later have to use it ill check it out how to include it, but at least i know where the problem is.

Thanks a lot for the quick response, the library is great! regards from Argentina
see you

Quick Reply

With Quick-Reply you can write a post when viewing a topic without loading a new page. You can still use bulletin board code and smileys as you would in a normal post.

Name:
Email:

Shortcuts: ALT+S save/post or ALT+P preview

SMF spam blocked by CleanTalk