(file) Return to tog-pegasus.spec CVS log (file) (dir) Up to [Pegasus] / pegasus / rpm

  1 a.dunfey 1.76.2.1 #//%2006////////////////////////////////////////////////////////////////////////
  2                   #//
  3                   #// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
  4                   #// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
  5                   #// Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
  6                   #// IBM Corp.; EMC Corporation, The Open Group.
  7                   #// Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
  8                   #// IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
  9                   #// Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 10                   #// EMC Corporation; VERITAS Software Corporation; The Open Group.
 11                   #// Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 12                   #// EMC Corporation; Symantec Corporation; The Open Group.
 13                   #//
 14                   #// Permission is hereby granted, free of charge, to any person obtaining a copy
 15                   #// of this software and associated documentation files (the "Software"), to
 16                   #// deal in the Software without restriction, including without limitation the
 17                   #// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
 18                   #// sell copies of the Software, and to permit persons to whom the Software is
 19                   #// furnished to do so, subject to the following conditions:
 20                   #// 
 21                   #// THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
 22 a.dunfey 1.76.2.1 #// ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
 23                   #// "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
 24                   #// LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
 25                   #// PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
 26                   #// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 27                   #// ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 28                   #// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 29                   #//
 30                   #//==============================================================================
 31 w.otsuka 1.1      #%/////////////////////////////////////////////////////////////////////////////
 32                   #
 33                   # tog-pegasus.spec
 34                   #
 35 denise.eckstein 1.32     #%/////////////////////////////////////////////////////////////////////////////
 36                          
 37                          #
 38                          # WARNING: This file is automatically generated by executing 
 39                          #   make -f pegasus/Makefile.Release create_OpenPegasusRPMSpecFile
 40 denise.eckstein 1.74     # Any changes made directly to this file in the OpenPegasus source will
 41                          # be lost the next time this file is regenerated and submitted to CVS.
 42 w.otsuka        1.1      #
 43 denise.eckstein 1.32     
 44 denise.eckstein 1.74     Version: 2.5RC1
 45 w.otsuka        1.68     Release: 1%{?LINUX_VERSION:.%{LINUX_VERSION}}
 46 w.otsuka        1.56     Epoch:   1
 47 denise.eckstein 1.32     
 48                          # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
 49 denise.eckstein 1.74     #
 50 w.otsuka        1.56     %{?!PEGASUS_BUILD_TEST_RPM:   %define PEGASUS_BUILD_TEST_RPM        0}
 51 denise.eckstein 1.74     # do "rpmbuild --define 'PEGASUS_BUILD_TEST_RPM 1'" to build test RPM.
 52                          #
 53                          %{?!AUTOSTART:   %define AUTOSTART        0}
 54                          # Use "rpm -[iU]vh --define 'AUTOSTART 1'" in order to have cimserver enabled
 55                          # (chkconfig --level=345 tog-pegasus on) after installation.
 56                          #
 57                          
 58 w.otsuka        1.75     %define srcRelease 1
 59 denise.eckstein 1.74     Summary:   OpenPegasus WBEM Services for Linux
 60                          Name:      tog-pegasus
 61                          Group:     Systems Management/Base
 62                          License:   Open Group Pegasus Open Source
 63                          BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
 64                          URL:       http://www.openpegasus.org
 65                          
 66 denise.eckstein 1.76     Source:    %{name}-%{version}-%{srcRelease}.tar.gz
 67 denise.eckstein 1.74     
 68                          BuildRequires:      bash, sed, grep, coreutils, procps, gcc, gcc-c++
 69                          BuildRequires:      libstdc++, make, pam-devel
 70                          BuildRequires:      openssl-devel >= 0.9.6, e2fsprogs
 71                          Requires:           bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 72                          #Requires:          krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 73                          Requires:           e2fsprogs, bind-utils, net-tools
 74                          Requires(post):     bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 75                          #Requires(post):    krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 76                          Requires(post):     e2fsprogs, bind-utils, net-tools
 77                          Requires(pre):      bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 78                          #Requires(pre):     krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 79                          Requires(pre):      e2fsprogs, bind-utils, net-tools
 80                          Requires(postun):   bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 81                          #Requires(postun):  krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 82                          Requires(postun):   e2fsprogs, bind-utils, net-tools
 83                          
 84 w.otsuka        1.73     Conflicts: openwbem
 85 denise.eckstein 1.32     Provides: tog-pegasus-cimserver
 86 w.otsuka        1.64     BuildConflicts: tog-pegasus
 87 w.otsuka        1.1      
 88                          %description
 89 w.otsuka        1.9      OpenPegasus WBEM Services for Linux enables management solutions that deliver
 90 w.otsuka        1.1      increased control of enterprise resources. WBEM is a platform and resource
 91                          independent DMTF standard that defines a common information model and
 92                          communication protocol for monitoring and controlling resources from diverse
 93                          sources.
 94 denise.eckstein 1.74     #
 95 denise.eckstein 1.32     # End of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
 96 w.otsuka        1.1      
 97 denise.eckstein 1.74     # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
 98                          #
 99 w.otsuka        1.54     %ifarch ia64
