public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Running a cygwin application on Windows
@ 2014-08-16 10:11 Fernando Gont
  2014-08-16 10:29 ` Achim Gratz
  2014-08-16 10:47 ` Corinna Vinschen
  0 siblings, 2 replies; 8+ messages in thread
From: Fernando Gont @ 2014-08-16 10:11 UTC (permalink / raw)
  To: cygwin

Folks,

I'm the main developer of an open source project
<http://www.si6networks.com/tools/ipv6toolkit>, and was meaning to port
our project to Windows.

My idea was to use cygwin, since I'm not much of a Windows programmer.
Is there any way to produce and ship an exe with the relevant libraries?

I'm not sure which libraries I should grab from cygwin, and where I
should put them on the windows system.

Thoughts?

P.S.: Our project is GPL'ed, so no issues in terms of licenses....

Thanks!

Best regards,
-- 
Fernando Gont
SI6 Networks
e-mail: fgont@si6networks.com
PGP Fingerprint: 6666 31C6 D484 63B2 8FB1 E3C4 AE25 0D55 1D4E 7492





--
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

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Running a cygwin application on Windows
  2014-08-16 10:11 Running a cygwin application on Windows Fernando Gont
@ 2014-08-16 10:29 ` Achim Gratz
  2014-08-16 10:49   ` Corinna Vinschen
  2014-08-16 10:47 ` Corinna Vinschen
  1 sibling, 1 reply; 8+ messages in thread
From: Achim Gratz @ 2014-08-16 10:29 UTC (permalink / raw)
  To: cygwin

Fernando Gont writes:
> My idea was to use cygwin, since I'm not much of a Windows programmer.
> Is there any way to produce and ship an exe with the relevant libraries?

If I understand correctly what you're trying to do, you need to obtain a
commercial license from RedHat for doing so.  Otherwise, if you ship
binaries linked against cygwin1.dll you need to also include all sources
(for Cygwin and your own application) with each such shipment.

> P.S.: Our project is GPL'ed, so no issues in terms of licenses....

You need to read the license for Cygwin:
https://cygwin.com/licensing.html

Alternatively, why don't you just package your application with cygport
and offer it to be included with the distribution?


Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

SD adaptations for Waldorf Q V3.00R3 and Q+ V3.54R2:
http://Synth.Stromeko.net/Downloads.html#WaldorfSDada

--
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

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Running a cygwin application on Windows
  2014-08-16 10:11 Running a cygwin application on Windows Fernando Gont
  2014-08-16 10:29 ` Achim Gratz
@ 2014-08-16 10:47 ` Corinna Vinschen
  2014-08-16 12:59   ` Fernando Gont
  1 sibling, 1 reply; 8+ messages in thread
From: Corinna Vinschen @ 2014-08-16 10:47 UTC (permalink / raw)
  To: cygwin

[-- Attachment #1: Type: text/plain, Size: 1269 bytes --]

On Aug 14 21:52, Fernando Gont wrote:
> Folks,
> 
> I'm the main developer of an open source project
> <http://www.si6networks.com/tools/ipv6toolkit>, and was meaning to port
> our project to Windows.
> 
> My idea was to use cygwin, since I'm not much of a Windows programmer.
> Is there any way to produce and ship an exe with the relevant libraries?

What about just creating a Cygwin package and including and maintaining
it as part of the Cygwin distro?

This way, you can simply point users to the Cygwin distro, never have to
care for keeping third-party libs up-to-date, never have to provide
sources for third party libs on your site, never have to look into
library collisions on user systems, and in general, just have to point
users to the Cygwin distro to fetch your package.

As an additional benefit, you get a lot more help porting your package
on the cygwin and cygwin-apps mailing lists.  In some cases we're also
going as far as patching Cygwin itself for the benefit of a package :)

> P.S.: Our project is GPL'ed, so no issues in terms of licenses....

Right.


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Running a cygwin application on Windows
  2014-08-16 10:29 ` Achim Gratz
@ 2014-08-16 10:49   ` Corinna Vinschen
  2014-08-16 12:59     ` Fernando Gont
  0 siblings, 1 reply; 8+ messages in thread
From: Corinna Vinschen @ 2014-08-16 10:49 UTC (permalink / raw)
  To: cygwin

[-- Attachment #1: Type: text/plain, Size: 980 bytes --]

On Aug 16 12:29, Achim Gratz wrote:
> Fernando Gont writes:
> > My idea was to use cygwin, since I'm not much of a Windows programmer.
> > Is there any way to produce and ship an exe with the relevant libraries?
> 
> If I understand correctly what you're trying to do, you need to obtain a
> commercial license from RedHat for doing so.  Otherwise, if you ship
> binaries linked against cygwin1.dll you need to also include all sources
> (for Cygwin and your own application) with each such shipment.

You only need the buyout license if you want to provide binaries only.
But this is a GPL'ed project, so I assume there's no desire to create
binary-only packages.

> Alternatively, why don't you just package your application with cygport
> and offer it to be included with the distribution?

Yep!


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Running a cygwin application on Windows
  2014-08-16 10:49   ` Corinna Vinschen
@ 2014-08-16 12:59     ` Fernando Gont
  2014-08-16 19:15       ` Michael DePaulo
  2014-08-18  9:22       ` Corinna Vinschen
  0 siblings, 2 replies; 8+ messages in thread
From: Fernando Gont @ 2014-08-16 12:59 UTC (permalink / raw)
  To: cygwin

On 08/16/2014 06:49 AM, Corinna Vinschen wrote:
> On Aug 16 12:29, Achim Gratz wrote:
>> Fernando Gont writes:
>>> My idea was to use cygwin, since I'm not much of a Windows programmer.
>>> Is there any way to produce and ship an exe with the relevant libraries?
>>
>> If I understand correctly what you're trying to do, you need to obtain a
>> commercial license from RedHat for doing so.  Otherwise, if you ship
>> binaries linked against cygwin1.dll you need to also include all sources
>> (for Cygwin and your own application) with each such shipment.
> 
> You only need the buyout license if you want to provide binaries only.
> But this is a GPL'ed project, so I assume there's no desire to create
> binary-only packages.

To be as honest and straightforward as possible :-): My goal is to
provide as may options as possible. I will be producing a Cygwin package
since that seems to be a fair way to contribute to this project. But I
also want to address the user that just knows how to run commands from
the windows command line and wants to quickly download & install my
toolkit to try it. -- hence my goal of also producing some sort of
"binary" distribution (even if the binary package also includes the source).

I'm in the process of reading the online information to produce the
Cygwin package. Are there any pointers to get the other stuff done?

Thanks!
-- 
Fernando Gont
SI6 Networks
e-mail: fgont@si6networks.com
PGP Fingerprint: 6666 31C6 D484 63B2 8FB1 E3C4 AE25 0D55 1D4E 7492





--
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

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Running a cygwin application on Windows
  2014-08-16 10:47 ` Corinna Vinschen
@ 2014-08-16 12:59   ` Fernando Gont
  0 siblings, 0 replies; 8+ messages in thread
From: Fernando Gont @ 2014-08-16 12:59 UTC (permalink / raw)
  To: cygwin

Hi, Corinna,

Thanks so much for your prompt response! Comments in-line...

On 08/16/2014 06:47 AM, Corinna Vinschen wrote:
> On Aug 14 21:52, Fernando Gont wrote:
>> Folks,
>> 
>> I'm the main developer of an open source project 
>> <http://www.si6networks.com/tools/ipv6toolkit>, and was meaning
>> to port our project to Windows.
>> 
>> My idea was to use cygwin, since I'm not much of a Windows
>> programmer. Is there any way to produce and ship an exe with the
>> relevant libraries?
> 
> What about just creating a Cygwin package and including and
> maintaining it as part of the Cygwin distro?

I have just started reading to corresponding documentation to produce
a Cygwin package of my toolkit (be prepared for possible rather
clueless questions, since this would be my first Cygwin package).

That said, I'd also like to produce some sort of standalone binary for
folks that may just want to quickly run the toolkit from the Windows
command line...



> This way, you can simply point users to the Cygwin distro, never
> have to care for keeping third-party libs up-to-date, never have to
> provide sources for third party libs on your site, never have to
> look into library collisions on user systems, and in general, just
> have to point users to the Cygwin distro to fetch your package.
> 
> As an additional benefit, you get a lot more help porting your
> package on the cygwin and cygwin-apps mailing lists.  In some cases
> we're also going as far as patching Cygwin itself for the benefit
> of a package :)

I'll do both. For instance, I've tried to provide packages (or have
them produced one way or another) for as many platforms as possible.
("Turnabout is fair play" some friend once said...)

Thanks!

Best regards,
-- 
Fernando Gont
SI6 Networks
e-mail: fgont@si6networks.com
PGP Fingerprint: 6666 31C6 D484 63B2 8FB1 E3C4 AE25 0D55 1D4E 7492





--
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

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Running a cygwin application on Windows
  2014-08-16 12:59     ` Fernando Gont
