sourmash-bio / sourmash_plugin_branchwater

fast, multithreaded sourmash operations: search, compare, and gather.
GNU Affero General Public License v3.0
13 stars 2 forks source link

Issues with development environment on Mac OS X #346

Open olgabot opened 1 month ago

olgabot commented 1 month ago

Hello, Hope you are well! I am having trouble getting the development environment set up for this following the developer docs

`pip install -e .` error ``` (branchwater-dev) Mon 3 Jun - 18:45  ~/code/sourmash_plugin_branchwater   origin ☊ olgabot/hp-dayhoff ✔  @olgabot  pip install -e . Obtaining file:///Users/olgabot/code/sourmash_plugin_branchwater Installing build dependencies ... done Checking if build backend supports build_editable ... done Getting requirements to build editable ... done Preparing editable metadata (pyproject.toml) ... done Requirement already satisfied: sourmash<5,>=4.8.5 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash_plugin_branchwater==0.9.3) (4.8.8) Requirement already satisfied: screed<2,>=1.1.3 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (1.1.3) Requirement already satisfied: cffi>=1.14.0 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (1.16.0) Requirement already satisfied: numpy in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (1.26.4) Requirement already satisfied: matplotlib in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (3.8.4) Requirement already satisfied: scipy in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (1.13.1) Requirement already satisfied: deprecation>=2.0.6 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (2.1.0) Requirement already satisfied: cachetools<6,>=4 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (4.2.4) Requirement already satisfied: bitstring<5,>=3.1.9 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (3.1.9) Requirement already satisfied: pycparser in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from cffi>=1.14.0->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (2.22) Requirement already satisfied: packaging in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from deprecation>=2.0.6->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (24.0) Requirement already satisfied: contourpy>=1.0.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (1.2.1) Requirement already satisfied: cycler>=0.10 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (0.12.1) Requirement already satisfied: fonttools>=4.22.0 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (4.53.0) Requirement already satisfied: kiwisolver>=1.3.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (1.4.5) Requirement already satisfied: pillow>=8 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (10.3.0) Requirement already satisfied: pyparsing>=2.3.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (3.1.2) Requirement already satisfied: python-dateutil>=2.7 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (2.9.0) Requirement already satisfied: six>=1.5 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from python-dateutil>=2.7->matplotlib->sourmash<5,>=4.8.5->sourmash_plugin_branchwater==0.9.3) (1.16.0) Building wheels for collected packages: sourmash_plugin_branchwater Building editable for sourmash_plugin_branchwater (pyproject.toml) ... | .... error occurred: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/63eaf76b2ca4ac87-write_batch_with_index_internal.o" "-c" "rocksdb/utilities/write_batch_with_index/write_batch_with_index_internal.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1). 💥 maturin failed Caused by: Failed to build a native library through cargo Caused by: Cargo build finished with "exit status: 101": `env -u CARGO PYO3_ENVIRONMENT_SIGNATURE="cpython-3.12-64bit" PYO3_PYTHON="/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python3.12" PYTHON_SYS_EXECUTABLE="/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python3.12" "cargo" "rustc" "--message-format" "json-render-diagnostics" "--manifest-path" "/Users/olgabot/code/sourmash_plugin_branchwater/Cargo.toml" "--release" "--lib" "--" "-C" "link-arg=-undefined" "-C" "link-arg=dynamic_lookup" "-C" "link-args=-Wl,-install_name,@rpath/sourmash_plugin_branchwater.cpython-312-darwin.so"` Error: command ['maturin', 'pep517', 'build-wheel', '-i', '/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python3.12', '--compatibility', 'off', '--editable'] returned non-zero exit status 1 [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building editable for sourmash_plugin_branchwater Failed to build sourmash_plugin_branchwater ERROR: Could not build wheels for sourmash_plugin_branchwater, which is required to install pyproject.toml-based projects ```
`maturin develop` error message (last few lines because it's 1000s of lines) ``` exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-gdwarf-2" "-fno-omit-frame-pointer" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/lz4-sys-1ee437c85c70df78/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/libz-sys-188cf6965b4da6bb/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/bzip2-sys-a0ae573be6098e2d/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/librocksdb-sys-1a5cfe62a5c25073/out/2200fd353fada6b7-write_unprepared_txn.o" "-c" "rocksdb/utilities/transactions/write_unprepared_txn.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-gdwarf-2" "-fno-omit-frame-pointer" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/lz4-sys-1ee437c85c70df78/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/libz-sys-188cf6965b4da6bb/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/bzip2-sys-a0ae573be6098e2d/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/librocksdb-sys-1a5cfe62a5c25073/out/17455aaab6b3cd3e-db_ttl_impl.o" "-c" "rocksdb/utilities/ttl/db_ttl_impl.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-gdwarf-2" "-fno-omit-frame-pointer" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/lz4-sys-1ee437c85c70df78/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/libz-sys-188cf6965b4da6bb/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/bzip2-sys-a0ae573be6098e2d/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/librocksdb-sys-1a5cfe62a5c25073/out/63eaf76b2ca4ac87-write_batch_with_index.o" "-c" "rocksdb/utilities/write_batch_with_index/write_batch_with_index.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-gdwarf-2" "-fno-omit-frame-pointer" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/lz4-sys-1ee437c85c70df78/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/libz-sys-188cf6965b4da6bb/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/bzip2-sys-a0ae573be6098e2d/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/librocksdb-sys-1a5cfe62a5c25073/out/63eaf76b2ca4ac87-write_batch_with_index_internal.o" "-c" "rocksdb/utilities/write_batch_with_index/write_batch_with_index_internal.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1). --- stderr error occurred: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-gdwarf-2" "-fno-omit-frame-pointer" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/lz4-sys-1ee437c85c70df78/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/libz-sys-188cf6965b4da6bb/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/bzip2-sys-a0ae573be6098e2d/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/debug/build/librocksdb-sys-1a5cfe62a5c25073/out/63eaf76b2ca4ac87-write_batch_with_index_internal.o" "-c" "rocksdb/utilities/write_batch_with_index/write_batch_with_index_internal.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1). 💥 maturin failed Caused by: Failed to build a native library through cargo Caused by: Cargo build finished with "exit status: 101": `env -u CARGO PYO3_ENVIRONMENT_SIGNATURE="cpython-3.12-64bit" PYO3_PYTHON="/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python" PYTHON_SYS_EXECUTABLE="/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python" "cargo" "rustc" "--message-format" "json-render-diagnostics" "--manifest-path" "/Users/olgabot/code/sourmash_plugin_branchwater/Cargo.toml" "--lib" "--" "-C" "link-arg=-undefined" "-C" "link-arg=dynamic_lookup" "-C" "link-args=-Wl,-install_name,@rpath/sourmash_plugin_branchwater.cpython-312-darwin.so"` ```

Do you have a sense of what could be going wrong? I do have two Rusts installed on this machine, but the conda-installed one should take precendence:

(branchwater-dev)
 Mon  3 Jun - 18:46  ~/code/sourmash_plugin_branchwater   origin ☊ olgabot/hp-dayhoff ✔ 
 @olgabot  which -a rustc
/Users/olgabot/anaconda3/envs/branchwater-dev/bin/rustc
/Users/olgabot/.cargo/bin/rustc

Thank you so much! Warmest, Olga

EDIT: Added full error message for pip install -e . error.

olgabot commented 1 month ago

Tried moving ~/.cargo to another place to see if that could be the issue, but seeing a similar (the same?): error

(branchwater-dev)
 Mon  3 Jun - 18:48  ~/code/sourmash_plugin_branchwater   origin ☊ olgabot/hp-dayhoff ✔ 
 @olgabot  mv /Users/olgabot/.cargo /Users/olgabot/.cargo-backup
`pip install -e .` error ``` exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/63eaf76b2ca4ac87-write_batch_with_index.o" "-c" "rocksdb/utilities/write_batch_with_index/write_batch_with_index.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/2200fd353fada6b7-write_unprepared_txn_db.o" "-c" "rocksdb/utilities/transactions/write_unprepared_txn_db.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/2200fd353fada6b7-write_prepared_txn_db.o" "-c" "rocksdb/utilities/transactions/write_prepared_txn_db.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/2200fd353fada6b7-write_unprepared_txn.o" "-c" "rocksdb/utilities/transactions/write_unprepared_txn.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/63eaf76b2ca4ac87-write_batch_with_index_internal.o" "-c" "rocksdb/utilities/write_batch_with_index/write_batch_with_index_internal.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1).cargo:warning=2 errors generated. exit status: 1 cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/17455aaab6b3cd3e-db_ttl_impl.o" "-c" "rocksdb/utilities/ttl/db_ttl_impl.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1). --- stderr error occurred: Command env -u IPHONEOS_DEPLOYMENT_TARGET "x86_64-apple-darwin13.4.0-clang++" "-O3" "-ffunction-sections" "-fdata-sections" "-fPIC" "-m64" "--target=x86_64-apple-darwin" "-mmacosx-version-min=10.7" "-march=core2" "-mtune=haswell" "-mssse3" "-ftree-vectorize" "-fPIC" "-fstack-protector-strong" "-O2" "-pipe" "-stdlib=libc++" "-fvisibility-inlines-hidden" "-fmessage-length=0" "-isystem" "/Users/olgabot/anaconda3/envs/branchwater-dev/include" "-I" "rocksdb/include/" "-I" "rocksdb/" "-I" "rocksdb/third-party/gtest-1.8.1/fused-src/" "-I" "snappy/" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/lz4-sys-b16904cfd846838f/out/include" "-I" "/Users/olgabot/.cargo/registry/src/index.crates.io-6f17d22bba15001f/zstd-sys-2.0.9+zstd.1.5.5/zstd/lib" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/libz-sys-fc8c08ef063bce1e/out/include" "-I" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/bzip2-sys-4489849e76e92161/out/include" "-I" "." "-std=c++17" "-Wsign-compare" "-Wshadow" "-Wno-unused-parameter" "-Wno-unused-variable" "-Woverloaded-virtual" "-Wnon-virtual-dtor" "-Wno-missing-field-initializers" "-Wno-strict-aliasing" "-Wno-invalid-offsetof" "-msse2" "-msse4.1" "-std=c++17" "-DSNAPPY=1" "-DLZ4=1" "-DZSTD=1" "-DZLIB=1" "-DBZIP2=1" "-DNDEBUG=1" "-DOS_MACOSX" "-DROCKSDB_PLATFORM_POSIX" "-DROCKSDB_LIB_IO_POSIX" "-DROCKSDB_SUPPORT_THREAD_LOCAL" "-o" "/Users/olgabot/code/sourmash_plugin_branchwater/target/release/build/librocksdb-sys-49c431dc0ccefd6b/out/17455aaab6b3cd3e-db_ttl_impl.o" "-c" "rocksdb/utilities/ttl/db_ttl_impl.cc" with args "x86_64-apple-darwin13.4.0-clang++" did not execute successfully (status code exit status: 1). 💥 maturin failed Caused by: Failed to build a native library through cargo Caused by: Cargo build finished with "exit status: 101": `env -u CARGO PYO3_ENVIRONMENT_SIGNATURE="cpython-3.12-64bit" PYO3_PYTHON="/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python3.12" PYTHON_SYS_EXECUTABLE="/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python3.12" "cargo" "rustc" "--message-format" "json-render-diagnostics" "--manifest-path" "/Users/olgabot/code/sourmash_plugin_branchwater/Cargo.toml" "--release" "--lib" "--" "-C" "link-arg=-undefined" "-C" "link-arg=dynamic_lookup" "-C" "link-args=-Wl,-install_name,@rpath/sourmash_plugin_branchwater.cpython-312-darwin.so"` Error: command ['maturin', 'pep517', 'build-wheel', '-i', '/Users/olgabot/anaconda3/envs/branchwater-dev/bin/python3.12', '--compatibility', 'off', '--editable'] returned non-zero exit status 1 [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building editable for sourmash_plugin_branchwater Failed to build sourmash_plugin_branchwater ERROR: Could not build wheels for sourmash_plugin_branchwater, which is required to install pyproject.toml-based projects ```
ctb commented 1 month ago

hi @olgabot I ran this today, and it all worked for me - here's my info:

% uname -a
Darwin Titus-MacBook-tsalmoth.local 22.5.0 Darwin Kernel Version 22.5.0: Thu Jun  8 22:22:19 PDT 2023; root:xnu-8796.121.3~7/RELEASE_ARM64_T8103 arm64

It's an old version of Mac OS X tho.

Maybe @bluegenes can give it a try - she uses a Mac, but I'm not sure what kind (ARM or whatnot).

You might also take a look at the conda-forge feedstock for inspiration, since it compiles packages for both x86 and ARM Mac OS X. The relevant PRs are https://github.com/conda-forge/sourmash_plugin_branchwater-feedstock/pull/3 and https://github.com/conda-forge/sourmash_plugin_branchwater-feedstock/pull/5 - neither one was very pleasant 😅

olgabot commented 1 month ago

Here's my uname for my Intel mac where I'm getting this error.

$ uname -a
Darwin Olgas-MacBook-Pro-2.local 23.4.0 Darwin Kernel Version 23.4.0: Fri Mar 15 00:11:05 PDT 2024; root:xnu-10063.101.17~1/RELEASE_X86_64 x86_64 i386 Darwin

I can try installing on my M1 mac to see if intel is the problem, but not sure when I'll get to this as adding new moltypes isn't yet mission-critical for me. I was hoping https://github.com/sourmash-bio/sourmash_plugin_branchwater/issues/337 was a "simple" fix ... 😅

ctb commented 1 month ago

image

software development is never simple 😆

olgabot commented 3 weeks ago

Looking back at my error, I noticed that maturin seemed to be building for iPhone instead of MacOS, because the error contained IPHONEOS_DEPLOYMENT_TARGET: cargo:warning=ToolExecError: Command env -u IPHONEOS_DEPLOYMENT_TARGET

From https://github.com/PyO3/maturin/issues/1742#issuecomment-1686117078, I saw that you could specify OSX_SDKROOT and IOS_SDKROOT, so I tried specifying only OSX_SDKROOT, and not the IOS_SDKROOT:

export OSX_SDKROOT=$(xcrun --sdk macosx --show-sdk-path)
export MACOSX_DEPLOYMENT_TARGET=10.14
pip install -e .

And it worked!

I don't know how export OSX_SDKROOT=$(xcrun --sdk macosx --show-sdk-path) translates into a pyproject.toml line, though. That one issue is the only search result that comes up 🙀

image
Full installation output ``` (branchwater-dev) ✘  Wed 12 Jun - 07:44  ~/code/sourmash_plugin_branchwater   olgabot/mac-os-dev-env ✔ ☗v0.9.4  @olgabot  export MACOSX_DEPLOYMENT_TARGET=10.14 (branchwater-dev) Wed 12 Jun - 07:44  ~/code/sourmash_plugin_branchwater   olgabot/mac-os-dev-env ✔ ☗v0.9.4  @olgabot  export OSX_SDKROOT=$(xcrun --sdk macosx --show-sdk-path) (branchwater-dev) Wed 12 Jun - 07:44  ~/code/sourmash_plugin_branchwater   olgabot/mac-os-dev-env ✔ ☗v0.9.4  @olgabot  pip install -e . Obtaining file:///Users/olgabot/code/sourmash_plugin_branchwater Installing build dependencies ... done Checking if build backend supports build_editable ... done Getting requirements to build editable ... done Preparing editable metadata (pyproject.toml) ... done Collecting sourmash<5,>=4.8.9 (from sourmash_plugin_branchwater==0.9.4) Using cached sourmash-4.8.9-py3-none-macosx_11_0_x86_64.whl.metadata (9.5 kB) Requirement already satisfied: screed<2,>=1.1.3 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (1.1.3) Requirement already satisfied: cffi>=1.14.0 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (1.16.0) Requirement already satisfied: numpy in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (1.26.4) Requirement already satisfied: matplotlib in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (3.8.4) Requirement already satisfied: scipy in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (1.13.1) Requirement already satisfied: deprecation>=2.0.6 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (2.1.0) Requirement already satisfied: cachetools<6,>=4 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (4.2.4) Requirement already satisfied: bitstring<5,>=3.1.9 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (3.1.9) Requirement already satisfied: pycparser in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from cffi>=1.14.0->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (2.22) Requirement already satisfied: packaging in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from deprecation>=2.0.6->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (24.0) Requirement already satisfied: contourpy>=1.0.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (1.2.1) Requirement already satisfied: cycler>=0.10 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (0.12.1) Requirement already satisfied: fonttools>=4.22.0 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (4.53.0) Requirement already satisfied: kiwisolver>=1.3.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (1.4.5) Requirement already satisfied: pillow>=8 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (10.3.0) Requirement already satisfied: pyparsing>=2.3.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (3.1.2) Requirement already satisfied: python-dateutil>=2.7 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (2.9.0) Requirement already satisfied: six>=1.5 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from python-dateutil>=2.7->matplotlib->sourmash<5,>=4.8.9->sourmash_plugin_branchwater==0.9.4) (1.16.0) Using cached sourmash-4.8.9-py3-none-macosx_11_0_x86_64.whl (2.5 MB) Building wheels for collected packages: sourmash_plugin_branchwater Building editable for sourmash_plugin_branchwater (pyproject.toml) ... done Created wheel for sourmash_plugin_branchwater: filename=sourmash_plugin_branchwater-0.9.4-cp312-cp312-macosx_10_14_x86_64.whl size=15586 sha256=90efb5bd1ac14403da0f80a573b9cd3ae4fb199a5593ade747a37e97f3ad89e1 Stored in directory: /private/var/folders/7z/r1593ybs1sj2ks5zzl9vy8840000gn/T/pip-ephem-wheel-cache-jve7244l/wheels/01/39/f6/6a7c3de3fe47a8b7ea39450ffc11963396000e02610d5e484c Successfully built sourmash_plugin_branchwater Installing collected packages: sourmash, sourmash_plugin_branchwater Attempting uninstall: sourmash Found existing installation: sourmash 4.8.8 Uninstalling sourmash-4.8.8: Successfully uninstalled sourmash-4.8.8 Successfully installed sourmash-4.8.9 sourmash_plugin_branchwater-0.9.4 ```
ctb commented 3 weeks ago

fantastic!! thanks for sharing and please leave this issue open for a bit 😆

olgabot commented 3 weeks ago

Here is the maturin develop output (which worked!)

maturin develop output ``` (branchwater-dev) Wed 12 Jun - 07:47  ~/code/sourmash_plugin_branchwater   olgabot/mac-os-dev-env ✔ ☗v0.9.4  @olgabot  maturin develop 📦 Including license file "/Users/olgabot/code/sourmash_plugin_branchwater/LICENSE.txt" 🍹 Building a mixed python/rust project 🔗 Found pyo3 bindings 🐍 Found CPython 3.12 at /Users/olgabot/anaconda3/envs/branchwater-dev/bin/python Ignoring pytest: markers 'extra == "test"' don't match your environment Ignoring pytest-cov: markers 'extra == "test"' don't match your environment Ignoring pytest-xdist: markers 'extra == "test"' don't match your environment Ignoring pandas: markers 'extra == "test"' don't match your environment Requirement already satisfied: sourmash<5,>=4.8.9 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (4.8.9) Requirement already satisfied: screed<2,>=1.1.3 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (1.1.3) Requirement already satisfied: cffi>=1.14.0 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (1.16.0) Requirement already satisfied: numpy in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (1.26.4) Requirement already satisfied: matplotlib in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (3.8.4) Requirement already satisfied: scipy in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (1.13.1) Requirement already satisfied: deprecation>=2.0.6 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (2.1.0) Requirement already satisfied: cachetools<6,>=4 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (4.2.4) Requirement already satisfied: bitstring<5,>=3.1.9 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from sourmash<5,>=4.8.9) (3.1.9) Requirement already satisfied: pycparser in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from cffi>=1.14.0->sourmash<5,>=4.8.9) (2.22) Requirement already satisfied: packaging in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from deprecation>=2.0.6->sourmash<5,>=4.8.9) (24.0) Requirement already satisfied: contourpy>=1.0.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9) (1.2.1) Requirement already satisfied: cycler>=0.10 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9) (0.12.1) Requirement already satisfied: fonttools>=4.22.0 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9) (4.53.0) Requirement already satisfied: kiwisolver>=1.3.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9) (1.4.5) Requirement already satisfied: pillow>=8 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9) (10.3.0) Requirement already satisfied: pyparsing>=2.3.1 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9) (3.1.2) Requirement already satisfied: python-dateutil>=2.7 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from matplotlib->sourmash<5,>=4.8.9) (2.9.0) Requirement already satisfied: six>=1.5 in /Users/olgabot/anaconda3/envs/branchwater-dev/lib/python3.12/site-packages (from python-dateutil>=2.7->matplotlib->sourmash<5,>=4.8.9) (1.16.0) Compiling clang-sys v1.8.1 Compiling prettyplease v0.2.17 Compiling libloading v0.8.3 Compiling libz-sys v1.1.16 Compiling itertools v0.12.1 Compiling sourmash v0.14.0 Compiling statrs v0.16.1 Compiling roaring v0.10.5 Compiling histogram v0.10.2 Compiling num-iter v0.1.45 Compiling itertools v0.13.0 Compiling bindgen v0.65.1 Compiling ouroboros_macro v0.18.4 Compiling ouroboros v0.18.4 Compiling librocksdb-sys v0.11.0+8.1.1 Compiling rocksdb v0.21.0 Compiling sourmash_plugin_branchwater v0.9.4 (/Users/olgabot/code/sourmash_plugin_branchwater) warning: use of deprecated method `pyo3::deprecations::GilRefs::::function_arg`: use `&Bound<'_, T>` instead for this function argument --> src/lib.rs:310:45 | 310 | fn sourmash_plugin_branchwater(_py: Python, m: &PyModule) -> PyResult<()> { | ^ | = note: `#[warn(deprecated)]` on by default warning: `sourmash_plugin_branchwater` (lib) generated 1 warning Finished dev [unoptimized + debuginfo] target(s) in 3m 37s 📦 Built wheel for CPython 3.12 to /var/folders/7z/r1593ybs1sj2ks5zzl9vy8840000gn/T/.tmpFNRgIW/sourmash_plugin_branchwater-0.9.4-cp312-cp312-macosx_10_14_x86_64.whl ✏️ Setting installed package as editable 🛠 Installed sourmash_plugin_branchwater-0.9.4 ```
olgabot commented 1 week ago

FYI to get cargo doc --open to work, I needed to do export MACOSX_DEPLOYMENT_TARGET=10.14 first, so it looks like this:

export MACOSX_DEPLOYMENT_TARGET=10.14
cargo doc --open

For some reason, the MacOS deployment target was getting set at 10.7 on my machine, so I think somehow this line in the pyproject.toml file was getting ignored:

https://github.com/sourmash-bio/sourmash_plugin_branchwater/blob/a24cdd6f72d7f51b2a385f020a4a948d7df43a24/pyproject.toml#L47