[issue28762] configure links with lockf and F_LOCK is not declared in Android API 24

2016-12-21 Thread Xavier de Gaye

Xavier de Gaye added the comment:

Thanks for the review Victor.

I have created issue 29040: building Android with android-ndk-r14.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28762] configure links with lockf and F_LOCK is not declared in Android API 24

2016-12-21 Thread STINNER Victor

STINNER Victor added the comment:

Oh ok, the issue is more subtle than what I understood.

I reviewed test_posix_flock.patch and proposed some changes to the comment/doc.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28762] configure links with lockf and F_LOCK is not declared in Android API 24

2016-12-21 Thread Xavier de Gaye

Xavier de Gaye added the comment:

No, the patch prevents posix.flock() to be defined on Android API 24 with 
android-ndk-r13. But I plan to change it so that the test is skipped when posix 
does not have the F_LOCK attribute as this problem is not worth a change in the 
build machinery. It makes even more sense now that android-ndk-r14 will be 
released with "Unified Headers". BTW thanks Chi Hsuan Yen for this important 
information.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28762] configure links with lockf and F_LOCK is not declared in Android API 24

2016-12-21 Thread STINNER Victor

STINNER Victor added the comment:

> The patch fixes the following error:

Do you mean that the patch adds posix.F_LOCK constant on Android?

--
nosy: +haypo

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28762] configure links with lockf and F_LOCK is not declared in Android API 24

2016-12-21 Thread Chi Hsuan Yen

Chi Hsuan Yen added the comment:

FYI: Since Android NDK r14 beta1, F_LOCK is defined in unified headers. [1] In 
$ANDROID_NDK/sysroot/usr/include/bits/lockf.h:

#define F_ULOCK 0
#define F_LOCK 1
#define F_TLOCK 2
#define F_TEST 3

[1] 
https://android.googlesource.com/platform/ndk.git/+/master/docs/UnifiedHeaders.md

--
nosy: +Chi Hsuan Yen

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28762] configure links with lockf and F_LOCK is not declared in Android API 24

2016-11-21 Thread Xavier de Gaye

New submission from Xavier de Gaye:

The patch fixes the following error:

==
ERROR: test_lockf (test.test_posix.PosixTester)
--
Traceback (most recent call last):
  File "/sdcard/org.bitbucket.pyona/lib/python3.7/test/test_posix.py", line 
195, in test_lockf
posix.lockf(fd, posix.F_LOCK, 4)
AttributeError: module 'posix' has no attribute 'F_LOCK'

--
assignee: xdegaye
components: Interpreter Core
files: test_posix_flock.patch
keywords: patch
messages: 281344
nosy: xdegaye
priority: normal
severity: normal
stage: patch review
status: open
title: configure links with lockf and F_LOCK is not declared in Android API 24
type: behavior
versions: Python 3.6, Python 3.7
Added file: http://bugs.python.org/file45582/test_posix_flock.patch

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com