[Coco] OS9 C question

Bill Pierce ooogalapasooo at aol.com
Wed Mar 13 17:55:32 EDT 2013


Bob,
It should work either way if the sub is written right. I know some methods will not work well in a library. I found that out the hard way. Basically the library is just an ".r" file that's included into the program, but the compiler treats it special and only uses the functions called and the others are left out (supposedly). It's the way the variables are set up that makes the big difference in the library.

I've been tryiing to make my drivewire function into a library for ease of use but there's too many large arrays that need to be global. A library "should" be (for the most part) self contained. If I could get it into a library, it would make programming in C for drivewire, a breeze.

My C programming is getting better all the time.
Bill P

Music from the Tandy/Radio Shack Color Computer 2 & 3
https://sites.google.com/site/dabarnstudio/
Bill Pierce
ooogalapasooo at aol.com




-----Original Message-----
From: Bob Devries <devries.bob at gmail.com>
To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
Sent: Wed, Mar 13, 2013 5:36 pm
Subject: Re: [Coco] OS9 C question


Actually, I think your idea about making a separate library file was 
probably correct. Unfortunately, there's no documentation for it at all. It 
may have been mentioned on the Princeton email list at the time of course...

Regards, Bob Devries
Dalby, QLD, Australia

----- Original Message ----- 
From: "Bill Pierce" <ooogalapasooo at aol.com>
To: <coco at maltedmedia.com>
Sent: Wednesday, March 13, 2013 4:37 PM
Subject: Re: [Coco] OS9 C question


