Solved

GCC for DOS / "Abort!"

Posted on 1998-05-02
5
281 Views
Last Modified: 2010-04-15
Hello,

I tried to port a Linux C program to DOS. When compiling with GCC, everything seems to work ok, but after some second it just says "Abort!". Do you have an explanation for this?

If you need to look at the script, it's located at ourworld.compuserve.com/homepages/Christian_Wenz/test.c - the C library function strtod using assembler.
0
Comment
Question by:Christian_Wenz
5 Comments
 
LVL 4

Expert Comment

by:emmons
ID: 1256848
First off, this is an assembly program embedded in a C file.

Can you give a better idea of where it fails and what the register values are when it does?
0
 
LVL 4

Expert Comment

by:emmons
ID: 1256849
First off, this is an assembly program embedded in a C file.

Can you give a better idea of where it fails and what the register values are when it does?
0
 
LVL 5

Author Comment

by:Christian_Wenz
ID: 1256850
I have no idea if it fails when running, as I get this "Abort!" message during compilation.
0
 
LVL 4

Expert Comment

by:jtwine100697
ID: 1256851
Have you tried turning on all warnings to their highest levels?  That might give you a bit more information on what the problem might be.

-=- James.
0
 

Accepted Solution

by:
gavriep earned 20 total points
ID: 1256852
Linux and DOS use a different syntax of inline assembler. That's the reason you get the "Abort".

You asked for an explanation, so this is submitted as an answer.

As to the solution -- I can't be specific, but you need to change the format of the inline ASM. See the DJGPP docs!
0

Featured Post

VMware Disaster Recovery and Data Protection

In this expert guide, you’ll learn about the components of a Modern Data Center. You will use cases for the value-added capabilities of Veeam®, including combining backup and replication for VMware disaster recovery and using replication for data center migration.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Preface I don't like visual development tools that are supposed to write a program for me. Even if it is Xcode and I can use Interface Builder. Yes, it is a perfect tool and has helped me a lot, mainly, in the beginning, when my programs were small…
Examines three attack vectors, specifically, the different types of malware used in malicious attacks, web application attacks, and finally, network based attacks.  Concludes by examining the means of securing and protecting critical systems and inf…
The goal of this video is to provide viewers with basic examples to understand how to use strings and some functions related to them in the C programming language.
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use for-loops in the C programming language.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question