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

  1 karl  1.84 #//%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 karl  1.84 #// 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 dave.sudlik     1.91 Version: 2.7.0
 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 yi.zhou         1.93 #
 68                      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
 69 denise.eckstein 1.74 
 70 yi.zhou         1.93 # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-buildRequires.spec
 71                      #
 72 denise.eckstein 1.74 BuildRequires:      bash, sed, grep, coreutils, procps, gcc, gcc-c++
 73                      BuildRequires:      libstdc++, make, pam-devel
 74                      BuildRequires:      openssl-devel >= 0.9.6, e2fsprogs
 75 yi.zhou         1.93 BuildRequires:      net-snmp-devel
 76                      #
 77                      # End of section  pegasus/rpm/tog-specfiles/tog-pegasus-buildRequires.spec
 78                      
 79                      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-requires.spec
 80                      #
 81 denise.eckstein 1.74 Requires:           bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 82                      #Requires:          krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 83                      Requires:           e2fsprogs, bind-utils, net-tools
 84                      Requires(post):     bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 85                      #Requires(post):    krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 86                      Requires(post):     e2fsprogs, bind-utils, net-tools
 87                      Requires(pre):      bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 88                      #Requires(pre):     krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 89                      Requires(pre):      e2fsprogs, bind-utils, net-tools
 90                      Requires(postun):   bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 91                      #Requires(postun):  krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 92                      Requires(postun):   e2fsprogs, bind-utils, net-tools
 93 yi.zhou         1.93 Requires:           net-snmp
 94                      #
 95                      # End of section  pegasus/rpm/tog-specfiles/tog-pegasus-requires.spec
 96 denise.eckstein 1.74 
 97 yi.zhou         1.93 # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-desc.spec
 98                      #
 99 w.otsuka        1.73 Conflicts: openwbem
