View | Details | Raw Unified | Return to bug 34122
Collapse All | Expand All

(-)a/zabbix.spec (-7 / +23 lines)
Lines 4-9 Link Here
4
%define svnrev		73588
4
%define svnrev		73588
5
5
6
%def_with pgsql
6
%def_with pgsql
7
%def_enable java
7
8
8
%ifndef _unitdir
9
%ifndef _unitdir
9
%define _unitdir %systemd_unitdir
10
%define _unitdir %systemd_unitdir
Lines 11-17 Link Here
11
12
12
Name: zabbix
13
Name: zabbix
13
Version: 3.4.3
14
Version: 3.4.3
14
Release: alt1
15
Release: alt2
15
16
16
Packager: Alexei Takaseev <taf@altlinux.ru>
17
Packager: Alexei Takaseev <taf@altlinux.ru>
17
18
Lines 27-41 Url: http://www.zabbix.com Link Here
27
Source0: %name-%version.tar
28
Source0: %name-%version.tar
28
Patch0: %name-%version-%release.patch
29
Patch0: %name-%version-%release.patch
29
30
30
BuildPreReq: java-devel-default
31
%{?_enable_java:BuildPreReq: java-devel-default}
31
BuildPreReq: libelf-devel
32
BuildPreReq: libelf-devel
32
BuildRequires(pre): rpm-build-webserver-common
33
BuildRequires(pre): rpm-build-webserver-common
33
34
34
# Automatically added by buildreq on Tue Aug 22 2017 (-bi)
35
# Automatically added by buildreq on Thu Nov 02 2017 (-bi)
36
# optimized out: elfutils glibc-kernheaders-generic glibc-kernheaders-x86 libcom_err-devel libkrb5-devel libnet-snmp30 libp11-kit libpq-devel libsasl2-3 libssl-devel net-snmp-config perl pkg-config python-base python3 rpm-build-python3 xz
37
BuildRequires: libcurl-devel libelf-devel libevent-devel libiksemel-devel libldap-devel libmysqlclient-devel libnet-snmp-devel libopenipmi-devel libpcre-devel libsqlite3-devel libxml2-devel postgresql-devel python3-base
38
35
# optimized out: elfutils glibc-kernheaders-x86 java java-1.8.0-oracle-headless libcom_err-devel libgpg-error libkrb5-devel libnet-snmp30 libp11-kit libpq-devel libsasl2-3 libssl-devel net-snmp-config perl pkg-config python-base python3 python3-base python3-module-javapackages python3-module-lxml python3-module-six rpm-build-python3 xz
39
# optimized out: elfutils glibc-kernheaders-x86 java java-1.8.0-oracle-headless libcom_err-devel libgpg-error libkrb5-devel libnet-snmp30 libp11-kit libpq-devel libsasl2-3 libssl-devel net-snmp-config perl pkg-config python-base python3 python3-base python3-module-javapackages python3-module-lxml python3-module-six rpm-build-python3 xz
36
BuildRequires: glibc-kernheaders-generic java-devel libcurl-devel libelf-devel libevent-devel libiksemel-devel libldap-devel libmysqlclient-devel libnet-snmp-devel libopenipmi-devel libpcre-devel libsqlite3-devel libxml2-devel postgresql-devel rpm-build-java
40
%{?_enable_java:BuildRequires: java-devel rpm-build-java}
37
41
38
BuildRequires: libnet-snmp-devel libopenipmi-devel libsqlite3-devel libxml2-devel perl-Switch
42
BuildRequires: perl-Switch
39
43
40
%if_with pgsql
44
%if_with pgsql
41
BuildRequires: postgresql-devel
45
BuildRequires: postgresql-devel
Lines 268-274 mv src/%{name}_server/%{name}_server src/%{name}_server/%{name}_pgsql Link Here
268
	--enable-proxy \
272
	--enable-proxy \
269
	--enable-ipv6 \
273
	--enable-ipv6 \
270
	--enable-agent \
274
	--enable-agent \
271
	--enable-java \
275
	%{subst_enable java} \
272
	--with-libcurl \
276
	--with-libcurl \
273
	--with-libxml2 \
277
	--with-libxml2 \
274
	--with-net-snmp \
278
	--with-net-snmp \
