Your message dated Tue, 10 May 2016 12:19:02 +0000
with message-id <e1b06cw-0001zy...@franck.debian.org>
and subject line Bug#823705: fixed in firebird3.0 3.0.0.32483.ds4-2
has caused the Debian Bug report #823705,
regarding src:firebird3.0: FTBFS On Big-Endian Architectures
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)


-- 
823705: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=823705
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: src:firebird3.0
Version: 3.0.0.32483.ds4-1
Severity: serious
Tags: upstream patch
Justification: Policy 4.2

Control: forwarded -1 https://github.com/FirebirdSQL/firebird/pull/21

As can be seen from
https://buildd.debian.org/status/package.php?p=firebird3.0&suite=experimental,
this package fails to build from source on any big-endian architecture. Please
apply the attached patch to fix this.



-- System Information:
Debian Release: stretch/sid
  APT prefers unstable-debug
  APT policy: (500, 'unstable-debug'), (500, 'unstable'), (1, 'experimental-
debug'), (1, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 4.5.0-2-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
--- a/src/jrd/Relation.cpp
+++ b/src/jrd/Relation.cpp
@@ -308,7 +308,7 @@
 	const USHORT relLockLen = relation->getRelLockKeyLength();
 
 	Lock* lock = FB_NEW_RPT(*pool, relLockLen) Lock(tdbb, relLockLen, lckType, relation);
-	relation->getRelLockKey(tdbb, &lock->lck_key.lck_string[0]);
+	relation->getRelLockKey(tdbb, lock->getKeyString());
 
 	lock->lck_type = lckType;
 	switch (lckType)
--- a/src/jrd/btr.cpp
+++ b/src/jrd/btr.cpp
@@ -223,7 +223,7 @@
 
 void BtrPageGCLock::disablePageGC(thread_db* tdbb, const PageNumber &page)
 {
-	page.getLockStr(lck_key.lck_string);
+	page.getLockStr(getKeyString());
 	LCK_lock(tdbb, this, LCK_read, LCK_WAIT);
 }
 
@@ -235,7 +235,7 @@
 bool BtrPageGCLock::isPageGCAllowed(thread_db* tdbb, const PageNumber& page)
 {
 	BtrPageGCLock lock(tdbb);
-	page.getLockStr(lock.lck_key.lck_string);
+	page.getLockStr(lock.getKeyString());
 
 	ThreadStatusGuard temp_status(tdbb);
 
--- a/src/jrd/cch.cpp
+++ b/src/jrd/cch.cpp
@@ -4055,7 +4055,7 @@
 			fb_assert(lock->lck_ast != NULL);
 		}
 
-		bdb->bdb_page.getLockStr(lock->lck_key.lck_string);
+		bdb->bdb_page.getLockStr(lock->getKeyString());
 		if (LCK_lock_opt(tdbb, lock, lock_type, wait))
 		{
 			if (!lock->lck_ast)
--- a/src/jrd/lck.cpp
+++ b/src/jrd/lck.cpp
@@ -739,7 +739,7 @@
 
 	const SINT64 data =
 		dbb->dbb_lock_mgr->readData2(lock->lck_type,
-									 lock->lck_key.lck_string, lock->lck_length,
+									 lock->getKeyString(), lock->lck_length,
 									 lock->lck_owner_handle);
 	fb_assert(LCK_CHECK_LOCK(lock));
 	return data;
@@ -909,7 +909,7 @@
 	fb_assert(LCK_CHECK_LOCK(lock));
 
 	lock->lck_id = dbb->dbb_lock_mgr->enqueue(tdbb, statusVector, lock->lck_id,
-		lock->lck_type, lock->lck_key.lck_string, lock->lck_length,
+		lock->lck_type, lock->getKeyString(), lock->lck_length,
 		level, lock->lck_ast, lock->lck_object, lock->lck_data, wait,
 		lock->lck_owner_handle);
 
@@ -1036,7 +1036,7 @@
 	if (!att->att_compatibility_table)
 		hash_allocate(lock);
 
-	const USHORT hash_value = hash_func((UCHAR*) &lock->lck_key, lock->lck_length);
+	const USHORT hash_value = hash_func(lock->getKeyString(), lock->lck_length);
 
 	if (hash_slot)
 		*hash_slot = hash_value;
@@ -1061,7 +1061,7 @@
 		{
 			// check that the keys are the same
 
-			if (!memcmp(lock->lck_key.lck_string, collision->lck_key.lck_string, lock->lck_length))
+			if (!memcmp(lock->getKeyString(), collision->getKeyString(), lock->lck_length))
 				return collision;
 		}
 
@@ -1426,7 +1426,7 @@
 	// with the local ast handler, passing it the lock block itself
 
 	lock->lck_id = dbb->dbb_lock_mgr->enqueue(tdbb, statusVector, lock->lck_id,
-		lock->lck_type, (const UCHAR*) &lock->lck_key, lock->lck_length,
+		lock->lck_type, lock->getKeyString(), lock->lck_length,
 		level, external_ast, lock, lock->lck_data, wait, lock->lck_owner_handle);
 
 	// If the lock exchange failed, set the lock levels appropriately
--- a/src/jrd/lck.h
+++ b/src/jrd/lck.h
@@ -134,10 +134,19 @@
 
 	union
 	{
-		UCHAR lck_string[1];
+		UCHAR lck_string[8];
 		SINT64 lck_long;
 	} lck_key;						// Lock key string
 
+	UCHAR* getKeyString()
+	{
+#ifdef WORDS_BIGENDIAN
+		if (lck_length <= 8)
+			return &lck_key.lck_string[8-lck_length];
+#endif
+		return &lck_key.lck_string[0];
+	}
+
 	UCHAR lck_tail[1];				// Makes the allocator happy
 };
 
--- a/src/jrd/met.epp
+++ b/src/jrd/met.epp
@@ -1390,7 +1390,7 @@
 	const USHORT key_length = item->lock->lck_length;
 	AutoPtr<Lock> temp_lock(FB_NEW_RPT(*tdbb->getDefaultPool(), key_length)
 		Lock(tdbb, key_length, LCK_dsql_cache));
-	memcpy(temp_lock->lck_key.lck_string, item->lock->lck_key.lck_string, key_length);
+	memcpy(temp_lock->getKeyString(), item->lock->getKeyString(), key_length);
 
 	if (LCK_lock(tdbb, temp_lock, LCK_EX, LCK_WAIT))
 		LCK_release(tdbb, temp_lock);
@@ -4134,7 +4134,7 @@
 		item->locked = false;
 		item->lock = FB_NEW_RPT(*attachment->att_pool, key.length())
 			Lock(tdbb, key.length(), LCK_dsql_cache, item, blocking_ast_dsql_cache);
-		memcpy(item->lock->lck_key.lck_string, key.c_str(), key.length());
+		memcpy(item->lock->getKeyString(), key.c_str(), key.length());
 	}
 	else
 	{
--- a/src/jrd/GlobalRWLock.cpp
+++ b/src/jrd/GlobalRWLock.cpp
@@ -78,7 +78,7 @@
 
 	cachedLock = FB_NEW_RPT(getPool(), lockLen)
 		Lock(tdbb, lockLen, lckType, this, lockCaching ? blocking_ast_cached_lock : NULL);
-	memcpy(&cachedLock->lck_key, lockStr, lockLen);
+	memcpy(cachedLock->getKeyString(), lockStr, lockLen);
 }
 
 GlobalRWLock::~GlobalRWLock()

