From 08e0d8c39aa1b2d3d29bbe0ff9f4becb099b8c21 Mon Sep 17 00:00:00 2001 From: espie Date: Fri, 17 Jul 2009 09:33:12 +0000 Subject: [PATCH] a few minor tweaks: - don't reload rewrite if it's already there, one less warning for httpd - pinpoint translation errors - document the painful state of updates from drupal5... --- www/drupal6/core/Makefile | 4 ++-- www/drupal6/core/files/drupal.conf | 6 ++++-- .../core/patches/patch-includes_locale_inc | 12 +++++++++++ www/drupal6/core/pkg/MESSAGE | 21 +++++++++++++++++++ 4 files changed, 39 insertions(+), 4 deletions(-) create mode 100644 www/drupal6/core/patches/patch-includes_locale_inc diff --git a/www/drupal6/core/Makefile b/www/drupal6/core/Makefile index caf9ac3b1e1..10d4f811277 100644 --- a/www/drupal6/core/Makefile +++ b/www/drupal6/core/Makefile @@ -1,9 +1,9 @@ -# $OpenBSD: Makefile,v 1.3 2009/07/15 10:33:39 espie Exp $ +# $OpenBSD: Makefile,v 1.4 2009/07/17 09:33:12 espie Exp $ COMMENT = powerful content management system DISTNAME = drupal-6.13 -PKGNAME= ${DISTNAME} +PKGNAME= ${DISTNAME}p0 DISTFILES= ${DISTNAME}${EXTRACT_SUFX} RUN_DEPENDS = ::www/php5/core \ diff --git a/www/drupal6/core/files/drupal.conf b/www/drupal6/core/files/drupal.conf index b2c349a4a30..db3cdcda5aa 100644 --- a/www/drupal6/core/files/drupal.conf +++ b/www/drupal6/core/files/drupal.conf @@ -1,8 +1,10 @@ -# $OpenBSD: drupal.conf,v 1.1 2009/04/03 23:27:16 espie Exp $ +# $OpenBSD: drupal.conf,v 1.2 2009/07/17 09:33:12 espie Exp $ # Written by Marc Espie, public domain # vim:filetype=apache: -LoadModule rewrite_module /usr/lib/apache/modules/mod_rewrite.so + + LoadModule rewrite_module /usr/lib/apache/modules/mod_rewrite.so + # Allows simple urls RewriteEngine on diff --git a/www/drupal6/core/patches/patch-includes_locale_inc b/www/drupal6/core/patches/patch-includes_locale_inc new file mode 100644 index 00000000000..f5b93471d6b --- /dev/null +++ b/www/drupal6/core/patches/patch-includes_locale_inc @@ -0,0 +1,12 @@ +$OpenBSD: patch-includes_locale_inc,v 1.1 2009/07/17 09:33:12 espie Exp $ +--- includes/locale.inc.orig Thu Jun 18 14:50:33 2009 ++++ includes/locale.inc Fri Jul 17 10:55:58 2009 +@@ -1271,7 +1271,7 @@ function _locale_import_one_string($op, $value = NULL, + $header = _locale_import_parse_header($value['msgstr']); + + // Get the plural formula and update in database. +- if (isset($header["Plural-Forms"]) && $p = _locale_import_parse_plural_forms($header["Plural-Forms"], $file->filename)) { ++ if (isset($header["Plural-Forms"]) && $p = _locale_import_parse_plural_forms($header["Plural-Forms"], $file->filepath)) { + list($nplurals, $plural) = $p; + db_query("UPDATE {languages} SET plurals = %d, formula = '%s' WHERE language = '%s'", $nplurals, $plural, $lang); + } diff --git a/www/drupal6/core/pkg/MESSAGE b/www/drupal6/core/pkg/MESSAGE index 7e5232134a3..0fb753201c3 100644 --- a/www/drupal6/core/pkg/MESSAGE +++ b/www/drupal6/core/pkg/MESSAGE @@ -39,3 +39,24 @@ In postgresql, assuming an `admin' account has all rights: createuser -U admin --pwprompt --no-superuser --createdb --no-createrole drupal createdb -U drupal -E UTF8 drupal + +Updating from a drupal5 installation: + +a lot of things now work. Major stumbling blocks: +* views are lost. Recreating them may be quick, or very painful if you +have a lot of them. +* usernodes no longer exist. +* image has been replaced by imagefield. + +- first back-up your installation, using backup and migrate +- then DISABLE all 3rd party modules +- put the drupal5 site offline +- make sure you have enough space (database, website...) +- install the drupal6 packages you need. +- cp the defaults.settings.php to the settings.php, edit it to point to +your existing database. You will often also need $update_free_access=TRUE +- point your browser to update.php +- assuming things work, go to the /admin page, enable the modules you need +- rerun update.php +- you will often need to reconstruct the permissions +- don't forget to reset $update_free_access=FALSE