English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Language > Coders. C/C++

 
 
Thread Tools
Old 05 November 2022, 18:45   #1
jotd
This cat is no more
 
jotd's Avatar
 
Join Date: Dec 2004
Location: FRANCE
Age: 52
Posts: 8,389
gcc 10: can't link a simple (empty) C file

using compiler included in Bartman VS code package

Code:
K:\jff\AmigaHD\PROJETS\progs_asm_c_c++\blitter_emu>m68k-amiga-elf-gcc.exe -nostdlib -o test main.c
The output

Code:
k:/progs/vscode-amiga-debug-master/bin/win32/opt/bin/../lib/gcc/m68k-amiga-elf/12.1.0/../../../../m68k-amiga-elf/bin/ld.exe: warning: cannot find entry symbol _start; defaulting to 0000000080000054
Is there a startup code I can use ? or should I define _start myself? (I don't care about parsing argv, opening libs or such)
jotd is online now  
Old 05 November 2022, 19:09   #2
Eaglef00t
Registered User
 
Join Date: Dec 2017
Location: US
Posts: 9
-nostartfiles (along with -nostdlib)
Eaglef00t is offline  
Old 05 November 2022, 21:36   #3
Jobbo
Registered User
 
Jobbo's Avatar
 
Join Date: Jun 2020
Location: Druidia
Posts: 389
Build the sample project using VSCode or grab the files from the plugin folder and start from there.

It has a set of gcc8_c_support files which include the required _start and a handful of lib functions such as memcpy.

The sample makefile uses -nostdlib but it doesn't use -nostartfiles so I suspect doing so is a bad idea.
Jobbo is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to run flash update on empty cyberstormppc rom file in fs-uae. Amiguy support.AmigaOS 2 27 September 2022 23:50
Simple While/Wend loop for waiting inkey buffer is empty? JPQ Coders. Blitz Basic 3 08 October 2019 23:05
Double Dragon Amos file download link Brick Nash Coders. AMOS 11 28 September 2017 23:20
gcc sas/c link problem emufan Coders. C/C++ 6 23 July 2017 00:32
Creating an empty hdf file Harko33 support.WinUAE 1 25 September 2011 23:46

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 09:59.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.07493 seconds with 15 queries