Page 1 of 3
iff.library iff.l.main stub existing?
Posted: Tue Oct 25, 2011 6:32 pm
by JosDuchIt
Has someone allready provided an OS.1 stub for iff.library?
If not, how can such a stub be developed?
Re: iff.library iff.l.main stub existing?
Posted: Tue Oct 25, 2011 8:10 pm
by thomasrapp
Re: iff.library iff.l.main stub existing?
Posted: Tue Oct 25, 2011 8:42 pm
by JosDuchIt
Thanks Tom
I got as far as copying the makefile content for jpeg, replacing jpeg with iff
i get
11.Datas:Gui4Cli/Dev/iff_library/OS4> make
make: *** No rule to make target `fd/iff.fd', needed by `iff.c'. Stop.
the only other files that are in the OS4 drawer are
iff.h
iff_lib.fd
i renamed the last to iff.fd but got the same error
I never used or made a makefile. Can you help me?
Re: iff.library iff.l.main stub existing?
Posted: Tue Oct 25, 2011 9:24 pm
by thomasrapp
http://thomas-rapp.homepage.t-online.de ... ff_os4.lha
Note: I did not test if it actually works. It only compiled successfully.
Re: iff.library iff.l.main stub existing?
Posted: Tue Oct 25, 2011 10:13 pm
by JosDuchIt
Many thanks Thomas
and it seems to work OK
Re: iff.library iff.l.main stub working? (was "existing?")
Posted: Thu Oct 27, 2011 7:17 pm
by JosDuchIt
@thomasrapp
After more testing, i think i may have said to soon the stub was working. The 'undefined references to IFF functions came later.
i have the following in libs:
iff.l.main 6869 25-10-11 22:18:26
iff.library 3160 24-05-93 15:51:10 Version 323.2.2
i tried to compile the EasyExample.c modified for OS4 , it is here:
http://users.online.be/AD/EasyExampleOS4.c
gcc Datas:Programmeren/IFF_Lib/Examples/EasyExampleOS4.c -lauto -o ram:Easy
iff.h is in the same drawer as this example
I get a lot of undefined references
Datas:Programmeren/IFF_Lib/Examples/EasyExampleOS4.c: In function 'main':
Datas:Programmeren/IFF_Lib/Examples/EasyExampleOS4.c:147: warning: assignment from incompatible pointer type
/tmp/ccewaoFQ.o: In function `DisplayILBM':
EasyExampleOS4.c:(.text+0x2b0): undefined reference to `IFFL_OpenIFF'
EasyExampleOS4.c:(.text+0x2cc): undefined reference to `IFFL_GetBMHD'
EasyExampleOS4.c:(.text+0x33c): undefined reference to `IFFL_GetViewModes'
EasyExampleOS4.c:(.text+0x39c): undefined reference to `IFFL_GetColorTab'
EasyExampleOS4.c:(.text+0x418): undefined reference to `IFFL_DecodePic'
EasyExampleOS4.c:(.text+0x4c8): undefined reference to `IFFL_CloseIFF'
/tmp/ccewaoFQ.o: In function `main':
EasyExampleOS4.c:(.text+0x660): undefined reference to `IFFL_IFFError'
Re: iff.library iff.l.main stub working? (was "existing?")
Posted: Thu Oct 27, 2011 8:16 pm
by chris
@JosDuchIt
You'll need to change all the open/close library stuff so it also obtains/drops the interface.
The lack of an struct IFFIFace *IIIF is most likely to be the cause.
Re: iff.library iff.l.main stub existing?
Posted: Fri Oct 28, 2011 10:48 am
by JosDuchIt
@chris
I brushed up the code as suggested
http://users.online.be/AD/EasyExampleOS4.c
I still get the same undefined refrences to IFFL_functions
Re: iff.library iff.l.main stub existing?
Posted: Fri Oct 28, 2011 11:28 am
by salass00
@JosDuchIt
You're code doesn't work because it doesn't include proto/iff.h file.
For any library you want to use functions from you should always include the appropriate proto/libname.h file in your code.
Re: iff.library iff.l.main stub existing?
Posted: Fri Oct 28, 2011 3:55 pm
by JosDuchIt
@salasso
Thanks, a big step forward.
I did put the OS4/include/proto/iff.h OS4/include/inlines4/iff.h and OS4/include/interfaces/iff.h in the SDK in the include_h/ subdrawers proto/ inlines4/ and interfaces/ respectively and kept
the OS4/Include/iff.h in the same drawer as the source.
I only have one 'indefined reference' left
/tmp/cc6KBeGa.o: In function `DisplayILBM':
EasyExampleOS4.c:(.text+0x554): undefined reference to `IFFL_CloseIFF'
Doing a search for IFFL_CloseIFF i find that it is only present in
os4/fd/iff_lib.fd
whereas other functions appear also in
OS4/include/inlines4/iff.h
OS4/include/interfaces/iff.h
OS4/Include/iff.h
as IFFL_CloseIFF is the first function listed in the autodoc, i guess something went wring with the generation of the stub?
I don't see how to complete those files manually
If somebody has them ?
Thomas?