coin-or / CppAD

A C++ Algorithmic Differentiation Package: Home Page
https://cppad.readthedocs.io
Other
469 stars 95 forks source link

bin/get_colpack.sh Script Error #189

Closed raisin closed 7 months ago

raisin commented 7 months ago

When I run the following, command:

bin/get_colpack.sh

I get the following error/output:

bin/get_colpack.sh: line 67: ./configure: No such file or directory

Note: I encountered this error on both Debian 12 and Ubuntu 22.04 LTS.

raisin commented 7 months ago

The entire input and output in the shell is provided.

debianuser@debian:~/cppad.git$ bin/get_colpack.sh

prefix=/home/debianuser/cppad.git/build/prefix Executing get_colpack.sh cd external cd colpack.git git checkout --quiet v1.0.10 ./configure --prefix=/home/debianuser/cppad.git/build/prefix --libdir=/home/debianuser/cppad.git/build /prefix/lib64 --enable-static --enable-shared bin/get_colpack.sh: line 67: ./configure: No such file or directory

bradbell commented 7 months ago

It appears that you do not have the autotools installed on your system and colpack requires that. There error messaging for this case should be better.

Looking just below line 118 in https://github.com/coin-or/CppAD/blob/master/bin/get_colpack.sh we see

echo_eval cd $package.git
echo_eval git checkout --quiet v$version
# -----------------------------------------------------------------------------
if which autoconf >& /dev/null
then
   echo_eval libtoolize
   echo_eval autoreconf --install --force
fi

Feel free to post a pull request that gives a better error message. Note that colpack is optional and can be left out (while including other optional packages); see package_prefix on https://cppad.readthedocs.io/latest/cmake.html#package-prefix

raisin commented 7 months ago

Thanks - That was helpful. I'll create a pull request with a better error message. The README.md may be a bit misleading as indicated in the following annotation:

AutotoolsRequired

raisin commented 7 months ago

I created the following merge request:

https://github.com/coin-or/CppAD/pull/190

bradbell commented 7 months ago

colpack uses the autotools to do it's install. CppAD uses cmake to build its tests and do its install. CppAD can use colpack (if it is installed).

raisin commented 7 months ago

Thanks for the explanation. I see that you reviewed and merged my pull request. Thanks. I'm closing this issue.