libprima / prima

PRIMA is a package for solving general nonlinear optimization problems without using derivatives. It provides the reference implementation for Powell's derivative-free optimization methods, i.e., COBYLA, UOBYQA, NEWUOA, BOBYQA, and LINCOA. PRIMA means Reference Implementation for Powell's methods with Modernization and Amelioration, P for Powell.
http://libprima.net
BSD 3-Clause "New" or "Revised" License
296 stars 38 forks source link

`gtest` does not run correctly under macOS with GitHub Actions #9

Closed zaikunzhang closed 1 year ago

zaikunzhang commented 1 year ago

gtest fails with the following message when testing macOS on GitHub Actions.

ld: library not found for -lgcrt1.o
collect2: error: ld returned 1 exit status

It used to work, but now it fails, with the gfortran version being 9, 10, 11, or, 12.

N.B.:

  1. Despite the failure, the test did not terminate with an error but continued. This is not really ideal. Probably the makefile needs revision.
  2. In the GitHub Actions tests, the gfortran is provided by awvwgk / setup-fortran.
zaikunzhang commented 1 year ago

Solved by fbe58d1. It was because gfortran was invoked with -pg, which was used to compile for profiling with gprof in a previous test. This option necessitatesgcrt1.o. Everything works after -pg is removed.