diff --git a/.gitattributes b/.gitattributes index 6d91af9c8..f51bf96b4 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,5 +1,6 @@ # files/directories excluded from tarballs -.git* export-ignore -debian export-ignore -weechat.spec export-ignore +.git* export-ignore +debian export-ignore +weechat.spec export-ignore +weechat.cygport.in export-ignore diff --git a/.gitignore b/.gitignore index e0e5754e9..dce638474 100644 --- a/.gitignore +++ b/.gitignore @@ -43,6 +43,7 @@ POTFILES remove-potcdate.sed Rules-quot weechat.pc +weechat-*.cygport *stamp stamp* diff --git a/CMakeLists.txt b/CMakeLists.txt index 0913f9ff4..64f6bb7a1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -142,6 +142,9 @@ SET(includedir "\${prefix}/include") CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/weechat.pc.in ${CMAKE_CURRENT_BINARY_DIR}/weechat.pc @ONLY) INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/weechat.pc DESTINATION ${LIBDIR}/../pkgconfig) +# cygport file (used to build Cygwin packages) +CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/weechat.cygport.in ${CMAKE_CURRENT_BINARY_DIR}/weechat-${VERSION}-1.cygport @ONLY) + # icon INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/weechat.png DESTINATION ${SHAREDIR}/icons/hicolor/32x32/apps) diff --git a/Makefile.am b/Makefile.am index 03f499942..612fa2132 100644 --- a/Makefile.am +++ b/Makefile.am @@ -55,7 +55,8 @@ EXTRA_DIST = CMakeLists.txt \ po/CMakeLists.txt \ po/srcfiles.cmake \ weechat.png \ - weechat.pc.in + weechat.pc.in \ + weechat.cygport.in ACLOCAL_AMFLAGS = -I m4 diff --git a/configure.ac b/configure.ac index c044b2a8b..9befa8654 100644 --- a/configure.ac +++ b/configure.ac @@ -39,6 +39,7 @@ AM_PROG_LIBTOOL # Files to generate AC_CONFIG_FILES([weechat.pc]) +AC_CONFIG_FILES([weechat-${VERSION}-1.cygport:weechat.cygport.in]) # Add some flags for some OS case "$host_os" in diff --git a/weechat.cygport.in b/weechat.cygport.in new file mode 100644 index 000000000..94d4aabf6 --- /dev/null +++ b/weechat.cygport.in @@ -0,0 +1,160 @@ +# +# Copyright (C) 2013 Sebastien Helleu +# +# This file is part of WeeChat, the extensible chat client. +# +# WeeChat is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# WeeChat is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with WeeChat. If not, see . +# + +# +# This file is used to build Cygwin packages using the "cygport" command. +# +# It must be used *ONLY* for a stable release (version "X.Y.Z"), not for +# a development version (version "X.Y.Z-dev" or "X.Y.Z-rcN"). +# +# Instructions: execute these commands inside your build directory, +# after running cmake or configure script (replace X.Y.Z by WeeChat version): +# +# $ cygport weechat-X.Y.Z-1.cygport fetch +# $ cygport weechat-X.Y.Z-1.cygport almostall +# +# ==> packages are built in directory ./weechat-X.Y.Z-1/dist/weechat/ +# + +inherit cmake + +NAME="weechat" +VERSION=@VERSION@ +RELEASE=1 + +# Default category (some packages have extra category) +CATEGORY="Net" + +HOMEPAGE="http://weechat.org/" +SRC_URI="http://weechat.org/files/src/weechat-${VERSION}.tar.bz2" + +# Build dependencies only +DEPEND="asciidoc cmake docbook-xml-simple11 docbook-xsl gettext gnutls-devel \ +libaspell-devel libcurl-devel libgcrypt-devel libncursesw-devel lua perl \ +python ruby source-highlight tcl zlib-devel" + +# +# CMake compilation of WeeChat: +# 1. set prefix to /usr +# 2. enable build of man pages and documentation +# 3. disable Guile plugin because WeeChat requires Guile >= 2.0, +# which is not yet available in Cygwin +# +CYGCMAKE_ARGS="-DPREFIX=/usr -DENABLE_MAN=ON -DENABLE_DOC=ON \ +-DENABLE_GUILE=OFF" + +# +# Build 8 Cygwin packages: +# weechat +# weechat-python +# weechat-perl +# weechat-ruby +# weechat-lua +# weechat-tcl +# weechat-devel +# weechat-doc +# +PKG_NAMES="${PN} ${PN}-python ${PN}-perl ${PN}-ruby ${PN}-lua ${PN}-tcl \ +${PN}-devel ${PN}-doc" +PKG_HINTS="setup python perl ruby lua tcl devel doc" + +# +# Package "weechat": binary, all plugins except scripting languages, +# translations, icon, man pages +# +weechat_SUMMARY="Fast, light and extensible chat client (IRC/XMPP)" +weechat_DESCRIPTION="WeeChat (Wee Enhanced Environment for Chat) is a fast, \ +light and extensible chat client (IRC/XMPP). Everything can be done with a \ +keyboard, it is customizable and extensible with scripts." +weechat_CONTENTS=" + usr/bin/ + usr/lib/weechat/plugins/alias.dll + usr/lib/weechat/plugins/aspell.dll + usr/lib/weechat/plugins/charset.dll + usr/lib/weechat/plugins/fifo.dll + usr/lib/weechat/plugins/irc.dll + usr/lib/weechat/plugins/logger.dll + usr/lib/weechat/plugins/relay.dll + usr/lib/weechat/plugins/rmodifier.dll + usr/lib/weechat/plugins/script.dll + usr/lib/weechat/plugins/xfer.dll + usr/share/locale/ + usr/share/icons/ + usr/share/man/ + usr/share/doc/weechat/AUTHORS + usr/share/doc/weechat/ChangeLog + usr/share/doc/weechat/COPYING + usr/share/doc/weechat/NEWS + usr/share/doc/weechat/README +" +weechat_REQUIRES="libaspell15 libcurl4 libgcrypt11 libgnutls28 libncursesw10 zlib0" + +# +# Package "weechat-python": python scripting plugin +# +weechat_python_SUMMARY="Python scripting plugin for WeeChat" +weechat_python_DESCRIPTION="Python scripting plugin for WeeChat" +weechat_python_CONTENTS="usr/lib/weechat/plugins/python.dll" +weechat_python_REQUIRES="python weechat" + +# +# Package "weechat-perl": perl scripting plugin +# +weechat_perl_SUMMARY="Perl scripting plugin for WeeChat" +weechat_perl_DESCRIPTION="Perl scripting plugin for WeeChat" +weechat_perl_CONTENTS="usr/lib/weechat/plugins/perl.dll" +weechat_perl_REQUIRES="perl weechat" + +# +# Package "weechat-ruby": ruby scripting plugin +# +weechat_ruby_SUMMARY="Ruby scripting plugin for WeeChat" +weechat_ruby_DESCRIPTION="Ruby scripting plugin for WeeChat" +weechat_ruby_CONTENTS="usr/lib/weechat/plugins/ruby.dll" +weechat_ruby_REQUIRES="ruby weechat" + +# +# Package "weechat-lua": lua scripting plugin +# +weechat_lua_SUMMARY="Lua scripting plugin for WeeChat" +weechat_lua_DESCRIPTION="Lua scripting plugin for WeeChat" +weechat_lua_CONTENTS="usr/lib/weechat/plugins/lua.dll" +weechat_lua_REQUIRES="lua weechat" + +# +# Package "weechat-tcl": tcl scripting plugin +# +weechat_tcl_SUMMARY="Tcl scripting plugin for WeeChat" +weechat_tcl_DESCRIPTION="Tcl scripting plugin for WeeChat" +weechat_tcl_CONTENTS="usr/lib/weechat/plugins/tcl.dll" +weechat_tcl_REQUIRES="tcl weechat" + +# +# Package "weechat-devel": header to build plugins +# +weechat_devel_CATEGORY="Net Devel" +weechat_devel_SUMMARY="Development files to build WeeChat plugins" +weechat_devel_CONTENTS="usr/include/ usr/lib/pkgconfig/" + +# +# Package "weechat-doc": documentation +# +weechat_doc_CATEGORY="Net Doc" +weechat_doc_SUMMARY="Documentation for WeeChat" +weechat_doc_CONTENTS="usr/share/doc/weechat/*.html"