[debian-mysql] d/rules file issues shared among MySQL 5.5, 5.6 and MariaDB 5.5 packaing

Otto Kekäläinen otto at seravo.fi
Fri Aug 8 10:22:46 UTC 2014


I didn't get any replies to this one yet, but after discussing on
#debian-mentors I had the courage to do some cleanups. Please check my
commits and copy to mysql-5.6 what you think is good:
http://anonscm.debian.org/cgit/pkg-mysql/mariadb-5.5.git/log/

(or https://github.com/ottok/mariadb-5.5/commits/master if you want to
use Github tools to add comments per line or per commit)

When I started packaging MariaDB for Debian, I was told that the
mysql-5.6/debian in git.debian.org was the perfect role model I should
follow. I think that it might not be that perfect after all and it has
a lot of cruft in in. Could we maybe have some irc meeting to review
the rules file, and the version-server-X.Y.postinst and .postrm files
across all variants? I think those would be most important to have in
perfect shape, and at the moment they are not, and they are possible
the source of some the bugs Robie is concerned about.


2014-08-07 2:30 GMT+03:00 Otto Kekäläinen <otto at seravo.fi>:
> Hello!
>
> I have some of questions/issues regarding certain common parts in the
> rules file. Please comment so I feel better about making certain
> changes :)
>
> I'll be using the line numbering of
> http://anonscm.debian.org/cgit/pkg-mysql/mysql-5.6.git/tree/debian/rules
> as coordinates.
>
>
> 1)
>> PACKAGE:=mysql-5.6
>
> Why is this defined? Where is it used? Not at least later in the same
> rules file. I don't have one for MariaDB and everything seems to work
> well.
>
>
> 2)
>> export MYSQL_BUILD_CC=$(DEB_HOST_GNU_TYPE)-gcc
>> export MYSQL_BUILD_CXX=$(DEB_HOST_GNU_TYPE)-g++
>
> Why are this exported instead of usual := syntax?
> (MYSQL_BUILD_CXX := $(DEB_HOST_GNU_TYPE)-g++)
>
>
> 3)
>> # This causes seg11 crashes if LDAP is used for groups in /etc/nsswitch.conf
>> # so it is disabled by default although, according to MySQL, it brings >10%
>> # performance gain if enabled. See #299382.
>> ifeq ($(STATIC_MYSQLD), 1)
>>    USE_STATIC_MYSQLD:=--with-mysqld-ldflags=-all-static
>> endif
>
> Has anybody tried this lately? Should we re-visit the issue
> https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=299382 from 2005 and
> enable this performance boost again?
>
>
> 4)
>> override_dh_auto_clean:
>> @echo "RULES.$@"
>> dh_testdir
>> dh_testroot
>> [ ! -d mysql-test/var ] || rm -rf mysql-test/var
>> rm -rf $(BUILDDIR) $(BUILDDIR_PIC)
>>debconf-updatepo
>
> Why is updatepo as a part of the clean rule?
>
>
> 5)
>> override_dh_auto_install: auto_install-stamp
>>
>> auto_install-stamp:
>
> Why do we define alone stamps and then directly execute them? Why not
> simply have the contents of the lone stamps directly under the dh
> override?
>
>
> 6)
> Why is the make build starting from line 88 run inside sh -c and not
> directly as is?
>
>
> 7)
>> dh_installlogrotate --name mysql-server
> and
>> dh_installcron --name mysql-server
>
> Do you think the MariaDB packages should here define mariadb-server?
>
>
> 8)
>>  get-orig-source:
>
> What tool uses this target? Can we simply skip it and use the contents
> of the watchfile instead?



More information about the pkg-mysql-maint mailing list