Mail Archives: djgpp/2001/06/09/10:45:18

X-Apparently-To: clax86 AT yahoo DOT com via web9602; 08 Jun 2001 23:20:27 -0700 (PDT)
From: rendeg AT my-dejanews DOT com (Rennie deGraaf)
Newsgroups: comp.lang.asm.x86,comp.os.msdos.djgpp
Subject: error linking asm module
Approved: <johnfine AT earthlink DOT net>
Lines: 72
Message-ID: <kIpU6.5025$>
Date: Sat, 09 Jun 2001 13:41:36 GMT
X-Complaints-To: abuse AT earthlink DOT net
X-Trace: 992094096 (Sat, 09 Jun 2001 06:41:36 PDT)
NNTP-Posting-Date: Sat, 09 Jun 2001 06:41:36 PDT
X-Received-Date: Sat, 09 Jun 2001 06:39:35 PDT (
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

I have been trying to compile a program I wrote containing a keyboard
ISR written in asm with DJGPP, but ld has been giving me some strange
error messages:

    A:\>gcc -o as1.exe isr.o keyb.o as1.o util.o
    isr.o(.text+0x11):fake: relocation truncated to fit: 8 data
    collect2: ld returned 1 exit status

isr.s, the assembly language module, seems to assemble properly with 
"as -o isr.o isr.s", but the linking stage bombs on me.  

I don't even know what that error means (and I can't find any docs for
ld error messages), let alone debug it.  Most other posts I have found
concerning this errer went unanswered, or had bad or useless answers. 
Is there anyone out there who is sufficently familiar with using asm
in DJGPP or is just plain smart enough to find me an answer?


a listing of isr.s follows:
.globl _newInt9
.globl _ISRsize
.globl _buffer

    .long 0, 0, 0, 0, 0, 0, 0, 0
    .byte 0
    pushl %ebp
    movl %esp, %ebp
    pushl %ecx
    inb $0x64, %al
    and 0x01, %eax
    jz done
    inb $0x60, %al
    movb $_buffer, %cl
    movb %al, _newkey(%ecx)
    movb $0x20, %al
    outb %al, $0x20
    addb $1, _newkey
    and $0x1f, _newkey
    popl %ecx
    popl %ebx

    pushl %ebp
    movl %esp, %ebp
    movl $_end, %eax
    subl $_newInt9, %eax
    popl %ebp

NOTE: crossposted to comp.lang.asm.x86, comp.os.msdos.djgpp

- Raw text -

  webmaster     delorie software   privacy  
  Copyright 2019   by DJ Delorie     Updated Jul 2019