Geany Compler Errors

New to FreeBASIC? Post your questions here.
Post Reply
Mike Green9
Posts: 17
Joined: Jan 05, 2021 20:43
Location: 1000 Islands, Ontario, Canada

Geany Compler Errors

Post by Mike Green9 »

Ubuntu 20.04, FreeBasic V1.07, Geany 1.36

Hi.

Whenever Geany Compiles a program with either of these statements:

WindowTitle’ or ‘Screen’ or ‘#include “fbgfx.bi”’

the compiler says:
ld: cannot find -lXpm
ld: cannot find -lXander
ld: cannot find -lXrendend

What am I missing?

Thanks,
M….
dodicat
Posts: 7983
Joined: Jan 10, 2006 20:30
Location: Scotland

Re: Geany Compler Errors

Post by dodicat »

I think you'll need to get them from your repository.
Here are the first few lines of fbgfx.bi

Code: Select all

#ifndef __fbgfx_bi__
#define __fbgfx_bi__

#inclib "fbgfx"
#ifdef __FB_WIN32__
	#inclib "gdi32"
	#inclib "winmm"
	#inclib "user32"
#elseif defined(__FB_LINUX__)
	#libpath "/usr/X11R6/lib"
	#inclib "X11"
	#inclib "Xext"
	#inclib "Xpm"
	#inclib "Xrandr"
	#inclib "Xrender"
	#inclib "pthread"
#endif
 
Every Linux distro I have used, I had to do this, but I use Windows these days.
There are some regular Linux users here, perhaps they will elaborate.
badidea
Posts: 2591
Joined: May 24, 2007 22:10
Location: The Netherlands

Re: Geany Compler Errors

Post by badidea »

It is not Geany that does the compilation. That is done by the freebasic compiler (fbc), called by Geany.
The needed libraries are listed in the first topic in the linux section on this forum (https://freebasic.net/forum/viewforum.php?f=5), in the readme.txt shipped with freebasic (https://github.com/freebasic/fbc/blob/master/readme.txt) and on the wiki (https://freebasic.net/wiki/CompilerInstalling).
Mike Green9
Posts: 17
Joined: Jan 05, 2021 20:43
Location: 1000 Islands, Ontario, Canada

Re: Geany Compler Errors

Post by Mike Green9 »

Hi and thanks.

This did it:

sudo apt install libx11-dev libxext-dev libxpm-dev libxrender-dev libxrandr-dev

You guys are GREAT!!

M...
Post Reply