bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-wget] [bug-wget] Libpsl for cookie domain checking in Wget


From: Tim Ruehsen
Subject: Re: [Bug-wget] [bug-wget] Libpsl for cookie domain checking in Wget
Date: Mon, 16 Jun 2014 11:50:12 +0200
User-agent: KMail/4.12.4 (Linux/3.14-1-amd64; KDE/4.13.1; x86_64; ; )

It is ok for me.

Here is slightly different approach to set ENABLE_PSL.
Maybe you find it more readable / understandable.

ENABLE_PSL=no
AC_ARG_WITH(libpsl,
    AS_HELP_STRING([--without-libpsl], [disable support for libpsl cookie 
checking.]),
    [],
    [AC_SEARCH_LIBS(psl_builtin, psl,
                     [ENABLE_PSL=yes; AC_DEFINE([WITH_LIBPSL], [1], [PSL 
support enabled])],
                     [AC_MSG_WARN(*** libpsl was not found. Fallback to Wget 
builtin cookie checking.)])
    ])

Tim

On Monday 16 June 2014 14:17:01 Darshit Shah wrote:
> Are there any issues with this patch? Or can we push this?
> 
> It worked just fine for me. I guess, we should update the others too.
> 
> On Thu, Jun 12, 2014 at 8:53 PM, Tim Rühsen <address@hidden> wrote:
> > Am Donnerstag, 12. Juni 2014, 13:24:02 schrieb Giuseppe Scrivano:
> >> Darshit Shah <address@hidden> writes:
> >> > On Wed, Jun 11, 2014 at 5:20 PM, Tim Rühsen <address@hidden> wrote:
> >> >> Am Freitag, 6. Juni 2014, 13:39:32 schrieb Darshit Shah:
> >> >>> I'm facing an issue with the patch I submitted for libpsl and would
> >> >>> be
> >> >>> glad if someone could help me.
> >> >>> 
> >> >>> The configure.ac file does not work as expected. When libpsl is not
> >> >>> installed on a system, the LDFLAGS does not contain -lpsl flag, but
> >> >>> the configure summary shows LIBPSL: Yes.
> >> >>> 
> >> >>> There is some discrepency in the output that I'd like to fix. The
> >> >>> build completes successfully because the HAVE_LIBPSL variable isn't
> >> >>> set, and Wget compiles without libpsl support. This should however
> >> >>> happen only when --without-libpsl was explicitly specified as a
> >> >>> configure option.
> >> >> 
> >> >> This should do it:
> >> >> 
> >> >> AC_ARG_WITH(libpsl,
> >> >> 
> >> >>     AS_HELP_STRING([--without-libpsl], [disable support for libpsl
> >> >>     cookie
> >> >>     checking.]), [
> >> >>     
> >> >>       with_libpsl=no
> >> >>     
> >> >>     ], [
> >> >>     
> >> >>       AC_CHECK_LIB(psl, psl_builtin,
> >> >>       
> >> >>                    [with_libpsl=yes; AC_DEFINE([WITH_LIBPSL], [1],
> >> >>                    [PSL
> >> >>                    support enabled]) LIBS="${LIBS} -lpsl"],
> >> >>                    [with_libpsl=no; AC_MSG_WARN(*** libpsl was not
> >> >>                    found. Fallback to Wget builtin cookie
> >> >>                    checking.)])>>
> >> >>     
> >> >>     ])
> >> 
> >> I've not tested it but I think this version should fix the problem we
> >> had before.  Just one observation, can we use a different name instead
> >> of "with_libpsl"?  AFAICS, it is used only to display a message at the
> >> end of the configure script, so I would prefer we don't mess with
> >> variables set already by autoconf.
> >> We will then need to set it to no before the AC_CHECK_LIB is used.
> > 
> > Just read that today AC_SEARCH_LIBS should be used instead of
> > AC_CHECK_LIBS.
> > 
> > That would be something like:
> > 
> > AC_ARG_WITH(libpsl,
> > 
> >     AS_HELP_STRING([--without-libpsl], [disable support for libpsl cookie
> >     checking.]), [],
> >     [
> >     
> >       AC_SEARCH_LIBS(psl_builtin, psl,
> >       
> >                      [AC_DEFINE([WITH_LIBPSL], [1], [PSL support
> >                      enabled])],
> >                      [AC_MSG_WARN(*** libpsl was not found. Fallback to
> >                      Wget builtin cookie checking.)])>     
> >     ])
> > 
> > AS_IF([test x$ac_cv_search_psl_builtin != "x-lpsl"], [ ENABLE_PSL=no ], [
> > ENABLE_PSL=yes ])
> > 
> > ...
> > PSL:               $ENABLE_PSL
> > ...
> > 
> > Tim




reply via email to

[Prev in Thread] Current Thread [Next in Thread]