Re: [fpc-pascal] compiling on FreeBSD6 or 7 for target FreeBSD4 possible?
On Thu, 21 Aug 2008 00:39:55 +0200 Marc Santhoff wrote: > for some reason I have to have a compiler creating binaries for FreeBSD > 4 at hand. > Since all computers around here are on the way to FreeBSD 6 or 7 I have > to decide between having a seperate disk or partition or virtual machine > for FreeBSD 4 and setting up a build environment running on v6 and > creating binaries for v4. > Is the latter generally possible? We use a FreeBSD-current host with ports-mgmt/tinderbox to create packages for 5.x, 6.x, 7.x and 8.x. While CURRENT was 7.x we used to package for 4.x as well. You may create a local port of your software and package it for all versions at one host. HTH and WBR -- Boris Samorodov (bsam) Research Engineer, http://www.ipt.ru Telephone & Internet SP FreeBSD committer, http://www.FreeBSD.org The Power To Serve ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] compiling on FreeBSD6 or 7 for target FreeBSD4 possible?
Am Donnerstag, den 21.08.2008, 13:05 +0400 schrieb Boris Samorodov: > On Thu, 21 Aug 2008 00:39:55 +0200 Marc Santhoff wrote: > > > for some reason I have to have a compiler creating binaries for FreeBSD > > 4 at hand. > > > Since all computers around here are on the way to FreeBSD 6 or 7 I have > > to decide between having a seperate disk or partition or virtual machine > > for FreeBSD 4 and setting up a build environment running on v6 and > > creating binaries for v4. > > > Is the latter generally possible? > > We use a FreeBSD-current host with ports-mgmt/tinderbox to create > packages for 5.x, 6.x, 7.x and 8.x. While CURRENT was 7.x we used > to package for 4.x as well. You may create a local port of your > software and package it for all versions at one host. Sounds like it's a good idea - making a port of it is on my list a long time. At least I will not try to do some cross-os-version-compiling, I'd rather use a bootable thumbdrive containing a complete freebsd 4 ... Thank you, Marc ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
[fpc-pascal] missing functions in libc
Hi, I'm trying to compile LPTK 0.9.0 on FreeBSD 4 using a working fpc 2.0.4. I use this compiler for a long time now and never had the symptoms as following: At first the compiler does not find librt and libdl. I know these exist only on Linux and don't know, why they are tried to be pulled in. When I delete the -ldl an -lrt from the link.res and start ppas.sh, the compiler struggles on finding unit libc. If I add an extra -Fu... to the path where it is found, some functions are missing. Some of those are 64bit file system functions like stat64, so I assumed they where newer and tried the libc.pp from fpc 2.0.2, but the same thing happens (see below). Using "man" there where no such functions found, although the man pages on freebsd are generally very good and complete. This never happened to me, I have written some programs using plain gtk1 or functions from foreign libraries (including libc IIRC), but I never had any problem. So I'm stuck. What going on here? How can I repair it? TIA, Marc $ out/ppas.sh Linking out/app_vfd /usr/lib/libc.so: WARNING! setkey(3) not present in the system! /usr/lib/libc.so: warning: this program uses gets(), which is unsafe. /usr/lib/libc.so: warning: mktemp() possibly used unsafely; consider using mkstemp() /usr/lib/libc.so: WARNING! des_setkey(3) not present in the system! /usr/lib/libc.so: WARNING! encrypt(3) not present in the system! /usr/lib/libc.so: warning: tmpnam() possibly used unsafely; consider using mkstemp() /usr/lib/libc.so: warning: this program uses f_prealloc(), which is not recommended. /usr/lib/libc.so: WARNING! des_cipher(3) not present in the system! /usr/lib/libc.so: warning: tempnam() possibly used $ out/ppas.sh Linking out/app_vfd /usr/lib/libc.so: WARNING! setkey(3) not present in the system! /usr/lib/libc.so: warning: this program uses gets(), which is unsafe. /usr/lib/libc.so: warning: mktemp() possibly used unsafely; consider using mkstemp() /usr/lib/libc.so: WARNING! des_setkey(3) not present in the system! /usr/lib/libc.so: WARNING! encrypt(3) not present in the system! /usr/lib/libc.so: warning: tmpnam() possibly used unsafely; consider using mkstemp() /usr/lib/libc.so: warning: this program uses f_prealloc(), which is not recommended. /usr/lib/libc.so: WARNING! des_cipher(3) not present in the system! /usr/lib/libc.so: warning: tempnam() possibly used unsafely; consider using mkstemp() out/libc.o: In function `ERRNO': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/cerrno.inc:9: undefined reference to `__errno_location' out/libc.o: In function `SETERRNO': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/cerrno.inc:15: undefined reference to `__errno_location' out/libc.o: In function `CLK_TCK': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/time.inc:4: undefined reference to `__sysconf' out/libc.o: In function `FSTAT': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:50: undefined reference to `__fxstat' out/libc.o: In function `LSTAT': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:56: undefined reference to `__lxstat' out/libc.o: In function `STAT': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:62: undefined reference to `__xstat' out/libc.o: In function `FSTAT64': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:68: undefined reference to `__fxstat64' out/libc.o: In function `LSTAT64': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:74: undefined reference to `__lxstat64' out/libc.o: In function `STAT64': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:80: undefined reference to `__xstat64' out/libc.o: In function `STAT': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:86: undefined reference to `__xstat' out/libc.o: In function `FSTAT': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:92: undefined reference to `__fxstat' out/libc.o: In function `STAT64': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:98: undefined reference to `__xstat64' out/libc.o: In function `FSTAT64': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:104: undefined reference to `__fxstat64' out/libc.o: In function `LSTAT': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:110: undefined reference to `__lxstat' out/libc.o: In function `LSTAT64': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/sstat.inc:116: undefined reference to `__lxstat64' out/libc.o: In function `_IO_GETC_UNLOCKED': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/libio.inc:11: undefined reference to `__uflow' out/libc.o: In function `_IO_PEEKC_UNLOCKED': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/libio.inc:20: undefined reference to `__underflow' out/libc.o: In function `_IO_PUTC_UNLOCKED': /usr/home/marc/program/fpc-svn/fpc/packages/base/libc/libio.inc:32: undefined reference to `__overflow' out/libc.o: In function `_IO_GETWC_UNLOCKED': /usr/home/marc/program/fpc-svn
Re: [fpc-pascal] missing functions in libc
On Fri, 22 Aug 2008, Marc Santhoff wrote: > Hi, > > I'm trying to compile LPTK 0.9.0 on FreeBSD 4 using a working fpc 2.0.4. > I use this compiler for a long time now and never had the symptoms as > following: > > At first the compiler does not find librt and libdl. I know these exist > only on Linux and don't know, why they are tried to be pulled in. > > When I delete the -ldl an -lrt from the link.res and start ppas.sh, the > compiler struggles on finding unit libc. the libc is only for gnu libc, so the errors are normal. You should try to find out why unit libc is used. Michael. ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal
Re: [fpc-pascal] missing functions in libc
In our previous episode, Marc Santhoff said: > At first the compiler does not find librt and libdl. I know these exist > only on Linux and don't know, why they are tried to be pulled in. libdl is mostly uses for dynamically loading dynamic libraries. Probably that packages declares its own loadlibrary (dlload) equivalents somewhere. > When I delete the -ldl an -lrt from the link.res and start ppas.sh, the > compiler struggles on finding unit libc. That's a Kylix legacy unit. It means that this package was never fully converted to FPC. It only exists for linux/x86 with a glibc. See here : http://wiki.freepascal.org/libc_unit > If I add an extra -Fu... to the path where it is found, some functions > are missing. Some of those are 64bit file system functions like stat64, > so I assumed they where newer and tried the libc.pp from fpc 2.0.2, but > the same thing happens (see below). Using "man" there where no such > functions found, although the man pages on freebsd are generally very > good and complete. That's because they are temporary workarounds for the older linux architectures when they made a 32-bit -> 64-bit off_t transition. They are not even universal on Linux iirc. > This never happened to me, I have written some programs using plain gtk1 > or functions from foreign libraries (including libc IIRC), but I never > had any problem. So I'm stuck. > > What going on here? How can I repair it? Eliminate use of the libc unit, using mostly baseunix, dynlibs and the like (the above url has a longer list). Replace -64 functions by their plain equivalents. (FreeBSD 4+ already has 64-bit off_t) And hope that they didn't use too exotic functions from unit libc. If so, report here. In 2.2.2 some routines to access users/passwords were added, maybe you can take the sources from there (packages/users), and try to get it running under 2.0.4 ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/mailman/listinfo/fpc-pascal