Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

octave should have matching compilers availble #201376

Open
4 tasks done
dasergatskov opened this issue Dec 16, 2024 · 5 comments
Open
4 tasks done

octave should have matching compilers availble #201376

dasergatskov opened this issue Dec 16, 2024 · 5 comments
Labels
15-arm64 Sequoia arm64 is specifically affected 15 Sequoia is specifically affected bug Reproducible Homebrew/homebrew-core bug help wanted Task(s) needing PRs from the community or maintainers

Comments

@dasergatskov
Copy link

brew gist-logs <formula> link OR brew config AND brew doctor output

% brew config
HOMEBREW_VERSION: 4.4.12
ORIGIN: https://github.com/Homebrew/brew
HEAD: 3001afe88112c13b5aafdd92e097680897060881
Last commit: 24 hours ago
Branch: stable
Core tap JSON: 16 Dec 15:42 UTC
Core cask tap JSON: 16 Dec 15:42 UTC
HOMEBREW_PREFIX: /opt/homebrew
HOMEBREW_CASK_OPTS: []
HOMEBREW_MAKE_JOBS: 14
Homebrew Ruby: 3.3.6 => /opt/homebrew/Library/Homebrew/vendor/portable-ruby/3.3.6/bin/ruby
CPU: 14-core 64-bit arm_brava
Clang: 16.0.0 build 1600
Git: 2.39.5 => /Applications/Xcode.app/Contents/Developer/usr/bin/git
Curl: 8.7.1 => /usr/bin/curl
macOS: 15.2-arm64
CLT: 16.2.0.0.1.1733547573
Xcode: 16.2
Rosetta 2: false

Verification

  • My brew doctor output says Your system is ready to brew. and am still able to reproduce my issue.
  • I ran brew update and am still able to reproduce my issue.
  • I have resolved all warnings from brew doctor and that did not fix my problem.
  • I searched for recent similar issues at https://github.com/Homebrew/homebrew-core/issues?q=is%3Aissue and found no duplicates.

What were you trying to do (and why)?

For users to be able to install octave packages, the octave should be compiled with the same C/C+++/Fortran compilers
as on their systems. Currently there is a mismatch (at least for darwin24 systems), see e.g.
Homebrew/brew#18943 (comment)

What happened (include all command output)?

octave:1> pkg install -forge -verbose control
downloading tarball(s) from:
- https://packages.octave.org/download/control-4.1.0.tar.gz
mkdir (/var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T/oct-fvBVdD)
untar (/var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T/control-4.1.0-JcHsDy.tar.gz, /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T/oct-fvBVdD)
checking for mkoctfile... /opt/homebrew/Cellar/octave/9.3.0/bin/mkoctfile-9.3.0 --verbose
checking for octave-config... /opt/homebrew/Cellar/octave/9.3.0/bin/octave-config-9.3.0
...<deleted>...
clang++ -std=gnu++17 -c  -fPIC -I/opt/homebrew/Cellar/octave/9.3.0/include/octave-9.3.0/octave/.. -I/opt/homebrew/Cellar/octave/9.3.0/include/octave-9.3.0/octave -I/opt/homebrew/Cellar/octave/9.3.0/include  -pthread -g -O2  -Wall -Wno-deprecated-declarations   common.cc -o /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T//oct-DD7Qiz.o
clang++ -std=gnu++17 -I/opt/homebrew/Cellar/octave/9.3.0/include/octave-9.3.0/octave/.. -I/opt/homebrew/Cellar/octave/9.3.0/include/octave-9.3.0/octave -I/opt/homebrew/Cellar/octave/9.3.0/include  -pthread -g -O2  -Wall -Wno-deprecated-declarations -o __control_slicot_functions__.oct  /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T//oct-pYUwFC.o /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T//oct-DD7Qiz.o  slicotlibrary.a  -bundle -undefined dynamic_lookup -bind_at_load -bundle_loader /opt/homebrew/Cellar/octave/9.3.0/bin/octave-9.3.0 -L/opt/homebrew/Cellar/octave/9.3.0/lib/octave/9.3.0 -L/opt/homebrew/Cellar/octave/9.3.0/lib -bundle -undefined dynamic_lookup -bind_at_load -bundle_loader /opt/homebrew/Cellar/octave/9.3.0/bin/octave-9.3.0  -L/opt/homebrew/opt/openblas/lib -lopenblas  -L/opt/homebrew/opt/gcc/bin/../lib/gcc/current/gcc/aarch64-apple-darwin23/14 -L/opt/homebrew/opt/gcc/bin/../lib/gcc/current/gcc -L/opt/homebrew/opt/gcc/bin/../lib/gcc/current/gcc/aarch64-apple-darwin23/14/../../.. -lemutls_w -lheapt_w -lgfortran -lquadmath   -loctinterp -loctave
ld: warning: duplicate -bundle_loader option, '/opt/homebrew/Cellar/octave/9.3.0/bin/octave-9.3.0' ignored
ld: warning: search path '/opt/homebrew/opt/gcc/bin/../lib/gcc/current/gcc/aarch64-apple-darwin23/14' not found
ld: warning: search path '/opt/homebrew/opt/gcc/bin/../lib/gcc/current/gcc/aarch64-apple-darwin23/14/../../..' not found
ld: library 'emutls_w' not found
clang++: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [__control_slicot_functions__.oct] Error 1

