Discussion:
[bug-mailutils] how to download mailutils sources from git for next offline build
Franta Hanzlík
2017-07-06 14:54:53 UTC
Permalink
On Sat, 10 Jun 2017 14:44:07 +0200
Hello Franta,
How should I do that minimal tarbal, with ./configure for my system
autoconf, with .po files, radius.m4 and all needed files for mailutils
build - and withou other balast?
I think that `make dist` should do what you want. That's a default option for
gnu automake. There's also a `make distcheck`, which constructs the tarball
and additionnaly ensure most use case works, by attempting to build the
resulted tarball in a temporary directory. You'll find the documentation on the
automake/autotool website.
Kind Regards,
Pierre-Jean.
On Sat, 10 Jun 2017 19:08:54 +0300
Please, what is best way for preparing mailutils package for subsequent
build on destination machine,
make distcheck
Hello Pierre-Jean and Sergey,

thanks for your advices. Again I found some time working on compiling
mailutils, but results are not good:

- "make dist" ends with the contents of the directory 30 MB larger than
it was before.

- "make distcheck" produces decent tarball (~ 2.6 MB .tar.xz) and
continues with makeutils build. But after while it ends with error
...
CC inc.o
CC list.o
CC mail.o
CC mailline.o
CC mailvar.o
CC mbox.o
CC msgset.o
msgset.c:1176:5: error: two or more data types in declaration specifiers
msgset.c:1176:1: warning: useless type name in empty declaration [enabled by default]
msgset.c: In function ‘parse’:
msgset.c:1273:8: error: expected identifier or ‘(’ before ‘=’ token
msgset.c:1273:3: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
msgset.c:1380:7: error: expected expression before ‘char’
msgset.c:1383:12: error: expected identifier or ‘(’ before ‘=’ token
msgset.c:1383:7: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
msgset.c:1386:7: error: expected expression before ‘char’
msgset.c:1388:12: error: expected identifier or ‘(’ before ‘=’ token
msgset.c:1393:40: error: expected expression before ‘<=’ token
msgset.c:1420:8: error: expected identifier or ‘(’ before ‘=’ token
msgset.c:1420:3: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
msgset.c:1750:13: error: expected expression before ‘char’
msgset.c:1799:11: error: expected expression before ‘char’
msgset.c:1802:8: error: expected expression before ‘char’
msgset.c:1809:9: error: expected identifier or ‘(’ before ‘=’ token
msgset.c:1809:4: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
msgset.c:1907:7: error: expected expression before ‘char’
msgset.c:1911:40: error: expected expression before ‘<=’ token
make[4]: *** [msgset.o] Error 1
make[4]: Leaving directory `/mnt/ARCHIV/misc_src/mailutils/mailutils-3.2.93/mailutils-3.2.93/_build/mail'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/mnt/ARCHIV/misc_src/mailutils/mailutils-3.2.93/mailutils-3.2.93/_build/mail'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/mnt/ARCHIV/misc_src/mailutils/mailutils-3.2.93/mailutils-3.2.93/_build'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/mnt/ARCHIV/misc_src/mailutils/mailutils-3.2.93/mailutils-3.2.93/_build'
make: *** [distcheck] Error 1


I will get the same result when I take produced mailutils-3.2.93.tar.xz,
unpack it and then do ./configure && make :
...
CC list.o
CC mail.o
CC mailline.o
CC mailvar.o
CC mbox.o
CC msgset.o
msgset.c:1176:5: error: two or more data types in declaration specifiers
int char;
^
msgset.c:1176:1: warning: useless type name in empty declaration [enabled by default]
int char;
^
msgset.c: In function ‘parse’:
msgset.c:1273:8: error: expected identifier or ‘(’ before ‘=’ token
char = YYEMPTY; /* Cause a token to be read. */
^
msgset.c:1273:3: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
char = YYEMPTY; /* Cause a token to be read. */
^
msgset.c:1380:7: error: expected expression before ‘char’
if (char == YYEMPTY)
^
msgset.c:1383:12: error: expected identifier or ‘(’ before ‘=’ token
char = YYLEX;
^
msgset.c:1383:7: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
char = YYLEX;
^
msgset.c:1386:7: error: expected expression before ‘char’
if (char <= YYEOF)
^
msgset.c:1388:12: error: expected identifier or ‘(’ before ‘=’ token
char = yytoken = YYEOF;
^
msgset.c:1393:40: error: expected expression before ‘<=’ token
yytoken = YYTRANSLATE (char);
^
msgset.c:1420:8: error: expected identifier or ‘(’ before ‘=’ token
char = YYEMPTY;
^
msgset.c:1420:3: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
char = YYEMPTY;
^
msgset.c:1750:13: error: expected expression before ‘char’
yytoken = char == YYEMPTY ? YYEMPTY : YYTRANSLATE (char);
^
msgset.c:1799:11: error: expected expression before ‘char’
if (char <= YYEOF)
^
msgset.c:1802:8: error: expected expression before ‘char’
if (char == YYEOF)
^
msgset.c:1809:9: error: expected identifier or ‘(’ before ‘=’ token
char = YYEMPTY;
^
msgset.c:1809:4: warning: ISO C90 forbids mixed declarations and code [-Wdeclaration-after-statement]
char = YYEMPTY;
^
msgset.c:1907:7: error: expected expression before ‘char’
if (char != YYEMPTY)
^
msgset.c:1911:40: error: expected expression before ‘<=’ token
yytoken = YYTRANSLATE (char);
^
make[3]: *** [msgset.o] Error 1
make[3]: Leaving directory `/mnt/ARCHIV/dist/RH/MyRPMs/tmp/mailutils-3.2.93/mail'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/mnt/ARCHIV/dist/RH/MyRPMs/tmp/mailutils-3.2.93/mail'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/mnt/ARCHIV/dist/RH/MyRPMs/tmp/mailutils-3.2.93'
make: *** [all] Error 2


(I tried it with actual git version mailutils-3.2.93 ce4b84ab)

Regards, Franta
--
I hope the Fedora will have a better init and no binary logs
Sergey Poznyakoff
2017-07-06 15:50:18 UTC
Permalink
Post by Franta Hanzlík
msgset.c:1176:5: error: two or more data types in declaration specifiers
msgset.c:1176:1: warning: useless type name in empty declaration
[enabled by
I will need the contents of that file to be able to tell the cause of
the error.

Regards,
Sergey
Franta Hanzlík
2017-07-06 18:52:16 UTC
Permalink
On Thu, 06 Jul 2017 18:50:18 +0300
Post by Sergey Poznyakoff
Post by Franta Hanzlík
msgset.c:1176:5: error: two or more data types in declaration specifiers
msgset.c:1176:1: warning: useless type name in empty declaration
[enabled by
I will need the contents of that file to be able to tell the cause of
the error.
Regards,
Sergey
Hi Sergey, thanks for your help. Attached are outputs from configure and make
(I did just:
./configure --with-gsasl --with-gdbm --with-mysql --with-ldap --with-postgres >configure-output.lst 2>&1
make >make-output.lst 2>&1
)
and two mail/msgset.* files + some outputs perhaps from './configure'.
Sorry, the attachment is quite large.

Franta
--
I hope the Fedora will have a better init and no binary logs
Franta Hanzlík
2017-07-07 00:24:29 UTC
Permalink
On Thu, 06 Jul 2017 22:21:06 +0300
Post by Franta Hanzlík
Attached are outputs from configure and make
1. git pull
2. make maintainer-clean
3. ./bootstrap
4. ./configure
5. make
I'm far ahead, but there are still some little problem:

I did 'git clone', not 'git pull' (which I don't know, I know only clone),
and I got mailutils-3.2.93 commit 8d892095.

- ./bootstrap, ./configure and make ends OK on my F19/i686 machine.

- but when I tried to build mailutils on my F25/x86_64 server, ./configure
ends with error:
...
checking for struct sockaddr_in6... yes
checking for struct addrinfo... yes
checking for getnameinfo... yes
checking for wcwidth... (cached) yes
checking fribidi/fribidi.h usability... yes
checking fribidi/fribidi.h presence... yes
checking for fribidi/fribidi.h... yes
checking for fribidi_log2vis in -lfribidi... yes
checking for mysql_real_connect in -lmysqlclient... no
configure: error: in `/home/hanzlik/tmp/mailutils-3.2.93':
configure: error: The requested library libmysqlclient is not found or is unusable
See `config.log' for more details

which is perhaps because my libmysqlclient.so (mariadb-devel-10.1.24-3.fc25.x86_64)
is in /usr/lib64/mysql/ :
$ ls -l /usr/lib64/mysql/libmysqlclient.so
lrwxrwxrwx. 1 root root 20 Jun 9 08:31 /usr/lib64/mysql/libmysqlclient.so -> libmysqlclient.so.18

after patching 'configure' with:

$ diff -u configure_upto_2017.07.07 configure
--- configure_upto_2017.07.07 2017-07-07 00:33:11.000000000 +0200
+++ configure 2017-07-07 01:13:14.770476272 +0200
@@ -30825,7 +30825,7 @@
else
mu_cv_lib_mysqlclient=no
mu_check_lib_save_LIBS=$LIBS
- for path in "" /usr/local/lib/mysql /usr/lib/mysql
+ for path in "" /usr/lib64/mysql /usr/local/lib/mysql /usr/lib/mysql
do
if test -n "$path"; then
mu_ldflags="-L$path -lmysqlclient -lm"

I was able build mailutils on x86_64 arch too.

I tried, when this problem may be due to using tarball which was generated
on i32 system, and I was repeated new git clone/bootstrap/configure
procedure on x86_64 system, but configure ends with same
'libmysqlclient is not found' error.

I think, for now is my problem with mailutils build solved.
Again many thanks for your help.

Regards, Franta
--
I hope the Fedora will have a better init and no binary logs
Franta Hanzlík
2017-07-09 20:12:04 UTC
Permalink
On Fri, 07 Jul 2017 06:42:03 +0300
Post by Franta Hanzlík
which is perhaps because my libmysqlclient.so (mariadb-devel-10.1.24-3.fc25.x86_64)
$ ls -l /usr/lib64/mysql/libmysqlclient.so
lrwxrwxrwx. 1 root root 20 Jun 9 08:31 /usr/lib64/mysql/libmysqlclient.so -> libmysqlclient.so.18
./configure LDFLAGS='-L/usr/lib64/mysql'
This work, thanks.

But is this way of manually adding the path correct/optimal?
Should not solve this automatically ./bootstrap or ./configure itself?

What seems be weird and maybe related to problem above - on this x86_64
system are libraries installed under /usr/lib/ - although should be
(on systems, which support two architectures, as AMD64 is) placed under
/usr/lib64/, right?
Or am I doing something wrong?

Franta
--
I hope the Fedora will have a better init and no binary logs
Sergey Poznyakoff
2017-07-10 01:53:52 UTC
Permalink
Post by Franta Hanzlík
But is this way of manually adding the path correct/optimal?
It is quiet correct.
Post by Franta Hanzlík
Should not solve this automatically ./bootstrap or ./configure itself?
It could be figured out by configure.
Post by Franta Hanzlík
What seems be weird and maybe related to problem above - on this x86_64
system are libraries installed under /usr/lib/
Libraries in /usr/lib are 32-bit ones, those in /usr/lib64 are 64-bit
ones.

Regards,
Sergey
Franta Hanzlík
2017-07-15 22:25:42 UTC
Permalink
On Mon, 10 Jul 2017 04:53:52 +0300
Post by Sergey Poznyakoff
Post by Franta Hanzlík
But is this way of manually adding the path correct/optimal?
It is quiet correct.
Post by Franta Hanzlík
Should not solve this automatically ./bootstrap or ./configure itself?
It could be figured out by configure.
After looking to some other packages it seems as it should be solved
automatically - these paths for i386 and x86_64 are known.
In mailutils case perhaps sufficient should be patch:


--- configure.ac_OLD 2017-07-15 14:17:29.000000000 +0200
+++ configure.ac 2017-07-15 21:25:37.560452692 +0200
@@ -843,7 +843,7 @@
MU_SQL_LDADD(MYSQLLIBS, $mu_cv_lib_mysqlclient)
status_mysql=yes ],
[ AC_MSG_FAILURE([The requested library libmysqlclient is not found or is unusable])],
- [/usr/local/lib/mysql /usr/lib/mysql])
+ [${libdir}/mysql /usr/local/lib/mysql /usr/lib/mysql])
}

AC_ARG_WITH(mysql,
@@ -867,7 +867,7 @@
MU_SQL_LDADD(POSTGRESLIBS, $mu_cv_lib_pq)
status_pgsql=yes ],
[ AC_MSG_FAILURE([The requested library libpq is not found or is unusable])],
- [/usr/local/pgsql/lib /usr/pgsql/lib])
+ [${libdir}/pgsql/lib /usr/local/pgsql/lib /usr/pgsql/lib])
}

AC_ARG_WITH(postgres,


Using it and with '--libdir=/usr/lib64' ./configure option I was able build
mailutils also on Fedora 25/x86_64 systems.

Regards, Franta
--
I hope the Fedora will have a better init and no binary logs
Sergey Poznyakoff
2017-07-17 19:28:44 UTC
Permalink
Post by Franta Hanzlík
Using it and with '--libdir=/usr/lib64' ./configure option I was able build
I don't see any substantial difference between using
'--libdir=/usr/lib64' and 'LDFLAGS=-L/usr/lib64'.

Regards,
Sergey
Franta Hanzlík
2017-07-17 21:34:59 UTC
Permalink
On Mon, 17 Jul 2017 22:28:44 +0300
Post by Sergey Poznyakoff
Post by Franta Hanzlík
Using it and with '--libdir=/usr/lib64' ./configure option I was able build
I don't see any substantial difference between using
'--libdir=/usr/lib64' and 'LDFLAGS=-L/usr/lib64'.
I'm not sure. I would like to create an RPM mailutils package for my
distribution (I want to stick to the distribution convention and have
the system clean), and the LDFLAGS variable is somehow set up by its
packaging system and I do not want to influence it. While --libbir is
the regular option to the ./configure script.

Regards, Franta
--
I hope the Fedora will have a better init and no binary logs

Loading...