BUG#27769 - MySQL should include debian packaging dir

Replaced hardcoded sover reference with variable.
Removed references to added manpages.
---
BUG#27769 
Cleaned up some things to make building the packages go a little smoother. 
---
debian/rules really does need to be called from the source root.
---
Fixed two problems with the build caused by adding debian to the source tree
---
Left off the debian/ prefix to the Makefile filter.
---
BUG#27769 - MySQL should include debian packaging dir
Changed substitution variables to match already existing autoconf vars.
Generate debian/control and debian/defs.mk from autoconf now, since we run that
to make a source package. 
---
Corrected incorrect variable name
---
Renamed template files to have shorter names. 
---
Moved generation of debian/control to dist-hook so make clean won't eat it.
---
A few final changes to make debs build from a source tarball dist. 
parent 99c5f418
......@@ -98,6 +98,7 @@ bin-dist: all
# Remove BK's "SCCS" subdirectories from source distribution
# Create initial database files for Windows installations.
# Create default debian control file for debian packaging needs
dist-hook:
rm -rf `find $(distdir) -type d -name SCCS -print`
rm -f `find $(distdir) -type l -print`
......@@ -106,6 +107,7 @@ dist-hook:
--basedir=$(top_builddir) \
--datadir=$(distdir)/win/data \
--srcdir=$(top_srcdir)
debian/rules control-file && cp $(top_builddir)/debian/control $(distdir)/debian/control
tags:
support-files/build-tags
......
......@@ -32,6 +32,9 @@ MYSQL_NO_DASH_VERSION=`echo $VERSION | sed -e "s|[[a-z]]*-.*$||"`
MYSQL_BASE_VERSION=`echo $MYSQL_NO_DASH_VERSION | sed -e "s|\.[[^.]]*$||"`
MYSQL_VERSION_ID=`echo $MYSQL_NO_DASH_VERSION. | sed -e 's/[[^0-9.]]//g; s/\./ /g; s/ \([[0-9]]\) / 0\\1 /g; s/ //g'`
# Add previous major version for debian package upgrade path
MYSQL_PREVIOUS_BASE_VERSION=4.1
# The port should be constant for a LONG time
MYSQL_TCP_PORT_DEFAULT=3306
MYSQL_UNIX_ADDR_DEFAULT="/tmp/mysql.sock"
......@@ -68,6 +71,7 @@ romanian russian serbian slovak spanish swedish ukrainian"
AC_SUBST(MYSQL_NO_DASH_VERSION)
AC_SUBST(MYSQL_BASE_VERSION)
AC_SUBST(MYSQL_VERSION_ID)
AC_SUBST(MYSQL_PREVIOUS_BASE_VERSION)
AC_SUBST(PROTOCOL_VERSION)
AC_DEFINE_UNQUOTED([PROTOCOL_VERSION], [$PROTOCOL_VERSION],
[mysql client protocol version])
......@@ -2896,7 +2900,7 @@ AC_CONFIG_FILES(Makefile extra/Makefile mysys/Makefile dnl
cmd-line-utils/libedit/Makefile dnl
win/Makefile dnl
zlib/Makefile dnl
debian/Makefile dnl
debian/Makefile debian/defs.mk dnl
cmd-line-utils/readline/Makefile)
AC_CONFIG_COMMANDS([default], , test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h)
AC_OUTPUT
......
......@@ -14,7 +14,104 @@
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
## Process this file with automake to create Makefile.in
EXTRA_DIST = mysql-test-MYVER.files.in libndbclientNDBSOVER-dev.files.in mysql-server-MYVER.config.in libndbclientNDBSOVER.README.Debian.in mysql-server-MYVER.postrm.in mysql-server-MYVER.NEWS.in libndbclientNDBSOVER.postinst.in mysql-server-MYVER.links.in libndbclientNDBSOVER.files.in source.lintian-overrides.in mysql-server-MYVER.docs.in libmysqlclientMYSOVER.files.in mysql-server-MYVER.files.in libndbclientNDBSOVER-dev.links.in libmysqlclientMYSOVER.postinst.in mysql-extra-MYVER.dirs.in libmysqlclientMYSOVER-dev.links.in mysql-server-MYVER.dirs.in libmysqlclientMYSOVER-dev.examples.in mysql-client-MYVER.lintian-overrides.in copyright.more libndbclientNDBSOVER-dev.dirs.in mysql-server-MYVER.README.Debian.in libmysqlclientMYSOVER.docs.in compat mysql-test-MYVER.dirs.in libmysqlclientMYSOVER-dev.files.in libmysqlclientMYSOVER.dirs.in mysql-server-MYVER.logcheck.ignore.server.in mysql-storage-MYVER.mysql-storage.init.in libmysqlclientMYSOVER.README.Debian.in mysql-client-MYVER.README.Debian.in Makefile.am mysql-server-MYVER.prerm.in mysql-common.dirs.in defs.mk mysql-server-MYVER.mysql-server.logrotate.in mysql-common.README.Debian.in copyright mysql-storage-MYVER.dirs.in mysql-common.preinst.in mysql-client-MYVER.files.in mysql-server-MYVER.templates.in mysql-tools-MYVER.dirs.in mysql-management-MYVER.mysql-management.init.in watch mysql-common.postrm.in mysql-server-MYVER.preinst.in README.Maintainer mysql-tools-MYVER.files.in mysql-client-MYVER.NEWS.in mysql-server-MYVER.lintian-overrides.in changelog mysql-server-MYVER.logcheck.ignore.paranoid.in mysql-common.files.in mysql-server-MYVER.logcheck.ignore.workstation.in mysql-extra-MYVER.files.in mysql-management-MYVER.files.in mysql-client-MYVER.docs.in libmysqlclientMYSOVER-dev.README.Maintainer.in mysql-storage-MYVER.files.in additions additions/ndb_mgmd.cnf additions/mysql-server.lintian-overrides additions/my.cnf mysql-server-MYVER.postinst.in libndbclientNDBSOVER.dirs.in po po/fr.po po/sv.po po/da.po po/es.po po/ja.po po/tr.po po/nb.po po/POTFILES.in.in po/cs.po po/pt.po po/gl.po po/pt_BR.po po/nl.po po/templates.pot po/de.po po/eu.po po/ro.po po/ru.po po/it.po po/ca.po mysql-client-MYVER.dirs.in control.in libmysqlclientMYSOVER-dev.dirs.in mysql-server-MYOLDVER.preinst.in mysql-server.preinst.in mysql-management-MYVER.dirs.in rules libmysqlclientMYSOVER-dev.docs.in
EXTRA_DIST = \
mysql-test-BASE.files.in \
libndbclientNLIB-dev.files.in \
mysql-server-BASE.config.in \
libndbclientNLIB.README.Debian.in \
mysql-server-BASE.postrm.in \
mysql-server-BASE.NEWS.in \
libndbclientNLIB.postinst.in \
mysql-server-BASE.links.in \
libndbclientNLIB.files.in \
source.lintian-overrides.in \
mysql-server-BASE.docs.in \
libmysqlclientSLIB.files.in \
mysql-server-BASE.files.in \
libndbclientNLIB-dev.links.in \
libmysqlclientSLIB.postinst.in \
mysql-extra-BASE.dirs.in \
libmysqlclientSLIB-dev.links.in \
mysql-server-BASE.dirs.in \
libmysqlclientSLIB-dev.examples.in \
mysql-client-BASE.lintian-overrides.in \
copyright.more \
libndbclientNLIB-dev.dirs.in \
mysql-server-BASE.README.Debian.in \
libmysqlclientSLIB.docs.in \
compat \
mysql-test-BASE.dirs.in \
libmysqlclientSLIB-dev.files.in \
libmysqlclientSLIB.dirs.in \
mysql-server-BASE.logcheck.ignore.server.in \
mysql-storage-BASE.mysql-storage.init.in \
libmysqlclientSLIB.README.Debian.in \
mysql-client-BASE.README.Debian.in \
Makefile.am \
mysql-server-BASE.prerm.in \
mysql-common.dirs.in \
defs.mk \
defs.mk.in \
mysql-server-BASE.mysql-server.logrotate.in \
mysql-common.README.Debian.in \
copyright \
mysql-storage-BASE.dirs.in \
mysql-common.preinst.in \
mysql-client-BASE.files.in \
mysql-server-BASE.templates.in \
mysql-tools-BASE.dirs.in \
mysql-management-BASE.mysql-management.init.in \
watch \
mysql-common.postrm.in \
mysql-server-BASE.preinst.in \
README.Maintainer \
mysql-tools-BASE.files.in \
mysql-client-BASE.NEWS.in \
mysql-server-BASE.lintian-overrides.in \
changelog \
mysql-server-BASE.logcheck.ignore.paranoid.in \
mysql-common.files.in \
mysql-server-BASE.logcheck.ignore.workstation.in \
mysql-extra-BASE.files.in \
mysql-management-BASE.files.in \
mysql-client-BASE.docs.in \
libmysqlclientSLIB-dev.README.Maintainer.in \
mysql-storage-BASE.files.in \
additions \
additions/ndb_mgmd.cnf \
additions/mysql-server.lintian-overrides \
additions/my.cnf \
mysql-server-BASE.postinst.in \
libndbclientNLIB.dirs.in \
po \
po/fr.po \
po/sv.po \
po/da.po \
po/es.po \
po/ja.po \
po/tr.po \
po/nb.po \
po/POTFILES.in.in \
po/cs.po \
po/pt.po \
po/gl.po \
po/pt_BR.po \
po/nl.po \
po/templates.pot \
po/de.po \
po/eu.po \
po/ro.po \
po/ru.po \
po/it.po \
po/ca.po \
mysql-client-BASE.dirs.in \
control.in \
libmysqlclientSLIB-dev.dirs.in \
mysql-server-PREV.preinst.in \
mysql-server.preinst.in \
mysql-management-BASE.dirs.in \
rules \
libmysqlclientSLIB-dev.docs.in
# Don't update the files from bitkeeper
%::SCCS/s.%
......
This diff is collapsed.
......@@ -3,3 +3,10 @@ MYSQL_BUILD_CXXFLAGS=-DBIG_JOINS=1 -felide-constructors -fno-rtti -O2
MYSQL_BUILD_CFLAGS=-DBIG_JOINS=1 -O2
MYSQL_BUILD_CC=gcc
MYSQL_BUILD_CXX=gcc
# These two never pick up the flavor when we persist settings
VER=@MYSQL_BASE_VERSION@
OLDVER=@MYSQL_PREVIOUS_BASE_VERSION@
MYSQL_BASE_VERSION=@MYSQL_BASE_VERSION@
MYSQL_PREVIOUS_BASE_VERSION=@MYSQL_PREVIOUS_BASE_VERSION@
SHARED_LIB_MAJOR_VERSION=@SHARED_LIB_MAJOR_VERSION@
NDB_SHARED_LIB_MAJOR_VERSION=@NDB_SHARED_LIB_MAJOR_VERSION@
......@@ -10,7 +10,7 @@ usr/bin/mysqlcheck
usr/bin/mysqldump
usr/bin/mysqlimport
usr/bin/mysqlshow
usr/share/lintian/overrides/mysql-client-@MYVER@
usr/share/lintian/overrides/mysql-client-@MYSQL_BASE_VERSION@
usr/share/man/man1/mysql.1
usr/share/man/man1/mysqlaccess.1
usr/share/man/man1/mysqladmin.1
......
mysql-client-@MYSQL_BASE_VERSION@: package-has-a-duplicate-relation
mysql-client-@MYVER@: package-has-a-duplicate-relation
......@@ -9,7 +9,7 @@ CNF=/etc/mysql/my.cnf
# Beware that there are two ypwhich one of them needs the 2>/dev/null!
if test -n "`which ypwhich 2>/dev/null`" && ypwhich >/dev/null 2>&1; then
db_input high mysql-server-@MYVER@/nis_warning || true
db_input high mysql-server-@MYSQL_BASE_VERSION@/nis_warning || true
db_go
fi
......@@ -34,6 +34,6 @@ if [ "$1" = "configure" ] &&
egrep -q -i '^[[:space:]]*old.passwords[[:space:]]*=[[:space:]]*(1|true)' $CNF
)
then
db_input medium mysql-server-@MYVER@/need_sarge_compat || true
db_input medium mysql-server-@MYSQL_BASE_VERSION@/need_sarge_compat || true
db_go
fi
......@@ -26,7 +26,7 @@ usr/bin/resolveip
usr/sbin/mysqld
usr/sbin/mysqlmanager
usr/lib/mysql/mysqld.sym
usr/share/lintian/overrides/mysql-server-@MYVER@
usr/share/lintian/overrides/mysql-server-@MYSQL_BASE_VERSION@
usr/share/info/mysql.info
usr/share/man/man1/mysqlman.1
usr/share/man/man1/my_print_defaults.1
......
mysql-server-@MYSQL_BASE_VERSION@: possible-bashism-in-maintainer-script postinst:81 'p{("a".."z","A".."Z",0..9)[int(rand(62))]}'
mysql-server-@MYSQL_BASE_VERSION@: possible-bashism-in-maintainer-script preinst:33 '${cmd/ */}'
mysql-server-@MYSQL_BASE_VERSION@: statically-linked-binary ./usr/bin/mysql_tzinfo_to_sql
mysql-server-@MYSQL_BASE_VERSION@: statically-linked-binary ./usr/sbin/mysqld
......@@ -137,12 +137,12 @@ EOF
# On dist-upgrades, we ensure that the old_password setting is updated
# before passwords are changed. Except for that config files are taboo!
db_get mysql-server-@MYVER@/need_sarge_compat_done || true
db_get mysql-server-@MYSQL_BASE_VERSION@/need_sarge_compat_done || true
if [ "$RET" = "false" ]; then
db_get mysql-server-@MYVER@/need_sarge_compat
db_get mysql-server-@MYSQL_BASE_VERSION@/need_sarge_compat
echo -e "# created by debconf but save to be edited\n[mysqld]\nold_passwords = $RET" > /etc/mysql/conf.d/old_passwords.cnf
fi
db_set mysql-server-@MYVER@/need_sarge_compat_done true
db_set mysql-server-@MYSQL_BASE_VERSION@/need_sarge_compat_done true
# initiate databases. Output is not allowed by debconf :-(
# Debian: beware of the bashisms...
......
......@@ -49,9 +49,9 @@ if [ "$1" = "purge" -a ! \( -x /usr/sbin/mysqld -o -L /usr/sbin/mysqld \) ]; the
rm -f /var/log/mysql.{log,err}{,.0,.[1234567].gz}
rm -rf /var/log/mysql
db_input high mysql-server-@MYVER@/postrm_remove_databases || true
db_input high mysql-server-@MYSQL_BASE_VERSION@/postrm_remove_databases || true
db_go
db_get mysql-server-@MYVER@/postrm_remove_databases || true
db_get mysql-server-@MYSQL_BASE_VERSION@/postrm_remove_databases || true
if [ "$RET" = "true" ]; then
# never remove the debian.cnf when the databases are still existing
# else we ran into big trouble on the next install!
......@@ -87,6 +87,6 @@ if [ "$1" = "purge" ] ; then
fi
# (normally) End automatically added section
# no DEBHELPER here, "update-rc.d remove" fails if mysql-server-@MYVER@ is installed
# no DEBHELPER here, "update-rc.d remove" fails if mysql-server-@MYSQL_BASE_VERSION@ is installed
exit 0
Template: mysql-server-@MYVER@/really_downgrade
Template: mysql-server-@MYSQL_BASE_VERSION@/really_downgrade
Type: boolean
Default: false
_Description: Do you really want to downgrade?
......@@ -6,7 +6,7 @@ _Description: Do you really want to downgrade?
mysql-server package with a higher version has been installed before.
It can not be guaranteed that this version can use its data.
Template: mysql-server-@MYVER@/nis_warning
Template: mysql-server-@MYSQL_BASE_VERSION@/nis_warning
Type: note
_Description: Important note for NIS/YP users!
To use mysql you must install an equivalent user and group to the
......@@ -19,7 +19,7 @@ _Description: Important note for NIS/YP users!
.
/var/lib/mysql: drwxr-xr-x mysql mysql
Template: mysql-server-@MYVER@/postrm_remove_databases
Template: mysql-server-@MYSQL_BASE_VERSION@/postrm_remove_databases
Type: boolean
Default: false
_Description: Remove the databases used by all MySQL versions?
......@@ -27,7 +27,7 @@ _Description: Remove the databases used by all MySQL versions?
If it is planned to just install a higher MySQL version or if a different
mysql-server package is already using it, the data should be kept.
Template: mysql-server-@MYVER@/start_on_boot
Template: mysql-server-@MYSQL_BASE_VERSION@/start_on_boot
Type: boolean
Default: true
_Description: Should MySQL start on boot?
......@@ -54,16 +54,16 @@ _Description: Unable to set password for MySQL "root" user
is properly protected with a password (see README.Debian for more
information).
Template: mysql-server-@MYVER@/need_sarge_compat
Template: mysql-server-@MYSQL_BASE_VERSION@/need_sarge_compat
Type: boolean
Default: false
_Description: Support MySQL connections from hosts running Debian "sarge" or older?
The way passwords were stored was not very secure. This has been improved
with the drawback that clients (e.g. PHP) from hosts running Debian 3.1 Sarge
will not be able to connect to account which are new or whose password have
been changed. See /usr/share/doc/mysql-server-@MYVER@/README.Debian.
been changed. See /usr/share/doc/mysql-server-@MYSQL_BASE_VERSION@/README.Debian.
Template: mysql-server-@MYVER@/need_sarge_compat_done
Template: mysql-server-@MYSQL_BASE_VERSION@/need_sarge_compat_done
Type: boolean
Default: false
Description: for internal use
......
mysql-server-@MYVER@: possible-bashism-in-maintainer-script postinst:81 'p{("a".."z","A".."Z",0..9)[int(rand(62))]}'
mysql-server-@MYVER@: possible-bashism-in-maintainer-script preinst:33 '${cmd/ */}'
mysql-server-@MYVER@: statically-linked-binary ./usr/bin/mysql_tzinfo_to_sql
mysql-server-@MYVER@: statically-linked-binary ./usr/sbin/mysqld
[type: gettext/rfc822deb] mysql-server-@MYVER@.templates
[type: gettext/rfc822deb] mysql-server-@MYSQL_BASE_VERSION@.templates
This diff is collapsed.
maintainer-script-lacks-debhelper-token debian/mysql-server-@MYVER@.postinst
maintainer-script-lacks-debhelper-token debian/mysql-server-@MYVER@.postrm
maintainer-script-lacks-debhelper-token debian/mysql-server-@MYSQL_BASE_VERSION@.postinst
maintainer-script-lacks-debhelper-token debian/mysql-server-@MYSQL_BASE_VERSION@.postrm
outdated-autotools-helper-file bdb/dist/config.sub 2002-07-03
outdated-autotools-helper-file bdb/dist/config.guess 2002-07-23
bad-distribution-in-changes-file sarge
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment