19 August 2019, 22:04 | #1 |
Registered User
Join Date: Feb 2019
Location: Munich, Germany
Posts: 63
|
Amiga GCC 8.3+gdb extension for Visual Studio Code
I made an open-source VS Code extension for Amiga 500 demo development. Repo on GitHub
One-stop Visual Code Extention to compile and debug Amiga C programs compiled by included gcc 8.3.0 in WinUAE. Features
Have a look at My Seminar 'Modern Amiga 500 Demo Development' at Evoke 2019 for more information about this and behind-the-scenes of our 64k intro CODA. I'm here for any questions, just wanted to get the first release out there. First release with install instructions Last edited by Bartman; 20 August 2019 at 11:23. Reason: added link with release |
19 August 2019, 23:27 | #2 |
Registered User
Join Date: Mar 2017
Location: Minehead / UK
Posts: 608
|
[EDIT] Never mind - instructions are under the releases section of the GitHub repo
|
19 August 2019, 23:32 | #3 |
Zone Friend
Join Date: May 2006
Location: France
Posts: 1,835
|
Awesome, will try it ASAIC
|
20 August 2019, 01:30 | #4 |
AmigaDev.com
Join Date: Mar 2016
Location: Stockholm, Sweden
Age: 35
Posts: 625
|
nice
|
20 August 2019, 12:06 | #5 |
Registered User
Join Date: Jan 2017
Location: Antwerp / Belgium
Posts: 189
|
Holly cow, that's awesome!
And better still: it even works! :-) Thanks Bartman, that's a very VERY comfortable setup. |
20 August 2019, 12:27 | #6 |
Inviyya Dude!
Join Date: Sep 2016
Location: Amiga Island
Posts: 2,793
|
Wow, will try this out at home..
Thanks, Bartman. edit: it's only working on windows... damn it... Last edited by Tigerskunk; 20 August 2019 at 12:46. |
20 August 2019, 13:33 | #7 |
Registered User
Join Date: Mar 2017
Location: Minehead / UK
Posts: 608
|
My thoughts too! Fortunately I have access to Windows, Linux and Mac but I wish it were available for Mac (preferably) or Linux with FS-UAE. I guess someone needs to take care of the GCC 8 port first though.
I couldn't get the breakpoint to hit when using my own code. Actually some sample code from Novacoder but I'm probably doing something dumb so I'll have another go tonight by attempting to put some of my own code into the example and see if that hits breakpoints. |
20 August 2019, 14:28 | #8 |
Registered User
Join Date: Feb 2019
Location: Munich, Germany
Posts: 63
|
Getting GCC and GDB working on Linux should be very easy, as GCC only has like 4 lines of modifications, and GDB about 10 lines. I'll be posting my compilation flags in a bit. Porting the GDB-Server from WinUAE to FS-UAE is probably a bit more work, but could be done. So if someone's up to the task...
emoon started a GDB-Server for FS-UAE a while ago... https://github.com/emoon/fs-uae |
20 August 2019, 14:44 | #9 |
Registered User
Join Date: Feb 2019
Location: Munich, Germany
Posts: 63
|
updated the README with build command-lines
https://github.com/BartmanAbyss/vscode-amiga-debug |
21 August 2019, 15:34 | #10 |
Registered User
Join Date: Aug 2018
Location: canada
Posts: 6
|
Hello Bartman, why is it only C and not c++ too? Btw congratulation for the hard work, it's really impressive and now my tool chain with gcc 6.2 and vs2017 seems really old
|
21 August 2019, 16:38 | #11 |
Registered User
Join Date: May 2018
Location: France
Posts: 246
|
Nice work!
Your gdb integration is much more generic than mine on the amiga assembly extension. Does it work with a mix of assembly and C sources in step debug ? |
21 August 2019, 22:28 | #12 | |
Registered User
Join Date: Feb 2019
Location: Munich, Germany
Posts: 63
|
Quote:
The current version doesn't have any stdlib/default lib... |
|
21 August 2019, 22:29 | #13 |
Registered User
Join Date: Feb 2019
Location: Munich, Germany
Posts: 63
|
I guess so. Yeah, the gdb-server needed to work with a real GDB, so no faking around. Just had to patch a few lines in GDB...
|
22 August 2019, 08:29 | #14 |
It's coming back!
Join Date: Jul 2018
Location: comp.sys.amiga
Posts: 762
|
This is awesome. Up till now I've been happy with VBCC cross compiling from Windows, but always missed having a full debugger.
Is there any chance that the gdb-server integration might become a standard part of WinUAE? |
22 August 2019, 08:59 | #15 |
Registered User
Join Date: Jul 2011
Location: UK
Posts: 341
|
Now this is awesome. I must get round to trying this
|
22 August 2019, 09:05 | #16 |
It's coming back!
Join Date: Jul 2018
Location: comp.sys.amiga
Posts: 762
|
I'm getting the following when trying to init an amiga project:
Error: the description can't be converted into a problem matcher: { "base": "$gcc", "fileLocation": "absolute" } Any ideas? EDIT: Also, something doesn't like spaces in directory names: m68k-amiga-elf-gcc: fatal error: no input files compilation terminated. m68k-amiga-elf-gcc: error: C:/Users/Deimos/Desktop/Amiga: No such file or directory m68k-amiga-elf-gcc: error: Development/test/main.c: No such file or directory m68k-amiga-elf-gcc: fatal error: no input files That's one folder, "C:/Users/Deimos/Desktop/Amiga Development/test/main.c" EDIT 2: Removing the space in the folder name and starting over, it works, I can compile, run and debug the example, setting a break point, etc., but I still get the problem matcher error in the output tab. Last edited by deimos; 22 August 2019 at 09:25. |
22 August 2019, 09:27 | #17 |
Registered User
Join Date: Sep 2018
Location: Poland
Posts: 15
|
Amazing!
I'm using vscode on a daily basis not only for Amiga but also for my work, hence I have a small suggestion. Would it be possible to split that entire package into: - vscode extension available from vscode marketplace - this way we get auto updates from you - gcc / other executables - this way download size is smaller and would allow later portability by providing variants of only this package - ability to specify already installed WinUAE - from what I read you bundle one, but I have one already neatly set up in my OS This way I could have gcc 8.3 compiler in my "compilers" directory and perhaps one could also attach bebbo's compiler (for performance comparison) into your extension via settings.json or something. I know debugging probably won't work that way and I won't even encourage you to support it, but building would. Also, perhaps in some kind of future (I hope near one) we could attach LLVM-based toolchain, if any m68k target gets completed for it. Also, I haven't really launched it yet since I'm at work, but I wonder if it collides with other build systems. I tend to have my projects CMake-based. Perhaps this extension can be chained together with CMake extension? Overall, this is a very nice extension and I appreciate your effort! Please don't take my suggestions offensively, as I just want to help in making it more versatile. Also, Amiga debugging in vscode. What a treat! You're the best! |
22 August 2019, 11:03 | #18 | |
Registered User
Join Date: Feb 2019
Location: Munich, Germany
Posts: 63
|
Quote:
Ah yes, the dreaded spaces. Couldn't find a fix for it. IIRC gnumake doesn't like the spaces, not even when quoted. |
|
22 August 2019, 11:06 | #19 | |
Registered User
Join Date: Feb 2019
Location: Munich, Germany
Posts: 63
|
Quote:
You can't replace the gcc with bebbo's, because his outputs Amiga Hunk files directly whereas mine just outputs ELF files that are converted with elf2hunk, and GDB requires ELF files as well. I may be uploading the extension to the marketplace when I have time. |
|
22 August 2019, 13:25 | #20 | |
Registered User
Join Date: Sep 2018
Location: Poland
Posts: 15
|
Quote:
It's of course a long term plan. I hope Toni Wilen gets interested in merging your changes as it would guarantee getting latest UAE version without needing to rebase your changes on top of latest sources. |
|
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Amiga Assembly extension for Visual Studio Code | prb28 | Coders. Asm / Hardware | 342 | 15 December 2023 21:22 |
Visual Studio Code Blitz Basic extension | earok | Coders. Blitz Basic | 29 | 16 July 2019 17:59 |
very basic C/ASM/Visual Studio hand holding | Sephnroth | Coders. C/C++ | 2 | 08 March 2016 20:15 |
Profiling WinUAE with Visual Studio 2013 | mark_k | support.WinUAE | 3 | 14 January 2014 20:26 |
|
|