From owner-freebsd-questions Tue Nov 30 6:17: 2 1999 Delivered-To: freebsd-questions@freebsd.org Received: from ultra3000.if.sc.usp.br (uspfsc.ifqsc.sc.usp.br [143.107.228.1]) by hub.freebsd.org (Postfix) with ESMTP id AB906158D1 for ; Tue, 30 Nov 1999 06:16:51 -0800 (PST) (envelope-from toto@ultra3000.if.sc.usp.br) Received: (from toto@localhost) by ultra3000.if.sc.usp.br (8.8.8/8.8.8) id MAA21566 for freebsd-questions@freebsd.org; Tue, 30 Nov 1999 12:16:00 -0200 (EDT) Date: Tue, 30 Nov 1999 12:16:00 -0200 (EDT) From: Carlos Antonio Ruggiero Message-Id: <199911301416.MAA21566@ultra3000.if.sc.usp.br> To: freebsd-questions@freebsd.org Subject: Hello World in Assembler Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Hi eveybody, I am trying to write a "hello world" program in assembler, but can't get it right. The code is (based on The Assembly HOW-TO) section .data msg db "Hello World!" len equ $ - msg section .text global _start _start: mov eax,4 mov ebx,1 mov ecx,msg mov edx,len int 0x80 mov eax,1 xor ebx,ebx int 0x80 It assembles all right (using nasm -f elf -o hello. hello.asm) and links fine (ld -o hello hello.o). However it doesn't produce any output. The same code runs fine in Linux. With different parameters, it runs OK in DOS. I am running FreeBSD 3.1. Could anyone help me out? Thanks a lot To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message