首页 > 解决方案 > 在 macOS 达尔文内核版本 17.5.0 上使用 conda 打包 heasoft

问题描述

我需要一个用于数据缩减管道的 heasoft 库子集,我想将其作为一个conda包发布。我有在 Linux 下运行良好的食谱,但是当我构建 heasoft 包时,我在 OSX 中遇到了问题。

我这样做:

  1. 从正确的源下载所需的库作为配方目录中的 tar 文件;
  2. 在配方目录中设置path关键字;meta.yaml
  3. 在 中build.sh,我cd进入正确的目录,这BUILD_DIR与任何 heasoft 包一样。

现在,在导出所有需要的变量(CC和其他变量)之后,我启动./configure了,并开始看到我无法处理的行为。

这些是配置的第一行:

francesco:heasoft-osx(master)*$ conda build .
Attempting to finalize metadata for heasoft
INFO:conda_build.metadata:Attempting to finalize metadata for heasoft
BUILD START: ['heasoft-6.24-h9b869f0_1.tar.bz2']
Copying /Users/francesco/ascisoft-recipes/heasoft-osx to /Users/francesco/anaconda3/conda-bld/heasoft_1525868116683/work
source tree in: /Users/francesco/anaconda3/conda-bld/heasoft_1525868116683/work
/Users/francesco/anaconda3/conda-bld/heasoft_1525868116683/work/heasoft-6.24/BUILD_DIR
configure: WARNING: /usr/bin/perl and /usr/local/Cellar/llvm/5.0.0/bin/clang may not work well together!
rm: conftest.dSYM: is a directory
rm: conftest.dSYM: is a directory
configure: WARNING: no header file found for arc4random
configure: WARNING: Cannot find idn library
configure: WARNING: Compilation of Fortran wrappers and PGSBOX disabled
configure: WARNING: CFITSIO disabled
configure: WARNING: PGPLOT disabled
configure: WARNING: Compilation of WCS utilities disabled

相反,如果使用下载的 tar 文件,我执行通常的编译步骤,我会得到公平的输出

francesco:BUILD_DIR$ ./configure --with-components="heacore heatools"
checking build system type... x86_64-apple-darwin17.5.0
checking host system type... x86_64-apple-darwin17.5.0
checking target system type... x86_64-apple-darwin17.5.0
Will force readline build on Darwin if available
Found component heacore
Found heacore/BUILD_DIR/hd_config_info
Found component heatools

...

checking build system type... x86_64-apple-darwin17.5.0
checking host system type... x86_64-apple-darwin17.5.0
checking target system type... x86_64-apple-darwin17.5.0
checking for strip... strip
checking for ar... ar
checking for ranlib... ranlib
checking for gmake... no
checking for make... make
checking whether make is GNU make... yes

等等。

我会在这里停下来,但构建过程仍在继续,我还有更烦人的行为,例如

ignoring file /[...]/x86_64-apple-darwin17.5.0/lib/libape_2.9.dylib, file was built for x86_64 which is not the architecture being linked (i386)

它与我的系统设置相关conda-build吗?

如果需要,我当然可以提供我的食谱。

标签: macoscondafits

解决方案


推荐阅读