--- End Message ---
--- Begin Message ---
Source: firebird3.0
Source-Version: 3.0.0.32483.ds4-2

We believe that the bug you reported is fixed in the latest version of
firebird3.0, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to 823...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Damyan Ivanov <d...@debian.org> (supplier of updated firebird3.0 package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmas...@ftp-master.debian.org)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Format: 1.8
Date: Tue, 10 May 2016 11:50:00 +0000
Source: firebird3.0
Binary: firebird3.0-server firebird3.0-utils libfbclient2 libib-util 
firebird3.0-common firebird-dev firebird3.0-examples firebird3.0-doc 
firebird3.0-common-doc
Architecture: source
Version: 3.0.0.32483.ds4-2
Distribution: experimental
Urgency: medium
Maintainer: Debian Firebird Group <pkg-firebird-gene...@lists.alioth.debian.org>
Changed-By: Damyan Ivanov <d...@debian.org>
Closes: 823705
Description: 
 firebird3.0-common - common files for firebird 3.0 server, client and utilities
 firebird3.0-common-doc - copyright, licensing and changelogs of firebird3.0
 firebird3.0-doc - Documentation files for firebird database version 3.0
 firebird3.0-examples - Examples for Firebird - an RDBMS based on InterBase 6.0 
code
 firebird3.0-server - Firebird Server - an RDBMS based on InterBase 6.0 code
 firebird3.0-utils - Firebird user utilities
 firebird-dev - Development files for Firebird
 libfbclient2 - Firebird client library
 libib-util - Firebird UDF support library
