dun / munge

MUNGE (MUNGE Uid 'N' Gid Emporium) is an authentication service for creating and validating user credentials.
GNU Lesser General Public License v3.0
250 stars 46 forks source link

runstatedir causes error, it is not clear where run directory without it is. #117

Closed ggghamd closed 2 years ago

ggghamd commented 2 years ago

You said build with following command on readme but it is not working:

[root@localhost munge]# ./configure --prefix=/usr                 --sysconfdir=/etc             --localstatedir=/var          --runstatedir=/run       
configure: error: unrecognized option: `--runstatedir=/run'
Try `./configure --help' for more information
[root@localhost munge]# ./configure --prefix=/usr          ^C     --sysconfdir=/etc             --localstatedir=/var          --runstatedir=/run       
[root@localhost munge]# 

[root@localhost munge]# git remote -v
origin  https://github.com/dun/munge.git (fetch)
origin  https://github.com/dun/munge.git (push)
[root@localhost munge]# git branch
* master
[root@localhost munge]# git log
commit 0c37cc03b649d8861c2d9e8d172bff736bfd9ea4 (HEAD -> master, origin/master, origin/HEAD)
Author: Chris Dunlap <cdunlap@llnl.gov>
Date:   Wed Aug 4 21:41:36 2021 -0700

    Remove GCRYPT_VERSION from gcry_check_version

Without --runstatedir=/run , it continues but it is unclear where the runstatedir would be.

dun commented 2 years ago

I suspect you're using a version of autoconf prior to 2.70 (see autoconf --version). The --runstatedir option is only available if the configure script was generated with autoconf-2.70 or later.

However, you can also append the configure line with either --with-runstatedir=/run or runstatedir=/run.

If you're watching the configure script output, towards the top you should see something like:

checking for runstatedir... /run

After running configure, you can check the resulting config.log:

$ egrep ^runstatedir config.log
runstatedir='/run'

If runstatedir is not specified, it will default to ${localstatedir}/run.