On January 17, 2008 02:48:04 am Jacques Pelletier wrote:
> On January 17, 2008 02:06:15 am Jacques Pelletier wrote:
> > Hi,
> >
> > I just installed the latest version of SDCC, 2.7.0, compiled from the
> > sources. Previously, I had the package SDCC 2.6.x installed through
> > Synaptic on Ubuntu.
> >
> > One of my project compiled and linked fine with SDCC 2.6.
> > Now with SDCC 2.7, it compiles but the linker gave "Invalid file type"
> >
> > I tried changing the -i main.ihx to -s main.s19, same result.
> >
> > SDCC seems to produce valid object code. It seems that the linker doesn't
> > like the files '*.o' produced by SDCC.
> >
> > Any ideas, anyone?
> >
> >
> > JP
>
> I tried modifying the makefile by replacing the link command with this:
>
> main.ihx:  $(OBJECTS)
>       $(CC) $(MFLAGS) $(LFLAGS) $(OBJECTS)
>
> SDCC now complains that it doesn't know what to do with the .o files, which
> are all there and properly compiled.
>
> Here is the modified makefile, and a makefile from another project, which
> compiles and links properly, with the same version of SDCC and executing
> from the same shell (so that the same environment variables are used).
>
> I'm suspecting some black magic here... :)

When linking, it was missing the option -mz80. Now the project compiles and 
links.

>
> JP



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
Sdcc-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sdcc-user

Reply via email to