Nekochan Net

Official Chat Channel: #nekochan // irc.nekochan.net
It is currently Fri Nov 21, 2014 5:02 am

All times are UTC - 8 hours [ DST ]


Forum rules


Any posts concerning pirated software or offering to buy/sell/trade commercial software are subject to removal.



Post new topic Reply to topic  [ 5 posts ] 
Author Message
 Post subject: getopt_long for IRIX
Unread postPosted: Wed Jul 04, 2012 9:01 pm 
Offline
User avatar

Joined: Thu Nov 24, 2005 10:11 am
Posts: 217
Location: Aguascalientes, Mexico
Hi guys!!

I was playing with my SGI and needed an Irix implementation of getopt_long(), so I got source code from NetBSD and OpenBSD and created a SGI version of it.

I tested an example program of getopt_long() I found in google and all seems works flawlessly :), except by a one line change. However the behavior is same than gnu's getopt_long().

I got a tar with sources, header, Makefile and test program, it builds with MipsPro in Irix 6.5. If anybody interested, I would like to share this.

_________________
__Zacatito__Image 600 MHZ R14000; 17GBytes HD
__Nopalito__Image 200 MHZ R5000; 9GBytes HD
Guadalajara, Jal and Aguascalientes, Ags
Mexico


Top
 Profile  
 
 Post subject: Re: getopt_long for IRIX
Unread postPosted: Wed Jul 04, 2012 10:17 pm 
Offline
User avatar

Joined: Tue Jul 15, 2008 5:48 pm
Posts: 1887
Location: P.O. Box 121, Pymble, Sydney, NSW 2073, Australia.
BSDero wrote:
Hi guys!!

I was playing with my SGI and needed an Irix implementation of getopt_long(), so I got source code from NetBSD and OpenBSD and created a SGI version of it.

I tested an example program of getopt_long() I found in google and all seems works flawlessly :), except by a one line change. However the behavior is same than gnu's getopt_long().

I got a tar with sources, header, Makefile and test program, it builds with MipsPro in Irix 6.5. If anybody interested, I would like to share this.


From memory there is/was something about this on the MIPS Pro nekochan wiki page.. if not I intended to put something on there at the same time I wrote the section on work arounds or porting or something like that..

EDIT
oh, wait nup.. that was the senenv/putenv thing .. I did have a solution for getopt_long() which I intended to put in a section after ..
http://www.nekochan.net/wiki/MIPS_Pro#s ... ng_in_IRIX

I think I did this when porting hercules IBM mainframe emulator to IRIX.. years ago..

R.

_________________
死の神はりんごだけ食べる

開いた括弧は必ず閉じる -- あるプログラマー

:Tezro: :Tezro: :Onyx2R: :Onyx2RE: :Onyx2: :O3x04R: :O3x0: :O200: :Octane: :Octane2: :O2: :O2: :Indigo2IMP: :PI: :PI: :1600SW: :1600SW: :Indy: :Indy: :Indy: :Indy: :Indy:
:hpserv: J5600, 2 x Mac, 3 x SUN, Alpha DS20E, Alpha 800 5/550, 3 x RS/6000, Amiga 4000 VideoToaster, Amiga4000 -030, 733MHz Sam440 AmigaOS 4.1 update 1.

Sold: :Indy: :Indy: :Indy: :Indigo: Tandem Himalaya S-Series Nonstop S72000 ServerNet.

@PymbleSoftware
Current Apps -> https://itunes.apple.com/au/artist/pymb ... d553990081
Cortex ---> http://www.facebook.com/pages/Cortex-th ... 11?sk=info
Minnie ---> http://www.facebook.com/pages/Minnie-th ... 02?sk=info
Github ---> https://github.com/pymblesoftware
Visit http://www.pymblesoftware.com
Search for "Pymble", "InstaElf", "CryWhy" or "Cricket Score Sheet" in the iPad App store or search for "Pymble" or "CryWhy" in the iPhone App store.


Top
 Profile  
 
 Post subject: Re: getopt_long for IRIX
Unread postPosted: Thu Jul 05, 2012 11:49 am 
Offline
User avatar

Joined: Mon Jul 21, 2003 6:19 am
Posts: 754
An Implementation of getopt_long is part of gnulib http://www.gnu.org/software/gnulib/MODULES.html#module=getopt-posix. I usually just copy the source files into a suitable directory and add them to the list of .c-Files in the Makefile.


Top
 Profile  
 
 Post subject: Re: getopt_long for IRIX
Unread postPosted: Thu Jul 05, 2012 1:44 pm 
Offline
User avatar

Joined: Tue Jul 15, 2008 5:48 pm
Posts: 1887
Location: P.O. Box 121, Pymble, Sydney, NSW 2073, Australia.
Updated to the wiki to point back here.... http://www.nekochan.net/wiki/MIPSpro#ge ... ng_in_IRIX

R.

_________________
死の神はりんごだけ食べる

開いた括弧は必ず閉じる -- あるプログラマー

:Tezro: :Tezro: :Onyx2R: :Onyx2RE: :Onyx2: :O3x04R: :O3x0: :O200: :Octane: :Octane2: :O2: :O2: :Indigo2IMP: :PI: :PI: :1600SW: :1600SW: :Indy: :Indy: :Indy: :Indy: :Indy:
:hpserv: J5600, 2 x Mac, 3 x SUN, Alpha DS20E, Alpha 800 5/550, 3 x RS/6000, Amiga 4000 VideoToaster, Amiga4000 -030, 733MHz Sam440 AmigaOS 4.1 update 1.

Sold: :Indy: :Indy: :Indy: :Indigo: Tandem Himalaya S-Series Nonstop S72000 ServerNet.

@PymbleSoftware
Current Apps -> https://itunes.apple.com/au/artist/pymb ... d553990081
Cortex ---> http://www.facebook.com/pages/Cortex-th ... 11?sk=info
Minnie ---> http://www.facebook.com/pages/Minnie-th ... 02?sk=info
Github ---> https://github.com/pymblesoftware
Visit http://www.pymblesoftware.com
Search for "Pymble", "InstaElf", "CryWhy" or "Cricket Score Sheet" in the iPad App store or search for "Pymble" or "CryWhy" in the iPhone App store.


Top
 Profile  
 
 Post subject: Re: getopt_long for IRIX
Unread postPosted: Wed Jul 11, 2012 8:08 am 
Offline
User avatar

Joined: Thu Nov 24, 2005 10:11 am
Posts: 217
Location: Aguascalientes, Mexico
In those GCC-isms related issues I've found *bsd source code easier to port and maintain witrhout all that flags and thinks like that. Source code is way easier to port, clear and maintain.

_________________
__Zacatito__Image 600 MHZ R14000; 17GBytes HD
__Nopalito__Image 200 MHZ R5000; 9GBytes HD
Guadalajara, Jal and Aguascalientes, Ags
Mexico


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 5 posts ] 

All times are UTC - 8 hours [ DST ]


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group