]>
Commit | Line | Data |
---|---|---|
82afe06a MP |
1 | # |
2 | # Conditional build: | |
3 | %bcond_without tests # do not perform "make test" | |
4 | # | |
5 | %include /usr/lib/rpm/macros.perl | |
6 | %define pdir DJabberd | |
7 | Summary: DJabberd - scalable, extensible Jabber/XMPP server. | |
8 | #Summary(pl): | |
9 | Name: DJabberd | |
10 | Version: 0.83 | |
11 | Release: 0.4 | |
12 | # same as perl | |
13 | License: GPL v1+ or Artistic | |
14 | Group: Development/Languages/Perl | |
15 | Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{version}.tar.gz | |
16 | Source1: djabberd.conf | |
17 | Source2: djabberd-log.conf | |
18 | # Source0-md5: ce449b6ef429eb65ec03be4c8d19b1aa | |
19 | BuildRequires: perl-devel >= 1:5.8.0 | |
20 | BuildRequires: rpm-perlprov >= 4.1-13 | |
21 | %if %{with tests} | |
22 | BuildRequires: perl(Danga::Socket) >= 1.51 | |
23 | BuildRequires: perl(Digest::HMAC_SHA1) | |
24 | BuildRequires: perl(Log::Log4perl) | |
25 | BuildRequires: perl(Net::DNS) >= 0.48 | |
26 | BuildRequires: perl(Net::SSLeay) | |
27 | BuildRequires: perl(XML::LibXML::SAX) | |
28 | BuildRequires: perl(XML::SAX) | |
29 | %endif | |
30 | BuildArch: noarch | |
31 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
32 | ||
33 | # this is mentioned in example component | |
34 | %define _noautoreq 'perl(DJabberd::Bot::Eliza)' | |
35 | ||
36 | %description | |
37 | DJabberd was the answer to LiveJournal's Jabber (XMPP) | |
38 | server needs. We needed: | |
39 | ||
40 | Basically we wanted the swiss army knife of Jabber servers (think | |
41 | qpsmtpd or mod_perl), but none existed in any language. While some | |
42 | popular Jabber servers let us do pluggable auth, none let us get our | |
43 | hands into roster storage, vcards, avatars, presence, etc. | |
44 | ||
45 | So we made DJabberd. It's a Jabber server where almost everything | |
46 | defers to hooks to be implemented by plugins. It does the core spec | |
47 | itself (including SSL, StartTLS, server-to-server, etc), but it | |
48 | doesn't come with any way to do authentication or storage or rosters, | |
49 | etc. You'll need to go pick up a plugin to do those. | |
50 | ||
51 | You should be able to plop DJabberd into your existing systems / | |
52 | userbase with minimal pain. Just find a plugin that's close (if a | |
53 | perfect match doesn't already exist!) and tweak. | |
54 | ||
55 | DJabberd is event-based so we can have really low per-connection | |
56 | memory requirements, smaller than is possible with a threaded jabber | |
57 | server. Because of this, all plugins can operate asynchronously, | |
58 | taking as long as they want to finish their work, or to decline to the | |
59 | next handler. (in the meantime, while plugins wait on a response from | |
60 | whatever they're talking to, the DJabberd event loop continues at full | |
61 | speed) However, that's more work, so some plugins may choose to | |
62 | operate synchronously, but they do so with the understanding that | |
63 | those plugins will cause the whole server to get bogged down. If | |
64 | you're running a Jabber server for 5 users, you may not care that the | |
65 | SQLite authentication backend pauses your server for milliseconds at a | |
66 | time, but on a site with hundreds of thousands of connections, that | |
67 | wouldn't be acceptable. Watch out for those plugins. | |
68 | ||
69 | ||
70 | ||
71 | # %description -l pl | |
72 | # TODO | |
73 | ||
74 | %prep | |
75 | %setup -q -n %{pdir}-%{version} | |
76 | ||
77 | %build | |
78 | %{__perl} Makefile.PL \ | |
79 | INSTALLDIRS=vendor | |
80 | %{__make} | |
81 | ||
82 | %{?with_tests:%{__make} test} | |
83 | ||
84 | %install | |
85 | rm -rf $RPM_BUILD_ROOT | |
86 | ||
87 | %{__make} install \ | |
88 | DESTDIR=$RPM_BUILD_ROOT | |
89 | ||
90 | install -d $RPM_BUILD_ROOT%{_sysconfdir}/djabberd | |
91 | install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/djabberd/ | |
92 | install %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/djabberd/log.conf | |
93 | ||
94 | %clean | |
95 | rm -rf $RPM_BUILD_ROOT | |
96 | ||
97 | %files | |
98 | %defattr(644,root,root,755) | |
99 | %doc CHANGES | |
100 | %{perl_vendorlib}/DJabberd.pm | |
101 | %{perl_vendorlib}/DJabberd/ | |
102 | %{_mandir}/man3/* | |
103 | %attr(755,root,root) %{_bindir}/djabberd | |
104 | %dir %{_sysconfdir}/djabberd | |
105 | %config %{_sysconfdir}/djabberd/djabberd.conf | |
106 | %config %{_sysconfdir}/djabberd/log.conf |