Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Py_UNICODE_SIZE=4 fails to link on Windows #80006

Closed
kristof mannequin opened this issue Jan 25, 2019 · 2 comments
Closed

Py_UNICODE_SIZE=4 fails to link on Windows #80006

kristof mannequin opened this issue Jan 25, 2019 · 2 comments
Labels
build The build process and cross-build OS-windows

Comments

@kristof
Copy link
Mannequin

kristof mannequin commented Jan 25, 2019

BPO 35825
Nosy @terryjreedy, @pfmoore, @tjguk, @zware, @zooba

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2019-01-31.09:46:00.582>
created_at = <Date 2019-01-25.10:31:17.702>
labels = ['build', 'invalid', 'OS-windows']
title = 'Py_UNICODE_SIZE=4 fails to link on Windows'
updated_at = <Date 2019-01-31.09:46:00.581>
user = 'https://bugs.python.org/kristof'

bugs.python.org fields:

activity = <Date 2019-01-31.09:46:00.581>
actor = 'methane'
assignee = 'none'
closed = True
closed_date = <Date 2019-01-31.09:46:00.582>
closer = 'methane'
components = ['Build', 'Windows']
creation = <Date 2019-01-25.10:31:17.702>
creator = 'kristof'
dependencies = []
files = []
hgrepos = []
issue_num = 35825
keywords = []
message_count = 2.0
messages = ['334348', '334367']
nosy_count = 6.0
nosy_names = ['terry.reedy', 'paul.moore', 'tim.golden', 'zach.ware', 'steve.dower', 'kristof']
pr_nums = []
priority = 'normal'
resolution = 'not a bug'
stage = 'resolved'
status = 'closed'
superseder = None
type = 'compile error'
url = 'https://bugs.python.org/issue35825'
versions = ['Python 2.7']

@kristof
Copy link
Mannequin Author

kristof mannequin commented Jan 25, 2019

When I change Py_UNICODE_SIZE from 2 (default) to 4 in PC/pyconfig.h, msvc-14 gives the following error:
_winreg.obj : error LNK2001: unresolved external symbol PyUnicode_DecodeMBCS [e:\kristof\SDR\sdrsandbox\w64\msvc140\Python-2.7.15\PCbuild\pythoncore.vcxproj]
e:\kristof\SDR\sdrsandbox\w64\msvc140\Python-2.7.15\PCBuild\\amd64\python27_snps_vp.dll : fatal error LNK1120: 1 unresolved externals [e:\kristof\SDR\sdrsandbox\w64\msvc140\Python-2.7.15\PCbuild\pythoncore.vcxproj]

The problem appears to be that the missing function gets disabled in unicodeobject.c with
#if defined(MS_WINDOWS) && defined(HAVE_USABLE_WCHAR_T)
...
#endif

while _winreg.c does not check the availability of this function.

Thanks,
Kristof

@kristof kristof mannequin added build The build process and cross-build OS-windows labels Jan 25, 2019
@terryjreedy
Copy link
Member

I think this falls in the category of "don't do that", because Windows does not support wide builds. If so, this issue should be closed as 'not a bug'. If not, some Windows expert should enlighten me.

@methane methane closed this as completed Jan 31, 2019
@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build The build process and cross-build OS-windows
Projects
None yet
Development

No branches or pull requests

2 participants