100 denise.eckstein 1.32 Provides: tog-pegasus-cimserver
101 w.otsuka        1.64 BuildConflicts: tog-pegasus
102 w.otsuka        1.1  
103                      %description
104 w.otsuka        1.9  OpenPegasus WBEM Services for Linux enables management solutions that deliver
105 w.otsuka        1.1  increased control of enterprise resources. WBEM is a platform and resource
106                      independent DMTF standard that defines a common information model and
107                      communication protocol for monitoring and controlling resources from diverse
108                      sources.
109 denise.eckstein 1.74 #
110 yi.zhou         1.93 # End of section pegasus/rpm/tog-specfiles/tog-pegasus-desc.spec
111 w.otsuka        1.1  
112 denise.eckstein 1.74 # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
113                      #
114 w.otsuka        1.54 %ifarch ia64
115 denise.eckstein 1.32 %global PEGASUS_HARDWARE_PLATFORM LINUX_IA64_GNU
116 w.otsuka        1.1  %else
117 w.otsuka        1.54 %ifarch x86_64
118                      %global PEGASUS_HARDWARE_PLATFORM LINUX_X86_64_GNU
119                      %else
120 w.otsuka        1.24 %ifarch ppc
121 denise.eckstein 1.32 %global PEGASUS_HARDWARE_PLATFORM LINUX_PPC_GNU
122 w.otsuka        1.24 %else
123 denise.eckstein 1.44 %ifarch ppc64 pseries
124 denise.eckstein 1.32 %global PEGASUS_HARDWARE_PLATFORM LINUX_PPC64_GNU
125 w.otsuka        1.24 %else
126                      %ifarch s390
127 denise.eckstein 1.32 %global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES_GNU
128 w.otsuka        1.24 %else
129                      %ifarch s390x zseries
130 denise.eckstein 1.32 %global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES64_GNU
131 w.otsuka        1.24 %else
132 denise.eckstein 1.32 %global PEGASUS_HARDWARE_PLATFORM LINUX_IX86_GNU
133 denise.eckstein 1.74 %endif 
134                      %endif 
135                      %endif 
136                      %endif 
137 w.otsuka        1.1  %endif
138 w.otsuka        1.24 %endif
139 denise.eckstein 1.74 #
140                      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
141 w.otsuka        1.55 
142 denise.eckstein 1.81 %global PEGASUS_ARCH_LIB %{_lib}
143 w.otsuka        1.86 %global OPENSSL_HOME /usr
144 denise.eckstein 1.81 %global OPENSSL_BIN /usr/bin
145                      %global PEGASUS_PEM_DIR /etc/Pegasus
146                      %global PEGASUS_SSL_CERT_FILE server.pem
147                      %global PEGASUS_SSL_KEY_FILE file.pem
148                      %global PEGASUS_SSL_TRUSTSTORE client.pem
149                      %global PAM_CONFIG_DIR /etc/pam.d
150                      %global PEGASUS_CONFIG_DIR /etc/Pegasus
151                      %global PEGASUS_VARDATA_DIR /var/lib/Pegasus
152                      %global PEGASUS_VARDATA_CACHE_DIR /var/lib/Pegasus/cache
153                      %global PEGASUS_LOCAL_DOMAIN_SOCKET_PATH  /var/run/tog-pegasus/socket/cimxml.socket
154                      %global PEGASUS_CIMSERVER_START_FILE /var/run/tog-pegasus/cimserver.pid
155 kumpf           1.94 %global PEGASUS_CIMSERVER_START_LOCK_FILE /var/run/tog-pegasus/cimserver_start.lock
156 denise.eckstein 1.81 %global PEGASUS_REPOSITORY_DIR /var/lib/Pegasus/repository
157                      %global PEGASUS_PREV_REPOSITORY_DIR_NAME prev_repository
158                      %global PEGASUS_REPOSITORY_PARENT_DIR /var/lib/Pegasus
159                      %global PEGASUS_PREV_REPOSITORY_DIR /var/lib/Pegasus/prev_repository
160                      %global PEGASUS_SBIN_DIR /usr/sbin
161 dave.sudlik     1.91 %global PEGASUS_DOC_DIR /usr/share/doc/tog-pegasus-2.7
162 denise.eckstein 1.81 
163                      %global PEGASUS_RPM_ROOT  $RPM_BUILD_DIR/$RPM_PACKAGE_NAME-$RPM_PACKAGE_VERSION
164                      %global PEGASUS_RPM_HOME $RPM_BUILD_ROOT/build/tog-pegasus
165                      %global PEGASUS_INSTALL_LOG /var/lib/Pegasus/log/install.log
166                      
167 denise.eckstein 1.32 # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
168 denise.eckstein 1.74 #
169 w.otsuka        1.69 %package devel
170 denise.eckstein 1.32 Summary: The OpenPegasus Software Development Kit
171                      Group: Systems Management/Base
172                      Requires: tog-pegasus >= %{version}
173 w.otsuka        1.69 Obsoletes: tog-pegasus-sdk
174 w.otsuka        1.1  
175 w.otsuka        1.69 %description devel
176 denise.eckstein 1.74 The OpenPegasus WBEM Services for Linux SDK is the developer's kit for the
177                      OpenPegasus WBEM Services for Linux release. It provides Linux C++ developers
178                      with the WBEM files required to build WBEM Clients and Providers. It also
179                      supports C provider developers via the CMPI interface.
180 w.otsuka        1.1  
181 w.otsuka        1.56 %if %{PEGASUS_BUILD_TEST_RPM}
182 denise.eckstein 1.32 %package test
183                      Summary: The OpenPegasus Tests
184                      Group: Systems Management/Base
185                      Requires: tog-pegasus >= %{version} 
186 w.otsuka        1.1  
187 denise.eckstein 1.32 %description test
188                      The OpenPegasus WBEM tests for the OpenPegasus %{version} Linux rpm.
189 w.otsuka        1.56 %endif
190 denise.eckstein 1.74 #
191                      #End of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
192 w.otsuka        1.1  
193 denise.eckstein 1.32 %prep
194 denise.eckstein 1.74 %setup -q -n %{name}-%{version}
195 w.otsuka        1.28 
196 denise.eckstein 1.32 %build
197                      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
198 denise.eckstein 1.74 #
199 denise.eckstein 1.32 export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
200                      export PEGASUS_HOME=%PEGASUS_RPM_HOME
201                      export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
202 denise.eckstein 1.74 export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
203 denise.eckstein 1.32 export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
204 w.otsuka        1.1  
205 denise.eckstein 1.32 export OPENSSL_HOME=%OPENSSL_HOME
206                      export OPENSSL_BIN=%OPENSSL_BIN
207                      export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
208                      export PATH=$PEGASUS_HOME/bin:$PATH
209 w.otsuka        1.1  
210 denise.eckstein 1.74 export PEGASUS_EXTRA_C_FLAGS="$RPM_OPT_FLAGS -g"
211 denise.eckstein 1.32 export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS"
212 denise.eckstein 1.74 export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS"
213                      #export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS -g -pie -Wl,-z,relro,-z,now,-z,nodlopen,-z,noexecstack"
214 w.otsuka        1.1  
215 w.otsuka        1.87 %if %{PEGASUS_BUILD_TEST_RPM}
216                      export PEGASUS_DISPLAYCONSUMER_DIR=%PEGASUS_VARDATA_DIR/log
217                      %endif
218                      
219 denise.eckstein 1.32 make -f $PEGASUS_ROOT/Makefile.Release create_ProductVersionFile
220 denise.eckstein 1.76 make -f $PEGASUS_ROOT/Makefile.Release create_CommonProductDirectoriesInclude
221                      make -f $PEGASUS_ROOT/Makefile.Release create_ConfigProductDirectoriesInclude
222 w.otsuka        1.92 make %{?_smp_mflags} -f $PEGASUS_ROOT/Makefile.Release all
223 denise.eckstein 1.32 make -f $PEGASUS_ROOT/Makefile.Release repository
224 denise.eckstein 1.74 #
225 denise.eckstein 1.32 # End of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
226 w.otsuka        1.27 
227 denise.eckstein 1.32 %install
228                      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
229 denise.eckstein 1.74 #
230 denise.eckstein 1.32 export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
231                      export PEGASUS_HOME=%PEGASUS_RPM_HOME
232                      export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
233 denise.eckstein 1.74 export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
234 denise.eckstein 1.32 export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
235 w.otsuka        1.1  
236 denise.eckstein 1.32 export OPENSSL_BIN=%OPENSSL_BIN
237                      export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
238                      export PATH=$PEGASUS_HOME/bin:$PATH
239 w.otsuka        1.1  
240 denise.eckstein 1.32 export PEGASUS_STAGING_DIR=$RPM_BUILD_ROOT
241 w.otsuka        1.1  
242 w.otsuka        1.56 %if %{PEGASUS_BUILD_TEST_RPM}
243 denise.eckstein 1.74 make -f $PEGASUS_ROOT/Makefile.Release stage \
244                          PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR \
245                          PEGASUS_BUILD_TEST_RPM=%{PEGASUS_BUILD_TEST_RPM}
246 w.otsuka        1.56 %else
247 denise.eckstein 1.74 make -f $PEGASUS_ROOT/Makefile.Release stage \
248                          PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR
249 w.otsuka        1.56 %endif
250 denise.eckstein 1.74 
251                      [ "$PEGASUS_HOME" != "/" ] && [ -d $PEGASUS_HOME ] && rm -rf $PEGASUS_HOME;
252                      #
253 denise.eckstein 1.32 # End of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
254 w.otsuka        1.1  
255 denise.eckstein 1.32 %clean
256                      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
257 denise.eckstein 1.74 #
258 w.otsuka        1.77 [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT;
259                      [ "${RPM_BUILD_DIR}" != "/" ] && rm -rf ${RPM_BUILD_DIR}/%{name}-%{version};
260 denise.eckstein 1.74 #
261 denise.eckstein 1.32 # End of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
262 w.otsuka        1.1  
263                      %pre
264 denise.eckstein 1.74 # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
265                      #           install   remove   upgrade  reinstall
266                      # pre          1        -         2         2
267                      #
268                      # If it exists, the active OpenPegasus Repository
269                      #    directory, %PEGASUS_REPOSITORY_DIR is renamed
270                      #    to %PEGASUS_PREV_REPOSITORY_DIR.  If
271                      #    %PEGASUS_PREV_REPOSITORY_DIR already exists,
272                      #    it is saved as an archive file.
273 denise.eckstein 1.32 
274 denise.eckstein 1.74 if [ -d %PEGASUS_REPOSITORY_DIR"/root#PG_Internal" ]; then
275                         #
276                         # Save the current repository to prev_repository
277                         #
278                         if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
279                              /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
280                                  %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
281                                  %PEGASUS_PREV_REPOSITORY_DIR_NAME
282                              rm -rf %PEGASUS_PREV_REPOSITORY_DIR
283                         fi
284                         /bin/mv %PEGASUS_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR
285                      fi
286 w.otsuka        1.82 if [ $1 -gt 0 ]; then
287 denise.eckstein 1.74    #  Create the 'pegasus' user and group:
288                         /usr/sbin/groupadd pegasus > /dev/null 2>&1 || :;
289                         /usr/sbin/useradd -c "tog-pegasus OpenPegasus WBEM/CIM services" \
290                              -g pegasus -s /sbin/nologin -r -d %PEGASUS_VARDATA_DIR pegasus \
291                               > /dev/null 2>&1 || :;
292 w.otsuka        1.1  fi
293 denise.eckstein 1.74 #
294 denise.eckstein 1.32 # End of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
295 w.otsuka        1.1  
296                      %post
297 w.otsuka        1.24 if [ $1 -eq 1 ]; then
298 denise.eckstein 1.35    echo `date` > %PEGASUS_INSTALL_LOG 2>&1
299 denise.eckstein 1.76    %define PEGASUS_CONFIG_DIR /etc/Pegasus
300                         %define PEGASUS_PEM_DIR /etc/Pegasus
301 denise.eckstein 1.32    %define PEGASUS_SSL_CERT_FILE server.pem
302                         %define PEGASUS_SSL_KEY_FILE file.pem
303                         %define PEGASUS_SSL_TRUSTSTORE client.pem
304                      
305                         # Create Symbolic Links for SDK Libraries
306                         #
307 denise.eckstein 1.81    ln -sf libpegclient.so.1 /usr/%PEGASUS_ARCH_LIB/libpegclient.so
308                         ln -sf libpegcommon.so.1 /usr/%PEGASUS_ARCH_LIB/libpegcommon.so
309                         ln -sf libpegprovider.so.1 /usr/%PEGASUS_ARCH_LIB/libpegprovider.so
310                         ln -sf libDefaultProviderManager.so.1 /usr/%PEGASUS_ARCH_LIB/libDefaultProviderManager.so
311                         ln -sf libCIMxmlIndicationHandler.so.1 /usr/%PEGASUS_ARCH_LIB/libCIMxmlIndicationHandler.so
312                         ln -sf libCMPIProviderManager.so.1 /usr/%PEGASUS_ARCH_LIB/libCMPIProviderManager.so
313 yi.zhou         1.93    ln -sf libsnmpIndicationHandler.so.1 /usr/%PEGASUS_ARCH_LIB/libsnmpIndicationHandler.so
314 denise.eckstein 1.32 
315                         # Create Symbolic Links for Packaged Provider Libraries
316                         #
317 denise.eckstein 1.81    ln -sf libComputerSystemProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libComputerSystemProvider.so
318                         ln -sf libOSProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libOSProvider.so
319                         ln -sf libProcessProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libProcessProvider.so
320 denise.eckstein 1.32 
321                      
322                      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
323 denise.eckstein 1.74 #
324                      #           install   remove   upgrade  reinstall
325                      # %post        1        -         2         2
326                      #
327 denise.eckstein 1.81    export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
328                      
329 denise.eckstein 1.74    if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
330                             # Running Repository Upgrade utility
331                             %PEGASUS_SBIN_DIR/repupgrade %PEGASUS_PREV_REPOSITORY_DIR \
332                                 %PEGASUS_REPOSITORY_DIR 2>>%PEGASUS_INSTALL_LOG
333                             /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
334                                 %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
335                                 %PEGASUS_PREV_REPOSITORY_DIR_NAME
336                             rm -rf %PEGASUS_PREV_REPOSITORY_DIR
337 denise.eckstein 1.32    fi
338 denise.eckstein 1.74    if [ $1 -eq 1 ]; then
339                      %if %{AUTOSTART}
340                             /sbin/chkconfig --add tog-pegasus
341                      %endif
342                         :;
343                         elif [ $1 -gt 0 ]; then
344 w.otsuka        1.79        /etc/init.d/tog-pegasus condrestart
345 denise.eckstein 1.74    :;
346 denise.eckstein 1.32    fi
347 denise.eckstein 1.74 #
348 denise.eckstein 1.32 # End of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
349 w.otsuka        1.1  
350 w.otsuka        1.57 elif [ $1 -gt 1 ]; then
351 denise.eckstein 1.74    if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
352 w.otsuka        1.71      # Running Repository Upgrade utility
353                           %PEGASUS_SBIN_DIR/repupgrade 2>>%PEGASUS_INSTALL_LOG
354                         fi
355 w.otsuka        1.79    /etc/init.d/tog-pegasus condrestart
356 denise.eckstein 1.74    :;
357 w.otsuka        1.24 fi
358 denise.eckstein 1.74 
359 w.otsuka        1.1  %preun
360 denise.eckstein 1.74 # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
361                      #           install   remove   upgrade  reinstall
362                      #  preun       -        0         1         -
363 w.otsuka        1.24 if [ $1 -eq 0 ]; then
364 denise.eckstein 1.32    # Check if the cimserver is running
365 denise.eckstein 1.74    isRunning=`ps -el | grep cimserver |  grep -v "grep cimserver"`
366 denise.eckstein 1.32    if [ "$isRunning" ]; then
367 denise.eckstein 1.74       %PEGASUS_SBIN_DIR/cimserver -s
368                         fi 
369                         /sbin/chkconfig --del tog-pegasus;
370                         rm -f %PEGASUS_VARDATA_DIR/cimserver_current.conf;
371                         rm -f %PEGASUS_INSTALL_LOG;
372                         [ -d %PEGASUS_REPOSITORY_DIR ]  && rm -rf %PEGASUS_REPOSITORY_DIR;
373                         [ -d %PEGASUS_VARDATA_CACHE_DIR ]  && rm -rf %PEGASUS_VARDATA_CACHE_DIR;
374                         rm -f %PEGASUS_LOCAL_DOMAIN_SOCKET_PATH;
375                         rm -f %PEGASUS_CIMSERVER_START_FILE;
376 kumpf           1.94    rm -f %PEGASUS_CIMSERVER_START_LOCK_FILE;
377 w.otsuka        1.24 fi
378 denise.eckstein 1.74 #
379                      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
380 w.otsuka        1.1  
381 w.otsuka        1.69 %preun devel
382 denise.eckstein 1.76 make --directory /usr/share/Pegasus/samples -s clean
383 denise.eckstein 1.44 
384 w.otsuka        1.56 %if %{PEGASUS_BUILD_TEST_RPM}
385 denise.eckstein 1.46 %preun test
386 denise.eckstein 1.76 make --directory /usr/share/Pegasus/test -s unsetupTEST
387                      [ -d /var/lib/Pegasus/testrepository ] &&  rm -rf /var/lib/Pegasus/testrepository;
388 denise.eckstein 1.46 
389 w.otsuka        1.56 %endif
390 w.otsuka        1.1  %postun
391 w.otsuka        1.24 if [ $1 -eq 0 ]; then
392 denise.eckstein 1.32    export LC_ALL=C
393 w.otsuka        1.1  fi
394 denise.eckstein 1.74 # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
395                      #
396                      #           install   remove   upgrade  reinstall
397                      #  postun      -        0         1         -
398                      if [ $1 -eq 0 ]; then
399                         /usr/sbin/userdel pegasus > /dev/null 2>&1 || :;
400 w.otsuka        1.78    /usr/sbin/groupdel pegasus > /dev/null 2>&1 || :;
401 denise.eckstein 1.74 fi;
402                      #
403                      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
404 w.otsuka        1.1  
405                      %files
406 denise.eckstein 1.76 %defattr(600, root, pegasus, 755)
407 dave.sudlik     1.91 %dir /usr/share/doc/tog-pegasus-2.7
408 denise.eckstein 1.76 %dir /usr/share/Pegasus
409                      %dir /usr/share/Pegasus/scripts
410                      %dir /usr/share/Pegasus/mof
411                      %dir /usr/share/Pegasus/mof/CIM29
412                      %dir /usr/share/Pegasus/mof/Pegasus
413                      %dir /var/lib/Pegasus
414                      %dir /var/lib/Pegasus/cache
415                      %dir /var/lib/Pegasus/log
416                      %dir /var/lib/Pegasus/cache/localauth
417 denise.eckstein 1.74 %dir /var/run/tog-pegasus
418 denise.eckstein 1.81 %dir /usr/%PEGASUS_ARCH_LIB/Pegasus 
419                      %dir /usr/%PEGASUS_ARCH_LIB/Pegasus/providers 
420 denise.eckstein 1.74 
421 w.otsuka        1.90 %dir %attr(755, root, pegasus) /etc/Pegasus
422 denise.eckstein 1.74 %dir %attr(1555,root,pegasus) /var/run/tog-pegasus/socket
423 denise.eckstein 1.76 %dir %attr(1777,root,pegasus) /var/lib/Pegasus/cache/trace
424 denise.eckstein 1.74 
425 denise.eckstein 1.76 %dir %attr(750, root, pegasus) /var/lib/Pegasus/repository
426                      /var/lib/Pegasus/repository/*
427                      /usr/share/Pegasus/mof/CIM29/*
428                      /usr/share/Pegasus/mof/Pegasus/*
429 denise.eckstein 1.74 
430                      %config %attr(750,root,pegasus) /etc/init.d/tog-pegasus
431 denise.eckstein 1.76 %config(noreplace) /var/lib/Pegasus/cimserver_planned.conf
432                      %config(noreplace) /etc/Pegasus/access.conf
433 denise.eckstein 1.74 %config(noreplace) /etc/pam.d/wbem
434                      
435 denise.eckstein 1.76 %ghost %config(noreplace) /etc/Pegasus/ssl.cnf
436                      %ghost %config(noreplace) /etc/Pegasus/client.pem
437                      %ghost %config(noreplace) /etc/Pegasus/server.pem
438                      %ghost %config(noreplace) /etc/Pegasus/file.pem
439                      %ghost /var/lib/Pegasus/log/install.log
440                      
441                      %attr(750,root,pegasus) /usr/sbin/*
442                      %attr(755,root,pegasus) /usr/bin/*
443 denise.eckstein 1.81 %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/*.so.1
444                      %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/*.so.1
445 denise.eckstein 1.76 %attr(750,root,pegasus) /usr/share/Pegasus/scripts/*
446                      %attr(644,root,pegasus) /usr/share/man/man1/*
447                      %attr(640,root,pegasus) /usr/share/man/man8/*
448                      
449 dave.sudlik     1.91 %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.7/Admin_Guide_Release.pdf
450                      %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.7/PegasusSSLGuidelines.htm
451                      %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.7/license.txt
452 denise.eckstein 1.81 /usr/%PEGASUS_ARCH_LIB/libpegclient.so
453                      /usr/%PEGASUS_ARCH_LIB/libpegcommon.so
454                      /usr/%PEGASUS_ARCH_LIB/libpegprovider.so
455                      /usr/%PEGASUS_ARCH_LIB/libDefaultProviderManager.so
456                      /usr/%PEGASUS_ARCH_LIB/libCIMxmlIndicationHandler.so
457                      /usr/%PEGASUS_ARCH_LIB/libCMPIProviderManager.so
458 yi.zhou         1.93 /usr/%PEGASUS_ARCH_LIB/libsnmpIndicationHandler.so
459 denise.eckstein 1.81 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libComputerSystemProvider.so
460                      /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libOSProvider.so
461                      /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libProcessProvider.so
462 w.otsuka        1.1  
463 w.otsuka        1.69 %files devel
464 denise.eckstein 1.76 %defattr(644,root,pegasus,755)
465 denise.eckstein 1.89 /usr/share/Pegasus/samples
466                      /usr/share/Pegasus/samples/obj
467                      /usr/share/Pegasus/samples/lib
468                      /usr/share/Pegasus/samples/bin
469 w.otsuka        1.80 /usr/include/Pegasus
470 dave.sudlik     1.91 /usr/share/doc/tog-pegasus-2.7/*
471 denise.eckstein 1.76 /usr/share/Pegasus/html
472 denise.eckstein 1.81 %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/*.so
473 w.otsuka        1.28 
474 w.otsuka        1.56 %if %{PEGASUS_BUILD_TEST_RPM}
475 w.otsuka        1.28 %files test
476 denise.eckstein 1.74 %defattr(-,root,pegasus,-)
477 denise.eckstein 1.76 /usr/share/Pegasus/test
478                      /var/lib/Pegasus/testrepository
479 w.otsuka        1.56 %endif

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2