Re: z88dk compile problem




Paul F. Johnson wrote:

> I've set up the environment variables required for building z88dk
> (namely Z80_OZFILES, ZCCCFG and adjusted PATH). I can run make without a
> problem and the binaries are created.
>
> When I run make libs
> I keep getting the same error (which I also see
> when compiling anything in the examples/spectrum directory). The error
> reads

Hmm, to make the libs just change to the libsrc
directory and enter "make". "make install" will
move the libs to the right destination directory
and "make clean" will clean up everything for you.

I think all download pkgs come with the z80 libraries
already made (it certainly did with the Windows
installer) so this step shouldn't be necessary.

> zcc -vn -make-lib brotherdor.c
> Unrecognised argument: Cz+z88
> Any ideas on this and how to fix it?

To compile C programs you need to specify a target
machine and link in the file io library. Here's the
same compile command for a Spectrum target:

zcc +zx -vn -create-app brotherdor.c -lndos

The +zx means Spectrum and the -lndos links to
the ndos file io library (ie the no dos lib
as the Spectrum doesn't have dos functions).
+3DOS is supported, however, and if you want
to use the +3 disk you'd link to something
else. The -create-app option creates a self
loading tap file (the binary is also made).

The Makefile in the examples/spectrum dir shows
how to compile each of the examples.

Now it could be I have missed the point because
I'm not sure why you have "-make-lib" in there :)


Alvin

.



Relevant Pages

  • Re: Two gnome versions installed -> compiling GTK/Gnome programs: undefined reference to `g_retur
    ... >try to compile programs and they complain about undefined ... >Any idea how to tell the ./configure script not to use the old libraries? ... you have to watch your pkgconfig. ... /usr/local/lib/pkgconfig and see what libs they point to. ...
    (comp.os.linux.misc)
  • Re: ppc -> intel
    ... You cannot be sure the libraries are in the same path also on systems ... or a static library.a for intel macs. ... I use either of these libs while creating the universal ... compile through command line it's quite simple just set your compiler ...
    (comp.sys.mac.programmer.help)
  • Re: Compiling for 32-bit on AMD64
    ... The way I would do it is to explicitly say where the libs are ... It determines where libraries are installed, ... But it can link OK at runtime if I compile it before removing libX11.so. ... Should ldconfig create libX11.so? ...
    (uk.comp.os.linux)
  • Re: Install from source on a x86_64 machine
    ... think of is that the configure script doesn't check the mode the OS is ... running in and take appropriate steps, ie.e compile the libs in both ... I know this is a problem because when I try and compile up mod_python ... that is required for libraries on a 64bit OS. ...
    (comp.lang.python)
  • Re: P4 Xeon compatibility with 5.0.5
    ... > because of the changes to the shared libraries. ... get new libs onto old box so binaries can use them. ... ship your app with copies of any new libs that your app needs, ... > into line with the typical SCO system, I beleive the rate of change ...
    (comp.unix.sco.misc)