diff options
author | Alexander Logvinov <avl@FreeBSD.org> | 2010-12-17 03:14:17 +0000 |
---|---|---|
committer | Alexander Logvinov <avl@FreeBSD.org> | 2010-12-17 03:14:17 +0000 |
commit | 8138f75d54abe0f976c99ef8fcf3d33c464674b6 (patch) | |
tree | a8d0cd3b91d6721ea2312bcf4a3ab26ff323300a /net-im/openfetion | |
parent | 993dc341c5a87170f69ba3410ab67ce54027dd5f (diff) | |
download | ports-8138f75d54abe0f976c99ef8fcf3d33c464674b6.tar.gz ports-8138f75d54abe0f976c99ef8fcf3d33c464674b6.zip |
Notes
Diffstat (limited to 'net-im/openfetion')
-rw-r--r-- | net-im/openfetion/Makefile | 67 | ||||
-rw-r--r-- | net-im/openfetion/distinfo | 2 | ||||
-rw-r--r-- | net-im/openfetion/files/patch-lib_fetion_connection.c | 75 | ||||
-rw-r--r-- | net-im/openfetion/files/patch-src_fx_conn.c | 12 | ||||
-rw-r--r-- | net-im/openfetion/pkg-descr | 6 | ||||
-rw-r--r-- | net-im/openfetion/pkg-plist | 174 |
6 files changed, 336 insertions, 0 deletions
diff --git a/net-im/openfetion/Makefile b/net-im/openfetion/Makefile new file mode 100644 index 000000000000..6168abfcac97 --- /dev/null +++ b/net-im/openfetion/Makefile @@ -0,0 +1,67 @@ +# New ports collection makefile for: openfetion +# Date created: 11 December 2010 +# Whom: Yanhui Shen <shen.elf@gmail.com> +# +# $FreeBSD$ +# + +PORTNAME= openfetion +PORTVERSION= 2.0.7 +CATEGORIES= net-im +MASTER_SITES= GOOGLE_CODE + +MAINTAINER= shen.elf@gmail.com +COMMENT= An open source client for China Mobile's Fetion IM + +LIB_DEPENDS= sqlite3.8:${PORTSDIR}/databases/sqlite3 + +OPTIONS= XSCREENSAVER "Enable X screensaver extension" on \ + NOTIFY "Enable libnotify support" on \ + GSTREAMER "Enable gstreamer support" on + +GNU_CONFIGURE= yes +USE_GMAKE= yes +USE_GETTEXT= yes +USE_GNOME= gnomehack glib20 gtk20 libxml2 desktopfileutils +USE_OPENSSL= yes +USE_LDCONFIG= yes + +CONFIGURE_ARGS=--disable-nm +CONFIGURE_ENV= LIBSSL_CFLAGS=-Wl,-rpath,${OPENSSLRPATH} \ + LIBSSL_LIBS=-rpath=${OPENSSLRPATH} + +PROJECTHOST= ofetion +LICENSE= GPLv2 + +.include <bsd.port.options.mk> + +.if !defined(WITHOUT_XSCREENSAVER) +USE_XORG= xscrnsaver +CONFIGURE_ARGS+=--enable-screensaver +.else +CONFIGURE_ARGS+=--disable-screensaver +.endif + +.if !defined(WITHOUT_GSTREAMER) +USE_GSTREAMER= yes +CONFIGURE_ARGS+=--enable-gst +.else +CONFIGURE_ARGS+=--disable-gst +.endif + +.if !defined(WITHOUT_NOTIFY) +LIB_DEPENDS+= notify.1:${PORTSDIR}/devel/libnotify +CONFIGURE_ARGS+=--enable-libnotify +.else +CONFIGURE_ARGS+=--disable-libnotify +.endif + +post-patch: + @${REINPLACE_CMD} -e 's|$$(DESTDIR)$$(itlocaledir)|$${datarootdir}/locale|g' \ + ${WRKSRC}/po/Makefile.in.in + @${REINPLACE_CMD} -e 's|/usr|${PREFIX}|' ${WRKSRC}/resource/Makefile.in + +post-install: + @-update-desktop-database + +.include <bsd.port.mk> diff --git a/net-im/openfetion/distinfo b/net-im/openfetion/distinfo new file mode 100644 index 000000000000..1d1719d8e40d --- /dev/null +++ b/net-im/openfetion/distinfo @@ -0,0 +1,2 @@ +SHA256 (openfetion-2.0.7.tar.gz) = 37bdab942713512ab02d34e1b16a810764e55688c93cd5daee88c64c50c22695 +SIZE (openfetion-2.0.7.tar.gz) = 794386 diff --git a/net-im/openfetion/files/patch-lib_fetion_connection.c b/net-im/openfetion/files/patch-lib_fetion_connection.c new file mode 100644 index 000000000000..261e0c3a7182 --- /dev/null +++ b/net-im/openfetion/files/patch-lib_fetion_connection.c @@ -0,0 +1,75 @@ +--- lib/fetion_connection.c.orig 2010-11-28 20:53:01.000000000 +0900 ++++ lib/fetion_connection.c 2010-12-12 11:56:42.000000000 +0900 +@@ -22,6 +22,7 @@ + #include <fcntl.h> + #include <sys/ioctl.h> + #include <sys/types.h> ++#include <sys/socket.h> + #include <netinet/in.h> + #include <netinet/tcp.h> + #include <arpa/inet.h> +@@ -34,9 +35,15 @@ + int tcp_keep_alive(int socketfd) + { + int keepAlive = 1; ++#ifdef TCP_KEEPIDEL + int keepIdle = 10; ++#endif ++#ifdef TCP_KEEPINTVL + int keepInterval = 10; ++#endif ++#ifdef TCP_KEEPCNT + int keepCount = 10; ++#endif + + if(setsockopt(socketfd , SOL_SOCKET , SO_KEEPALIVE + ,(void*)&keepAlive,sizeof(keepAlive)) == -1){ +@@ -44,23 +51,29 @@ + return -1; + } + ++#ifdef TCP_KEEPIDEL + if(setsockopt(socketfd , SOL_TCP , TCP_KEEPIDLE + ,(void *)&keepIdle,sizeof(keepIdle)) == -1){ + debug_info("set TCP_KEEPIDEL failed\n"); + return -1; + } ++#endif + ++#ifdef TCP_KEEPINTVL + if(setsockopt(socketfd , SOL_TCP , TCP_KEEPINTVL + ,(void *)&keepInterval,sizeof(keepInterval)) == -1){ + debug_info("set TCP_KEEPINTVL failed\n"); + return -1; + } ++#endif + ++#ifdef TCP_KEEPCNF + if(setsockopt(socketfd , SOL_TCP , TCP_KEEPCNT + ,(void *)&keepCount,sizeof(keepCount)) == -1){ + debug_info("set TCP_KEEPCNT failed\n"); + return -1; + } ++#endif + return 1; + } + +@@ -369,10 +382,16 @@ + c = tcp_connection_recv(conn , buf , sizeof(buf) - 1); + if(c <= 0) + break; +- strcpy(res + n, buf); + n += c; +- if(n >= len) ++ if(n > len){ ++ free(res); ++ res = NULL; + break; ++ } ++ strcpy(res + n -c, buf); ++ if(n == len){ ++ break; ++ } + } + + return res; diff --git a/net-im/openfetion/files/patch-src_fx_conn.c b/net-im/openfetion/files/patch-src_fx_conn.c new file mode 100644 index 000000000000..63aa3197a0be --- /dev/null +++ b/net-im/openfetion/files/patch-src_fx_conn.c @@ -0,0 +1,12 @@ +--- src/fx_conn.c.orig 2010-11-28 20:53:01.000000000 +0900 ++++ src/fx_conn.c 2010-12-12 11:56:42.000000000 +0900 +@@ -24,8 +24,8 @@ + #include <netinet/in.h> + #include <netinet/tcp.h> + #include <arpa/inet.h> +-#include <net/if.h> + #include <sys/socket.h> ++#include <net/if.h> + #include <netdb.h> + + int old_state; diff --git a/net-im/openfetion/pkg-descr b/net-im/openfetion/pkg-descr new file mode 100644 index 000000000000..234673413b70 --- /dev/null +++ b/net-im/openfetion/pkg-descr @@ -0,0 +1,6 @@ +Fetion is an IM provided by China Mobile with features like text chat, +voice call, file sharing, etc. +Openfetion is an open source client of Fetion with limited features. +It's small and fast, and it looks better. + +WWW: http://code.google.com/p/ofetion/ diff --git a/net-im/openfetion/pkg-plist b/net-im/openfetion/pkg-plist new file mode 100644 index 000000000000..8b0942268753 --- /dev/null +++ b/net-im/openfetion/pkg-plist @@ -0,0 +1,174 @@ +bin/openfetion +include/fetion_buddylist.h +include/fetion_config.h +include/fetion_connection.h +include/fetion_contact.h +include/fetion_conversation.h +include/fetion_debug.h +include/fetion_directsms.h +include/fetion_group.h +include/fetion_history.h +include/fetion_list.h +include/fetion_login.h +include/fetion_message.h +include/fetion_share.h +include/fetion_sip.h +include/fetion_types.h +include/fetion_user.h +include/openfetion.h +lib/libofetion.a +lib/libofetion.la +lib/libofetion.so +lib/libofetion.so.0 +libdata/pkgconfig/ofetion.pc +share/applications/openfetion.desktop +share/pixmaps/fetion.svg +share/locale/zh_CN/LC_MESSAGES/openfetion.mo +%%DATADIR%%/resource/city.xml +%%DATADIR%%/resource/newmessage.wav +%%DATADIR%%/resource/province.xml +%%DATADIR%%/skin/LoadingImage.gif +%%DATADIR%%/skin/add.png +%%DATADIR%%/skin/away.svg +%%DATADIR%%/skin/bigimage.png +%%DATADIR%%/skin/busy.svg +%%DATADIR%%/skin/delete.png +%%DATADIR%%/skin/directsms.png +%%DATADIR%%/skin/edit.png +%%DATADIR%%/skin/emotion.png +%%DATADIR%%/skin/exit.png +%%DATADIR%%/skin/face_images/1.gif +%%DATADIR%%/skin/face_images/10.gif +%%DATADIR%%/skin/face_images/11.gif +%%DATADIR%%/skin/face_images/12.gif +%%DATADIR%%/skin/face_images/13.gif +%%DATADIR%%/skin/face_images/14.gif +%%DATADIR%%/skin/face_images/15.gif +%%DATADIR%%/skin/face_images/16.gif +%%DATADIR%%/skin/face_images/17.gif +%%DATADIR%%/skin/face_images/18.gif +%%DATADIR%%/skin/face_images/19.gif +%%DATADIR%%/skin/face_images/2.gif +%%DATADIR%%/skin/face_images/20.gif +%%DATADIR%%/skin/face_images/21.gif +%%DATADIR%%/skin/face_images/22.gif +%%DATADIR%%/skin/face_images/23.gif +%%DATADIR%%/skin/face_images/24.gif +%%DATADIR%%/skin/face_images/25.gif +%%DATADIR%%/skin/face_images/26.gif +%%DATADIR%%/skin/face_images/27.gif +%%DATADIR%%/skin/face_images/28.gif +%%DATADIR%%/skin/face_images/29.gif +%%DATADIR%%/skin/face_images/3.gif +%%DATADIR%%/skin/face_images/30.gif +%%DATADIR%%/skin/face_images/31.gif +%%DATADIR%%/skin/face_images/32.gif +%%DATADIR%%/skin/face_images/33.gif +%%DATADIR%%/skin/face_images/34.gif +%%DATADIR%%/skin/face_images/35.gif +%%DATADIR%%/skin/face_images/36.gif +%%DATADIR%%/skin/face_images/37.gif +%%DATADIR%%/skin/face_images/38.gif +%%DATADIR%%/skin/face_images/39.gif +%%DATADIR%%/skin/face_images/4.gif +%%DATADIR%%/skin/face_images/40.gif +%%DATADIR%%/skin/face_images/41.gif +%%DATADIR%%/skin/face_images/42.gif +%%DATADIR%%/skin/face_images/43.gif +%%DATADIR%%/skin/face_images/44.gif +%%DATADIR%%/skin/face_images/45.gif +%%DATADIR%%/skin/face_images/46.gif +%%DATADIR%%/skin/face_images/47.gif +%%DATADIR%%/skin/face_images/48.gif +%%DATADIR%%/skin/face_images/49.gif +%%DATADIR%%/skin/face_images/5.gif +%%DATADIR%%/skin/face_images/50.gif +%%DATADIR%%/skin/face_images/51.gif +%%DATADIR%%/skin/face_images/52.gif +%%DATADIR%%/skin/face_images/6.gif +%%DATADIR%%/skin/face_images/7.gif +%%DATADIR%%/skin/face_images/8.gif +%%DATADIR%%/skin/face_images/9.gif +%%DATADIR%%/skin/face_images/big_1.gif +%%DATADIR%%/skin/face_images/big_10.gif +%%DATADIR%%/skin/face_images/big_11.gif +%%DATADIR%%/skin/face_images/big_12.gif +%%DATADIR%%/skin/face_images/big_13.gif +%%DATADIR%%/skin/face_images/big_14.gif +%%DATADIR%%/skin/face_images/big_15.gif +%%DATADIR%%/skin/face_images/big_16.gif +%%DATADIR%%/skin/face_images/big_17.gif +%%DATADIR%%/skin/face_images/big_18.gif +%%DATADIR%%/skin/face_images/big_19.gif +%%DATADIR%%/skin/face_images/big_2.gif +%%DATADIR%%/skin/face_images/big_20.gif +%%DATADIR%%/skin/face_images/big_21.gif +%%DATADIR%%/skin/face_images/big_22.gif +%%DATADIR%%/skin/face_images/big_23.gif +%%DATADIR%%/skin/face_images/big_24.gif +%%DATADIR%%/skin/face_images/big_25.gif +%%DATADIR%%/skin/face_images/big_26.gif +%%DATADIR%%/skin/face_images/big_27.gif +%%DATADIR%%/skin/face_images/big_28.gif +%%DATADIR%%/skin/face_images/big_29.gif +%%DATADIR%%/skin/face_images/big_3.gif +%%DATADIR%%/skin/face_images/big_30.gif +%%DATADIR%%/skin/face_images/big_31.gif +%%DATADIR%%/skin/face_images/big_32.gif +%%DATADIR%%/skin/face_images/big_33.gif +%%DATADIR%%/skin/face_images/big_34.gif +%%DATADIR%%/skin/face_images/big_35.gif +%%DATADIR%%/skin/face_images/big_36.gif +%%DATADIR%%/skin/face_images/big_37.gif +%%DATADIR%%/skin/face_images/big_38.gif +%%DATADIR%%/skin/face_images/big_39.gif +%%DATADIR%%/skin/face_images/big_4.gif +%%DATADIR%%/skin/face_images/big_40.gif +%%DATADIR%%/skin/face_images/big_41.gif +%%DATADIR%%/skin/face_images/big_42.gif +%%DATADIR%%/skin/face_images/big_43.gif +%%DATADIR%%/skin/face_images/big_44.gif +%%DATADIR%%/skin/face_images/big_45.gif +%%DATADIR%%/skin/face_images/big_46.gif +%%DATADIR%%/skin/face_images/big_47.gif +%%DATADIR%%/skin/face_images/big_48.gif +%%DATADIR%%/skin/face_images/big_49.gif +%%DATADIR%%/skin/face_images/big_5.gif +%%DATADIR%%/skin/face_images/big_50.gif +%%DATADIR%%/skin/face_images/big_51.gif +%%DATADIR%%/skin/face_images/big_52.gif +%%DATADIR%%/skin/face_images/big_6.gif +%%DATADIR%%/skin/face_images/big_7.gif +%%DATADIR%%/skin/face_images/big_8.gif +%%DATADIR%%/skin/face_images/big_9.gif +%%DATADIR%%/skin/fetion.svg +%%DATADIR%%/skin/find.png +%%DATADIR%%/skin/groupsend.png +%%DATADIR%%/skin/hilight.png +%%DATADIR%%/skin/history.png +%%DATADIR%%/skin/home.png +%%DATADIR%%/skin/invisible.svg +%%DATADIR%%/skin/login.png +%%DATADIR%%/skin/logining.gif +%%DATADIR%%/skin/move.png +%%DATADIR%%/skin/myselfsms.png +%%DATADIR%%/skin/nudge.png +%%DATADIR%%/skin/offline.svg +%%DATADIR%%/skin/online.svg +%%DATADIR%%/skin/openfetion.png +%%DATADIR%%/skin/options.png +%%DATADIR%%/skin/pggroup.png +%%DATADIR%%/skin/phone.png +%%DATADIR%%/skin/portrait.png +%%DATADIR%%/skin/profile.png +%%DATADIR%%/skin/proxy.png +%%DATADIR%%/skin/reconnecting.gif +%%DATADIR%%/skin/refresh.png +%%DATADIR%%/skin/warning.svg +@exec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true +@unexec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true +@dirrm %%DATADIR%%/skin/face_images +@dirrm %%DATADIR%%/skin +@dirrm %%DATADIR%%/resource +@dirrm %%DATADIR%% +@dirrmtry share/applications |