When I add those lines to configure.ac I added them near the end immediatly after this line "AC_MSG_RESULT(${enable_experimental-no})"
the "./configure" portion of building works, but it dies on make with the following error
" checking for lirc_init in -llirc_client... yes ./configure: line 28725: syntax error near unexpected token `newline' ./configure: line 28725: ` yes:no:' make: *** [config.status] Error 2 "
This particular line is the last line generated by ./configure command, and appears in different parts of the file depending on where the autoconf steps have been added. I Have added in the part of the configure file that is causing the error.
line number 28725 reads " ac_header_preproc=no" for reference.
Any advice on how to fix this is much appreciated. The problem is especially annoying, because once the configure file has become corrupted, it can't be run again in an effort to fix itself. The "bad" parts of the file are being created by the lines in the origional message (which I have left at the bottom of the letter). Once they become a part of the configure file it's ruined, and I have to go scrounge up a new copy.
Regards Dave
" #include <lirc/lirc_client.h> _ACEOF if { (eval echo "$as_me:$LINENO: "$ac_cpp conftest.$ac_ext"") >&5 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1 ac_status=$? grep -v '^ *+' conftest.er1 >conftest.err rm -f conftest.er1 cat conftest.err >&5 echo "$as_me:$LINENO: $? = $ac_status" >&5 (exit $ac_status); } >/dev/null; then if test -s conftest.err; then ac_cpp_err=$ac_c_preproc_warn_flag ac_cpp_err=$ac_cpp_err$ac_c_werror_flag else ac_cpp_err= fi else ac_cpp_err=yes fi if test -z "$ac_cpp_err"; then ac_header_preproc=yes else echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5
ac_header_preproc=no fi "
On Thu, 30 Sep 2004, Rafael [iso-8859-1] Ávila de Espíndola wrote:
On Thursday 30 September 2004 14:07, David wrote:
I've been working for the last several days on adding lirc support directally into 'madplay' and am almost done, but I have a few questions that would make the finishing touches a lot easier.
Question:
I don't know anything about autoconf or automake or what a m4 macro is. I have manually edited the Makefile to support my builds, but i'm trying for correct implementation. The lirc web site says that only the following lines would be neded to add to the configuration process (files) to check for support.
here is the site for refereence. http://www.lirc.org/html/technical.html#library
dnl Check for LIRC client support dnl This really is not worth making a separate file for it.
have_lirc=yes AC_REQUIRE_CPP AC_CHECK_LIB(lirc_client,lirc_init, AC_CHECK_HEADER(lirc/lirc_client.h,true,have_lirc=no),have_lirc=no)
if test "$have_lirc" = "yes"; then dnl AC_DEFINE(HAVE_LIRC); true; else AC_MSG_ERROR([*** LIRC client support not available ***]); fi
Can someone plese tell me where and in which file to add these lines? Or just forward to me directally a copy of the files in a fixed state.
This is part of configure.ac
I'm not sure that this is all that is actually needed I did have to add this line to the Makefile to correctly link the program
LDFLAGS += /usr/lib/liblirc_client.so
try with -llirc_client. I don't remember if autoconf will add this for you. If it doesn't, add the LDFLAGS line in the true branch of the "if" in the configure.ac.
Hope this helps, and sorry I really don't understand automake and conf.
Rafael