@ 2014-08-16 19:15       ` Michael DePaulo
  2014-08-18  9:22       ` Corinna Vinschen
  1 sibling, 0 replies; 8+ messages in thread
From: Michael DePaulo @ 2014-08-16 19:15 UTC (permalink / raw)
  To: cygwin

On Sat, Aug 16, 2014 at 8:57 AM, Fernando Gont <fgont@si6networks.com> wrote:
> On 08/16/2014 06:49 AM, Corinna Vinschen wrote:
>> On Aug 16 12:29, Achim Gratz wrote:
>>> Fernando Gont writes:
>>>> My idea was to use cygwin, since I'm not much of a Windows programmer.
>>>> Is there any way to produce and ship an exe with the relevant libraries?
>>>
>>> If I understand correctly what you're trying to do, you need to obtain a
>>> commercial license from RedHat for doing so.  Otherwise, if you ship
>>> binaries linked against cygwin1.dll you need to also include all sources
>>> (for Cygwin and your own application) with each such shipment.
>>
>> You only need the buyout license if you want to provide binaries only.
>> But this is a GPL'ed project, so I assume there's no desire to create
>> binary-only packages.
>
> To be as honest and straightforward as possible :-): My goal is to
> provide as may options as possible. I will be producing a Cygwin package
> since that seems to be a fair way to contribute to this project. But I
> also want to address the user that just knows how to run commands from
> the windows command line and wants to quickly download & install my
> toolkit to try it. -- hence my goal of also producing some sort of
> "binary" distribution (even if the binary package also includes the source).
>
> I'm in the process of reading the online information to produce the
> Cygwin package. Are there any pointers to get the other stuff done?
>
> Thanks!
> --
> Fernando Gont
> SI6 Networks
> e-mail: fgont@si6networks.com
> PGP Fingerprint: 6666 31C6 D484 63B2 8FB1 E3C4 AE25 0D55 1D4E 7492
[...]

Hi Fernando,

I'm a volunteer contributor to the open source project X2Go.

In addition to producing a Cygwin package, you might want to do what
we currently do for the Windows builds of X2Go Client.

We provide 5 binaries linked against cygwin .DLL files. They are
nxproxy.exe (part "nx-libs", maintained by our project), and 4 patched
OpenSSH binaries: sftp.exe sftp-server.exe ssh-keygen.exe sshd.exe
(We of course provide the source code.)

Our build process needs improvement. But for now, after building those
binaries, our solution is to manually copy all of the following into
one single directory:
1. Those 5 binaries
2. All their cygwin .DLL dependencies
3. sh.exe
We then call the cygwin-built binaries from our native win32 app,
x2goclient.exe, like any other command-line binary. We can also call
them from cmd.exe.

We include the files (in one directory) as part of our NSIS installer

That's all there is to it if you only care about a small number of our
binaries working, and their dependencies don't require any directory
structure.

----

More info:

1. Our entire Windows build process is documented here. :
http://wiki.x2go.org/doku.php/wiki:development:build-howto-mswin:x2goclient

2. How we handle Cygwin updates is a larger discussion. Basically,
whenever we update cygwin, we rebuild our .binaries.  And I monitor
cygwin-announce for any security updates. Usually when there is a
security update (e.g., to openssl), we update the vulnerable.DLL files
individually and refer to it as a new "build" of x2goclient at version
X.

3. We do not package nx-libs for Cygwin because it is useless without
X2Go Client for Windows, which is only available for native win32, and
which in turn has native win32 dependencies.

4. We do not try to upstream our SSH patch because it is specific to
X2Go's needs.

