FrontEnd GDB for freebasic
FrontEnd GDB for freebasic
Version 1
Version 2
A simple gui implementation for gdb just for the freebasic programming language.
Linux , Windows
Tested with GDB 8.1.0.
Tested a bit with GDB 10, GDB 11
1 version is very simple (toy)
2 version is a fully functional program
Video clip for version 1 : https://disk.yandex.ru/i/vMZIc9tHPssB2Q
Download
GDB debugger for windows 64-bit can be downloaded from here. Build from source codes myself.
Version 2
A simple gui implementation for gdb just for the freebasic programming language.
Linux , Windows
Tested with GDB 8.1.0.
Tested a bit with GDB 10, GDB 11
1 version is very simple (toy)
2 version is a fully functional program
Video clip for version 1 : https://disk.yandex.ru/i/vMZIc9tHPssB2Q
Download
GDB debugger for windows 64-bit can be downloaded from here. Build from source codes myself.
Last edited by VANYA on Dec 28, 2022 7:25, edited 4 times in total.
Re: FrontEnd GDB for freebasic
Updated. Now works same on the platform Windows 64-bit
If there are problems with finding a debugger under Windows 64-bit, then in the first post of the topic there is a link to download GDB 64-bit
upd:
I forgot to write. If someone is going to build the program from source, update window9 for windows.
If there are problems with finding a debugger under Windows 64-bit, then in the first post of the topic there is a link to download GDB 64-bit
upd:
I forgot to write. If someone is going to build the program from source, update window9 for windows.
-
- Posts: 789
- Joined: Jul 26, 2018 18:28
Re: FrontEnd GDB for freebasic
A very useful program.
Re: FrontEnd GDB for freebasic
Hi All
Tried to compile in Debian and got the following:
Is it compatible with 32 bit Linux ?
Regards
Tried to compile in Debian and got the following:
- FreeBASIC Compiler - Version 1.07.1 (2019-09-27), built for linux-x86 (32bit)
Copyright (C) 2004-2019 The FreeBASIC development team.
target: linux-x86, 486, 32bit
compiling: Debug.bas -o Debug.asm (main module)
/home/dinosaur/FBDebug/declares.bi(1) error 23: File not found, "window9.bi" in '#include Once "window9.bi"'
Is it compatible with 32 bit Linux ?
Regards
Re: FrontEnd GDB for freebasic
Windows9 is the graphical user interface library it uses. According to this page, Windows9 should build on Linux.
Re: FrontEnd GDB for freebasic
The program is only supported on 64-bit platforms. This is indicated in the first post in blue.FreeBASIC Compiler - Version 1.07.1 (2019-09-27), built for linux-x86 (32bit)
Re: FrontEnd GDB for freebasic
Updated. Now the program should also work on windows-32bit, linux-32bit. The first post has been updated. The archive has been updated. Now in the archive:
1) source files
2) LIB folder: (DLL files for windows; * so files for Linux). For Linux 32-bit, the latest version of Scintilla is compiled on Debian 11.1.
3) BIN folder: (EXE files for windows; executable files without extension for Linux).
---- EXE building: windows 7 32-bit , windows 10 64-bit , linux mint 19 x86-64 , linux debian 11.1 (32-bit)
1) source files
2) LIB folder: (DLL files for windows; * so files for Linux). For Linux 32-bit, the latest version of Scintilla is compiled on Debian 11.1.
3) BIN folder: (EXE files for windows; executable files without extension for Linux).
---- EXE building: windows 7 32-bit , windows 10 64-bit , linux mint 19 x86-64 , linux debian 11.1 (32-bit)
Re: FrontEnd GDB for freebasic
Hi All
Linux Debian 10.11 32 bit
Got as far as:
No install candidates for libwebkitgtk-1.0-dev or libwebkitgtk-1.0.0-dev.
The only candidates for installing on Debian are libwebkit2gtk-4.0-dev
What am I missing here ?
Regards
Linux Debian 10.11 32 bit
Got as far as:
Trying to install libwebkitgtk-1.0ld: cannot find -lwebkitgtk-1.0
After install doing a search for libwebkitgtk gets no hits of anything with libwebkitgtk in the name.Note, selecting 'libwebkitgtk-1.0-0' for regex 'libwebkitgtk-1.0'
No install candidates for libwebkitgtk-1.0-dev or libwebkitgtk-1.0.0-dev.
The only candidates for installing on Debian are libwebkit2gtk-4.0-dev
What am I missing here ?
Regards
Re: FrontEnd GDB for freebasic
For debian 10 you need to manually download and install the packages in order of priority:Dinosaur wrote:Hi All
Linux Debian 10.11 32 bit
Got as far as:Trying to install libwebkitgtk-1.0ld: cannot find -lwebkitgtk-1.0After install doing a search for libwebkitgtk gets no hits of anything with libwebkitgtk in the name.Note, selecting 'libwebkitgtk-1.0-0' for regex 'libwebkitgtk-1.0'
No install candidates for libwebkitgtk-1.0-dev or libwebkitgtk-1.0.0-dev.
The only candidates for installing on Debian are libwebkit2gtk-4.0-dev
What am I missing here ?
Regards
1) libhunspell-1.4-0: https://packages.debian.org/stretch/libhunspell-1.4-0
2) libenchant1c2a : https://packages.debian.org/stretch/libenchant1c2a
3) libicu57: https://packages.debian.org/stretch/libicu57
4) libjavascriptcoregtk-1.0-0: https://packages.debian.org/stretch/lib ... egtk-1.0-0
5) libwebkitgtk-1.0-0: https://packages.debian.org/stretch/libwebkitgtk-1.0-0
Debian packages are installed using the dpkg command, for example:
After installation in the folder /usr/lib/i386-linux-gnu/ the file will be located: libwebkitgtk-1.0.so.0.22.17sudo dpkg -i libenchant1c2a_1.6.0-11.1+b1_i386.deb
Go to folder /usr/lib/i386-linux-gnu/ and create a symlink:
sudo ln -s libwebkitgtk-1.0.so.0.22.17 libwebkitgtk-1.0.so
Re: FrontEnd GDB for freebasic
Hi All
Vanya many thanks for the instructions.
I now have no dependency errors.
However lots of undefined references
Any suggestions ?
Regards
Vanya many thanks for the instructions.
I now have no dependency errors.
However lots of undefined references
Code: Select all
fbc -v -R -asm intel -s gui >>Results.txt -w all "Debug.bas" (in directory: /home/dinosaur/FBDebug)
ld: Debug.o: in function `INIT_DEBUGING':
(.text+0x1e7): undefined reference to `DEINIT'
ld: (.text+0x205): undefined reference to `LOAD_FILE'
ld: (.text+0x213): undefined reference to `FILL_GLOBAL_VAR_LISTVIEW'
ld: (.text+0x220): undefined reference to `FILL_PANEL'
ld: (.text+0x2c9): undefined reference to `RESIZE_WIN'
ld: (.text+0x311): undefined reference to `RESIZE_WIN'
ld: Debug.o: in function `main':
(.text+0x3eb): undefined reference to `CREATE_MAIN_DIALOG'
ld: (.text+0x6ad): undefined reference to `OPENFILEREQUESTEREXE'
ld: (.text+0x7d6): undefined reference to `OPENFILEREQUESTEREXE'
ld: (.text+0x8fe): undefined reference to `INFO_GL_VARIABLES_DEBUG'
ld: (.text+0x903): undefined reference to `INFO_LOC_VARIABLES_DEBUG'
ld: (.text+0x943): undefined reference to `INFO_LOC_VARIABLES_DEBUG'
ld: (.text+0xa19): undefined reference to `TIMER_DATA'
ld: (.text+0xa3e): undefined reference to `RUN_DEBUG'
ld: (.text+0xa4d): undefined reference to `RUN_DEBUG'
ld: (.text+0xa60): undefined reference to `CONTINUE_DEBUG'
ld: (.text+0xa70): undefined reference to `STEP_IN_DEBUG'
ld: (.text+0xa80): undefined reference to `STEP_OUT_DEBUG'
ld: (.text+0xa90): undefined reference to `KILL_DEBUG'
ld: (.text+0xb5e): undefined reference to `COMMAND_DEBUG'
ld: (.text+0xb6e): undefined reference to `DIALOG_CHOOSE_DEBUG_PATH'
ld: (.text+0xb7b): undefined reference to `RESIZE_WIN'
Compilation failed.
Regards
Re: FrontEnd GDB for freebasic
Hi Dinosaur!
Different versions of GDB display slightly different information. Debian 10 has gdb 8.2 and its output differs from 8.1, 10.1, 11.1. At the moment I have updated the archive, please download a new one.
By the way, please tell me you also have GDB 8.2?
fbc Debug.bas debug_gui.bas dialogs.bas pipe.bas interface.bas
Different versions of GDB display slightly different information. Debian 10 has gdb 8.2 and its output differs from 8.1, 10.1, 11.1. At the moment I have updated the archive, please download a new one.
By the way, please tell me you also have GDB 8.2?
compilation should be something like this:However lots of undefined references
fbc Debug.bas debug_gui.bas dialogs.bas pipe.bas interface.bas
Re: FrontEnd GDB for freebasic
Hi All
Vanya, I am so used to making projects in Geany that have one Project.bi which has all the includes, that I never
looked beyond my nose to see that others don't.
Anyway it all compiles without a problem and my GDB is:
GNU gdb (Debian 8.2.1-2+b3) 8.2.1
I changed Window9.bi uncomment :#define __USE_GTK3__ BUT that didn't make any difference.
Running your included binary file works correctly and solved a problem that the previous version had, which was:
A multi module project didn't show the main module in the debug window, so you could not set a BP at the start.
Worth noting that I have used "Gede" debugger for a couple of years now, but it has annoying problems and I am hoping that your front end doesn't.
How do you change the colour of the high lighting bar ? so it is more pronounced when stepping ?
Regards
Vanya, I am so used to making projects in Geany that have one Project.bi which has all the includes, that I never
looked beyond my nose to see that others don't.
Anyway it all compiles without a problem and my GDB is:
GNU gdb (Debian 8.2.1-2+b3) 8.2.1
Code: Select all
(Debug:1978): Gtk-ERROR **: 19:12:07.970: GTK+ 2.x symbols detected. Using GTK+ 2.x and GTK+ 3 in the same process is not supported
Trace/breakpoint trap
Running your included binary file works correctly and solved a problem that the previous version had, which was:
A multi module project didn't show the main module in the debug window, so you could not set a BP at the start.
Worth noting that I have used "Gede" debugger for a couple of years now, but it has annoying problems and I am hoping that your front end doesn't.
How do you change the colour of the high lighting bar ? so it is more pronounced when stepping ?
Regards
Re: FrontEnd GDB for freebasic
You are mixing GTK2 and GTK3. The program is made with GTK2 in mind. I think you took the file libwindow9.a from folder bin/lin32/gtk3 - it is not right. You need to take the file libwindow9.a from folder bin/lin32/gtk2(Debug:1978): Gtk-ERROR **: 19:12:07.970: GTK+ 2.x symbols detected. Using GTK+ 2.x and GTK+ 3 in the same process is not supported
You don't need to do this for GTK2.I changed Window9.bi uncomment :#define __USE_GTK3__ BUT that didn't make any difference.
The program uses the default highlight color. If you like, you can add color change lines in sci.bi in the SetOptionsciHWND procedure after the line:How do you change the colour of the high lighting bar ? so it is more pronounced when stepping ?
Code: Select all
SendMessage(sciHWND,SCI_INDICSETSTYLE , 0, INDIC_FULLBOX)
Code: Select all
SendMessage(sciHWND,SCI_INDICSETFORE , 0, &hff0000) ' color blue for example
SendMessage(sciHWND,SCI_INDICSETALPHA , 0, 10) ' alpha 10 , can be done (from 0 to 255)
Re: FrontEnd GDB for freebasic
Hi All
Vanya, I can now compile & run without any issues.
The colour selection is great.
Will now test on projects and let you know how I go.
One final question:
Type MyType
Value as integer
End Type
How do we see the value of MyType.Value ?
Regards
EDIT: In fact I am not seeing any values.
Correction: When pressing update the standard Integers show values.
Vanya, I can now compile & run without any issues.
The colour selection is great.
Will now test on projects and let you know how I go.
One final question:
Type MyType
Value as integer
End Type
How do we see the value of MyType.Value ?
Regards
EDIT: In fact I am not seeing any values.
Correction: When pressing update the standard Integers show values.
Re: FrontEnd GDB for freebasic
Hi ALL!
Released version 2 of the program. The first version is also available for download.
What's new in the second version:
1) found bugs fixed
2) the interface was changed (icons appeared instead of labels, a pop-up menu was added)
3) it became possible to change the value of variables (a menu is called in the variables window)
4) you can copy data from the variables window (the menu is called in the variables window)
5) you can enable / disable auto-update of variables during step-by-step debugging (the menu is called when you press the OPTIONS button)
6) the output of global variables is optimized
Unfortunately, on 32-bit systems there is an unsolvable problem with updating global variables (voiced here). This is a problem with variable and struct names that GDB does not recognize. Due to this problem, the data of variables in the GUI may be incorrect.
Released version 2 of the program. The first version is also available for download.
What's new in the second version:
1) found bugs fixed
2) the interface was changed (icons appeared instead of labels, a pop-up menu was added)
3) it became possible to change the value of variables (a menu is called in the variables window)
4) you can copy data from the variables window (the menu is called in the variables window)
5) you can enable / disable auto-update of variables during step-by-step debugging (the menu is called when you press the OPTIONS button)
6) the output of global variables is optimized
Unfortunately, on 32-bit systems there is an unsolvable problem with updating global variables (voiced here). This is a problem with variable and struct names that GDB does not recognize. Due to this problem, the data of variables in the GUI may be incorrect.