Return-Path: Delivered-To: apmail-ant-user-archive@www.apache.org Received: (qmail 56682 invoked from network); 22 Jan 2007 13:25:54 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 22 Jan 2007 13:25:54 -0000 Received: (qmail 26780 invoked by uid 500); 22 Jan 2007 13:25:46 -0000 Delivered-To: apmail-ant-user-archive@ant.apache.org Received: (qmail 26749 invoked by uid 500); 22 Jan 2007 13:25:46 -0000 Mailing-List: contact user-help@ant.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Help: List-Post: List-Id: "Ant Users List" Reply-To: "Ant Users List" Delivered-To: mailing list user@ant.apache.org Received: (qmail 26707 invoked by uid 99); 22 Jan 2007 13:25:46 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 22 Jan 2007 05:25:46 -0800 X-ASF-Spam-Status: No, hits=2.5 required=10.0 tests=HTML_MESSAGE,NO_REAL_NAME X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: local policy) Received: from [85.158.137.35] (HELO mail134.messagelabs.com) (85.158.137.35) by apache.org (qpsmtpd/0.29) with SMTP; Mon, 22 Jan 2007 05:25:35 -0800 X-VirusChecked: Checked X-Env-Sender: Mike.Horn@wincanton.co.uk X-Msg-Ref: server-5.tower-134.messagelabs.com!1169472312!22789403!1 X-StarScan-Version: 5.5.10.7; banners=wincanton.co.uk,-,- X-Originating-IP: [194.73.81.11] Received: (qmail 21553 invoked from network); 22 Jan 2007 13:25:12 -0000 Received: from mailhost.wincanton.co.uk (HELO windom01.wl.wincanton-local.co.uk) (194.73.81.11) by server-5.tower-134.messagelabs.com with SMTP; 22 Jan 2007 13:25:12 -0000 In-Reply-To: <45B4A51B.7050508@apache.org> To: "Ant Users List" Subject: Re: java errors when running build file MIME-Version: 1.0 X-Mailer: Lotus Notes Release 6.5.3 September 14, 2004 Message-ID: From: Mike.Horn@wincanton.co.uk Date: Mon, 22 Jan 2007 13:23:46 +0000 X-MIMETrack: Serialize by Router on WINDOM01/Wincanton/UK(Release 6.5.4FP3 | January 13, 2006) at 22/01/2007 13:23:48, Serialize complete at 22/01/2007 13:23:48 Content-Type: multipart/alternative; boundary="=_alternative 0049B7B08025726B_=" X-Virus-Checked: Checked by ClamAV on apache.org --=_alternative 0049B7B08025726B_= Content-Type: text/plain; charset="US-ASCII" Thanks all for your input, especially to Steve for your laymans explanation at the foot of your last post! As this build file will be run by a cron job in the wee small hours of the morning, and doesn't require any user input, I don't think I need to bother too much about my JVM's lack uf support for the full signal set. I will report the problem to my vendor though. Mike Steve Loughran 22/01/2007 11:50 Please respond to "Ant Users List" To Ant Users List cc Subject Re: java errors when running build file Dalibor Topic wrote: > Steve Loughran apache.org> writes: > >> Mike.Horn wincanton.co.uk wrote: >>> Hello >>> >>> HP-UX11i >>> Java 1.3 >>> ANT v.1.7.0 >>> >>> $ ant -f Unix_Build.xml >>> Buildfile: Unix_Build.xml >>> [property] java.lang.reflect.InvocationTargetException: >>> java.lang.IllegalArgume >>> ntException: Unknown signal: HUP >>> [property] at sun.misc.Signal.(Unknown Source) >>> [property] at java.lang.Terminator.setup(Unknown Source) > > [snip] > >> In smartfrog we have to wrap signal setup with an exception catcher, as >> it fails earlly on on the kaffe JVMs. We catch it and warn that the tool >> is not tested on those JVMs and so use at your own risk... > > We don't have an implementation of sun.misc.Signal in Kaffe, I don't think it's > part of the standard API. > no, its not, which is why my work project skips the whole signal handling setup -its currently sun JVM only. If ant is doing some signal handling during an exec it should catch a failure and continue with the run. (pause) OK. here's the source in question. 1. ant uses reflection to get the shutdown hook. public ProcessDestroyer() { try { // check to see if the shutdown hook methods exists // (support pre-JDK 1.3 VMs) Class[] paramTypes = {Thread.class}; addShutdownHookMethod = Runtime.class.getMethod("addShutdownHook", paramTypes); removeShutdownHookMethod = Runtime.class.getMethod("removeShutdownHook", paramTypes); // wait to add shutdown hook as needed } catch (NoSuchMethodException e) { // it just won't be added as a shutdown hook... :( } catch (Exception e) { e.printStackTrace(); } } If there is no method (as with kaffe), then nothing is printed. 2. when the hook is added, if the method throws an exception, then yes, it is printed. private void addShutdownHook() { if (addShutdownHookMethod != null && !running) { destroyProcessThread = new ProcessDestroyerImpl(); Object[] args = {destroyProcessThread}; try { addShutdownHookMethod.invoke(Runtime.getRuntime(), args); added = true; } catch (IllegalAccessException e) { e.printStackTrace(); } catch (InvocationTargetException e) { Throwable t = e.getTargetException(); if (t != null && t.getClass() == IllegalStateException.class) { // shutdown already is in progress running = true; } else { e.printStackTrace(); } } } } This code is not tied to a project, and so cannot use Project.log(). Otherwise I'd downgrade the trace to a -verbose level. As it is, I think we just need to leave it in. Mike: this stack trace is a warning that your JVM doesnt support the complete signal set. It is mostly harmless, but you should know that if you kill ant with a control-C or similar, processes it starts may hang around, as ant wont get told. Other than that, its a message you can ignore. -steve --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@ant.apache.org For additional commands, e-mail: user-help@ant.apache.org *************************************************************** Wincanton plc is a leading European provider of supply chain solutions. We design, implement and operate creative solutions for customers in 15 countries. Our business has a turnover of over EUR2.7bn /GBP1.81bn and employs 27,000 staff across 360 locations. Warehousing, transport and specialist services are provided for customers in a range of sectors including automotive, retail, FMCG, petrochemicals and manufacturing. Further information on our unique achievements and competencies can be found by visiting www.wincanton.co.uk **************************************************************** This e-mail and any files transmitted with it are confidential and intended solely for the use of the individual(s) to whom it is addressed. If you have received this e-mail in error please contact IT Service Desk on +44 (0) 870 870 9393 or e-mail mail.monitor@wincanton.co.uk Any views or opinions expressed are solely those of the author and do not necessarily represent those of Wincanton plc or any of its subsidiary companies. Unauthorised publication, use, dissemination, forwarding, printing or copying of this e-mail and its associated attachment(s) is strictly prohibited. Wincanton plc, Methuen Park, Chippenham, Wiltshire SN14 0WT. **************************************************************** --=_alternative 0049B7B08025726B_=--