X-Recipient: archive-cygwin@delorie.com
X-SWARE-Spam-Status: No, hits=-2.4 required=5.0	tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL,TW_YG
X-Spam-Check-By: sourceware.org
Message-Id: <1337334953.24356.140661077217501.3F01724A@webmail.messagingengine.com>
From: Filipp Gunbin <fgunbin@fastmail.fm>
To: himoundary <himanshu2004@gmail.com>, cygwin@cygwin.com
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Type: text/plain
Subject: Re: Making Unix like paths work when using java program from Cygwin
Date: Fri, 18 May 2012 13:55:53 +0400
In-Reply-To: <33869106.post@talk.nabble.com>
References: <33869106.post@talk.nabble.com>
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
Precedence: bulk
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie.com@cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

> Is there a way to get the equivalent of the "native" javac and java
> programs one would find on a typical Linux workstation. If not, can I
> accomplish what I want using the gcc java compiler gjc?

Even if you compile with gjc, you still need the virtual machine, which
is as far as I know not available.

But you have another option.

You can make your Java program OS-independent (as it should be) and run
it from the shell script in Cygwin using a usual Java VM for Windows.
For that, you need to fix paths in environment variables appropriately
(unix->windows) using the cygpath utility before starting java.

You can see examples of this in startup scripts of some well-established
Java projects like Tomcat, ActiveMQ or JBoss.

--
Filipp Gunbin

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

