Update recipes for Caya

* Caya itself is building
 * The protocol add-ons aren't yet
This commit is contained in:
Adrien Destugues
2013-10-03 23:09:51 +02:00
parent fc08c3ad25
commit 29c2d2eabc
5 changed files with 224 additions and 168 deletions

View File

@@ -1,36 +0,0 @@
DESCRIPTION="Caya is a multiprotocol IM client."
HOMEPAGE="http://dev.osdrawer.net/projects/caya"
SRC_URI="svn+http://svn.osdrawer.net/caya/trunk"
REVISION="1"
STATUS_HAIKU="stable"
DEPEND="dev-libs/expat >= 2.0.1"
#CHECKSUM_MD5=""
BUILD()
{
cd caya-0.HEAD
./configure
jam
}
INSTALL()
{
cd caya-0.HEAD
mkdir -p ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya
mkdir -p ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya/smileys
mkdir -p ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya/protocols
mkdir -p ${DESTDIR}/`finddir B_COMMON_DIRECTORY`/include/caya/
ARCH=`readlink /boot/develop/abi/current |sed -e s!/!-!g`
cp generated/distro-haiku-${ARCH}-debug/Caya ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya
cp generated/distro-haiku-${ARCH}-debug/aim ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya/protocols
cp smileys/*.gif smileys/settings.xml ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya/smileys
cp application/CayaProtocol.h ${DESTDIR}/`finddir B_COMMON_DIRECTORY`/include/caya/
cp application/CayaConstants.h ${DESTDIR}/`finddir B_COMMON_DIRECTORY`/include/caya/
cp application/CayaProtocolMessages.h ${DESTDIR}/`finddir B_COMMON_DIRECTORY`/include/caya/
}
LICENSE="MIT"
COPYRIGHT="2009-2011 Andrea Anzani
2009-2011 Pierluigi Fiorini
2010-2011 Oliver Ruiz Dorantes
2011-2012 Casalinuovo Dario"

View File

@@ -0,0 +1,63 @@
SUMMARY="Caya is a multiprotocol IM client."
HOMEPAGE="http://dev.osdrawer.net/projects/caya"
SRC_URI="svn+http://svn.osdrawer.net/caya/trunk#293"
REVISION="1"
ARCHITECTURES="x86 x86_gcc2"
PROVIDES="
caya = $portVersion
lib:libexpat
"
REQUIRES="
haiku >= $haikuVersion
"
BUILD_REQUIRES="
devel:libexpat
"
BUILD_PREREQUIRES="
haiku_devel >= $haikuVersion
cmd:gcc
cmd:ld
cmd:jam
cmd:which
"
PATCH()
{
mkdir -p $sourceDir/generated/objects-haiku-x86-gcc2-debug/application
echo $portVersion > $sourceDir/generated/objects-haiku-x86-gcc2-debug/application/svn_revision
}
BUILD()
{
./configure
jam
}
INSTALL()
{
mkdir -p $appsDir/Caya
mkdir -p $appsDir/Caya/smileys
mkdir -p $appsDir/Caya/protocols
mkdir -p $includeDir/caya/
cp generated/distro-haiku-*-debug/Caya $appsDir/Caya
cp generated/distro-haiku-*-debug/aim $appsDir/Caya/protocols
cp smileys/*.gif smileys/settings.xml $appsDir/Caya/smileys
cp application/CayaProtocol.h $includeDir/caya/
cp application/CayaConstants.h $includeDir/caya/
cp application/CayaProtocolMessages.h $includeDir/caya/
}
LICENSE="MIT"
COPYRIGHT="
2009-2011 Andrea Anzani
2009-2011 Pierluigi Fiorini
2010-2011 Oliver Ruiz Dorantes
2011-2012 Casalinuovo Dario
"
DESCRIPTION="
Caya is a multiprotocol chat client for Haiku. It supports msn, aim, jabber,
google talk, and facebook.
"

View File

@@ -1,21 +1,37 @@
DESCRIPTION="GPL Plugins for Caya, protocols MSN and XMPP"
SUMMARY="MSN and XMPPprotocols for Caya"
HOMEPAGE="http://dev.osdrawer.net/projects/caya-gpl-protocols"
SRC_URI="svn+http://svn.osdrawer.net/caya-gpl-protocols/trunk#36"
REVISION="1"
STATUS_HAIKU="stable"
DEPEND="caya"
#CHECKSUM_MD5=""
MESSAGE="This port only builds with gcc4."
SUPPLEMENTS="caya"
ARCHITECTURES="!x86 !x86_gcc2"
PROVIDES="
caya_gpl_protocols = $portVersion
"
REQUIRES="
caya
"
BUILD_REQUIRES="
caya
"
BUILD_PREREQUIRES="
cmd:jam
cmd:gcc
cmd:which
"
PATCH="caya_gpl_protocol-36.patchset"
BUILD()
{
cd caya-gpl-protocols-36
./configure
includeDir=$includeDir ./configure
jam
}
INSTALL()
{
cd caya-gpl-protocols-36
mkdir -p ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya/protocols
cp generated/distro-haiku-x86-gcc4-debug/msn ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya/protocols
cp generated/distro-haiku-x86-gcc4-debug/gtalk ${DESTDIR}/`finddir B_APPS_DIRECTORY`/Caya/protocols
@@ -28,4 +44,8 @@ LICENSE="GNU GPL v2"
COPYRIGHT="2010-2011 Casalinuovo Dario
2009-2011 Pierluigi Fiorini
2010-2011 Oliver Ruiz Dorantes"
DESCRIPTION="
Caya is a multi-protocol IM client.
This package enables support for XMPP (jabber, google talk, facebook)
and MSN protocols.
"

View File

@@ -1,21 +1,72 @@
Index: libs/libmsn/msnobject.cpp
===================================================================
--- libs/libmsn/msnobject.cpp (revision 36)
+++ libs/libmsn/msnobject.cpp (working copy)
@@ -30,7 +30,7 @@
{
void MSNObject::addMSNObject(std::string filename, int Type)
From 2fcbc23eca1e8c07e03ecffcbb4ecbfce71b3757 Mon Sep 17 00:00:00 2001
From: Adrien Destugues <pulkomandy@pulkomandy.tk>
Date: Thu, 3 Oct 2013 22:52:00 +0200
Subject: Import gcc2 compatibility fixes.
diff --git a/libs/libgloox/connectionbosh.cpp b/libs/libgloox/connectionbosh.cpp
index f0a1124..c433564 100644
--- a/libs/libgloox/connectionbosh.cpp
+++ b/libs/libgloox/connectionbosh.cpp
@@ -303,7 +303,7 @@ namespace gloox
bool ci_equal( char ch1, char ch2 )
{
- return std::toupper( (unsigned char)ch1 ) == std::toupper( (unsigned char)ch2 );
+ return toupper( (unsigned char)ch1 ) == toupper( (unsigned char)ch2 );
}
std::string::size_type ci_find( const std::string& str1, const std::string& str2 )
diff --git a/libs/libgloox/gloox.h b/libs/libgloox/gloox.h
index b86462e..8186d20 100644
--- a/libs/libgloox/gloox.h
+++ b/libs/libgloox/gloox.h
@@ -1214,7 +1214,7 @@ namespace gloox
/**
* A multimap of strings.
*/
- typedef std::multimap<std::string, std::string> StringMultiMap;
+ typedef std::multimap<const std::string, const std::string> StringMultiMap;
class StanzaExtension;
/**
diff --git a/libs/libgloox/parser.cpp b/libs/libgloox/parser.cpp
index a72fbdc..5884624 100644
--- a/libs/libgloox/parser.cpp
+++ b/libs/libgloox/parser.cpp
@@ -141,7 +141,7 @@ namespace gloox
{
if( pos + needle.length() <= data.length() )
{
- std::ifstream::pos_type size;
+ std::streampos size;
char * memblock;
SHA_CTX ctx;
unsigned char digest[SHA_DIGEST_LENGTH];
Index: libs/libmsn/Jamfile
===================================================================
--- libs/libmsn/Jamfile (revision 36)
+++ libs/libmsn/Jamfile (working copy)
@@ -2,6 +2,7 @@
- if( !data.compare( pos, needle.length(), needle ) )
+ if( !data.compare(pos, needle.length(), needle ) )
{
pos += needle.length() - 1;
return ForwardFound;
diff --git a/libs/libgloox/siprofileft.cpp b/libs/libgloox/siprofileft.cpp
index 4836efd..aeafac4 100644
--- a/libs/libgloox/siprofileft.cpp
+++ b/libs/libgloox/siprofileft.cpp
@@ -84,11 +84,11 @@ namespace gloox
DataFormField* dff = df.addField( DataFormField::TypeListSingle, "stream-method" );
StringMultiMap sm;
if( streamTypes & FTTypeS5B )
- sm.insert( std::make_pair( "s5b", XMLNS_BYTESTREAMS ) );
+ sm.insert( std::make_pair<const char*, std::string>( "s5b", XMLNS_BYTESTREAMS ) );
if( streamTypes & FTTypeIBB )
- sm.insert( std::make_pair( "ibb", XMLNS_IBB ) );
+ sm.insert( std::make_pair<const char*, std::string>( "ibb", XMLNS_IBB ) );
if( streamTypes & FTTypeOOB )
- sm.insert( std::make_pair( "oob", XMLNS_IQ_OOB ) );
+ sm.insert( std::make_pair<const char*, std::string>( "oob", XMLNS_IQ_OOB ) );
dff->setOptions( sm );
feature->addChild( df.tag() );
diff --git a/libs/libmsn/Jamfile b/libs/libmsn/Jamfile
index ec7bd45..02a1dc4 100644
--- a/libs/libmsn/Jamfile
+++ b/libs/libmsn/Jamfile
@@ -2,6 +2,7 @@ SubDir TOP libs libmsn ;
SubDirSysHdrs [ FDirName $(TOP) ] ;
SubDirSysHdrs [ FDirName $(TOP) libs ] ;
@@ -23,10 +74,10 @@ Index: libs/libmsn/Jamfile
SubDirSysHdrs [ FDirName $(OPENSSL_INCLUDE_DIR) ] ;
Index: libs/libmsn/connection.h
===================================================================
--- libs/libmsn/connection.h (revision 36)
+++ libs/libmsn/connection.h (working copy)
diff --git a/libs/libmsn/connection.h b/libs/libmsn/connection.h
index c469460..c92539b 100644
--- a/libs/libmsn/connection.h
+++ b/libs/libmsn/connection.h
@@ -29,6 +29,7 @@
#include <vector>
#include <map>
@@ -35,11 +86,46 @@ Index: libs/libmsn/connection.h
#ifdef _MSC_VER
#pragma warning( disable : 4290 )
Index: libs/libmsn/util.cpp
===================================================================
--- libs/libmsn/util.cpp (revision 36)
+++ libs/libmsn/util.cpp (working copy)
@@ -146,8 +146,8 @@
diff --git a/libs/libmsn/message.cpp b/libs/libmsn/message.cpp
index aedf463..26eebd0 100644
--- a/libs/libmsn/message.cpp
+++ b/libs/libmsn/message.cpp
@@ -124,7 +124,7 @@ namespace MSN
{
std::string color = this->getFormatInfo()["CO"];
assert(color.size() <= 6 && color.size() >= 0);
- color.insert(0U, 6 - color.size(), '0');
+ color.insert((size_t)0, (size_t)(6 - color.size()), '0');
int r = 0, g = 0, b = 0;
b = strtol(color.substr(0, 2).c_str(), NULL, 16);
@@ -167,7 +167,7 @@ namespace MSN
void Message::setColor(std::string color)
{
- color.insert(0U, 6 - color.size(), '0');
+ color.insert((size_t)0, (size_t)(6 - color.size()), '0');
int r = 0, g = 0, b = 0;
r = strtol(color.substr(0, 2).c_str(), NULL, 16);
diff --git a/libs/libmsn/msnobject.cpp b/libs/libmsn/msnobject.cpp
index 4a83221..8192c3a 100644
--- a/libs/libmsn/msnobject.cpp
+++ b/libs/libmsn/msnobject.cpp
@@ -30,7 +30,7 @@ namespace MSN
{
void MSNObject::addMSNObject(std::string filename, int Type)
{
- std::ifstream::pos_type size;
+ std::streampos size;
char * memblock;
SHA_CTX ctx;
unsigned char digest[SHA_DIGEST_LENGTH];
diff --git a/libs/libmsn/util.cpp b/libs/libmsn/util.cpp
index b2f843f..5e73f54 100644
--- a/libs/libmsn/util.cpp
+++ b/libs/libmsn/util.cpp
@@ -146,8 +146,8 @@ namespace MSN
it1 != s1.end() && it2 != s2.end();
++it1, ++it2)
{
@@ -50,7 +136,7 @@ Index: libs/libmsn/util.cpp
}
size_t size1 = s1.size(), size2 = s2.size();
return (int) (size1 - size2);
@@ -358,11 +358,11 @@
@@ -358,11 +358,11 @@ namespace MSN
int FileSize(const char* sFileName)
{
std::ifstream f;
@@ -66,32 +152,10 @@ Index: libs/libmsn/util.cpp
return static_cast<int>(f.tellg() - begin_pos);
}
Index: libs/libmsn/message.cpp
===================================================================
--- libs/libmsn/message.cpp (revision 36)
+++ libs/libmsn/message.cpp (working copy)
@@ -124,7 +124,7 @@
{
std::string color = this->getFormatInfo()["CO"];
assert(color.size() <= 6 && color.size() >= 0);
- color.insert(0U, 6 - color.size(), '0');
+ color.insert((size_t)0, (size_t)(6 - color.size()), '0');
int r = 0, g = 0, b = 0;
b = strtol(color.substr(0, 2).c_str(), NULL, 16);
@@ -167,7 +167,7 @@
void Message::setColor(std::string color)
{
- color.insert(0U, 6 - color.size(), '0');
+ color.insert((size_t)0, (size_t)(6 - color.size()), '0');
int r = 0, g = 0, b = 0;
r = strtol(color.substr(0, 2).c_str(), NULL, 16);
Index: libs/libyahoo2/yahoo_httplib.c
===================================================================
--- libs/libyahoo2/yahoo_httplib.c (revision 36)
+++ libs/libyahoo2/yahoo_httplib.c (working copy)
diff --git a/libs/libyahoo2/yahoo_httplib.c b/libs/libyahoo2/yahoo_httplib.c
index 049f6e7..d2f6a53 100755
--- a/libs/libyahoo2/yahoo_httplib.c
+++ b/libs/libyahoo2/yahoo_httplib.c
@@ -29,19 +29,7 @@
#include <stdio.h>
#include <stdlib.h>
@@ -112,7 +176,7 @@ Index: libs/libyahoo2/yahoo_httplib.c
#include <errno.h>
#if HAVE_UNISTD_H
@@ -374,7 +362,6 @@
@@ -374,7 +362,6 @@ void yahoo_http_get(int id, const char *url, const char *cookies, int http11,
void yahoo_http_head(int id, const char *url, const char *cookies, int len,
char *payload, yahoo_get_fd_callback callback, void *data)
{
@@ -120,69 +184,11 @@ Index: libs/libyahoo2/yahoo_httplib.c
char host[255];
int port = 80;
char path[255];
Index: libs/libgloox/parser.cpp
===================================================================
--- libs/libgloox/parser.cpp (revision 36)
+++ libs/libgloox/parser.cpp (working copy)
@@ -141,7 +141,7 @@
{
if( pos + needle.length() <= data.length() )
{
- if( !data.compare( pos, needle.length(), needle ) )
+ if( !data.compare(pos, needle.length(), needle ) )
{
pos += needle.length() - 1;
return ForwardFound;
Index: libs/libgloox/siprofileft.cpp
===================================================================
--- libs/libgloox/siprofileft.cpp (revision 36)
+++ libs/libgloox/siprofileft.cpp (working copy)
@@ -84,11 +84,11 @@
DataFormField* dff = df.addField( DataFormField::TypeListSingle, "stream-method" );
StringMultiMap sm;
if( streamTypes & FTTypeS5B )
- sm.insert( std::make_pair( "s5b", XMLNS_BYTESTREAMS ) );
+ sm.insert( std::make_pair<const char*, std::string>( "s5b", XMLNS_BYTESTREAMS ) );
if( streamTypes & FTTypeIBB )
- sm.insert( std::make_pair( "ibb", XMLNS_IBB ) );
+ sm.insert( std::make_pair<const char*, std::string>( "ibb", XMLNS_IBB ) );
if( streamTypes & FTTypeOOB )
- sm.insert( std::make_pair( "oob", XMLNS_IQ_OOB ) );
+ sm.insert( std::make_pair<const char*, std::string>( "oob", XMLNS_IQ_OOB ) );
dff->setOptions( sm );
feature->addChild( df.tag() );
Index: libs/libgloox/connectionbosh.cpp
===================================================================
--- libs/libgloox/connectionbosh.cpp (revision 36)
+++ libs/libgloox/connectionbosh.cpp (working copy)
@@ -303,7 +303,7 @@
bool ci_equal( char ch1, char ch2 )
{
- return std::toupper( (unsigned char)ch1 ) == std::toupper( (unsigned char)ch2 );
+ return toupper( (unsigned char)ch1 ) == toupper( (unsigned char)ch2 );
}
std::string::size_type ci_find( const std::string& str1, const std::string& str2 )
Index: libs/libgloox/gloox.h
===================================================================
--- libs/libgloox/gloox.h (revision 36)
+++ libs/libgloox/gloox.h (working copy)
@@ -1214,7 +1214,7 @@
/**
* A multimap of strings.
*/
- typedef std::multimap<std::string, std::string> StringMultiMap;
+ typedef std::multimap<const std::string, const std::string> StringMultiMap;
class StanzaExtension;
/**
Index: protocols/msn/MSN.cpp
===================================================================
--- protocols/msn/MSN.cpp (revision 36)
+++ protocols/msn/MSN.cpp (working copy)
@@ -52,7 +52,7 @@
diff --git a/protocols/msn/MSN.cpp b/protocols/msn/MSN.cpp
index 087b949..e987c27 100644
--- a/protocols/msn/MSN.cpp
+++ b/protocols/msn/MSN.cpp
@@ -52,7 +52,7 @@ const char* kProtocolName = "MSN Protocol";
const uint32 kAvatarCheckMessage = 'AVMs';
struct pollfd* kPollSockets = NULL;
@@ -191,7 +197,7 @@ Index: protocols/msn/MSN.cpp
bool isSSL;
bool isConnected;
SSL *ssl;
@@ -718,7 +718,7 @@
@@ -718,7 +718,7 @@ void MSNP::registerSocket(void *s, int reading, int writing, bool isSSL)
return;
}
@@ -200,11 +206,11 @@ Index: protocols/msn/MSN.cpp
if (kSocketsSsl == NULL) {
Error("Memory Error!!\n", NULL);
return;
Index: protocols/xmpp/Jamfile
===================================================================
--- protocols/xmpp/Jamfile (revision 36)
+++ protocols/xmpp/Jamfile (working copy)
@@ -2,6 +2,7 @@
diff --git a/protocols/xmpp/Jamfile b/protocols/xmpp/Jamfile
index 34351ec..3848ff7 100644
--- a/protocols/xmpp/Jamfile
+++ b/protocols/xmpp/Jamfile
@@ -2,6 +2,7 @@ SubDir TOP protocols xmpp ;
SubDirSysHdrs [ FDirName $(TOP) ] ;
SubDirSysHdrs [ FDirName $(TOP) libs ] ;
@@ -212,3 +218,6 @@ Index: protocols/xmpp/Jamfile
SubDirSysHdrs [ FDirName $(OPENSSL_INCLUDE_DIR) ] ;
SubDirSysHdrs [ FDirName $(CAYA_INCLUDE_DIR) ] ;
--
1.8.3.4