Re: compiling FreeBSD date on Linux

2009-05-23 Thread francis keyes
I added #include time.h to date .c but still get some errors: date.c: In function ‘setthetime’: date.c:192: warning: assignment makes pointer from integer without a cast /tmp/ccZTmvsY.o: In function `netsettime': netdate.c:(.text+0x1f1): undefined reference to `strlcpy' collect2: ld returned 1

Re: compiling FreeBSD date on Linux

2009-05-23 Thread Roland Smith
On Sat, May 23, 2009 at 05:00:08PM -0300, francis keyes wrote: I added #include time.h to date .c but still get some errors: date.c: In function *setthetime*: date.c:192: warning: assignment makes pointer from integer without a cast /tmp/ccZTmvsY.o: In function `netsettime':

Re: compiling FreeBSD date on Linux

2009-05-23 Thread Polytropon
Te strlcpy function is part of the system's C library, libc. It is declared in string.h. Did you #include string.h and check if the Linux C library has this function included? If it has, man strlcpy should mention it. Oh wait, when talking about Linux, it's possible that there is no

Re: compiling FreeBSD date on Linux

2009-05-22 Thread Roland Smith
On Thu, May 21, 2009 at 09:08:31PM -0300, francis keyes wrote: I patched date.c and tried to compile but I get a few errors, as you suspected: In file included from date.c:59: vary.h:35: warning: *struct tm* declared inside parameter list vary.h:35: warning: its scope is only this

Re: compiling FreeBSD date on Linux

2009-05-21 Thread francis keyes
I patched date.c and tried to compile but I get a few errors, as you suspected: In file included from date.c:59: vary.h:35: warning: ‘struct tm’ declared inside parameter list vary.h:35: warning: its scope is only this definition or declaration, which is probably not what you want date.c: In

Re: compiling FreeBSD date on Linux

2009-05-20 Thread francis keyes
Hmm... the date program looks pretty simple but I don't understand the Makfile: #@(#)Makefile8.1 (Berkeley) 5/31/93 # $FreeBSD: src/bin/date/Makefile,v 1.11.30.1 2009/04/15 03:14:26 kensmith Exp $ PROG=date SRCS=date.c netdate.c vary.c DPADD=${LIBUTIL} LDADD=-lutil

Re: compiling FreeBSD date on Linux

2009-05-20 Thread Roland Smith
On Wed, May 20, 2009 at 02:45:59PM -0300, francis keyes wrote: Hmm... the date program looks pretty simple but I don't understand the Makfile: #@(#)Makefile8.1 (Berkeley) 5/31/93 # $FreeBSD: src/bin/date/Makefile,v 1.11.30.1 2009/04/15 03:14:26 kensmith Exp $ PROG=date SRCS=

Re: compiling FreeBSD date on Linux

2009-05-20 Thread Mel Flynn
On Wednesday 20 May 2009 19:45:59 francis keyes wrote: Hmm... the date program looks pretty simple but I don't understand the Makfile: #@(#)Makefile8.1 (Berkeley) 5/31/93 # $FreeBSD: src/bin/date/Makefile,v 1.11.30.1 2009/04/15 03:14:26 kensmith Exp $ PROG=date SRCS=date.c

Re: compiling FreeBSD date on Linux

2009-05-20 Thread Polytropon
On Wed, 20 May 2009 14:45:59 -0300, francis keyes fke...@gmail.com wrote: Hmm... the date program looks pretty simple but I don't understand the Makfile: #@(#)Makefile8.1 (Berkeley) 5/31/93 # $FreeBSD: src/bin/date/Makefile,v 1.11.30.1 2009/04/15 03:14:26 kensmith Exp $ PROG=

Re: compiling FreeBSD date on Linux

2009-05-20 Thread Mel Flynn
#warning Pedantic mode on #define TOPIC BSD build system tricks On Wednesday 20 May 2009 21:57:02 Polytropon wrote: DPADD=${LIBUTIL} Needs to compile what ${LIBUTIL} point to, usually the libutil directory in the src/ tree. This is the actual build dependency and the var is defined in

Re: compiling FreeBSD date on Linux

2009-05-20 Thread Giorgos Keramidas
On Wed, 20 May 2009 14:45:59 -0300, francis keyes fke...@gmail.com wrote: Hmm... the date program looks pretty simple but I don't understand the Makfile: #@(#)Makefile8.1 (Berkeley) 5/31/93 # $FreeBSD: src/bin/date/Makefile,v 1.11.30.1 2009/04/15 03:14:26 kensmith Exp $ PROG=

Re: compiling FreeBSD date on Linux

2009-05-19 Thread Polytropon
On Tue, 19 May 2009 18:19:21 -0300, francis keyes fke...@gmail.com wrote: I would like to compile the FreeBSD date command for use on Linux because the FreeBSD version has some features that are not present in Linux. I downloaded all the files from

Re: compiling FreeBSD date on Linux

2009-05-19 Thread Chuck Robey
Polytropon wrote: On Tue, 19 May 2009 18:19:21 -0300, francis keyes fke...@gmail.com wrote: I would like to compile the FreeBSD date command for use on Linux because the FreeBSD version has some features that are not present in Linux. I downloaded all the files from