Package cfengine: Specfile
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 | %define unstable 0 %define workdir %_localstatedir/cfengine Name: cfengine Version: 3.1.1 Release: alt3.3 Group: System/Base Summary: Atomation framework for system administration or IT Management. License: %gpl3only Url: http://www.cfengine.org Packager: Andriy Stepanov <stanv@altlinux.ru> Source0: %name-%version.tar Source2: cf-monitord Source3: cf-execd Source4: cf-serverd Source5: users_managment.cf Patch1: cfengine-3-alt-config.patch Patch2: cfengine-3-alt-build.patch Patch3: cfengine-3.1.1-alt-DSO.patch BuildRequires: flex libacl-devel libssl-devel glibc-devel-static libdb4-devel libgraphviz-devel libmysqlclient-devel libpcre-devel BuildRequires: rpm-build-licenses %description Cfengine was designed to enable scalable configuration management, for the whole system life-cycle, in any kind of environment. Today it is the most advanced automation framework, supporting all common platforms, and designed with security in mind, from the ground up. %prep %setup -q -n %name-%version %patch1 %patch2 -p1 %patch3 -p0 %build %if %unstable %define optflags_debug -g %define _optlevel 0 %add_optflags %optflags_debug %def_enable debug %endif export CFLAGS="%optflags" %configure \ %{subst_enable debug} \ --with-workdir=%workdir \ --with-graphviz sed -ri 's/^(hardcode_libdir_flag_spec|runpath_var)=.*/\1=/' libtool export LD_LIBRARY_PATH=$PWD/src/.libs %make_build %install %make install DESTDIR=%buildroot # Install service scripts install -m 755 -d "%buildroot/%_initdir" install -m 744 %{S:2} %{S:3} %{S:4} "%buildroot/%_initdir" # Install own modules as examples install -m 755 -d "%buildroot/%_defaultdocdir/%name" install -m 644 %{S:5} "%buildroot/%_defaultdocdir/%name" %preun # Turn off and unregister services. %preun_service cf-monitord %preun_service cf-execd %preun_service cf-serverd %post # Register services at first installation. # Restart services at package updates. %post_service cf-monitord %post_service cf-execd %post_service cf-serverd ################################## # Follow fault tolerance design. # ################################## ## # Placing CFengine inputs (default configuration) in the workdir. # Configuration files updates for new CFengine version must be done manually. # if ! [ -d "%workdir/inputs" ]; then echo "Copy standard promises to CFengine workdir..." install -m 755 -d "%workdir/inputs" find "%_defaultdocdir/%name/inputs" -type f -exec install -m 600 '{}' "%workdir/inputs" ';' if [ -x "%_sbindir/cf-agent" -a -f "%workdir/inputs/failsafe.cf" ]; then echo "Bootstrap a cfengine configuration from failsafe file in the workdir..." "%_sbindir/cf-agent" --bootstrap fi fi %files %doc AUTHORS ChangeLog README COPYING docs/ContributorStatement.pdf %_libdir/lib* %_sbindir/* %_man8dir/* %_defaultdocdir/%name %_initdir/* %changelog * Tue Jul 17 2012 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 3.1.1-alt3.3 - Fixed build * Thu Feb 02 2012 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 3.1.1-alt3.2 - Removed bad RPATH * Sun Sep 25 2011 Michael Shigorin <mike@altlinux.org> 3.1.1-alt3.1 - NMU: rebuilt with current graphviz * Mon Apr 18 2011 Vitaly Kuznetsov <vitty@altlinux.ru> 3.1.1-alt3 - fix build * Fri Dec 03 2010 Andriy Stepanov <stanv@altlinux.ru> 3.1.1-alt2 - Rebuild with user managment module. * Wed Dec 01 2010 Andriy Stepanov <stanv@altlinux.ru> 3.1.1-alt1 - New version. Build static version instead shared. Add service files. * Thu Nov 25 2010 Andriy Stepanov <stanv@altlinux.ru> 3.1.0-alt2 - Put binaries and inputs to CFengine workdir * Sat Nov 13 2010 Andriy Stepanov <stanv@altlinux.ru> 3.1.0-alt1 - Build for ALTLinux |