Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8638847
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T10:50:41+00:00 2026-06-12T10:50:41+00:00

I have never encounted this error on my old linux machine(both are intel 32bit)

  • 0

I have never encounted this error on my old linux machine(both are intel 32bit) so I am at a loss.

I am trying to assemble and link assembly code (which is very simplistic and should work) but ld is giving the error

rs.o: In function `_start':
(.text+0x11): undefined reference to `eax'

the line in question is the pushl %eax line. I only need to push a single byte of 0 to the stack so I decided to use the xor’d eax register. but pushb gives me an “invalid suffix or operands for push” error while assembling with as using the code pushb %al and if I try to use pushl %eax as assembles fine but the linker yells at me.

here is the code.

.section .data

.section .text

.global _start

_start:

xorl %eax, %eax

#sys_socketcall(int call, __user *args)
#sys_socket(int domain, int type, int protocol)

pushl %eax          #protocol: 0
pushl $1            #type: SOCK_STREAM
pushl $2            #domain: AF_INET
movL $1, %ebx       #sys_socket
movl $102, %eax    #sys_socketcall
int $0x80

movl $eax, %ebx  #move socket fd to check echo $?
movl $1, %eax    #exit
int $0x80

any help is appreciated.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T10:50:43+00:00Added an answer on June 12, 2026 at 10:50 am

    You have an error in your assembly: $eax should be %eax in

    movl $eax, %ebx  #move socket fd to check echo $?
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have never encountered an error like this before. I was using prepared statements
I have never come across this issue but most recently I noticed that a
I have done this many times and have never seen this. I have an
This problem is bizarre. I have never encountered anything like it before. I am
I can honestly say I've never encountered this one before: I have two .ascx
while programming throughout the years I have never posted a question on this website,
I have never saved and retrieved an image to and from the database before.
I have never programed in bash before. I am reading all the files that
I have never used Foxpro before. Can you convert the following Foxpro code into
I have never done any Windows coding and I would like to give it

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.