100 denise.eckstein 1.32     %global PEGASUS_HARDWARE_PLATFORM LINUX_IA64_GNU
101 w.otsuka        1.1      %else
102 w.otsuka        1.54     %ifarch x86_64
103                          %global PEGASUS_HARDWARE_PLATFORM LINUX_X86_64_GNU
104                          %else
105 w.otsuka        1.24     %ifarch ppc
106 denise.eckstein 1.32     %global PEGASUS_HARDWARE_PLATFORM LINUX_PPC_GNU
107 w.otsuka        1.24     %else
108 denise.eckstein 1.44     %ifarch ppc64 pseries
109 denise.eckstein 1.32     %global PEGASUS_HARDWARE_PLATFORM LINUX_PPC64_GNU
110 w.otsuka        1.24     %else
111                          %ifarch s390
112 denise.eckstein 1.32     %global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES_GNU
113 w.otsuka        1.24     %else
114                          %ifarch s390x zseries
115 denise.eckstein 1.32     %global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES64_GNU
116 w.otsuka        1.24     %else
117 denise.eckstein 1.32     %global PEGASUS_HARDWARE_PLATFORM LINUX_IX86_GNU
118 denise.eckstein 1.74     %endif 
119                          %endif 
120                          %endif 
121                          %endif 
122 w.otsuka        1.1      %endif
123 w.otsuka        1.24     %endif
124 denise.eckstein 1.74     #
125                          # End of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
126 w.otsuka        1.55     
127 a.dunfey        1.76.2.1 %global PEGASUS_ARCH_LIB %{_lib}
128 a.dunfey        1.76.2.2 %global OPENSSL_HOME /usr
129 a.dunfey        1.76.2.1 %global OPENSSL_BIN /usr/bin
130                          %global PEGASUS_PEM_DIR /etc/Pegasus
131                          %global PEGASUS_SSL_CERT_FILE server.pem
132                          %global PEGASUS_SSL_KEY_FILE file.pem
133                          %global PEGASUS_SSL_TRUSTSTORE client.pem
134                          %global PAM_CONFIG_DIR /etc/pam.d
135                          %global PEGASUS_CONFIG_DIR /etc/Pegasus
136                          %global PEGASUS_VARDATA_DIR /var/lib/Pegasus
137                          %global PEGASUS_VARDATA_CACHE_DIR /var/lib/Pegasus/cache
138                          %global PEGASUS_LOCAL_DOMAIN_SOCKET_PATH  /var/run/tog-pegasus/socket/cimxml.socket
139                          %global PEGASUS_CIMSERVER_START_FILE /var/run/tog-pegasus/cimserver.pid
140                          %global CIMSERVER_LOCK_FILE /var/run/tog-pegasus/cimserver_start.lock
141                          %global PEGASUS_REPOSITORY_DIR /var/lib/Pegasus/repository
142                          %global PEGASUS_PREV_REPOSITORY_DIR_NAME prev_repository
143                          %global PEGASUS_REPOSITORY_PARENT_DIR /var/lib/Pegasus
144                          %global PEGASUS_PREV_REPOSITORY_DIR /var/lib/Pegasus/prev_repository
145                          %global PEGASUS_SBIN_DIR /usr/sbin
146                          %global PEGASUS_DOC_DIR /usr/share/doc/tog-pegasus-2.5
147                          
148                          %global PEGASUS_RPM_ROOT  $RPM_BUILD_DIR/$RPM_PACKAGE_NAME-$RPM_PACKAGE_VERSION
149                          %global PEGASUS_RPM_HOME $RPM_BUILD_ROOT/build/tog-pegasus
150 a.dunfey        1.76.2.1 %global PEGASUS_INSTALL_LOG /var/lib/Pegasus/log/install.log
151                          
152 denise.eckstein 1.32     # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
153 denise.eckstein 1.74     #
154 w.otsuka        1.69     %package devel
155 denise.eckstein 1.32     Summary: The OpenPegasus Software Development Kit
156                          Group: Systems Management/Base
157                          Requires: tog-pegasus >= %{version}
158 w.otsuka        1.69     Obsoletes: tog-pegasus-sdk
159 w.otsuka        1.1      
160 w.otsuka        1.69     %description devel
161 denise.eckstein 1.74     The OpenPegasus WBEM Services for Linux SDK is the developer's kit for the
162                          OpenPegasus WBEM Services for Linux release. It provides Linux C++ developers
163                          with the WBEM files required to build WBEM Clients and Providers. It also
164                          supports C provider developers via the CMPI interface.
165 w.otsuka        1.1      
166 w.otsuka        1.56     %if %{PEGASUS_BUILD_TEST_RPM}
167 denise.eckstein 1.32     %package test
168                          Summary: The OpenPegasus Tests
169                          Group: Systems Management/Base
170                          Requires: tog-pegasus >= %{version} 
171 w.otsuka        1.1      
172 denise.eckstein 1.32     %description test
173                          The OpenPegasus WBEM tests for the OpenPegasus %{version} Linux rpm.
174 w.otsuka        1.56     %endif
175 denise.eckstein 1.74     #
176                          #End of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
177 w.otsuka        1.1      
178 denise.eckstein 1.32     %prep
179 denise.eckstein 1.74     %setup -q -n %{name}-%{version}
180 w.otsuka        1.28     
181 denise.eckstein 1.32     %build
182                          # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
183 denise.eckstein 1.74     #
184 denise.eckstein 1.32     export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
185                          export PEGASUS_HOME=%PEGASUS_RPM_HOME
186                          export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
187 denise.eckstein 1.74     export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
188 denise.eckstein 1.32     export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
189 w.otsuka        1.1      
190 denise.eckstein 1.32     export OPENSSL_HOME=%OPENSSL_HOME
191                          export OPENSSL_BIN=%OPENSSL_BIN
192                          export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
193                          export PATH=$PEGASUS_HOME/bin:$PATH
194 w.otsuka        1.1      
195 denise.eckstein 1.74     export PEGASUS_EXTRA_C_FLAGS="$RPM_OPT_FLAGS -g"
196 denise.eckstein 1.32     export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS"
197 denise.eckstein 1.74     export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS"
198                          #export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS -g -pie -Wl,-z,relro,-z,now,-z,nodlopen,-z,noexecstack"
199 w.otsuka        1.1      
200 denise.eckstein 1.32     make -f $PEGASUS_ROOT/Makefile.Release create_ProductVersionFile
201 denise.eckstein 1.76     make -f $PEGASUS_ROOT/Makefile.Release create_CommonProductDirectoriesInclude
202                          make -f $PEGASUS_ROOT/Makefile.Release create_ConfigProductDirectoriesInclude
203 denise.eckstein 1.32     make -f $PEGASUS_ROOT/Makefile.Release all
204                          make -f $PEGASUS_ROOT/Makefile.Release repository
205 denise.eckstein 1.74     #
206 denise.eckstein 1.32     # End of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
207 w.otsuka        1.27     
208 denise.eckstein 1.32     %install
209                          # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
210 denise.eckstein 1.74     #
211 denise.eckstein 1.32     export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
212                          export PEGASUS_HOME=%PEGASUS_RPM_HOME
213                          export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
214 denise.eckstein 1.74     export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
215 denise.eckstein 1.32     export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
216 w.otsuka        1.1      
217 denise.eckstein 1.32     export OPENSSL_BIN=%OPENSSL_BIN
218                          export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
219                          export PATH=$PEGASUS_HOME/bin:$PATH
220 w.otsuka        1.1      
221 denise.eckstein 1.32     export PEGASUS_STAGING_DIR=$RPM_BUILD_ROOT
222 w.otsuka        1.1      
223 w.otsuka        1.56     %if %{PEGASUS_BUILD_TEST_RPM}
224 denise.eckstein 1.74     make -f $PEGASUS_ROOT/Makefile.Release stage \
225                              PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR \
226                              PEGASUS_BUILD_TEST_RPM=%{PEGASUS_BUILD_TEST_RPM}
227 w.otsuka        1.56     %else
228 denise.eckstein 1.74     make -f $PEGASUS_ROOT/Makefile.Release stage \
229                              PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR
230 w.otsuka        1.56     %endif
231 denise.eckstein 1.74     
232                          [ "$PEGASUS_HOME" != "/" ] && [ -d $PEGASUS_HOME ] && rm -rf $PEGASUS_HOME;
233                          #
234 denise.eckstein 1.32     # End of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
235 w.otsuka        1.1      
236 denise.eckstein 1.32     %clean
237                          # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
238 denise.eckstein 1.74     #
239 a.dunfey        1.76.2.1 [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT;
240                          [ "${RPM_BUILD_DIR}" != "/" ] && rm -rf ${RPM_BUILD_DIR}/%{name}-%{version};
241 denise.eckstein 1.74     #
242 denise.eckstein 1.32     # End of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
243 w.otsuka        1.1      
244                          %pre
245 denise.eckstein 1.74     # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
246                          #           install   remove   upgrade  reinstall
247                          # pre          1        -         2         2
248                          #
249                          # If it exists, the active OpenPegasus Repository
250                          #    directory, %PEGASUS_REPOSITORY_DIR is renamed
251                          #    to %PEGASUS_PREV_REPOSITORY_DIR.  If
252                          #    %PEGASUS_PREV_REPOSITORY_DIR already exists,
253                          #    it is saved as an archive file.
254 denise.eckstein 1.32     
255 denise.eckstein 1.74     if [ -d %PEGASUS_REPOSITORY_DIR"/root#PG_Internal" ]; then
256                             #
257                             # Save the current repository to prev_repository
258                             #
259                             if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
260                                  /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
261                                      %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
262                                      %PEGASUS_PREV_REPOSITORY_DIR_NAME
263                                  rm -rf %PEGASUS_PREV_REPOSITORY_DIR
264                             fi
265                             /bin/mv %PEGASUS_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR
266                          fi
267 a.dunfey        1.76.2.1 if [ $1 -gt 0 ]; then
268 denise.eckstein 1.74        #  Create the 'pegasus' user and group:
269                             /usr/sbin/groupadd pegasus > /dev/null 2>&1 || :;
270                             /usr/sbin/useradd -c "tog-pegasus OpenPegasus WBEM/CIM services" \
271                                  -g pegasus -s /sbin/nologin -r -d %PEGASUS_VARDATA_DIR pegasus \
272                                   > /dev/null 2>&1 || :;
273 w.otsuka        1.1      fi
274 denise.eckstein 1.74     #
275 denise.eckstein 1.32     # End of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
276 w.otsuka        1.1      
277                          %post
278 w.otsuka        1.24     if [ $1 -eq 1 ]; then
279 denise.eckstein 1.35        echo `date` > %PEGASUS_INSTALL_LOG 2>&1
280 denise.eckstein 1.76        %define PEGASUS_CONFIG_DIR /etc/Pegasus
281                             %define PEGASUS_PEM_DIR /etc/Pegasus
282 denise.eckstein 1.32        %define PEGASUS_SSL_CERT_FILE server.pem
283                             %define PEGASUS_SSL_KEY_FILE file.pem
284                             %define PEGASUS_SSL_TRUSTSTORE client.pem
285                          
286                             # Create Symbolic Links for SDK Libraries
287                             #
288 a.dunfey        1.76.2.1    ln -sf libpegclient.so.1 /usr/%PEGASUS_ARCH_LIB/libpegclient.so
289                             ln -sf libpegcommon.so.1 /usr/%PEGASUS_ARCH_LIB/libpegcommon.so
290                             ln -sf libpegprovider.so.1 /usr/%PEGASUS_ARCH_LIB/libpegprovider.so
291                             ln -sf libDefaultProviderManager.so.1 /usr/%PEGASUS_ARCH_LIB/libDefaultProviderManager.so
292                             ln -sf libCIMxmlIndicationHandler.so.1 /usr/%PEGASUS_ARCH_LIB/libCIMxmlIndicationHandler.so
293                             ln -sf libCMPIProviderManager.so.1 /usr/%PEGASUS_ARCH_LIB/libCMPIProviderManager.so
294 denise.eckstein 1.32     
295                             # Create Symbolic Links for Packaged Provider Libraries
296                             #
297 a.dunfey        1.76.2.1    ln -sf libComputerSystemProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libComputerSystemProvider.so
298                             ln -sf libOSProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libOSProvider.so
299                             ln -sf libProcessProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libProcessProvider.so
300 denise.eckstein 1.32     
301                          
302                          # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
303 denise.eckstein 1.74     #
304                          #           install   remove   upgrade  reinstall
305                          # %post        1        -         2         2
306                          #
307 a.dunfey        1.76.2.1    export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
308                          
309 denise.eckstein 1.74        if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
310                                 # Running Repository Upgrade utility
311                                 %PEGASUS_SBIN_DIR/repupgrade %PEGASUS_PREV_REPOSITORY_DIR \
312                                     %PEGASUS_REPOSITORY_DIR 2>>%PEGASUS_INSTALL_LOG
313                                 /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
314                                     %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
315                                     %PEGASUS_PREV_REPOSITORY_DIR_NAME
316                                 rm -rf %PEGASUS_PREV_REPOSITORY_DIR
317 denise.eckstein 1.32        fi
318 denise.eckstein 1.74        if [ $1 -eq 1 ]; then
319                          %if %{AUTOSTART}
320                                 /sbin/chkconfig --add tog-pegasus
321                          %endif
322                             :;
323                             elif [ $1 -gt 0 ]; then
324 a.dunfey        1.76.2.1        /etc/init.d/tog-pegasus condrestart
325 denise.eckstein 1.74        :;
326 denise.eckstein 1.32        fi
327 denise.eckstein 1.74     #
328 denise.eckstein 1.32     # End of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
329 w.otsuka        1.1      
330 w.otsuka        1.57     elif [ $1 -gt 1 ]; then
331 denise.eckstein 1.74        if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
332 w.otsuka        1.71          # Running Repository Upgrade utility
333                               %PEGASUS_SBIN_DIR/repupgrade 2>>%PEGASUS_INSTALL_LOG
334                             fi
335 a.dunfey        1.76.2.1    /etc/init.d/tog-pegasus condrestart
336 denise.eckstein 1.74        :;
337 w.otsuka        1.24     fi
338 denise.eckstein 1.74     
339 w.otsuka        1.1      %preun
340 denise.eckstein 1.74     # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
341                          #           install   remove   upgrade  reinstall
342                          #  preun       -        0         1         -
343 w.otsuka        1.24     if [ $1 -eq 0 ]; then
344 denise.eckstein 1.32        # Check if the cimserver is running
345 denise.eckstein 1.74        isRunning=`ps -el | grep cimserver |  grep -v "grep cimserver"`
346 denise.eckstein 1.32        if [ "$isRunning" ]; then
347 denise.eckstein 1.74           %PEGASUS_SBIN_DIR/cimserver -s
348                             fi 
349                             /sbin/chkconfig --del tog-pegasus;
350                             rm -f %PEGASUS_VARDATA_DIR/cimserver_current.conf;
351                             rm -f %PEGASUS_INSTALL_LOG;
352                             [ -d %PEGASUS_REPOSITORY_DIR ]  && rm -rf %PEGASUS_REPOSITORY_DIR;
353                             [ -d %PEGASUS_VARDATA_CACHE_DIR ]  && rm -rf %PEGASUS_VARDATA_CACHE_DIR;
354                             rm -f %PEGASUS_LOCAL_DOMAIN_SOCKET_PATH;
355                             rm -f %PEGASUS_CIMSERVER_START_FILE;
356 a.dunfey        1.76.2.1    rm -f %CIMSERVER_LOCK_FILE;
357 w.otsuka        1.24     fi
358 denise.eckstein 1.74     #
359                          # End of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
360 w.otsuka        1.1      
361 w.otsuka        1.69     %preun devel
362 denise.eckstein 1.76     make --directory /usr/share/Pegasus/samples -s clean
363 denise.eckstein 1.44     
364 w.otsuka        1.56     %if %{PEGASUS_BUILD_TEST_RPM}
365 denise.eckstein 1.46     %preun test
366 denise.eckstein 1.76     make --directory /usr/share/Pegasus/test -s unsetupTEST
367                          [ -d /var/lib/Pegasus/testrepository ] &&  rm -rf /var/lib/Pegasus/testrepository;
368 denise.eckstein 1.46     
369 w.otsuka        1.56     %endif
370 w.otsuka        1.1      %postun
371 w.otsuka        1.24     if [ $1 -eq 0 ]; then
372 denise.eckstein 1.32        export LC_ALL=C
373 w.otsuka        1.1      fi
374 denise.eckstein 1.74     # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
375                          #
376                          #           install   remove   upgrade  reinstall
377                          #  postun      -        0         1         -
378                          if [ $1 -eq 0 ]; then
379                             /usr/sbin/userdel pegasus > /dev/null 2>&1 || :;
380 a.dunfey        1.76.2.1    /usr/sbin/groupdel pegasus > /dev/null 2>&1 || :;
381 denise.eckstein 1.74     fi;
382                          #
383                          # End of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
384 w.otsuka        1.1      
385                          %files
386 denise.eckstein 1.76     %defattr(600, root, pegasus, 755)
387                          %dir /usr/share/doc/tog-pegasus-2.5
388                          %dir /usr/share/Pegasus
389                          %dir /usr/share/Pegasus/scripts
390                          %dir /usr/share/Pegasus/mof
391                          %dir /usr/share/Pegasus/mof/CIM29
392                          %dir /usr/share/Pegasus/mof/Pegasus
393                          %dir /var/lib/Pegasus
394                          %dir /var/lib/Pegasus/cache
395                          %dir /var/lib/Pegasus/log
396                          %dir /var/lib/Pegasus/cache/localauth
397 denise.eckstein 1.74     %dir /var/run/tog-pegasus
398 a.dunfey        1.76.2.1 %dir /usr/%PEGASUS_ARCH_LIB/Pegasus 
399                          %dir /usr/%PEGASUS_ARCH_LIB/Pegasus/providers 
400 denise.eckstein 1.74     
401 denise.eckstein 1.76     %dir %attr(750, root, pegasus) /etc/Pegasus
402 denise.eckstein 1.74     %dir %attr(1555,root,pegasus) /var/run/tog-pegasus/socket
403 denise.eckstein 1.76     %dir %attr(1777,root,pegasus) /var/lib/Pegasus/cache/trace
404 denise.eckstein 1.74     
405 denise.eckstein 1.76     %dir %attr(750, root, pegasus) /var/lib/Pegasus/repository
406                          /var/lib/Pegasus/repository/*
407                          /usr/share/Pegasus/mof/CIM29/*
408                          /usr/share/Pegasus/mof/Pegasus/*
409 denise.eckstein 1.74     
410                          %config %attr(750,root,pegasus) /etc/init.d/tog-pegasus
411 denise.eckstein 1.76     %config(noreplace) /var/lib/Pegasus/cimserver_planned.conf
412                          %config(noreplace) /etc/Pegasus/access.conf
413 denise.eckstein 1.74     %config(noreplace) /etc/pam.d/wbem
414                          
415 denise.eckstein 1.76     %ghost %config(noreplace) /etc/Pegasus/ssl.cnf
416                          %ghost %config(noreplace) /etc/Pegasus/client.pem
417                          %ghost %config(noreplace) /etc/Pegasus/server.pem
418                          %ghost %config(noreplace) /etc/Pegasus/file.pem
419                          %ghost /var/lib/Pegasus/log/install.log
420                          
421                          %attr(750,root,pegasus) /usr/sbin/*
422                          %attr(755,root,pegasus) /usr/bin/*
423 a.dunfey        1.76.2.1 %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/*.so.1
424                          %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/*.so.1
425 denise.eckstein 1.76     %attr(750,root,pegasus) /usr/share/Pegasus/scripts/*
426                          %attr(644,root,pegasus) /usr/share/man/man1/*
427                          %attr(640,root,pegasus) /usr/share/man/man8/*
428                          
429                          %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.5/Admin_Guide_Release.pdf
430                          %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.5/PegasusSSLGuidelines.htm
431                          %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.5/license.txt
432 a.dunfey        1.76.2.1 /usr/%PEGASUS_ARCH_LIB/libpegclient.so
433                          /usr/%PEGASUS_ARCH_LIB/libpegcommon.so
434                          /usr/%PEGASUS_ARCH_LIB/libpegprovider.so
435                          /usr/%PEGASUS_ARCH_LIB/libDefaultProviderManager.so
436                          /usr/%PEGASUS_ARCH_LIB/libCIMxmlIndicationHandler.so
437                          /usr/%PEGASUS_ARCH_LIB/libCMPIProviderManager.so
438                          /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libComputerSystemProvider.so
439                          /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libOSProvider.so
440                          /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libProcessProvider.so
441 w.otsuka        1.1      
442 w.otsuka        1.69     %files devel
443 denise.eckstein 1.76     %defattr(644,root,pegasus,755)
444 a.dunfey        1.76.2.1 /usr/include/Pegasus
445 denise.eckstein 1.76     /usr/share/Pegasus/samples
446                          /usr/share/doc/tog-pegasus-2.5/*
447                          /usr/share/Pegasus/html
448 a.dunfey        1.76.2.1 %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/*.so
449 w.otsuka        1.28     
450 w.otsuka        1.56     %if %{PEGASUS_BUILD_TEST_RPM}
451 w.otsuka        1.28     %files test
452 denise.eckstein 1.74     %defattr(-,root,pegasus,-)
453 denise.eckstein 1.76     /usr/share/Pegasus/test
454                          /var/lib/Pegasus/testrepository
455 w.otsuka        1.56     %endif

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2