Lines 343-350 install -pDm0755 sources/%{name}_mysql.init %buildroot%_initdir/%{name}_mysql Link Here
343
install -pDm0644 sources/%{name}_mysql.service %buildroot%_unitdir/%{name}_mysql.service
347
install -pDm0644 sources/%{name}_mysql.service %buildroot%_unitdir/%{name}_mysql.service
344
install -pDm0755 sources/%{name}_proxy.init %buildroot%_initdir/%{name}_proxy
348
install -pDm0755 sources/%{name}_proxy.init %buildroot%_initdir/%{name}_proxy
345
install -pDm0644 sources/%{name}_proxy.service %buildroot%_unitdir/%{name}_proxy.service
349
install -pDm0644 sources/%{name}_proxy.service %buildroot%_unitdir/%{name}_proxy.service
350
%if_enabled java
346
install -pDm0755 sources/%{name}_java_gateway.init %buildroot%_initdir/%{name}_java_gateway
351
install -pDm0755 sources/%{name}_java_gateway.init %buildroot%_initdir/%{name}_java_gateway
347
install -pDm0644 sources/%{name}_java_gateway.service %buildroot%_unitdir/%{name}_java_gateway.service
352
install -pDm0644 sources/%{name}_java_gateway.service %buildroot%_unitdir/%{name}_java_gateway.service
353
%endif
348
354
349
# sudo entry
355
# sudo entry
350
install -pDm0400 sources/%name.sudo %buildroot%_sysconfdir/sudoers.d/%name
356
install -pDm0400 sources/%name.sudo %buildroot%_sysconfdir/sudoers.d/%name
Lines 361-366 mv upgrades/dbpatches-final/dbpatches/2.0/postgresql upgrades-postgresql/2.0 Link Here
361
# include files
367
# include files
362
cp include/* %buildroot%_includedir/%name
368
cp include/* %buildroot%_includedir/%name
363
369
370
%if_enabled java
364
# delete unnecessary files from java gateway
371
# delete unnecessary files from java gateway
365
rm %buildroot%_sbindir/zabbix_java/settings.sh
372
rm %buildroot%_sbindir/zabbix_java/settings.sh
366
rm %buildroot%_sbindir/zabbix_java/startup.sh
373
rm %buildroot%_sbindir/zabbix_java/startup.sh
Lines 377-382 cat src/zabbix_java/settings.sh | sed \ Link Here
377
        -e 's|^PID_FILE=.*|PID_FILE="/var/run/zabbix/zabbix_java.pid"|g' \
384
        -e 's|^PID_FILE=.*|PID_FILE="/var/run/zabbix/zabbix_java.pid"|g' \
378
        -e '/^# TIMEOUT=/a \\nTIMEOUT=3' \
385
        -e '/^# TIMEOUT=/a \\nTIMEOUT=3' \
379
        > %buildroot%_sysconfdir/zabbix/zabbix_java_gateway.conf
386
        > %buildroot%_sysconfdir/zabbix/zabbix_java_gateway.conf
387
%endif
380
388
381
# ChangeLog
389
# ChangeLog
382
bzip2 ChangeLog
390
bzip2 ChangeLog
Lines 402-407 bzip2 ChangeLog Link Here
402
%post proxy
410
%post proxy
403
%post_service zabbix_proxy
411
%post_service zabbix_proxy
404
412
413
%if_enabled java
405
%preun proxy
414
%preun proxy
406
%preun_service zabbix_proxy
415
%preun_service zabbix_proxy
407
%post java-gateway
416
%post java-gateway
Lines 409-414 bzip2 ChangeLog Link Here
409
418
410
%preun java-gateway
419
%preun java-gateway
411
%preun_service zabbix_java_gateway
420
%preun_service zabbix_java_gateway
421
%endif
422
412
%post agent
423
%post agent
413
%post_service zabbix_agentd
424
%post_service zabbix_agentd
414
if [ $1 -eq 1 ]; then
425
if [ $1 -eq 1 ]; then
Lines 458-463 fi Link Here
458
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_proxy.conf
469
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_proxy.conf
459
%_man8dir/%{name}_proxy.*
470
%_man8dir/%{name}_proxy.*
460
471
472
%if_enabled java
461
%files java-gateway
473
%files java-gateway
462
%_sbindir/%{name}_java_gateway
474
%_sbindir/%{name}_java_gateway
463
%_initdir/%{name}_java_gateway
475
%_initdir/%{name}_java_gateway
Lines 465-470 fi Link Here
465
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_java_gateway.conf
477
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_java_gateway.conf
466
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_java_gateway_logback.xml
478
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_java_gateway_logback.xml
467
%_javadir/*
479
%_javadir/*
480
%endif
468
481
469
%files agent
482
%files agent
470
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_agentd.conf
483
%config(noreplace) %attr(0640,root,%zabbix_group) %_sysconfdir/%name/%{name}_agentd.conf
Lines 499-504 fi Link Here
499
%_includedir/%name
512
%_includedir/%name
500
513
501
%changelog
514
%changelog
515
* Thu Nov 02 2017 Michael Shigorin <mike@altlinux.org> 1:3.4.3-alt2
516
- introduce java knob (on by default); see also #33206
517
- buildreq again
518
502
* Thu Oct 19 2017 Alexei Takaseev <taf@altlinux.org> 1:3.4.3-alt1
519
* Thu Oct 19 2017 Alexei Takaseev <taf@altlinux.org> 1:3.4.3-alt1
503
- 3.4.3
520
- 3.4.3
504
521
505
- 

Return to bug 34122