mirror of
https://github.com/yann64/haikuports.git
synced 2026-03-19 01:46:00 +01:00
net-im/purple_matrix: Add libpurple matrix plugin
* The plugin for libpurple "works", but doesn't connect currently to matrix's services. * A good starting off point if someone wants to try and maintain purple-matrix since we need a matrix client badly. * Plugin loads in Chat-O-Matic
This commit is contained in:
20
net-im/purple_matrix/patches/purple_matrix-0.1.0.diff
Normal file
20
net-im/purple_matrix/patches/purple_matrix-0.1.0.diff
Normal file
@@ -0,0 +1,20 @@
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 1c01e5c..b3fe4b5 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -9,13 +9,13 @@ PKG_CFLAGS:=$(shell $(PKG_CONFIG) --cflags $(LIBS) || echo "FAILED")
|
||||
ifeq ($(PKG_CFLAGS),FAILED)
|
||||
$(error "$(PKG_CONFIG) failed")
|
||||
endif
|
||||
-CFLAGS+=$(PKG_CFLAGS) -fPIC -DPIC
|
||||
+CFLAGS+=$(PKG_CFLAGS) -fPIC -DPIC -Ivendor/http-parser
|
||||
|
||||
PKG_LDLIBS:=$(shell $(PKG_CONFIG) --libs $(LIBS) || echo "FAILED")
|
||||
ifeq ($(PKG_LDLIBS),FAILED)
|
||||
$(error "$(PKG_CONFIG) failed")
|
||||
endif
|
||||
-LDLIBS+=$(PKG_LDLIBS) -lhttp_parser
|
||||
+LDLIBS+=$(PKG_LDLIBS) vendor/http-parser/http_parser.o
|
||||
|
||||
ifndef MATRIX_NO_E2E
|
||||
LDLIBS+=-lolm -lgcrypt
|
||||
79
net-im/purple_matrix/purple_matrix-0.1.0.recipe
Normal file
79
net-im/purple_matrix/purple_matrix-0.1.0.recipe
Normal file
@@ -0,0 +1,79 @@
|
||||
SUMMARY="Matrix plugin for libpurple"
|
||||
DESCRIPTION="A plugin giving support for matrix, a popular chat service, to \
|
||||
libpurple."
|
||||
HOMEPAGE="https://github.com/matrix-org/purple-matrix"
|
||||
COPYRIGHT="2015 Richard van der Ho"
|
||||
LICENSE="GNU GPL v3"
|
||||
REVISION="2"
|
||||
SOURCE_URI="https://github.com/matrix-org/purple-matrix/archive/refs/tags/v$portVersion.tar.gz"
|
||||
SOURCE_DIR="purple-matrix-$portVersion"
|
||||
CHECKSUM_SHA256="645c7952740e1b53a9e7a0ea347acc3d305ee5a7aeb20aa43a711e794861ebcf"
|
||||
SOURCE_URI_2="https://github.com/nodejs/http-parser/archive/refs/tags/v2.9.4.tar.gz"
|
||||
SOURCE_DIR_2="http-parser-2.9.4"
|
||||
CHECKSUM_SHA256_2="467b9e30fd0979ee301065e70f637d525c28193449e1b13fbcb1b1fab3ad224f"
|
||||
PATCHES="purple_matrix-0.1.0.diff"
|
||||
|
||||
ARCHITECTURES="all !x86_gcc2"
|
||||
SECONDARY_ARCHITECTURES="x86"
|
||||
|
||||
PROVIDES="
|
||||
purple_matrix$secondaryArchSuffix = $portVersion
|
||||
lib:purple_discord$secondaryArchSuffix = $portVersion
|
||||
"
|
||||
REQUIRES="
|
||||
haiku$secondaryArchSuffix
|
||||
lib:libgcrypt$secondaryArchSuffix
|
||||
lib:libglib_2.0$secondaryArchSuffix
|
||||
lib:libjson_glib_1.0$secondaryArchSuffix
|
||||
lib:libsqlite3$secondaryArchSuffix
|
||||
lib:libolm$secondaryArchSuffix
|
||||
lib:libintl$secondaryArchSuffix
|
||||
lib:libpurple$secondaryArchSuffix
|
||||
lib:libz$secondaryArchSuffix
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku${secondaryArchSuffix}_devel
|
||||
devel:libgcrypt$secondaryArchSuffix
|
||||
devel:libglib_2.0$secondaryArchSuffix
|
||||
devel:libjson_glib_1.0$secondaryArchSuffix
|
||||
devel:libsqlite3$secondaryArchSuffix
|
||||
devel:libolm$secondaryArchSuffix
|
||||
devel:libintl$secondaryArchSuffix
|
||||
devel:libpurple$secondaryArchSuffix
|
||||
devel:libz$secondaryArchSuffix
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc$secondaryArchSuffix
|
||||
cmd:gettext
|
||||
cmd:make
|
||||
cmd:pkg_config$secondaryArchSuffix
|
||||
cmd:sed
|
||||
cmd:git
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
# Put old http-parser into vendor, our diff uses it in the build
|
||||
rm -rf vendor
|
||||
mkdir -p $sourceDir/vendor
|
||||
ln -s $sourceDir2 $sourceDir/vendor/http-parser
|
||||
|
||||
# build http-parser
|
||||
make -C vendor/http-parser $jobArgs
|
||||
|
||||
# build purple-matrix
|
||||
make $jobArgs
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
mkdir -p $libDir/purple-2
|
||||
cp libmatrix.so $libDir/purple-2/
|
||||
|
||||
# install protocol icons
|
||||
for i in 16 22 48; do
|
||||
mkdir -p $dataDir/pixmaps/pidgin/protocols/${i}
|
||||
install -m 644 matrix-${i}px.png $dataDir/pixmaps/pidgin/protocols/${i}/matrix.png
|
||||
done
|
||||
}
|
||||
Reference in New Issue
Block a user