From owner-freebsd-stable@FreeBSD.ORG Sun Aug 3 02:29:23 2008 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 515A31065674 for ; Sun, 3 Aug 2008 02:29:23 +0000 (UTC) (envelope-from andymac@bullseye.apana.org.au) Received: from ipmail05.adl2.internode.on.net (ipmail05.adl2.internode.on.net [203.16.214.145]) by mx1.freebsd.org (Postfix) with ESMTP id C0A798FC0C for ; Sun, 3 Aug 2008 02:29:22 +0000 (UTC) (envelope-from andymac@bullseye.apana.org.au) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AjgNALmxlEg7pzeZ/2dsb2JhbACBUYkSolU X-IronPort-AV: E=Sophos;i="4.31,298,1215354600"; d="scan'208";a="173161225" Received: from ppp59-167-55-153.lns1.cbr1.internode.on.net (HELO bullseye.apana.org.au) ([59.167.55.153]) by ipmail05.adl2.internode.on.net with ESMTP; 03 Aug 2008 11:43:58 +0930 Received: from [192.168.63.10] (tenring.andymac.org [192.168.63.10]) by bullseye.apana.org.au (8.14.2/8.14.2) with ESMTP id m7329im2064442 for ; Sun, 3 Aug 2008 12:09:44 +1000 (EST) (envelope-from andymac@bullseye.andymac.org) Message-ID: <48950685.4020303@bullseye.andymac.org> Date: Sun, 03 Aug 2008 12:14:45 +1100 From: Andrew MacIntyre User-Agent: Thunderbird 2.0.0.14 (OS/2/20080509) MIME-Version: 1.0 To: freebsd-stable@freebsd.org References: <372128.56919.qm@web51502.mail.re2.yahoo.com> <20080802.002039.58462077.imp@bsdimp.com> <4894A9D8.2090606@freebsd.org> <20080802225643.GA84798@onelab2.iet.unipi.it> In-Reply-To: <20080802225643.GA84798@onelab2.iet.unipi.it> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: busybox and small scripting languages on FreeBSD ? (was Re: 80 Mb / enough for 7.x? OK to delete /stand/ and /modules/ ?) X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 03 Aug 2008 02:29:23 -0000 Luigi Rizzo wrote: > Also, what would you suggest as a small scripting language to be used > in this kind of platform for implementing CGI scripts (and preferably > able to use sockets/select) ? > > The various perl/python/php and friend are in the 10MB range once you > pick up a little bit of libraries (sockets etc) and the tangle of > modules they require; awk (which is present in busybox) is ok-ish for > some things, but doing I/O and calling external programs with it is > very unfriendly; I've not tried to do this myself (had no need), but Python does support having its standard library code in a ZIP archive. The .py (source) files can be omitted, so the ZIP archive only needs to contain the byte compiled files (.pyc, and .pyo if you ever use Python's -O option). With a stripped interpreter, I'd estimate you might get an install down to ~6MB, with non-essentials (for an embedded production environment) removed. But you do have to work at it... :-( I hear Lua is compact and capable, including sockets support, but have never looked at it. -- ------------------------------------------------------------------------- Andrew I MacIntyre "These thoughts are mine alone..." E-mail: andymac@bullseye.apana.org.au (pref) | Snail: PO Box 370 andymac@pcug.org.au (alt) | Belconnen ACT 2616 Web: http://www.andymac.org/ | Australia