Talk About Network



Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Forth > Re: Forth for M...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 47 of 54 Topic 3987 of 4053
Post > Topic >>

Re: Forth for Mac OS X Leopard (Intel) - what are the options?

by Josh Grams <josh@[EMAIL PROTECTED] > Apr 12, 2008 at 12:23 AM

Albert van der Horst <albert@[EMAIL PROTECTED]
> wrote:
> In article <iHJLj.2992$dg.2176@[EMAIL PROTECTED]
>,
> Josh Grams  <josh@[EMAIL PROTECTED]
> wrote:
>>Robert Spykerman <robert.spykerman@[EMAIL PROTECTED]
> wrote:
>>
>>> Albert sections his code very nicely into 2 user defined sections,
>>> forth and dictionary - dictionary being unitialized for further
>>> additions, with the exec flag on.
>>>
>>> This appears to build without a fuss on linux. On OSX, the tools give
>>> out big stink about there not being a .text, data,
>>
>>That's BSD for you.  You are required to have .text and .data, so you
>>might as well use them.  The other thing you could do (which might save
>>a bit of space in the executable is to put everything in .text, have an
>>empty .data, and then immediately mprotect() everything to rwx.  But
>>your way seems fine to me.
>
> Without a fuzz? Not quite.

Sorry, I can't make sense of that...

> I should have shown the actual build commands on linux before. This is
> an excerpt of my Makefile:
>
> glina : ci86.lina.s ; as $+; \
>     strip a.out --strip-unneeded -R .bss -R .data -R .text ; \
>     ld a.out -o $@[EMAIL PROTECTED]
  ; strip $@[EMAIL PROTECTED]
 -s -R .bss
>
> So immediately after assembling I got rid of everything unneeded
> and specifically of the .data and .text segment.
> The loader doesn't complain if those are absent, on linux, but
> it does add a gratituous .bss segment.
> That is stripped too.

On Linux, yes.  But the BSD systems I've seen are pickier.  Even if
you're not doing dynamic linking (and hence don't need any section
headers), they won't run your ELF unless it has at least .text and .data
section headers (AFAICT).  Have you had a different experience with BSD?

I hope I'm not missing your point again...

> Then as part of SAVE-SYSTEM all sections are killed anyway.
> The program is just loaded, using the "program" information
> in the header.
>
> This is how lina looks after stripping of symbols and SAVE-SYSTEM.

Nice and clean.  But I haven't been able to get an executable like that
to run under BSD.  At least not under the BSD ABI or whatever you call
it -- I don't think I tried with the Linux emulation layer.

--Josh




 54 Posts in Topic:
Forth for Mac OS X Leopard (Intel) - what are the options?
billclem@[EMAIL PROTECTED  2008-04-03 18:19:47 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-04 03:53:57 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
stephenXXX@[EMAIL PROTECT  2008-04-04 13:42:15 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Ian Osgood <iano@[EMAI  2008-04-04 08:44:54 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
anton@[EMAIL PROTECTED]   2008-04-05 15:26:25 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Bernd Paysan <bernd.pa  2008-04-05 23:14:35 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Roelf Toxopeus <these3  2008-04-04 20:44:10 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
dhoffman@[EMAIL PROTECTED  2008-04-04 18:01:21 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Henry <henry.olders@[E  2008-04-04 12:44:04 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
billclem@[EMAIL PROTECTED  2008-04-04 15:36:47 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-04 23:20:15 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-05 08:44:20 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-04 18:21:56 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
anton@[EMAIL PROTECTED]   2008-04-05 15:33:28 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-04 18:27:24 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
anton@[EMAIL PROTECTED]   2008-04-05 15:22:30 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
pliz <s.m.plis@[EMAIL   2008-04-05 19:27:42 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Bernd Paysan <bernd.pa  2008-04-06 14:05:50 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
sToRNG.BaRE.dURiD@[EMAIL   2008-04-07 03:09:18 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-07 12:08:28 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-07 22:18:46 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-10 01:52:10 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-07 03:50:05 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
billclem@[EMAIL PROTECTED  2008-04-07 13:35:54 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-07 17:35:47 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-07 21:53:32 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-08 19:21:05 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-08 16:39:52 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Duke Normandin <dukeof  2008-04-09 00:18:48 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-10 03:10:44 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-10 11:30:24 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-10 18:10:11 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-11 00:03:18 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-08 18:36:55 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-10 03:25:30 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-09 05:56:53 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-10 04:09:29 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-10 07:45:29 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-10 16:33:31 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-10 21:13:01 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-11 00:20:38 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-10 17:08:26 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-11 13:27:42 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Thomas Pornin <pornin@  2008-04-11 16:32:25 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-11 21:21:11 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Albert van der Horst <  2008-04-11 22:26:52 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-12 00:23:55 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-11 10:27:30 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Josh Grams <josh@[EMAI  2008-04-12 00:14:10 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-11 10:43:54 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Slava Pestov <slava@[E  2008-04-11 17:29:31 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
Robert Spykerman <robe  2008-04-12 08:55:47 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
billclem@[EMAIL PROTECTED  2008-04-13 22:43:10 
Re: Forth for Mac OS X Leopard (Intel) - what are the options?
"M. Edward (Ed) Bora  2008-04-22 05:59:28 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Fri May 16 4:14:21 CDT 2008.