error: pkg: error running 'make' for the control package
error: called from
    configure_make at line 117 column 9
    install at line 202 column 7
    pkg at line 619 column 9
octave:2> 

What did you expect to happen?

With self-compiled octave binary on the same system, it works fine:

clang++ -std=gnu++17 -I/usr/local/include/octave-10.0.0/octave/.. -I/usr/local/include/octave-10.0.0/octave -I/usr/local/include  -pthread -ggdb3 -O2 -march=native -mcpu=native -flto=thin  -Wall -Wno-deprecated-declarations -o __control_slicot_functions__.oct  /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T//oct-wQ6p9k.o /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T//oct-zBcofN.o  slicotlibrary.a  -bundle -undefined dynamic_lookup -bind_at_load  -L/usr/local/lib -bundle -undefined dynamic_lookup -bind_at_load  -L/opt/homebrew/opt/openblas/lib -lopenblas  -L/opt/homebrew/lib -L/opt/homebrew/Cellar/gcc/14.2.0_1/bin/../lib/gcc/current/gcc/aarch64-apple-darwin24/14 -L/opt/homebrew/Cellar/gcc/14.2.0_1/bin/../lib/gcc/current/gcc -L/opt/homebrew/Cellar/gcc/14.2.0_1/bin/../lib/gcc/current/gcc/aarch64-apple-darwin24/14/../../.. -lemutls_w -lheapt_w -lgfortran -lquadmath  -L/opt/homebrew/lib -bundle_loader /usr/local/bin/octave-10.0.0
copyfile /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T/oct-rC69gC/control-4.1.0/src/__control_helper_functions__.oct /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T/oct-rC69gC/control-4.1.0/src/__control_slicot_functions__.oct /var/folders/ds/5xsh6x4914x78jswflyz20c40000gn/T/oct-rC69gC/control-4.1.0/inst/aarch64-apple-darwin24.1.0-api-v59
The control package was installed into the directory
/Users/dmitri/.local/share/octave/api-v59/packages/control-4.1.0.

Step-by-step reproduction instructions (by running brew commands)

see above
@dasergatskov dasergatskov added the bug Reproducible Homebrew/homebrew-core bug label Dec 16, 2024

This comment was marked as resolved.

@carlocab
Copy link
Member

Can you try doing

/usr/bin/sed -i '' \
  's/aarch64-apple-darwin23/aarch64-apple-darwin24/g' \
  "$(brew --prefix octave)/lib/pkgconfig/octave.pc"

and see if it helps?

@dasergatskov
Copy link
Author

I tried it. Does not change anything.

@carlocab
Copy link
Member

Yes, looks like the flags are baked into mkoctfile. You'll probably need to rebuild octave from source with something like

brew reinstall --build-from-source octave

@carlocab carlocab added help wanted Task(s) needing PRs from the community or maintainers 15 Sequoia is specifically affected 15-arm64 Sequoia arm64 is specifically affected labels Dec 16, 2024
@dasergatskov
Copy link
Author

Yes, the paths are built into mkoctfile. I can build octave from sourse, though brew reinstall --build-from-source octave does not seem to be doing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
15-arm64 Sequoia arm64 is specifically affected 15 Sequoia is specifically affected bug Reproducible Homebrew/homebrew-core bug help wanted Task(s) needing PRs from the community or maintainers
Projects
None yet
Development

No branches or pull requests

2 participants