From owner-freebsd-hackers@FreeBSD.ORG Wed Jun 16 16:09:18 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4BA0616A4CE for ; Wed, 16 Jun 2004 16:09:18 +0000 (GMT) Received: from gandalf.online.bg (gandalf.online.bg [217.75.128.9]) by mx1.FreeBSD.org (Postfix) with SMTP id A611843D2F for ; Wed, 16 Jun 2004 16:09:16 +0000 (GMT) (envelope-from roam@ringlet.net) Received: (qmail 9921 invoked from network); 16 Jun 2004 16:06:51 -0000 Received: from office.sbnd.net (HELO straylight.m.ringlet.net) (217.75.140.130) by gandalf.online.bg with SMTP; 16 Jun 2004 16:06:50 -0000 Received: (qmail 86116 invoked by uid 1000); 16 Jun 2004 16:08:48 -0000 Date: Wed, 16 Jun 2004 19:08:48 +0300 From: Peter Pentchev To: Wes Peters Message-ID: <20040616160848.GG975@straylight.m.ringlet.net> Mail-Followup-To: Wes Peters , freebsd-hackers@freebsd.org, Jos? Nicol?s Castellano References: <003801c45207$01ddfa70$0200a8c0@peron> <20040614140400.GF827@straylight.m.ringlet.net> <200406160901.02996.wes@softweyr.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="KuLpqunXa7jZSBt+" Content-Disposition: inline In-Reply-To: <200406160901.02996.wes@softweyr.com> User-Agent: Mutt/1.5.6i cc: freebsd-hackers@freebsd.org cc: Jos? Nicol?s Castellano Subject: Re: freebsd asm X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Jun 2004 16:09:18 -0000 --KuLpqunXa7jZSBt+ Content-Type: text/plain; charset=windows-1251 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Jun 16, 2004 at 09:01:02AM -0700, Wes Peters wrote: > On Monday 14 June 2004 07:04, Peter Pentchev wrote: > > On Mon, Jun 14, 2004 at 01:59:11PM +0200, Jos? Nicol?s Castellano wrote: > > > Hello to all, > > > > > > I'm proud to join this mailing, having posibilities to learn some new > > > features of freebsd system. > > > > > > I have to mention i did some tests in asm from freebsd-devel and i get > > > surprised, look at this: > > > > > > [demon]~$ uname -a > > > FreeBSD demon.noconname.org 5.2.1-RELEASE-p4 FreeBSD 5.2.1-RELEASE-p4 > > > #0: Tue Apr 6 19:35:49 CEST 2004 > > > root@demon.noconname.org:/usr/obj/usr/src/sys/NocONName i386 > > > > > > [demon]~$ cat hello.asm > > > %include 'system.inc' > > > section .data > > > hola db 'Hola', 0Ah > > > hbytes equ $-hola > > > section .text > > > global _start > > > _start: > > > push dword hbytes > > > push dword hola > > > push dword stdout > > > sys.write > > > push dword 0 > > > sys.exit > > > > > > [demon]~$ nasm -f elf hello.asm > > > hello.asm:1: fatal: unable to open include file `system.inc' > > > > > > ?Where is that file?... the -current port of nasm is incomplete ? > > > > I assume you are referring to the system.inc file mentioned in > > http://www.freebsd.org/doc/en_US.ISO8859-1/books/developers-handbook/x8= 6- > >portable-code.html If so, note that this page says that you need to crea= te > > this file yourself, it is neither part of nasm nor part of the standard > > FreeBSD distribution :) See the last paragraph on the page - "Go ahead, > > enter it into your editor and save it as system.inc." :) >=20 > Gee, maybe somebody should do that and submit the file to krion@ for=20 > inclusion in the port patches. ;^) Well, there would have to be several versions, or it would have to be automatically generated from syscalls.master... though that would require parsing C syntax. Nah, several versions should be fine, updated each time a syscall is added/removed/changed - that should not be too often, would it now? :) I'll see if I can whip up something like that. G'luck, Peter --=20 Peter Pentchev roam@ringlet.net roam@sbnd.net roam@FreeBSD.org PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 I am the thought you are now thinking. --KuLpqunXa7jZSBt+ Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFA0HCQ7Ri2jRYZRVMRAgkFAJ4pKpeYKDd8d6LOhbvIfxmi2yopQACfR8Ic Et4KMUjjlthrXBC6XxY1SCI= =r/9f -----END PGP SIGNATURE----- --KuLpqunXa7jZSBt+--