Opened 14 years ago

Closed 14 years ago

Last modified 14 years ago

#25186 closed defect (fixed)

arpack-1 Configure error - build failure

Reported by: laurence@… Owned by: mamoll (Mark Moll)
Priority: Normal Milestone:
Component: ports Version: 1.9.0
Keywords: Cc: adfernandes (Andrew Fernandes), tenomoto (Takeshi Enomoto)
Port: arpack

Description

When installing arpack using: sudo port install arpack the build fails and reports that there were undefined symbols. Some of these symbols are functions from blas, which is found in vecLib framework. I do have vecLib installed, so I am assuming that arpack is not linking to the vecLib framework properly.

I am running:

  • Darwin 10.3.0 (from OS X Snow Leopard)
  • Xcode 3.2.2
  • gcc-4.4

Attachments (4)

arpack.log (26.1 KB) - added by laurence@… 14 years ago.
Snippet of log containing "Undefined symbols" error.
arpack.Portfile.patch (902 bytes) - added by laurence@… 14 years ago.
Patch for arpack Portfile
Portfile.diff (680 bytes) - added by adfernandes (Andrew Fernandes) 14 years ago.
Portfile_g95_atlas_accelerate.diff (3.5 KB) - added by tenomoto (Takeshi Enomoto) 14 years ago.

Download all attachments as: .zip

Change History (16)

Changed 14 years ago by laurence@…

Attachment: arpack.log added

Snippet of log containing "Undefined symbols" error.

comment:1 Changed 14 years ago by laurence@…

The error is reported as:

shell command "cd /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_math_arpack/work/ARPACK && /usr/bin/ld -arch x86_64 -dynamic -dylib -single_module -dead_strip -x -all_load -L. -L/opt/local/lib/gcc44/x86_64 -L/opt/local/lib/gcc44 -L/opt/local/lib -dylib_install_name /opt/local/lib/libarpack.1.dylib -current_version 1 -compatibility_version 1 libarpack.a -o libarpack.1.dylib -latlas -llapack -lgfortran -lSystem" returned error 1

I have found that this error can be fixed by adding -framework vecLib to the end of the linking command.

This changes the linking command from:

/usr/bin/ld -arch x86_64 -dynamic -dylib -single_module -dead_strip -x -all_load -L. -L/opt/local/lib/gcc44/x86_64 -L/opt/local/lib/gcc44 -L/opt/local/lib -dylib_install_name /opt/local/lib/libarpack.1.dylib -current_version 1 -compatibility_version 1 libarpack.a -o libarpack.1.dylib -latlas -llapack -lgfortran -lSystem

to

/usr/bin/ld -arch x86_64 -dynamic -dylib -single_module -dead_strip -x -all_load -L. -L/opt/local/lib/gcc44/x86_64 -L/opt/local/lib/gcc44 -L/opt/local/lib -dylib_install_name /opt/local/lib/libarpack.1.dylib -current_version 1 -compatibility_version 1 libarpack.a -o libarpack.1.dylib -latlas -llapack -lgfortran -lSystem -framework vecLib

comment:2 Changed 14 years ago by jmroot (Joshua Root)

Owner: changed from macports-tickets@… to mmoll@…
Port: arpack added

Please remember to fill in the Port field and cc the maintainer.

Changed 14 years ago by laurence@…

Attachment: arpack.Portfile.patch added

Patch for arpack Portfile

comment:3 Changed 14 years ago by laurence@…

I have attached a patch arpack.Portfile.patch that lead to arpack compiling on my machine.

comment:4 Changed 14 years ago by mamoll (Mark Moll)

I have exactly the environment as you and arpack installs fine for me (I just re-installed). There *has* to be some difference between your setup and mine. Can you attach the output of "port -dv install arpack +gcc44"? Also, can you check if instead of you change, adding "-lblas" to line 98 also fixes the bug?

comment:5 in reply to:  4 Changed 14 years ago by adfernandes (Andrew Fernandes)

Replying to mmoll@…:

I have exactly the environment as you and arpack installs fine for me (I just re-installed). There *has* to be some difference between your setup and mine. Can you attach the output of "port -dv install arpack +gcc44"? Also, can you check if instead of you change, adding "-lblas" to line 98 also fixes the bug?

Hi, mmoll - I have exactly the same build problem as laurence, and his patch fixed it for me. (Same computer/os/compiler, too.) Been wondering what the problem was.

I created specific patch based on laurence's submission. Fixed it for me.

Changed 14 years ago by adfernandes (Andrew Fernandes)

Attachment: Portfile.diff added

comment:6 Changed 14 years ago by adfernandes (Andrew Fernandes)

Cc: adfernandes@… added

Cc Me!

comment:7 Changed 14 years ago by mamoll (Mark Moll)

I committed a possible fix in r68674. Please let me know if it works.

comment:8 Changed 14 years ago by adfernandes (Andrew Fernandes)

I reverted and built using mmoll's r68674, and it works for me. Thanks! I'm guessing you can close this now.

Now to try and figure out why octave won't use arpack, as per #24476.

comment:9 in reply to:  8 Changed 14 years ago by laurence@…

Works for me too. Thanks.

comment:10 Changed 14 years ago by mamoll (Mark Moll)

Resolution: fixed
Status: newclosed

comment:11 Changed 14 years ago by tenomoto (Takeshi Enomoto)

Cc: takeshi@… added

Cc Me!

comment:12 Changed 14 years ago by tenomoto (Takeshi Enomoto)

arpack should depend on atlas if -lblas and -llapack is used or link agains vecLib as have already been suggested. I attached a yet another patch.

Octave uses arpack. Octave now depends on atlas, probably due to the problem with the *dot* problem arising from ABI differences (solution). Since atlas always takes long time to build and sometime falis I have tried to make vecLib back. See #21797.

Changed 14 years ago by tenomoto (Takeshi Enomoto)

Note: See TracTickets for help on using tickets.