delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/11/26/17:56:54

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-ID: <20021126225633.86241.qmail@web20006.mail.yahoo.com>
Date: Tue, 26 Nov 2002 14:56:33 -0800 (PST)
From: Joshua Daniel Franklin <joshuadfranklin AT yahoo DOT com>
Subject: Re: accessing cygwin functions from non-cygwin app
To: JBeulich AT novell DOT com, cygwin AT cygwin DOT com
MIME-Version: 1.0

> while I was trying to understand this on my own I'm ready to give up. All I
> intended was translating a coupld of filenames from cygwin to Win32 notation 
> in an otherwise Win32-only app.

> I have a problem using it as the application cannot be expected to have
> access to the perprocess class (nor is the app a C++ app, and neither is it
> being built with gcc) or other cygwin sources, and it also cannot link
against
> libcygwin.a.

Well, I don't follow all of what you're saying, but basically:

1) If you want to use the functions provided in the Cygwin DLL, you have to
   link against it. If you want to do this with gcc, there are lots of
   examples in the cygwin CVS (cygpath) or cygutils (mkshortcut). There is
   also an API reference available on the website.

2) If you don't want to link against the Cygwin DLL, you need to do your
   own translation. I believe it's pretty straighforward. There are some
   registry entries that provide a mount table for '/' and other directories.
   In most cases, this is "C:\cygwin", so /home/foo/ is c:\cygwin\home\foo\
   and so on. I'm assuming here that you're familiar with both Unix and 
   Windows path-styles.

Hope it helps.

__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019