Podem me ajudar?
Continuo tentando usar um ambiente gráfico que seja compatÃvel para Linux e Windows.
Enquanto tento converter um sistema antigo de Clipper para Harbour, estou criando um exemplo usando HwGui, para teste.
No momento a compilação apresenta a saÃda a seguir com o erro "/usr/bin/ld: cannot find -lgpm"
$ hbmk2 compila.hbp
hbmk2[compila]: Warning: Cannot find hwgui.hbc (referenced from compila.hbp)
Harbour 3.2.0dev (r1712151853)
Copyright (c) 1999-2016, http://harbour-project.org/
Compiling 'main.prg'...
Lines 3657, Functions/Procedures 1
Generating C source output to '/tmp/hbmk_gXGeh9.dir/main.c'... Done.
/usr/bin/ld: cannot find -lgpm
collect2: error: ld returned 1 exit status
hbmk2[compila]: Error: Running linker. 1
gcc '/tmp/hbmk_gXGeh9.dir/main.o' '/tmp/hbmk_gXGeh9.dir/hbmk_o6Ljkd.o' -Wl,--start-group -lhwgui -lm -lhbextern -lhbdebug -lhbvm -lhbrtl -lhblang -lhbcpage -lgtcgi -lgtpca -lgtstd -lgttrm -lhbrdd -lhbuddall -lhbusrrdd -lrddntx -lrddcdx -lrddnsx -lrddfpt -lhbrdd -lhbhsx -lhbsix -lhbmacro -lhbcplr -lhbpp -lhbcommon -lm -ldl -lrt -lhbpcre -lhbzlib -lgpm -Wl,--end-group -static -o'hwgui_test' -L/usr/lib/harbour -L'/home/sergio/workspace/hwgui-code/hwgui/lib'
Seguem mais detalhes:
Arquivo compila.hbp
#
# $Id: compila.hbp $
#
-w0
-gc3
-ohwgui_test
-lhwgui
hwgui.hbc
# Special parameters for LINUX/GTK
{linux}-lm
{linux}-static
{linux}-d__LINUX__
{linux}-d__GTK__
-L/home/sergio/workspace/hwgui-code/hwgui/lib/
-i/home/sergio/workspace/hwgui-code/hwgui/include
main.prg
Arquivo main.prg
#include "hwgui.ch"
Function Main()
Local oMainWnd, oFont
Local aCombo := {"First","Second" }
PREPARE FONT oFont NAME "MS Sans Serif" WIDTH 0 HEIGHT -13
INIT WINDOW oMainWnd TITLE "Example" ;
FONT oFont ;
ON EXIT {||hwg_MsgYesNo("Really want to quit ?")}
@ 20,10 EDITBOX "Hello, World!" SIZE 200,30
@ 270,10 COMBOBOX aCombo SIZE 100, 150 TOOLTIP "Combobox"
@ 120,60 BUTTON "Close" SIZE 150,30 ;
ON CLICK {||oMainWnd:Close()}
MENU OF oMainWnd
MENUITEM "About" ACTION hwg_MsgInfo("First HwGUI Application")
ENDMENU
ACTIVATE WINDOW oMainWnd
hwg_writelog( "Program terminated " + Dtoc(Date()) + " at " + Time() )
RETURN NIL
Se o problema é o arquivo ou lib "gpm" existe um "gpm" aqui:
$ which gpm
/usr/sbin/gpm
Estou no Linux Mint:
$ lsb_release -a
No LSB modules are available.
Distributor ID: Linuxmint
Description: Linux Mint 20
Release: 20
Codename: ulyana
Versões gcc e Harbour:
$ gcc --version
gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ hbmk2 --version
Harbour Make (hbmk2) 3.2.0dev (r2017-12-15 18:53)
Copyright (c) 1999-present, Viktor Szakats
https://github.com/harbour/core/
Obrigado!!