5. You can determine what source package a file is from by running
"cygcheck". For example:
$ cygcheck -f /usr/bin/cygcrypto-1.0.0.dll
libopenssl100-1.0.1i-1
I do not know of an easy way to determine what binary package it is
from. However, the cygwin mirrors keep all the binary packages (and
the 1 source package) under a directory named after the source
package. For example:
ftp://mirrors.kernel.org/sourceware/cygwin/x86/release/openssl/
So after looking at the contents of the tarballs, I found it in this
binary package
ftp://mirrors.kernel.org/sourceware/cygwin/x86/release/openssl/libopenssl100/libopenssl100-1.0.1i-1.tar.xz

-Mike DePaulo

--
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

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: Running a cygwin application on Windows
  2014-08-16 12:59     ` Fernando Gont
  2014-08-16 19:15       ` Michael DePaulo
@ 2014-08-18  9:22       ` Corinna Vinschen
  1 sibling, 0 replies; 8+ messages in thread
From: Corinna Vinschen @ 2014-08-18  9:22 UTC (permalink / raw)
  To: cygwin

[-- Attachment #1: Type: text/plain, Size: 3094 bytes --]

On Aug 16 08:57, Fernando Gont wrote:
> On 08/16/2014 06:49 AM, Corinna Vinschen wrote:
> > On Aug 16 12:29, Achim Gratz wrote:
> >> Fernando Gont writes:
> >>> My idea was to use cygwin, since I'm not much of a Windows programmer.
> >>> Is there any way to produce and ship an exe with the relevant libraries?
> >>
> >> If I understand correctly what you're trying to do, you need to obtain a
> >> commercial license from RedHat for doing so.  Otherwise, if you ship
> >> binaries linked against cygwin1.dll you need to also include all sources
> >> (for Cygwin and your own application) with each such shipment.
> > 
> > You only need the buyout license if you want to provide binaries only.
> > But this is a GPL'ed project, so I assume there's no desire to create
> > binary-only packages.
> 
> To be as honest and straightforward as possible :-): My goal is to
> provide as may options as possible. I will be producing a Cygwin package
> since that seems to be a fair way to contribute to this project. But I
> also want to address the user that just knows how to run commands from
> the windows command line and wants to quickly download & install my
> toolkit to try it. -- hence my goal of also producing some sort of
> "binary" distribution (even if the binary package also includes the source).

The binary package doesn't have to provide the sources, but your
download site would have to provide the sources of the Cygwin DLL
version you packed with your binary package.

The problem is, a user with an existing Cygwin installation might run
into trouble after installing your standalone package.  A user
installing Cygwin after installing your standalone package might run
into trouble, too.  Even though Cygwin tries its best to keep
installations separate, this breaks if multiple Cygwin DLLs of different
version numbers are in $PATH, or if the user tries to use Cygwin tools
from different installation paths on the same command line.  That's an
unfortunate side-effect of Cygwin trying to emulate a bit of an OS :}

So we'd like to ask you to install a Cygwin DLL only if there's no
Cygwin installation present.  Ideally you check if

  HKLM/Software/Cygwin/setup/rootdir or
  HKLM/Software/Cygwin/rhsetup/rootdir

or, if it's a 32 bit installation on a 64 bit Windows

  HKLM/Software/Wow6432Node/Cygwin/setup/rootdir or
  HKLM/Software/Wow6432Node/Cygwin/rhsetup/rootdir

exist and just install your tool into the Cygwin /bin path.

Alternatively, if you find a Cygwin installation, you could just point
the user to the cygwin distro to install from there.  Both solutions
don't fix the problems which might occur when installing Cygwin after
installing your tool, but we might be lucky there ;)

> I'm in the process of reading the online information to produce the
> Cygwin package. Are there any pointers to get the other stuff done?

"other stuff?"


Corinna

-- 
Corinna Vinschen                  Please, send mails regarding Cygwin to
Cygwin Maintainer                 cygwin AT cygwin DOT com
Red Hat

[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2014-08-18  9:22 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-08-16 10:11 Running a cygwin application on Windows Fernando Gont
2014-08-16 10:29 ` Achim Gratz
2014-08-16 10:49   ` Corinna Vinschen
2014-08-16 12:59     ` Fernando Gont
2014-08-16 19:15       ` Michael DePaulo
2014-08-18  9:22       ` Corinna Vinschen
2014-08-16 10:47 ` Corinna Vinschen
2014-08-16 12:59   ` Fernando Gont

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).