bpo-26317: Support OBJC and OBJCXX configure command line variables (GH-20176)

Add support to the configure script for OBJC and OBJCXX command line options so that the macOS builds can use the clang compiler for the macOS-specific Objective C source files. This allows third-party compilers, like GNU gcc, to be used to build the rest of the project since some of the Objective C system header files are not compilable by GNU gcc.

Co-authored-by: Jeffrey Kintscher <websurfer@surf2c.net>
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
This commit is contained in:
Ned Deily 2020-05-18 09:17:22 -04:00 committed by GitHub
parent c444108dd6
commit 0da5466650
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 670 additions and 15 deletions

View file

@ -1583,10 +1583,11 @@ class PyBuildExt(build_ext):
self.missing.append('ossaudiodev')
if MACOS:
self.add(Extension('_scproxy', ['_scproxy.c'],
self.add(Extension('_scproxy', [],
extra_link_args=[
'-framework', 'SystemConfiguration',
'-framework', 'CoreFoundation']))
'-framework', 'CoreFoundation'],
extra_objects=['Modules/_scproxy.o']))
def detect_compress_exts(self):
# Andrew Kuchling's zlib module. Note that some versions of zlib