>
> Thanks Bob, I'll give that a try. I had compiled mslib.c as a library 
> "mslib.l" and was linking it with the linker. It's probably supposed to be 
> inline. If the stddefs.h is just a c headr fo os9defs, then thats not a 
> problem. I can make that. Been meaning to do that anyway. A better 
> replacement for sys.l .
>
> Thanks again
> Bill
>
> Music from the Tandy/Radio Shack Color Computer 2 & 3
> https://sites.google.com/site/dabarnstudio/
> Bill Pierce
> ooogalapasooo at aol.com
>
>
>
>
> -----Original Message-----
> From: Bob Devries <devries.bob at gmail.com>
> To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
> Sent: Wed, Mar 13, 2013 12:44 am
> Subject: Re: [Coco] OS9 C question
>
>
> OK.
>
> Bill, it appears that the file mstest.c calls functions from the file
> mslib.c, so it's necessary to compile both together:
>
> cc mstest.c mslib.c -o=mstest
>
> I'm a bit rusty on the command line above. Someone can correct me if I'm
> wrong.
>
> The header files called by mstest.c will probably be in various packages
> such as Multivue for example. Certainly, mouse.h is there (page 10-70 of 
> the
> Multi-Vue C Language Graphics Library Support), and colors.h could be
> determined fairly easily from other parts of the several manuals.
>
> Regards, Bob Devries
> Dalby, QLD, Australia
>
> ----- Original Message ----- 
> From: "Bill Pierce" <ooogalapasooo at aol.com>
> To: <coco at maltedmedia.com>
> Sent: Wednesday, March 13, 2013 2:17 PM
> Subject: Re: [Coco] OS9 C question
>
>
>>
>> Bob, I was mistaken. It was not the Princeton files but the OCN
>> collection. The name of the archive is "mstest.ar".
>>
>> I found it when I was going through the various collections and creating
>> "Collections" archive VHDs with everything decompressed for ease of use.
>> Each archive in it's own dir under a directory named for the collection.
>> I've done (so far) RTSI, Princeton, OCN, OS9UG, CCFIA (Color Computer
>> Floppy Image Archive),Rainbow On Tape/Disk, and I soon will have the Cis
>> files done as well. I use VHDs with both OS9 and RSDOS partitions so I 
>> can
>> provide the RSDOS files of these archives as well (when available). Where
>> I can, the contents documents are supplied. I will have these up for
>> download soon on both my site and the Color Computer Archives.
>>
>> Music from the Tandy/Radio Shack Color Computer 2 & 3
>> https://sites.google.com/site/dabarnstudio/
>> Bill Pierce
>> ooogalapasooo at aol.com
>>
>>
>>
>>
>> -----Original Message-----
>> From: Bob Devries <devries.bob at gmail.com>
>> To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
>> Sent: Tue, Mar 12, 2013 11:12 pm
>> Subject: Re: [Coco] OS9 C question
>>
>>
>> Bill,
>>
>> it might be useful if you tell us which archive file you are referring 
>> to.
>> I
>> have the complete file archive from Princeton here on CDROM, so I can
>> study
>> the code also.
>>
>> Regards, Bob Devries
>> Dalby, QLD, Australia
>>
>> ----- Original Message ----- 
>> From: "Bill Pierce" <ooogalapasooo at aol.com>
>> To: <coco at maltedmedia.com>
>> Sent: Wednesday, March 13, 2013 12:33 PM
>> Subject: Re: [Coco] OS9 C question
>>
>>
>>>
>>> When I comment out the "stddefs.h" file, (or leave it), I get an error
>>> for
>>> "undefined variable" (loop). Finding the variable in the code it's a 
>>> call
>>> to loop(); So this why I think this is a homebrew header for the 
>>> homebrew
>>> library that's in the archive. Either he forgot to put it in or it's
>>> referred to in another earlier package like "use the stddefs.h for the
>>> file I uploaded last month. This program is a sub to use the mouse on a
>>> hardware test screen with a text cursor as a pointer.
>>>
>>> The Princeton files were mustly "cuts" files and were pak or ar files
>>> once
>>> cuts was run. A lot of these archives I had already and most of them had
>>> more info in the original archives. I suspect people were trimming down
>>> the file size for the cuts operation so they would fit in an email.
>>>
>>> Bill P
>>>
>>> Music from the Tandy/Radio Shack Color Computer 2 & 3
>>> https://sites.google.com/site/dabarnstudio/
>>> Bill Pierce
>>> ooogalapasooo at aol.com
>>>
>>>
>>>
>>>
>>> -----Original Message-----
>>> From: T. Franklin <tim at franklinlabs.com>
>>> To: CoCoList for Color Computer Enthusiasts <coco at maltedmedia.com>
>>> Sent: Tue, Mar 12, 2013 9:39 pm
>>> Subject: Re: [Coco] OS9 C question
>>>
>>>
>>> Guys,
>>>
>>> If the source file doesn't need anything from the STDDEF.H file then 
>>> just
>>> delete
>>> the reference by commenting out the line #include <stddef.h>. The
>>> STDDEF.H
>>> is a
>>> prototype/macro definition file. Creating a "dummy" file would be 
>>> useless
>>> if the
>
>>> originating source needs information that the STDDEF.H file has.
>>>
>>> As shown in one of the previous posts, this file should contain
>>> definitions for
>>> NULL, wchar_t, size_t and some others. Most source files don't need 
>>> this.
>>>
>>> -----Original Message-----
>>> From: Bob Devries [mailto:devries.bob at gmail.com]
>>> Sent: Tuesday, March 12, 2013 08:09 PM
>>> To: 'CoCoList for Color Computer Enthusiasts'
>>> Subject: Re: [Coco] OS9 C question
>>>
>>> My suggestion would be to create a dummy file "stddefs.h" and then try 
>>> to
>>> compile the source, and see what breaks ;)Regards, Bob DevriesDalby, 
>>> QLD,
>>> Australia----- Original Message ----- From: "Bill Pierce" To: Sent:
>>> Wednesday,
>>> March 13, 2013 9:00 AMSubject: [Coco] OS9 C question>> Hi Guys,> Does 
>>> any
>>> know
>>> of a file named "stddefs.h"?> I was trying to compile a utility source I
>>> found
>>> in the archives and it > requires this file. I have searched through all
>>> the
>>> stuff I have available > and can't find it. It seems (from the utility
>>> source)
>>> to contain some > macros that the program needs.>> Also, does anyone 
>>> know
>>> how to
>>> set the OS9 key repeat? There must be a way > to do it as "Control" from
>>> multivue has a place to set the repeat speed > and start delay.>> Any
>>> help
>>> is
>>> appreciated... thanks> Bill P>> Music from the Tandy/Radio Shack Color
>>> Computer
>>> 2 & 3> https://sites.google.com/site/dabarnstudio/> Bill Pierce>
>>> ooogalapasooo at aol.com>>> --> Coco mailing list> Coco at maltedmedia.com> ht
>>> tp://five.pairlist.net/mailman/listinfo/coco --Coco mailing
>>> listCoco at maltedmedia.comhttp://five.pairlist.net/mailman/listinfo/coco
>>>
>>> --
>>> Coco mailing list
>>> Coco at maltedmedia.com
>>> http://five.pairlist.net/mailman/listinfo/coco
>>>
>>>
>>>
>>> --
>>> Coco mailing list
>>> Coco at maltedmedia.com
>>> http://five.pairlist.net/mailman/listinfo/coco
>>
>>
>> --
>> Coco mailing list
>> Coco at maltedmedia.com
>> http://five.pairlist.net/mailman/listinfo/coco
>>
>>
>>
>> --
>> Coco mailing list
>> Coco at maltedmedia.com
>> http://five.pairlist.net/mailman/listinfo/coco
>
>
> --
> Coco mailing list
> Coco at maltedmedia.com
> http://five.pairlist.net/mailman/listinfo/coco
>
>
>
> --
> Coco mailing list
> Coco at maltedmedia.com
> http://five.pairlist.net/mailman/listinfo/coco 


--
Coco mailing list
Coco at maltedmedia.com
http://five.pairlist.net/mailman/listinfo/coco

 



More information about the Coco mailing list