I am new to m4 and am trying to set up a macro that allows the user to specify the location of the library in configure mode ./configure --with-mylib=/path/to/lib.so.
./configure --with-mylib=/path/to/lib.so
In the m4 macro, with help, AC_ARG_WITHI check if the given file really exists, and then save the path to the specified lib. MYLIB_PATH=esyscmd([dirname $withval]). This causes an error:
AC_ARG_WITH
MYLIB_PATH=esyscmd([dirname $withval])
dirname: missing operand
The shell does not know about $withval. How to execute it to execute this command?
$withval
Thank,
Andrew
This is because it esyscmdis executed m4when the configurescript is created, i.e. at compile time. Use
esyscmd
m4
configure
MYLIB_PATH=`dirname $with_mylib`
instead.
, $withval " with_package, - _", / , , .
with_package
_
/
Source: https://habr.com/ru/post/1784121/More articles:Menu icons are smaller than they should be - androidHow to get an Alfresco registration ticket without a user password, but with an impersonation of a user with a user principal name (UPN) - authenticationHow to format url formatting MVC form? - restЧтение файлов Excel в С# всегда в системе.__ ComObject? - c#Subversion svn: ignore after committing files not iggnore - version-controlGWT: how to get new size when doing onResize () in SplitLayoutPanel? - gwtWhy can't I access a variable from my event handler? - c #Stop DropShadowBorder console logging - javaRails Download Questions - ruby-on-railsQt здание 64 бит - 64bitAll Articles