rpms/akonadi/F-9 akonadi-1.1.1-mysql_conf.patch, NONE, 1.1 akonadi-1.1.1-startup-2.patch, NONE, 1.1 .cvsignore, 1.3, 1.4 akonadi.spec, 1.6, 1.7

Rex Dieter rdieter at fedoraproject.org
Sat Mar 14 16:36:54 UTC 2009


Author: rdieter

Update of /cvs/pkgs/rpms/akonadi/F-9
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv5929

Modified Files:
	.cvsignore akonadi.spec 
Added Files:
	akonadi-1.1.1-mysql_conf.patch akonadi-1.1.1-startup-2.patch 
Log Message:
sync w/devel branch (startup, mysql_conf patches mostly)


akonadi-1.1.1-mysql_conf.patch:

--- NEW FILE akonadi-1.1.1-mysql_conf.patch ---
diff -up akonadi-1.1.1/server/src/storage/mysql-global.conf.mysql_conf akonadi-1.1.1/server/src/storage/mysql-global.conf
--- akonadi-1.1.1/server/src/storage/mysql-global.conf.mysql_conf	2009-01-21 12:29:03.000000000 -0600
+++ akonadi-1.1.1/server/src/storage/mysql-global.conf	2009-02-20 11:18:57.000000000 -0600
@@ -49,6 +49,6 @@ innodb_additional_mem_pool_size=1M
 # SELECT sum(data_length) as bla, sum(index_length) as blub FROM information_schema.tables WHERE table_schema not in ("mysql", "information_schema");
 innodb_buffer_pool_size=80M
 # size of average write burst, keep Innob_log_waits small, keep Innodb_buffer_pool_wait_free small (see show global status like "inno%", show global variables)
-innodb_log_file_size=64M
+innodb_log_file_size=8M
 innodb_flush_log_at_trx_commit=2
 

akonadi-1.1.1-startup-2.patch:

--- NEW FILE akonadi-1.1.1-startup-2.patch ---
--- branches/akonadi/1.1/server/src/akonadi.cpp	2009/01/03 16:17:31	905029
+++ branches/akonadi/1.1/server/src/akonadi.cpp	2009/02/25 10:55:29	931467
@@ -225,23 +225,30 @@
   const QString actualConfig = XdgBaseDirs::saveDir( "data", QLatin1String( "akonadi" ) ) + QLatin1String("/mysql.conf");
   if ( globalConfig.isEmpty() )
     akFatal() << "Did not find MySQL server default configuration (mysql-global.conf)";
-  QFile globalFile( globalConfig );
-  QFile actualFile( actualConfig );
-  if ( globalFile.open( QFile::ReadOnly ) && actualFile.open( QFile::WriteOnly ) ) {
-    actualFile.write( globalFile.readAll() );
-    if ( !localConfig.isEmpty() ) {
-      QFile localFile( localConfig );
-      if ( localFile.open( QFile::ReadOnly ) ) {
-        actualFile.write( localFile.readAll() );
-        localFile.close();
+  bool confUpdate = false;
+  QFile actualFile ( actualConfig );
+  // update conf only if either global (or local) is newer than actual
+  if ( (QFileInfo( globalConfig ).lastModified() > QFileInfo( actualFile ).lastModified()) ||
+       (QFileInfo( localConfig ).lastModified()  > QFileInfo( actualFile ).lastModified()) )
+  {
+    QFile globalFile( globalConfig );
+    QFile localFile ( localConfig );
+    if ( globalFile.open( QFile::ReadOnly ) && actualFile.open( QFile::WriteOnly ) ) {
+      actualFile.write( globalFile.readAll() );
+      if ( !localConfig.isEmpty() ) {
+        if ( localFile.open( QFile::ReadOnly ) ) {
+          actualFile.write( localFile.readAll() );
+          localFile.close();
+        }
       }
+      globalFile.close();
+      actualFile.close();
+      confUpdate = true;
+    } else {
+      akError() << "Unable to create MySQL server configuration file.";
+      akError() << "This means that either the default configuration file (mysql-global.conf) was not readable";
+      akFatal() << "or the target file (mysql.conf) could not be written.";
     }
-    actualFile.close();
-    globalFile.close();
-  } else {
-    akError() << "Unable to create MySQL server configuration file.";
-    akError() << "This means that either the default configuration file (mysql-global.conf) was not readable";
-    akFatal() << "or the target file (mysql.conf) could not be written.";
   }
 
   // MySQL doesn't like world writeable config files (which makes sense), but
@@ -276,6 +283,12 @@
     }
   }
 
+  // clear mysql ib_logfile's in case innodb_log_file_size option changed in last confUpdate
+  if ( confUpdate ) {
+      QFile(dataDir + QDir::separator() + QString::fromLatin1( "ib_logfile0" )).remove();
+      QFile(dataDir + QDir::separator() + QString::fromLatin1( "ib_logfile1" )).remove();
+  }
+
   // synthesize the mysqld command
   QStringList arguments;
   arguments << QString::fromLatin1( "--defaults-file=%1/mysql.conf" ).arg( akDir );


Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/akonadi/F-9/.cvsignore,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- .cvsignore	23 Jul 2008 10:29:26 -0000	1.3
+++ .cvsignore	14 Mar 2009 16:36:22 -0000	1.4
@@ -1,2 +1 @@
-akonadi-0.82.0.tar.bz2
-akonadi-1.0.0.tar.bz2
+akonadi-1.1.1.tar.bz2


Index: akonadi.spec
===================================================================
RCS file: /cvs/pkgs/rpms/akonadi/F-9/akonadi.spec,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -r1.6 -r1.7
--- akonadi.spec	26 Jan 2009 10:57:58 -0000	1.6
+++ akonadi.spec	14 Mar 2009 16:36:22 -0000	1.7
@@ -1,7 +1,7 @@
 Summary: PIM Storage Service
 Name:    akonadi
 Version: 1.1.1
-Release: 1%{?dist}
+Release: 6%{?dist}
 
 Group:   System Environment/Libraries
 License: LGPLv2+
@@ -9,7 +9,15 @@
 Source0:  http://akonadi.omat.nl/akonadi-%{version}.tar.bz2
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
-BuildRequires: cmake
+# shrink default initial db size a bit (approx 140mb->28mb)
+%define mysql_conf_timestamp 20090220
+Patch1: akonadi-1.1.1-mysql_conf.patch
+
+## upstream
+# http://websvn.kde.org/branches/akonadi/1.1/server/src/akonadi.cpp?r1=905029&r2=931467&view=patch
+Patch100: akonadi-1.1.1-startup-2.patch
+
+BuildRequires: cmake >= 2.6.0
 BuildRequires: qt4-devel >= 4.4
 BuildRequires: automoc4
 BuildRequires: mysql-devel
@@ -48,14 +56,16 @@
 %prep
 %setup -q 
 
+%patch1 -p1 -b .mysql_conf
+touch -d %{mysql_conf_timestamp} server/src/storage/mysql-global.conf
+%patch100 -p3 -b .startup-2
+
 
 %build
 
 mkdir -p %{_target_platform}
 pushd %{_target_platform}
-# added CMAKE_SKIP_RPATH ... at least until universally in %%cmake macro -- Rex
 %{cmake} \
-  -DCMAKE_SKIP_RPATH:BOOL=ON \
   -DCONFIG_INSTALL_DIR=%{_sysconfdir} \
   ..
 popd
@@ -68,6 +78,8 @@
 make install DESTDIR=$RPM_BUILD_ROOT -C %{_target_platform}
 mkdir -p $RPM_BUILD_ROOT%{_datadir}/akonadi/agents
 
+touch -d %{mysql_conf_timestamp} $RPM_BUILD_ROOT%{_sysconfdir}/akonadi/mysql-local.conf
+
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -87,6 +99,7 @@
 %doc AUTHORS lgpl-license
 %dir %{_sysconfdir}/akonadi/
 %config(noreplace) %{_sysconfdir}/akonadi/mysql-global.conf
+%config(noreplace) %{_sysconfdir}/akonadi/mysql-local.conf
 %{_bindir}/akonadi_control
 %{_bindir}/akonadictl
 %{_bindir}/akonadiserver
@@ -105,7 +118,23 @@
 
 
 %changelog
-* Mon Jan 26 2009 Lukáš Tinkl <ltinkl at redhat.com> - 1.1.1-1
+* Wed Feb 25 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.1-6
+- rev startup patch
+- BR: cmake >= 2.6.0
+- preserve timestamp's on mysql*.conf's
+
+* Tue Feb 24 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.1-5
+- own %%_sysconfig/akonadi/mysql-local.conf
+- startup patch: reset conf only when needed, and clear mysql log file on update
+
+* Mon Feb 23 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.1.1-4
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
+
+* Fri Feb 20 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.1-3
+- shrink default db initial size a bit (approx 140mb->28mb)
+- drop extraneous RPATH-cmake baggage
+
+* Wed Jan 21 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.1-1
 - 1.1.1
 
 * Sun Jan 04 2009 Rex Dieter <rdieter at fedoraproject.org> - 1.1.0-1




More information about the fedora-extras-commits mailing list