[PATCH 4/4] timegm: add portable implementation (Solaris support)

2013-08-21 Thread vladimir.ma...@oracle.com
From: Blake Jones The timegm(3) function is a non-standard extension to libc which is available in GNU libc and on some BSDs. Although SunOS had this function in its libc, Solaris (unfortunately) removed it. This patch implements a very simple version of timegm() which is good

[PATCH 4/4] timegm: add portable implementation (Solaris support)

2013-08-20 Thread vladimir.ma...@oracle.com
From: Blake Jones The timegm(3) function is a non-standard extension to libc which is available in GNU libc and on some BSDs. Although SunOS had this function in its libc, Solaris (unfortunately) removed it. This patch implements a very simple version of timegm() which is good

[PATCH 4/4] timegm: add portable implementation (Solaris support)

2013-08-16 Thread vladimir.ma...@oracle.com
From: Blake Jones The timegm(3) function is a non-standard extension to libc which is available in GNU libc and on some BSDs. Although SunOS had this function in its libc, Solaris (unfortunately) removed it. This patch implements a very simple version of timegm() which is good

[PATCH 3/4] strsep: check for availability (Solaris support)

2013-08-16 Thread vladimir.ma...@oracle.com
From: Blake Jones Solaris does not ship a version of the strsep() function. This change adds a check to "configure" to see whether notmuch needs to provide its own implementation, and if so, it uses the new version in "compat/strsep.c" (which was copied from Mutt, and apparently

[PATCH 2/4] asctime: check for standards compliance (Solaris support)

2013-08-16 Thread vladimir.ma...@oracle.com
From: Vladimir Marek Add checks to "configure" to see whether _POSIX_PTHREAD_SEMANTICS needs to be defined to get the right number of arguments in the prototypes for asctime_r(). Solaris' default implementation conforms to POSIX.1c Draft 6, rather than the final POSIX.1c spec.

[PATCH 1/4] getpwuid: check for standards compliance (Solaris support)

2013-08-16 Thread vladimir.ma...@oracle.com
From: Blake Jones Add checks to "configure" to see whether _POSIX_PTHREAD_SEMANTICS needs to be defined to get the right number of arguments in the prototypes for getpwuid_r(). Solaris' default implementation conforms to POSIX.1c Draft 6, rather than the final POSIX.1c spec.

Solaris support - missing or incompatible functions (v2)

2013-08-16 Thread vladimir.ma...@oracle.com
Hi, I'm re-sending the patches which were rebased to current top of the tree. Apart from rebasing there has been no change made. I am using this notmuch for half a year and it seems to work fine. As I said in my previous email, not all the tests pass, but I know that the failures in the testing

[PATCH 4/4] timegm: add portable implementation (Solaris support)

2013-05-06 Thread vladimir.ma...@oracle.com
From: Blake Jones The timegm(3) function is a non-standard extension to libc which is available in GNU libc and on some BSDs. Although SunOS had this function in its libc, Solaris (unfortunately) removed it. This patch implements a very simple version of timegm() which is good

[PATCH 3/4] strsep: check for availability (Solaris support)

2013-05-06 Thread vladimir.ma...@oracle.com
From: Blake Jones Solaris does not ship a version of the strsep() function. This change adds a check to "configure" to see whether notmuch needs to provide its own implementation, and if so, it uses the new version in "compat/strsep.c" (which was copied from Mutt, and apparently

[PATCH 2/4] asctime: check for standards compliance (Solaris support)

2013-05-06 Thread vladimir.ma...@oracle.com
From: Vladimir Marek Add checks to "configure" to see whether _POSIX_PTHREAD_SEMANTICS needs to be defined to get the right number of arguments in the prototypes for asctime_r(). Solaris' default implementation conforms to POSIX.1c Draft 6, rather than the final POSIX.1c spec.

[PATCH 1/4] getpwuid: check for standards compliance (Solaris support)

2013-05-06 Thread vladimir.ma...@oracle.com
From: Blake Jones Add checks to "configure" to see whether _POSIX_PTHREAD_SEMANTICS needs to be defined to get the right number of arguments in the prototypes for getpwuid_r(). Solaris' default implementation conforms to POSIX.1c Draft 6, rather than the final POSIX.1c spec.

Solaris support - missing or incompatible functions

2013-05-06 Thread vladimir.ma...@oracle.com
Hi, This is next series of patches adding Solaris support to notmuch. I am mostly using what Blake Jones sent some time ago + I fixed all the comments he received back then. Since it's mostly his work, it's IMO fair to keep him as an author. But since I made sure the patches work, I'm signing

[PATCH] lib/message.cc: stale pointer bug (v3)

2013-05-02 Thread vladimir.ma...@oracle.com
From: Vladimir Marek Xapian::TermIterator::operator* returns std::string which is destroyed as soon as (*i).c_str() finishes. The remembered pointer 'term' then references invalid memory. Signed-off-by: Vladimir Marek --- lib/message.cc | 10 +- 1 file changed, 5

[PATCH 01/24] lib/message.cc: stale pointer bug

2013-05-02 Thread vladimir.ma...@oracle.com
From: Vladimir Marek Xapian::TermIterator::operator* returns std::string which is destroyed as soon as (*i).c_str() finishes. The remembered pointer 'term' then references invalid memory. Signed-off-by: Vladimir Marek --- lib/message.cc | 11 ++- 1 file changed, 6

[PATCH] don't store temporary value returned from c_str()

2013-04-20 Thread vladimir.ma...@oracle.com
From: Vladimir Marek This is causing problems when compiled by Oracle Studio. Memory pointed by (const char*)term was already changed once talloc_strdup was called. Signed-off-by: Vladimir Marek --- lib/message.cc |9 - 1 files changed, 4 insertions(+), 5

[PATCH 2/4] dirent->d_type not available on Soalris

2012-04-09 Thread vladimir.ma...@oracle.com
From: Vladimir Marek The inspiration was taken from similar issue in mutt: http://does-not-exist.org/mail-archives/mutt-dev/msg11290.html Signed-off-by: Vladimir Marek --- notmuch-new.c | 28 1 files changed, 28 insertions(+), 0 deletions(-)

[PATCH 4/4] Explicitly type void* pointers

2012-04-09 Thread vladimir.ma...@oracle.com
From: Vladimir Marek Signed-off-by: Vladimir Marek --- lib/database.cc |2 +- lib/message.cc |2 +- lib/thread.cc |2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/database.cc b/lib/database.cc index 16c4354..3c82632 100644 ---

[PATCH 3/4] Private strsep implementation

2012-04-09 Thread vladimir.ma...@oracle.com
From: Vladimir Marek strsep is not available on Solaris 10, so we stole the one used by mutt. Signed-off-by: Vladimir Marek --- compat/Makefile.local |4 +++ compat/compat.h |4 +++ compat/have_strsep.c | 10 +++ compat/strsep.c | 65

[PATCH 2/4] dirent->d_type not available on Soalris

2012-04-09 Thread vladimir.ma...@oracle.com
From: Vladimir Marek The inspiration was taken from similar issue in mutt: http://does-not-exist.org/mail-archives/mutt-dev/msg11290.html Signed-off-by: Vladimir Marek --- notmuch-new.c | 19 +-- 1 files changed, 13 insertions(+), 6 deletions(-) diff --git

notmuch on Solaris

2012-04-09 Thread vladimir.ma...@oracle.com
Hi, In order to make notmuch compilable on Solaris, I had to make some changes in the source code. Some changes are not yet ready to be included to official tree, some I believe are. So I took first few to see if I'm doing anything which could be accepted and hopefully decrease number of local