From: Adolf Belka <adolf.belka@ipfire.org>
To: development@lists.ipfire.org
Subject: Re: [PATCH] sarg: Update to 2.4.0 (Still problems with build)
Date: Wed, 28 Apr 2021 15:38:35 +0200 [thread overview]
Message-ID: <a6a95a3a-e94b-5265-969d-d149a8016496@ipfire.org> (raw)
In-Reply-To: <2706384d-9870-fcdf-8395-23b22b66e876@ipfire.org>
[-- Attachment #1: Type: text/plain, Size: 12047 bytes --]
Hi All,
On 26/04/2021 15:01, Adolf Belka wrote:
> Hi Michael,
>
> On 26/04/2021 13:15, Adolf Belka wrote:
>> Hi Michael,
>>
>> On 26/04/2021 13:08, Michael Tremer wrote:
>>> Hello,
>>>
>>>> On 26 Apr 2021, at 11:50, Adolf Belka <adolf.belka(a)ipfire.org> wrote:
>>>>
>>>> Hi Michael,
>>>>
>>>> On 26/04/2021 12:23, Michael Tremer wrote:
>>>>> Hello,
>>>>>> On 25 Apr 2021, at 13:28, Adolf Belka <adolf.belka(a)ipfire.org>
>>>>>> wrote:
>>>>>>
>>>>>> - Update from 2.3.11 to 2.4.0
>>>>>> - Update of rootfile not required
>>>>>> - Thanks to Marcel Lorenz for advice on changes to lfs needed to
>>>>>> enable
>>>>>> successful build of sarg-2.4.0
>>>>>> - Removal of old patches that are no longer needed
>>>>>>
>>>>>> Signed-off-by: Adolf Belka <adolf.belka(a)ipfire.org>
>>>>>> ---
>>>>>> lfs/sarg | 32 ++++++--------
>>>>>> src/patches/sarg/sarg-2.3.11-configure.patch | 38 -----------------
>>>>>> src/patches/sarg/sarg-2.3.11-format.patch | 45
>>>>>> --------------------
>>>>>> 3 files changed, 13 insertions(+), 102 deletions(-)
>>>>>> delete mode 100644 src/patches/sarg/sarg-2.3.11-configure.patch
>>>>>> delete mode 100644 src/patches/sarg/sarg-2.3.11-format.patch
>>>>>>
>>>>>> diff --git a/lfs/sarg b/lfs/sarg
>>>>>> index 697ce7513..9b8a2b763 100644
>>>>>> --- a/lfs/sarg
>>>>>> +++ b/lfs/sarg
>>>>>> @@ -24,7 +24,7 @@
>>>>>>
>>>>>> include Config
>>>>>>
>>>>>> -VER = 2.3.11
>>>>>> +VER = 2.4.0
>>>>>>
>>>>>> THISAPP = sarg-$(VER)
>>>>>> DL_FILE = $(THISAPP).tar.gz
>>>>>> @@ -32,11 +32,11 @@ DL_FROM = $(URL_IPFIRE)
>>>>>> DIR_APP = $(DIR_SRC)/$(THISAPP)
>>>>>> TARGET = $(DIR_INFO)/$(THISAPP)
>>>>>> PROG = sarg
>>>>>> -PAK_VER = 4
>>>>>> +PAK_VER = 5
>>>>>>
>>>>>> DEPS =
>>>>>>
>>>>>> -CFLAGS += -fcommon
>>>>>> +CFLAGS += -Wno-format-truncation -Wformat-overflow=1 -fcommon
>>>>> There are quite severe problems and I do not think that just
>>>>> silencing the warnings is a good solution.
>>>>> Is there no updated version of the patch available? Or: why has
>>>>> upstream not fixed those issues?
>>>> I created new versions of the two patches but then I had a problem
>>>> with the following error (in earlier email)
>>>>
>>>> error: gettext infrastructure mismatch: using a Makefile.in.in from
>>>> gettext version 0.20 but the autoconf macros are from gettext
>>>> version 0.18
>>>
>>> Hopefully running autopoint should fix that.
>>>
>>>> I could not find anything on line to fix this. Marcel Lorenz gave
>>>> the feedback that the only way he got sarg-2.4.0 to build was with
>>>> the lfs that I then copied where he had no patches and used the
>>>> CFLAGS I then used.
>>>
>>> Is he not able to use the list?
>> Sorry, I missed that he had not added the list and just did reply to
>> all.
>>>
>>>> If this is not the way that you would like to solve this then I
>>>> still need help with the autoconf gettext macro at version 0.18. I
>>>> could not find how to fix this.
>>>
>>> Running autopoint (or autoreconf which will probably call it) is
>>> fine. The problem is the stack overruns that were patched before and
>>> the patch that was dropped. Those could potentially be used to
>>> inject any code.
>> Okay. Will try autoreconf and pull the patches I created out of my
>> backup and do a v2 version of the sarg update patch.
>>
> I looked at the log file from the failed sarg build and realised that
> it already ran autoreconf -vfi and that included running autopoint
> --force so the problem with the infrastructure is there after the
> autoreconf/autopoint commands have been run.
>
So I now tried building sarg using ./make.sh shell
I followed the various steps in the LFS file.
After autoreconf -vfi it reports running autopoint --force and then
copies the various m4 macros.
After this step I look at the gettext.m4 macro and it has version
gettext 0.18
In /usr/share/aclocal/ the gettext.m4 is version m4
In /usr/share/gettext/ there is no m4 directory but there is a .xz
tarball which contains the po and m4 directories and files for all
versions of gettext.
I can't find the command that is copying the 0.18 version macros so I
can't figure out why it is picking the wrong version and
autoreconf/autopoint is not correcting it.
Everything I have tried ends up with the same error message
error: gettext infrastructure mismatch: using a Makefile.in.in from
gettext version 0.20 but the autoconf macros are from gettext version 0.18
and I can't figure out how to make it use the correct version macros
that are available.
Regards,
Adolf.
> Regards,
>
> Adolf.
>
>> Adolf.
>>
>>>
>>> -Michael
>>>
>>>>
>>>> Regards,
>>>> Adolf.
>>>>
>>>>>> ###############################################################################
>>>>>>
>>>>>> # Top-level Rules
>>>>>> @@ -46,7 +46,7 @@ objects = $(DL_FILE)
>>>>>>
>>>>>> $(DL_FILE) = $(DL_FROM)/$(DL_FILE)
>>>>>>
>>>>>> -$(DL_FILE)_MD5 = 8e30d86b16597aec89ad401c72c761bc
>>>>>> +$(DL_FILE)_MD5 = 1b84509c1a0d55d46148bd957744870f
>>>>>>
>>>>>> install : $(TARGET)
>>>>>>
>>>>>> @@ -79,23 +79,17 @@ $(subst %,%_MD5,$(objects)) :
>>>>>> $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
>>>>>> @$(PREBUILD)
>>>>>> @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf
>>>>>> $(DIR_DL)/$(DL_FILE)
>>>>>> - $(UPDATE_AUTOMAKE)
>>>>>> -
>>>>>> - cd $(DIR_APP) && patch -Np1 <
>>>>>> $(DIR_SRC)/src/patches/sarg/sarg-2.3.11-format.patch
>>>>>> - cd $(DIR_APP) && patch -Np1 <
>>>>>> $(DIR_SRC)/src/patches/sarg/sarg-2.3.11-configure.patch
>>>>>> -
>>>>>> - cd $(DIR_APP) && autoreconf -vfi
>>>>>> -
>>>>>> - # Update gettext Makefile
>>>>>> - cd $(DIR_APP) && cp -vf /usr/share/gettext/po/Makefile.in.in
>>>>>> po/Makefile.in.in
>>>>>> -
>>>>>> - cd $(DIR_APP) && ./configure \
>>>>>> - --prefix=/usr \
>>>>>> - --sysconfdir=/etc/sarg
>>>>>> - cd $(DIR_APP) && make $(MAKETUNING) $(EXTRA_MAKE)
>>>>>> - cd $(DIR_APP) && make $(EXTRA_INSTALL) install
>>>>>> + cd $(DIR_APP) && autoreconf -vi
>>>>>> + cd $(DIR_APP) && ./configure \
>>>>>> + --prefix=/usr \
>>>>>> + --sysconfdir=/etc/sarg \
>>>>>> + --enable-sargphp=/var/www/html/sarg-php \
>>>>> We don’t have PHP.
>>>>>> + --bindir=/usr/bin
>>>>> This should be the default.
>>>>>> + cd $(DIR_APP) && make $(MAKETUNING)
>>>>>> + cd $(DIR_APP) && make install
>>>>>>
>>>>>> # Install configuration file.
>>>>>> + mkdir -p /etc/sarg
>>>>>> cp -v $(DIR_SRC)/config/sarg/sarg.conf /etc/sarg/sarg.conf
>>>>>>
>>>>>> # Install helper script.
>>>>>> diff --git a/src/patches/sarg/sarg-2.3.11-configure.patch
>>>>>> b/src/patches/sarg/sarg-2.3.11-configure.patch
>>>>>> deleted file mode 100644
>>>>>> index ca9695595..000000000
>>>>>> --- a/src/patches/sarg/sarg-2.3.11-configure.patch
>>>>>> +++ /dev/null
>>>>>> @@ -1,38 +0,0 @@
>>>>>> ---- sarg-2.3.11/configure.ac~ 2019-04-26 22:34:33.499022406
>>>>>> +0000
>>>>>> -+++ sarg-2.3.11/configure.ac 2019-04-26 22:35:11.886556020 +0000
>>>>>> -@@ -29,35 +29,6 @@
>>>>>> - # Report more warnings to improve code quality.
>>>>>> - CFLAGS="${CFLAGS} -Wall -Wno-sign-compare"
>>>>>> -
>>>>>> --dnl Check for supported compiler options
>>>>>> --
>>>>>> --AC_MSG_CHECKING([for extra warnings flag in $CC])
>>>>>> --saved_CFLAGS="${CFLAGS}"
>>>>>> --CFLAGS="${CFLAGS} -Wextra -Wno-unused-parameter"
>>>>>> --AC_COMPILE_IFELSE([AC_LANG_SOURCE([])],[have_extra_warnings="yes"],[have_extra_warnings="no"])
>>>>>>
>>>>>> --AC_MSG_RESULT($have_extra_warnings)
>>>>>> --if test "$have_extra_warnings" = "no" ; then
>>>>>> -- CFLAGS="${saved_CFLAGS}"
>>>>>> --fi
>>>>>> --
>>>>>> --AC_MSG_CHECKING([for implicit-function-declaration error flag
>>>>>> in $CC])
>>>>>> --saved_CFLAGS="${CFLAGS}"
>>>>>> --CFLAGS="${CFLAGS} -Werror=implicit-function-declaration"
>>>>>> --AC_COMPILE_IFELSE([AC_LANG_SOURCE([])],[have_implicit_function_declaration="yes"],[have_implicit_function_declaration="no"])
>>>>>>
>>>>>> --AC_MSG_RESULT($have_implicit_function_declaration)
>>>>>> --if test "$have_implicit_function_declaration" = "no" ; then
>>>>>> -- CFLAGS="${saved_CFLAGS}"
>>>>>> --fi
>>>>>> --
>>>>>> --AC_MSG_CHECKING([for format error flag in $CC])
>>>>>> --saved_CFLAGS="${CFLAGS}"
>>>>>> --CFLAGS="${CFLAGS} -Werror=format"
>>>>>> --AC_COMPILE_IFELSE([AC_LANG_SOURCE([])],[have_error_format="yes"],[have_error_format="no"])
>>>>>>
>>>>>> --AC_MSG_RESULT($have_error_format)
>>>>>> --if test "$have_error_format" = "no" ; then
>>>>>> -- CFLAGS="${saved_CFLAGS}"
>>>>>> --fi
>>>>>> --
>>>>>> - case "$host" in
>>>>>> - *-solaris*)
>>>>>> - LDFLAGS="${LDFLAGS} -lsocket -lnsl"
>>>>>> diff --git a/src/patches/sarg/sarg-2.3.11-format.patch
>>>>>> b/src/patches/sarg/sarg-2.3.11-format.patch
>>>>>> deleted file mode 100644
>>>>>> index d8ed22028..000000000
>>>>>> --- a/src/patches/sarg/sarg-2.3.11-format.patch
>>>>>> +++ /dev/null
>>>>>> @@ -1,45 +0,0 @@
>>>>>> -diff -wbBur sarg-2.3.11/index.c sarg-2.3.11.my/index.c
>>>>>> ---- sarg-2.3.11/index.c 2018-01-14 21:00:22.000000000 +0300
>>>>>> -+++ sarg-2.3.11.my/index.c 2018-02-19 12:20:15.896203347 +0300
>>>>>> -@@ -208,7 +208,7 @@
>>>>>> - m1=month / 16;
>>>>>> - if(month % 16 != 0) {
>>>>>> - m2=month % 16;
>>>>>> -- sprintf(monthnum,"%02d-%02d",m1,m2);
>>>>>> -+ sprintf(monthnum,"%02u-%02u",(unsigned
>>>>>> int)m1,(unsigned int)m2);
>>>>>> - sprintf(monthname1,"%02d",m1);
>>>>>> - sprintf(monthname2,"%02d",m2);
>>>>>> - name_month(monthname1,sizeof(monthname1));
>>>>>> -@@ -269,7 +269,7 @@
>>>>>> - d1=day / 32;
>>>>>> - if(day % 32 != 0) {
>>>>>> - d2=day % 32;
>>>>>> -- sprintf(daynum,"%02d-%02d",d1,d2);
>>>>>> -+ sprintf(daynum,"%02u-%02u",(unsigned int)d1,(unsigned int)d2);
>>>>>> - } else {
>>>>>> - sprintf(daynum,"%02d",d1);
>>>>>> - }
>>>>>> -diff -wbBur sarg-2.3.11/report.c sarg-2.3.11.my/report.c
>>>>>> ---- sarg-2.3.11/report.c 2018-01-14 21:00:23.000000000 +0300
>>>>>> -+++ sarg-2.3.11.my/report.c 2018-02-19 12:18:45.151207192 +0300
>>>>>> -@@ -54,7 +54,7 @@
>>>>>> - char accsmart[MAXLEN];
>>>>>> - char crc2[MAXLEN/2 -1];
>>>>>> - char siteind[MAX_TRUNCATED_URL];
>>>>>> -- char arqtt[256];
>>>>>> -+ char arqtt[267];
>>>>>> - char *oldurltt=NULL;
>>>>>> - char oldaccdiatt[11],oldacchoratt[9];
>>>>>> - char tmp3[MAXLEN];
>>>>>> -diff -wbBur sarg-2.3.11/userinfo.c sarg-2.3.11.my/userinfo.c
>>>>>> ---- sarg-2.3.11/userinfo.c 2013-06-01 22:02:04.000000000 +0400
>>>>>> -+++ sarg-2.3.11.my/userinfo.c 2018-02-19 12:21:16.103200796
>>>>>> +0300
>>>>>> -@@ -67,7 +67,7 @@
>>>>>> - int skip;
>>>>>> - int flen;
>>>>>> - int count, clen;
>>>>>> -- char cstr[9];
>>>>>> -+ char cstr[11];
>>>>>> -
>>>>>> - last=NULL;
>>>>>> - for (group=first_user_group ; group ; group=group->next) {
>>>>>> --
>>>>>> 2.31.1
>>>
--
Sent from my laptop
next prev parent reply other threads:[~2021-04-28 13:38 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-04-25 12:28 [PATCH] sarg: Update to 2.4.0 Adolf Belka
2021-04-26 10:23 ` Michael Tremer
2021-04-26 10:50 ` Adolf Belka
2021-04-26 11:08 ` Michael Tremer
2021-04-26 11:15 ` Adolf Belka
2021-04-26 13:01 ` Adolf Belka
2021-04-28 13:38 ` Adolf Belka [this message]
2021-04-28 15:16 ` [PATCH] sarg: Update to 2.4.0 (Still problems with build) Michael Tremer
2021-04-29 11:07 ` Adolf Belka
2021-05-14 12:43 ` Michael Tremer
2021-05-14 15:11 ` Adolf Belka
2021-05-18 10:56 ` Michael Tremer
2021-05-18 16:43 ` Adolf Belka
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=a6a95a3a-e94b-5265-969d-d149a8016496@ipfire.org \
--to=adolf.belka@ipfire.org \
--cc=development@lists.ipfire.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox