Comments (9)
Do you have the 10.9 sdk installed in /opt?
See CONDA_BUILD_SYSROOT in conda _build_config.yaml for the exact location. You can get this from many different places. One is https://github.com/phracker/MacOSX-SDKs
We currently can't just provide packages due to licensing concerns. Thanks Apple.
from aggregate.
You're right, I didn't have the sdk installed. Did so, and adjusted conda_build_config.yaml location accordingly. Incidentally, there was a full 10.9 sdk installed to miniconda/conda-bld/llvm-suite_1507415239196/work/bootstrap/MacOSX10.9.sdk/System
at conda-build time that file-structure-wise is identical to the github sdk 10.9 repo.
Unfortunately, error was still the same. "Fixed" it by adding an extra library to cctools_build/ld64/Makefile
LTO_LIBS = -lxml2 -lpthread -lLTO
. Also had to edit cctools_build_libtool/ld64/Makefile
to add $(top_srcdir)/../prefix
to MYINCLUDES & MYLDFLAGS so that it could find tapi/tapi.h
and ltapi
(though this was during a hand-make
ing jaunt and hasn't been confirmed in a linear compilation sequence).
The next blocking error is the signature problem below. In occurs in cctools_build_final
and at that time, it has already successfully built the file twice (immediately below). The patch that toggles qsort_r signatures is present in the source, so this is clearly an issue that's being managed by the build. Any notion why macho_relocatable_file.cpp
could be failing to build only for "_final" (of "", "_libtool", & "_final")?
>>> cctools_build_final/ld64$ find ../../ -name "macho_relocatable_file*"
../..//cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp
../..//cctools/ld64/src/ld/parsers/macho_relocatable_file.h
../..//cctools_build/ld64/src/ld/parsers/macho_relocatable_file.o
../..//cctools_build_libtool/ld64/src/ld/parsers/macho_relocatable_file.o
/Users/github/toolchainconda/conda-bld/llvm-suite_1507415239196/work/prefix/bin/clang++ --sysroot /Users/github/toolchainconda/conda-bld/llvm-suite_1507415239196/work/bootstrap/MacOSX10.9.sdk -DHAVE_CONFIG_H -DDEBUG -DBINDIR="\"/Users/github/toolchainconda/conda-bld/llvm-suite_1507415239196/work/prefix/bin\"" -DLDPROG="\"x86_64-apple-darwin13.4.0-ld_classic\"" -DASPROG="\"x86_64-apple-darwin13.4.0-as\"" -DLTO_SUPPORT -DALL_SUPPORTED_ARCHS="\"armv6 armv7 armv7s arm64 i386 x86_64 x86_64h armv6m armv7k armv7m armv7em (tvOS)\"" -DBITCODE_XAR_VERSION="\"1.0\"" -DSUPPORT_APPLE_TV=1 -DSUPPORT_ARCH_x86_64=1 -DSUPPORT_ARCH_x86_64h=1 -DSUPPORT_ARCH_i386=1 -DSUPPORT_ARCH_armv4t=1 -DSUPPORT_ARCH_armv5=1 -DSUPPORT_ARCH_armv6=1 -DSUPPORT_ARCH_armv7=1 -DSUPPORT_ARCH_armv7f=1 -DSUPPORT_ARCH_armv7k=1 -DSUPPORT_ARCH_armv7s=1 -DSUPPORT_ARCH_armv6m=1 -DSUPPORT_ARCH_armv7m=1 -DSUPPORT_ARCH_armv7em=1 -DSUPPORT_ARCH_armv8=1 -DSUPPORT_ARCH_arm64=1 -DSUPPORT_ARCH_arm64v8=1 -I../../cctools/ld64/include -I../../cctools/ld64/Readers -I../../cctools/ld64/Writers -I../include -I../../cctools/include -I../../cctools/ld64/src/ld -I../../cctools/ld64/src/abstraction -I../../cctools/ld64/src/ld/parsers -include ../include/config.h -I/Users/github/toolchainconda/conda-bld/llvm-suite_1507415239196/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/include -mmacosx-version-min=10.9 -D__DARWIN_UNIX03 -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -I/Users/github/toolchainconda/conda-bld/llvm-suite_1507415239196/work/prefix/include -fno-builtin-round -fno-builtin-trunc -mdynamic-no-pic -I/Users/github/toolchainconda/conda-bld/llvm-suite_1507415239196/_h_env_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_placehold_plac/include -mmacosx-version-min=10.9 -D__DARWIN_UNIX03 -D__STDC_LIMIT_MACROS -D__STDC_CONSTANT_MACROS -std=c++11 -c -o src/ld/parsers/macho_relocatable_file.o ../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp
clang-4.0: warning: argument unused during compilation: '--sysroot=/Users/github/toolchainconda/conda-bld/llvm-suite_1507415239196/work/bootstrap/MacOSX10.9.sdk' [-Wunused-command-line-argument]
../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp:2363:2: error: cannot initialize a parameter of type 'void *' with an rvalue of type 'int (*)(const void *, const void *, void *)'
QSORT_R(array, _machOSectionsCount, sizeof(uint32_t), this, sectionIndexSorter);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp:59:64: note: expanded from macro 'QSORT_R'
#define QSORT_R(_a,_b,_c,_vp,_fn) ::qsort_r((_a), (_b), (_c), (int(*)(const void*, const void*, void*))(_fn), (_vp))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp:1762:8: note: in instantiation of member function 'mach_o::relocatable::Parser<x86_64>::makeSortedSectionsArray' requested here
this->makeSortedSectionsArray(sortedSectionIndexes);
^
../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp:1006:26: note: in instantiation of member function 'mach_o::relocatable::Parser<x86_64>::parse' requested here
return p.parse(opts);
^
../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp:7841:49: note: in instantiation of member function 'mach_o::relocatable::Parser<x86_64>::parse' requested here
return mach_o::relocatable::Parser<x86_64>::parse(fileContent, fileLength, path, modTime, ordinal, opts);
^
/Users/github/Git/MacOSX-SDKs/MacOSX10.9.sdk/usr/include/stdlib.h:299:45: note: passing argument to parameter here
void qsort_r(void *, size_t, size_t, void *,
^
../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp:2461:2: error: cannot initialize a parameter of type 'void *' with an rvalue of type 'int (*)(const void *, const void *, void *)'
QSORT_R(array, _symbolsInSections, sizeof(uint32_t), &extra, &symbolIndexSorter);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../../cctools/ld64/src/ld/parsers/macho_relocatable_file.cpp:59:64: note: expanded from macro 'QSORT_R'
#define QSORT_R(_a,_b,_c,_vp,_fn) ::qsort_r((_a), (_b), (_c), (int(*)(const void*, const void*, void*))(_fn), (_vp))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
from aggregate.
I probably would not attempt to build these compilers on any macOS other than 10.9. You'll be in for a tough time if you do. I did try once but it's kind of not worth it since you want to guarantee the compilers work on and generate code for 10.9 and building them on anything else risks breaking that guarantee (same as how the new gcc compilers were built on CentOS6).
The macOS compilers built with this recipe on conda defaults have omp.h
(it is in the llvm-openmp
package as is lib/libomp.dylib
):
tar -tf /opt/conda/pkgs/llvm-openmp-4.0.1-hda82c8b_0.tar.bz2
info/hash_input_files
info/files
info/index.json
info/paths.json
info/about.json
info/hash_input.json
info/LICENSE.txt
info/git
info/test/test_time_dependencies.json
info/recipe/install-openmp.sh
info/recipe/conda_build_config.yaml
info/recipe/meta.yaml
lib/clang/4.0.1/include/omp.h
info/recipe/build.sh
lib/libomp.dylib
I also tested these just now for building r-data.table
which requires OpenMP (https://github.com/Rdatatable/data.table/wiki/Installation#openmp-enabled-compiler-for-mac)
in build.sh
:
if [[ ${HOST} =~ .*darwin.* ]]; then
echo "CC=${CC} -fopenmp" > ~/.R/Makevars
fi
$R CMD INSTALL --build .
if [[ ${HOST} =~ .*darwin.* ]]; then
rm -rf ~/.R
fi
from aggregate.
You did warn us :-)
Thanks very much, @mingwandroid. Added llvm-openmp
to build and runtime, and my original package built like a charm. Now to impose -fopenmp=iomp5
...
Warning to future thread readers: to build clang packages, really must be on 10.9. Even with 10.9 sdk, neither 10.10 nor 10.11 will do.
from aggregate.
I can probably fix that but perhaps only if these compilers are used as a build dependency and that's cyclic and that won't work either so we'd need a hack.
Or maybe I can fix it without needing these compilers but it's unlikely to be looked at any time soon.
from aggregate.
No cause to "fix" them (allow compilation away from 10.9) on my part. I was only trying to build the compilers so that I could install an omp.h
, and you solved that by alerting me to package llvm-openmp
.
from aggregate.
All of the missing symbols that are being reported for libxar.a come from libicuuc.58 .
from aggregate.
And the requirement on libicuuc is coming from the statically linked libxml2.a in libxar.a
from aggregate.
If I make sure that the build uses https://repo.anaconda.com/pkgs/main/osx-64/xar-1.6.1-h50205bb_0.tar.bz2 , then the link error goes away.
from aggregate.
Related Issues (20)
- CDT for libudev HOT 1
- CDT for librdmacm HOT 1
- CDT for libnl HOT 4
- CDT for libibverbs HOT 1
- Send compiler-rt patches upstream HOT 3
- CuPy 6.0.0rc1 HOT 1
- ctng-compilers-activation-feedstock scripts shouldn't set HOST HOT 5
- CuPy 6.0.0 released HOT 1
- posix_ipc does not have py37 support HOT 1
- pyarrow update? HOT 1
- Add Scapy HOT 6
- Expand VS search paths for old toolchains installed by new VS
- Add `run_exports` to `cudnn` HOT 6
- vs2015 runtime finds unusable SDK version HOT 2
- Add pathy
- Add stone
- Powershell shortcut easily hits Windows string length limit HOT 1
- CDT packages are broken for s390x HOT 4
- remove conda-repo-cli feedstock
- Mastodon should be added? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aggregate.