Changes:
 firebird3.0 (3.0.0.32483.ds4-2) experimental; urgency=medium
 .
   * include Firebird.pas in firebird-dev package
   * Add patch from upstream commit 6a8067e fixing locking on big-endian
     (Closes: #823705)
   * libib-util.post{inst,rm}: replace ldconfig call with a trigger
   * Declare conformance with Policy 3.9.8 (no changes needed)
Checksums-Sha1: 
 1ede101a8ad187b563b9156706c786c33dbf3c30 2759 firebird3.0_3.0.0.32483.ds4-2.dsc
 e09cc46720582df15644f966c4640e056dfce383 97900 
firebird3.0_3.0.0.32483.ds4-2.debian.tar.xz
Checksums-Sha256: 
 49e211360b765c469b8ea5cc0193333db9756fa888ebd2af6d0cecff93d7b95e 2759 
firebird3.0_3.0.0.32483.ds4-2.dsc
 c45d0c7ec27ae9c769b5e51381e88b1067b7a1787640450f1e1373c2cbe059e1 97900 
firebird3.0_3.0.0.32483.ds4-2.debian.tar.xz
Files: 
 cd69ec427335a03d0f9f862c8d885e68 2759 database optional 
firebird3.0_3.0.0.32483.ds4-2.dsc
 90796758f25c7ef1e43b6d09c7c94db1 97900 database optional 
firebird3.0_3.0.0.32483.ds4-2.debian.tar.xz

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCAAGBQJXMc13AAoJENu+nU2Z0qAEcqwP/3VuRrjzpw5opcB0Ix/6G0OO
dzlHVs9J/Daxl2IYy54s2vBDues31oGV2UrEcfFaPuSUEngHv/aeYvNvCWOIFlg8
We06cAedGpdg5J+OXJ6N9VpNSYTNgGMyYNqZAsrpyOj3cySkzzAW3PuTO/R5Q3Fx
2idbOhkwMtNs9T9UCh6aVl2Gkf6UB1X00+UIswIpsdBCgpidpBuixdMgrLBrsMAo
mSU46PmjcYiWs2gcE6TAWQq87MSyT0LIfPO5JRdOJve8pQH2FZ7j+8df0/RtXknl
Xh/Cyjp/i3odDb8S0qOiLkekmPSkp1F8c8FN5hA9gRgGL+WgOywb2uTgLVcVCWSk
LpZeqAuBDz5PxDoV965EIeQfS41YAdt6m3p47LWys511dC2G/6Cgj9r59NQofjOH
YFQe+T7526Lx/KKw3s9zSH5tIOUi4PB+lR8YEOoSxUj7b6kXdNh0SRnfGs+RpWY7
hmE1m7zUCsrnYqBIL2OqxwBUIa7IWP7sTz2tJX05MSYHL/hDBzmEgffVDIPg6tj+
JvFtlgWINjUAafu3tuDk6AZ4h2s9u9IX2tx+7oypwq0jcKcE1OZ3yhxmpP1Yn3ZZ
y9OMhj2jikh/QjswOIY8Woseu3yaUo2QPytHN0zzn6hP68VXaU/wnW+JGPpXY2wu
1U5Tz32En7FlGoJc/OZ0
=neYQ
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to