From owner-freebsd-questions@FreeBSD.ORG Tue May 19 22:01:46 2009 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 61793106564A for ; Tue, 19 May 2009 22:01:46 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from mx01.qsc.de (mx01.qsc.de [213.148.129.14]) by mx1.freebsd.org (Postfix) with ESMTP id A69878FC0A for ; Tue, 19 May 2009 22:01:45 +0000 (UTC) (envelope-from freebsd@edvax.de) Received: from r55.edvax.de (port-92-195-124-142.dynamic.qsc.de [92.195.124.142]) by mx01.qsc.de (Postfix) with ESMTP id 3AD0E3D472; Wed, 20 May 2009 00:01:43 +0200 (CEST) Received: from r55.edvax.de (localhost [127.0.0.1]) by r55.edvax.de (8.14.2/8.14.2) with SMTP id n4JM1bmh004204; Wed, 20 May 2009 00:01:37 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Wed, 20 May 2009 00:01:37 +0200 From: Polytropon To: francis keyes Message-Id: <20090520000137.3d46fcb2.freebsd@edvax.de> In-Reply-To: References: Organization: EDVAX X-Mailer: Sylpheed 2.4.7 (GTK+ 2.12.1; i386-portbld-freebsd7.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: freebsd-questions@freebsd.org Subject: Re: compiling FreeBSD date on Linux X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 19 May 2009 22:01:46 -0000 On Tue, 19 May 2009 18:19:21 -0300, francis keyes 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 > http://www.freebsd.org/cgi/cvsweb.cgi/src/bin/date/ and tried to compile it > but I get an error from the Makefile: > Makefile:9: *** missing separator. Stop. First of all, it seems that it's not that easy. FreeBSD's make is, if I am correct, a different one than the Linux make. It uses - if you look into date's Makefile, an include file, named bsd.prog.mk which is located outside of the date/ directory, this is /usr/share/mk/bsd.prog.mk or /usr/src/share/mk/bsd.prog.mk or /usr/src/tools/build/mk/bsd.prog.mk. You could try to write an own Makefile on Linux, or try to work without one... > I suspect this is the first of many errors I will run into during this > process. Can anyone help me out with this or tell me if there is an easier > way to get this version of the date command running in Linux? I'm not sure, but it's possible that FreeBSD can be used to compile date so it will run on Linux (cross-compier). Because I never tried this, I can't tell you how to achieve this. Furthermore, I'm not sure in how far date hooks into the FreeBSD kernel in order to work. It's completely possible that it would be easier to implement FreeBSD's date functionality in Linux's date command itself ("from scratch"). -- Polytropon >From Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...