As OpenSSL is expected to be in a standard UNIX location but that's not always the case on macOS, this works around the issue regardless of package manager used as long as pkg-config is installed into $PATH
Macports default prefix is /opt/local
Homebrew on M1 uses /opt/homebrew
Move setting build_complete_file to after fetching project_name using
get_project_name_from_url. Avoids empty ".FOO_build_complete" file name.
* Fix up a number of shellcheck issues in get_sources().
Signed-off-by: Ben Kochie <superq@gmail.com>
* build_compiler_rt.sh: Change git repository. The llvm.org one is no longer synced.
* build_compiler_rt.sh: Add check for os/lock.h.
* xcrun: "Support" -show-sdk-platform-path.
* sw_vers: Output 0CFFFF for Build Version.
* Added support for TAPIv3 stubs (including "zippering" target)
* Added support for MacOSX SDKs up to 10.14
* Added new SDK packaging script for SDKs that end with ".xip" (tools/gen_sdk_package_pbzx.sh <xcode.xip>) (tested up to Xcode 10.2.1)
* Updated cctools to 921 and ld64 to 409.12
Fixed:
* Implemented fix for https://github.com/tpoechtrager/osxcross/issues/171
* Implemented fix for https://github.com/tpoechtrager/osxcross/issues/178
* Implemented fix for https://github.com/tpoechtrager/osxcross/issues/182
Changed:
* cctools, ld64, apple-libtapi and xar are now "git clone"'d and no longer come with OSXCross.
Removed:
* Support for Cygwin and *BSD (besides FreeBSD)
* Support for building OSXCross with GCC
This finally adds support for Xcode 7 / El Capitan.
With this commit I am also removing ld64-134.9 support.
I kept ld64-134.9 for users with an old C++ standard library.
A decent C++ standard library with C++11 support is now mandatory.
* Support for generating fat object files with gcc and '-foc-use-gcc-libstdc++'
has been removed.
This feature was not 100% correctly implemented; using multiple source files
did not work, i.e.: 'o32-g++ -m32 -m64 a.cpp b.cpp' would have failed;
And I refuse to implement that, instead I am removing all source file handling
from the wrapper with this commit for simplicity.
This feature should be implemented in the gcc driver instead.
This does NOT affect clang's fat object file support, which is implemented in
clang's darwin driver.
* '-oc-use-gcc-lib' has been renamed to '-foc-use-gcc-libstdc++'.
* Added support for '-stdc++' and '-gstdc++' compiler "shortcuts"
o32-clang++ --> uses libstdc++ for <= 10.8 and libc++ for >= 10.9
o32-clang++-libc++ --> uses the SDK's libc++
o32-clang++-stdc++ --> uses the SDK's libstdc++
o32-clang++-gstdc++ --> uses gcc's (build_gcc.sh) libstdc++
* Entirely rewrote the command line parser; the previous one wasn't very
readable.
* Minor Readme Updates
* Added unit tests
* Removed OSXCROSS_C_STANDARD / OSXCROSS_CXX_STANDARD support
I am no longer parsing -std=, so this feature has to be dropped.
Setting the language standard via an env variable isn't a good idea anyway.
* Removed unneeded stuff
Other Changes:
* Version bump to 0.11
* handle '-sdk' / 'SDKROOT' (env.) properly.
e.g. 'xcrun -sdk /[...]/MacOSX10.6.sdk clang' will use
the specified 10.6 SDK.
* never execute xcode tools outside target/bin even when
a full path is specified.
e.g. 'xcrun /usr/bin/gcc' will execute target/bin/<triple>-gcc.
other wrapper changes:
* implement 'OSXCROSS_SDKROOT' env. variable for 'xcrun -sdk'.
* error on '-arch x86_64h' + clang <= 3.4.
clang <= 3.4 misinterprets x86_64h as x86_64.
* only create x86_64h symlinks when the 10.8 (or later) SDK
is used.
other changes:
* misc fixes and cleanup
port changes:
- misc fixes
- add '-L/usr/pkg/lib' for NetBSD
- update libobjc2 to r37977
- silence / fix libobjc2 warnings
- remove freebsd ifdef in favor of '-isystem /usr/local'
- add installhdrs target (cctools-port/issues/2)
- prefer glibtoolize over libtoolize
- add support for OS X and iOS as host system (cctools-port/issues/1)
- add a workaround for a glibc 2.20 bug
- link with -rpath to ease finding libLTO
- check for __cxa_demangle in -lstdc++
- use std=c++0x instead of -std=gnu++0x
- fix ld64 to compile with libstdc++
- fix automake warnings
- ld64: enable all architectures
This also gets rid of the automake dependency.
add support for multiple -arch flags with gcc (and clang + -oc-use-gcc-libs)
fix an unwind issue with -oc-use-gcc-libs + -mmacosx-version-min <= 10.5
update changelog
to highlight some changes:
- this gets rid of the bash dependency (after installing)
- osxcross-env, osxcross-conf and (the fake) dsymutil are now implemented
in the wrapper
- added: 'sw_vers' tool, which is required by some projects (llvm, ...)
- added '-oc-use-gcc-libs' option (uses './build_gcc.sh' libstdc++)
This new wrapper is also more restrict and several times faster than the bash
implementation (~0.2ms vs. 10ms+).