Re: set XATTR_SIZE_MAX and XATTR_LIST_MAX in cygwin/limits.h

2023-12-22 Thread Philippe Cerfon via Cygwin
Hey Marco.

On Fri, Dec 22, 2023 at 5:46 AM Marco Atzeri  wrote:
> I am trying to backport on 3.9.18 for Cygwin

Great to hear!

I think it should be fairly easy. The only thing really needed on the
CPython side is USE_XATTRS being defined.

Regards,
Philippe

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


Re: set XATTR_SIZE_MAX and XATTR_LIST_MAX in cygwin/limits.h (was: python + XATTRs under cygwin?)

2023-05-30 Thread Philippe Cerfon via Cygwin
Hey Marco.

On Tue, May 30, 2023 at 1:43 PM marco atzeri  wrote:
> > > Currently, the most recent version of Python in cygwin is 3.9.9, which
>
> latest is 3.9.16
> https://cygwin.com/packages/summary/python39-src.html

Oops, sorry. For some reason I had 3.9.9 in mind which is however
simply the oldest version on that page.


> I will look on that, but do not expect anything in short term

Thanks :-)

Regards,
Philippe

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


Re: set XATTR_SIZE_MAX and XATTR_LIST_MAX in cygwin/limits.h (was: python + XATTRs under cygwin?)

2023-05-30 Thread Philippe Cerfon via Cygwin
Just for the records:

I've made a PR against CPython that would enable XATTRs with Cygwin:
https://github.com/python/cpython/pull/105075

and sent a patch against newlib, which is AFAICS the right place to
have the XATTR_*_MAX exported:
https://sourceware.org/pipermail/newlib/2023/020347.html

Thanks,
Philippe

On Tue, May 30, 2023 at 3:37 AM Philippe Cerfon  wrote:
>
> Hey.
>
> I did some further tests as described in detail at
> https://github.com/python/cpython/issues/90026#issuecomment-1567631574
> and it turns out that Python's code would already support XATTRs on
> Cygwin if the necessary defines were in place.
>
> Currently, the most recent version of Python in cygwin is 3.9.9, which
> uses the following check in cpython/Modules/posixmodule.c:
>#if defined(HAVE_SYS_XATTR_H) && defined(__GLIBC__) &&
> !defined(__FreeBSD_kernel__) && !defined(__GNU__)
>
> in order to determine whether the XATTR code should be compiled or not.
>
> In CPython’s master this was changed to:
>#if defined(HAVE_SYS_XATTR_H) && defined(__linux__) &&
> !defined(__FreeBSD_kernel__) && !defined(__GNU__)
>
> I plan on making a PR against CPython, which would also set the
> necessary symbol, if __CYGWIN__ is defined.
>
>
> There are however two problems:
> 1) Compilation then fails, as the code needs the symbols
> XATTR_SIZE_MAX and XATTR_LIST_MAX, which on Linux are defined in
> linux/limits.h as:
>#define XATTR_SIZE_MAX 65536/* size of an extended attribute
> value (64k) */
>#define XATTR_LIST_MAX 65536/* size of extended attribute
> namelist (64k) */
>
> This would need to be added to cygwin/limits.h with whichever values
> are proper for Cygwin (not sure how to find out?)
>
>
> 2) I guess the changes in CPython won't be backported (and it's not
> even merged)... so Cygwin's Python maintainer will hopefully find the
> time to package newer versions.
> So there will probably quite some time, until it finally works in Python.
>
>
> Anyway, whom can I ask or (1)?
>
>
> Thanks,
> Philippe.

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


Re: set XATTR_SIZE_MAX and XATTR_LIST_MAX in cygwin/limits.h (was: python + XATTRs under cygwin?)

2023-05-29 Thread Philippe Cerfon via Cygwin
Hey.

I did some further tests as described in detail at
https://github.com/python/cpython/issues/90026#issuecomment-1567631574
and it turns out that Python's code would already support XATTRs on
Cygwin if the necessary defines were in place.

Currently, the most recent version of Python in cygwin is 3.9.9, which
uses the following check in cpython/Modules/posixmodule.c:
   #if defined(HAVE_SYS_XATTR_H) && defined(__GLIBC__) &&
!defined(__FreeBSD_kernel__) && !defined(__GNU__)

in order to determine whether the XATTR code should be compiled or not.

In CPython’s master this was changed to:
   #if defined(HAVE_SYS_XATTR_H) && defined(__linux__) &&
!defined(__FreeBSD_kernel__) && !defined(__GNU__)

I plan on making a PR against CPython, which would also set the
necessary symbol, if __CYGWIN__ is defined.


There are however two problems:
1) Compilation then fails, as the code needs the symbols
XATTR_SIZE_MAX and XATTR_LIST_MAX, which on Linux are defined in
linux/limits.h as:
   #define XATTR_SIZE_MAX 65536/* size of an extended attribute
value (64k) */
   #define XATTR_LIST_MAX 65536/* size of extended attribute
namelist (64k) */

This would need to be added to cygwin/limits.h with whichever values
are proper for Cygwin (not sure how to find out?)


2) I guess the changes in CPython won't be backported (and it's not
even merged)... so Cygwin's Python maintainer will hopefully find the
time to package newer versions.
So there will probably quite some time, until it finally works in Python.


Anyway, whom can I ask or (1)?


Thanks,
Philippe.

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


python + XATTRs under cygwin?

2023-05-16 Thread Philippe Cerfon via Cygwin
Hey there.

Is there any known way to use XATTRs (which Cygwin seems to support in
some way, at least the standard attr(1) tool seems to work and somehow
map them into the Windows world) with Python?

The `os` module of Python3 (>3.3) comes with:
os.getxattr()
os.listxattr()
os.removexattr()
os.setxattr()
(see https://docs.python.org/3/library/os.html#linux-extended-attributes)
but these seem to be missing from the Cygwin python packages.

There is even an upstream bug
(https://github.com/python/cpython/issues/90026) about this, which has
however been closed (not because it would be fixed, but because Cygwin
is no officially maintained platform).


There are two external python modules that support xattrs:
python-xattr (https://github.com/xattr/xattr)
python-pyxattr (https://pyxattr.k1024.org/)
but neither seems to be available in Cygwin.


Any ideas or change to get one of these (ideally the ones from os) running?

Thanks,
Philippe

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


Re: have cygwin setup.exe signed and/or in the MS store

2023-05-16 Thread Philippe Cerfon via Cygwin
Hey there.

Now that sourceware seems to be under he SFC umbrella, I assume Cygwin
is so as well?

If so, could it perhaps be reconsidered, whether funding (from SFC)
can be found for buying some signing certs for setup.exe?

Regards,
Philippe.

On Thu, Apr 13, 2023 at 2:00 AM Philippe Cerfon  wrote:
>
> Hey.
>
> On Wed, Apr 12, 2023 at 3:35 PM Andrey Repin  wrote:
> > msgid:camu-taupf3dzpye3xj0f_gyrchzprxjxbyafd6tt9my+a7j...@mail.gmail.com
>
> I assume nothing came out of the SFC member thingy discussed back then
> in that thread?
>
> > And earlier mails on the subject.
>
> Perhaps this would be an item for the FAQ ;-)
>
>
> Regards,
> Philippe.

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


Re: have cygwin setup.exe signed and/or in the MS store

2023-04-12 Thread Philippe Cerfon via Cygwin
Hey.

On Wed, Apr 12, 2023 at 3:35 PM Andrey Repin  wrote:
> msgid:camu-taupf3dzpye3xj0f_gyrchzprxjxbyafd6tt9my+a7j...@mail.gmail.com

I assume nothing came out of the SFC member thingy discussed back then
in that thread?

> And earlier mails on the subject.

Perhaps this would be an item for the FAQ ;-)


Regards,
Philippe.

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


have cygwin setup.exe signed and/or in the MS store

2023-04-11 Thread Philippe Cerfon via Cygwin
Hey there.

I know you provide OpenPGP signatures for verification (which is good,
and should be kept), but would it perhaps make sense to have setup.exe
signed (in the sense of: by some MS trusted certificate) and/or in the
MS store (though I guess that might not be possible with their
policy)?

Regards,
Philippe.

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


SSH config in /etc/ssh/ rather than /etc?

2023-04-11 Thread Philippe Cerfon via Cygwin
Hey.

I've just wondered whether Cygwin packages could be changed to
place/expect any SSH config files in /etc/ssh, just as virtually any
Linux distribution seems to do? :-)

Regards,
Philippe

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