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

  1 martin 1.115 #//%LICENSE////////////////////////////////////////////////////////////////
  2 martin 1.116 #//
  3 martin 1.115 #// Licensed to The Open Group (TOG) under one or more contributor license
  4              #// agreements.  Refer to the OpenPegasusNOTICE.txt file distributed with
  5              #// this work for additional information regarding copyright ownership.
  6              #// Each contributor licenses this file to you under the OpenPegasus Open
  7              #// Source License; you may not use this file except in compliance with the
  8              #// License.
  9 martin 1.116 #//
 10 martin 1.115 #// Permission is hereby granted, free of charge, to any person obtaining a
 11              #// copy of this software and associated documentation files (the "Software"),
 12              #// to deal in the Software without restriction, including without limitation
 13              #// the rights to use, copy, modify, merge, publish, distribute, sublicense,
 14              #// and/or sell copies of the Software, and to permit persons to whom the
 15              #// Software is furnished to do so, subject to the following conditions:
 16 martin 1.116 #//
 17 martin 1.115 #// The above copyright notice and this permission notice shall be included
 18              #// in all copies or substantial portions of the Software.
 19 martin 1.116 #//
 20 martin 1.115 #// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 21 martin 1.116 #// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 22 martin 1.115 #// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 23              #// IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
 24              #// CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
 25              #// TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 26              #// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 27 martin 1.116 #//
 28 martin 1.115 #//////////////////////////////////////////////////////////////////////////
 29 w.otsuka 1.1   #%/////////////////////////////////////////////////////////////////////////////
 30                #
 31                # tog-pegasus.spec
 32                #
 33 denise.eckstein 1.32  #%/////////////////////////////////////////////////////////////////////////////
 34                       
 35                       #
 36 kumpf           1.119 # WARNING: This file is automatically generated by executing
 37 denise.eckstein 1.32  #   make -f pegasus/Makefile.Release create_OpenPegasusRPMSpecFile
 38 denise.eckstein 1.74  # Any changes made directly to this file in the OpenPegasus source will
 39                       # be lost the next time this file is regenerated and submitted to CVS.
 40 w.otsuka        1.1   #
 41 denise.eckstein 1.32  
 42 dave.sudlik     1.107 %define packageVersion 1
 43 karl            1.119.2.2 Version: 2.9.2
 44 denise.eckstein 1.102     Release: %{packageVersion}%{?LINUX_VERSION:.%{LINUX_VERSION}}
 45 w.otsuka        1.56      Epoch:   1
 46 denise.eckstein 1.32      
 47                           # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
 48 denise.eckstein 1.74      #
 49 w.otsuka        1.56      %{?!PEGASUS_BUILD_TEST_RPM:   %define PEGASUS_BUILD_TEST_RPM        0}
 50 denise.eckstein 1.74      # do "rpmbuild --define 'PEGASUS_BUILD_TEST_RPM 1'" to build test RPM.
 51                           #
 52                           %{?!AUTOSTART:   %define AUTOSTART        0}
 53                           # Use "rpm -[iU]vh --define 'AUTOSTART 1'" in order to have cimserver enabled
 54                           # (chkconfig --level=345 tog-pegasus on) after installation.
 55                           #
 56                           
 57 s.kodali        1.119.2.3 # Use "rpmbuild --define 'EXTERNAL_SLP_REQUESTED 1'" to include External SLP support.
 58                           %{?!EXTERNAL_SLP_REQUESTED: %define EXTERNAL_SLP_REQUESTED 0}
 59                           
 60 denise.eckstein 1.74      Summary:   OpenPegasus WBEM Services for Linux
 61                           Name:      tog-pegasus
 62                           Group:     Systems Management/Base
 63                           License:   Open Group Pegasus Open Source
 64                           BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
 65                           URL:       http://www.openpegasus.org
 66                           
 67 denise.eckstein 1.102     Source:    %{name}-%{version}-%{packageVersion}.tar.gz
 68 yi.zhou         1.93      #
 69                           # End of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
 70 denise.eckstein 1.74      
 71 yi.zhou         1.93      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-buildRequires.spec
 72                           #
 73 denise.eckstein 1.74      BuildRequires:      bash, sed, grep, coreutils, procps, gcc, gcc-c++
 74                           BuildRequires:      libstdc++, make, pam-devel
 75                           BuildRequires:      openssl-devel >= 0.9.6, e2fsprogs
 76 s.kodali        1.119.2.3 %if %{EXTERNAL_SLP_REQUESTED}
 77                           BuildRequires:      openslp
 78                           Requires:           openslp
 79                           %endif
 80                           
 81 yi.zhou         1.93      BuildRequires:      net-snmp-devel
 82                           #
 83                           # End of section  pegasus/rpm/tog-specfiles/tog-pegasus-buildRequires.spec
 84                           
 85                           # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-requires.spec
 86                           #
 87 denise.eckstein 1.74      Requires:           bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 88                           #Requires:          krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 89                           Requires:           e2fsprogs, bind-utils, net-tools
 90                           Requires(post):     bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 91                           #Requires(post):    krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 92                           Requires(post):     e2fsprogs, bind-utils, net-tools
 93                           Requires(pre):      bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 94                           #Requires(pre):     krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 95                           Requires(pre):      e2fsprogs, bind-utils, net-tools
 96                           Requires(postun):   bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
 97                           #Requires(postun):  krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
 98                           Requires(postun):   e2fsprogs, bind-utils, net-tools
 99 yi.zhou         1.93      Requires:           net-snmp
100                           #
101                           # End of section  pegasus/rpm/tog-specfiles/tog-pegasus-requires.spec
102 denise.eckstein 1.74      
103 yi.zhou         1.93      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-desc.spec
104                           #
105 w.otsuka        1.73      Conflicts: openwbem
106 denise.eckstein 1.32      Provides: tog-pegasus-cimserver
107 w.otsuka        1.64      BuildConflicts: tog-pegasus
108 w.otsuka        1.1       
109                           %description
110 w.otsuka        1.9       OpenPegasus WBEM Services for Linux enables management solutions that deliver
111 w.otsuka        1.1       increased control of enterprise resources. WBEM is a platform and resource
112                           independent DMTF standard that defines a common information model and
113                           communication protocol for monitoring and controlling resources from diverse
114                           sources.
115 denise.eckstein 1.74      #
116 yi.zhou         1.93      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-desc.spec
117 w.otsuka        1.1       
118 denise.eckstein 1.74      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
119                           #
120 w.otsuka        1.54      %ifarch ia64
121 denise.eckstein 1.32      %global PEGASUS_HARDWARE_PLATFORM LINUX_IA64_GNU
122 w.otsuka        1.1       %else
123 w.otsuka        1.54      %ifarch x86_64
124                           %global PEGASUS_HARDWARE_PLATFORM LINUX_X86_64_GNU
125                           %else
126 w.otsuka        1.24      %ifarch ppc
127 denise.eckstein 1.32      %global PEGASUS_HARDWARE_PLATFORM LINUX_PPC_GNU
128 w.otsuka        1.24      %else
129 denise.eckstein 1.44      %ifarch ppc64 pseries
130 denise.eckstein 1.32      %global PEGASUS_HARDWARE_PLATFORM LINUX_PPC64_GNU
131 w.otsuka        1.24      %else
132                           %ifarch s390
133 denise.eckstein 1.32      %global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES_GNU
134 w.otsuka        1.24      %else
135                           %ifarch s390x zseries
136 denise.eckstein 1.32      %global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES64_GNU
137 w.otsuka        1.24      %else
138 denise.eckstein 1.32      %global PEGASUS_HARDWARE_PLATFORM LINUX_IX86_GNU
139 kumpf           1.119     %endif
140                           %endif
141                           %endif
142                           %endif
143 w.otsuka        1.1       %endif
144 w.otsuka        1.24      %endif
145 denise.eckstein 1.74      #
146                           # End of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
147 w.otsuka        1.55      
148 denise.eckstein 1.81      %global PEGASUS_ARCH_LIB %{_lib}
149 w.otsuka        1.86      %global OPENSSL_HOME /usr
150 denise.eckstein 1.81      %global OPENSSL_BIN /usr/bin
151                           %global PEGASUS_PEM_DIR /etc/Pegasus
152                           %global PEGASUS_SSL_CERT_FILE server.pem
153                           %global PEGASUS_SSL_KEY_FILE file.pem
154                           %global PEGASUS_SSL_TRUSTSTORE client.pem
155                           %global PAM_CONFIG_DIR /etc/pam.d
156                           %global PEGASUS_CONFIG_DIR /etc/Pegasus
157                           %global PEGASUS_VARDATA_DIR /var/lib/Pegasus
158                           %global PEGASUS_VARDATA_CACHE_DIR /var/lib/Pegasus/cache
159                           %global PEGASUS_LOCAL_DOMAIN_SOCKET_PATH  /var/run/tog-pegasus/socket/cimxml.socket
160                           %global PEGASUS_CIMSERVER_START_FILE /var/run/tog-pegasus/cimserver.pid
161 yi.zhou         1.98      %global PEGASUS_TRACE_FILE_PATH /var/lib/Pegasus/cache/trace/cimserver.trc
162 kumpf           1.94      %global PEGASUS_CIMSERVER_START_LOCK_FILE /var/run/tog-pegasus/cimserver_start.lock
163 denise.eckstein 1.81      %global PEGASUS_REPOSITORY_DIR /var/lib/Pegasus/repository
164                           %global PEGASUS_PREV_REPOSITORY_DIR_NAME prev_repository
165                           %global PEGASUS_REPOSITORY_PARENT_DIR /var/lib/Pegasus
166                           %global PEGASUS_PREV_REPOSITORY_DIR /var/lib/Pegasus/prev_repository
167                           %global PEGASUS_SBIN_DIR /usr/sbin
168 denise.eckstein 1.113     %global PEGASUS_DOC_DIR /usr/share/doc/tog-pegasus-2.9
169 denise.eckstein 1.81      
170                           %global PEGASUS_RPM_ROOT  $RPM_BUILD_DIR/$RPM_PACKAGE_NAME-$RPM_PACKAGE_VERSION
171 denise.eckstein 1.95      %global PEGASUS_RPM_HOME %PEGASUS_RPM_ROOT/build
172 denise.eckstein 1.81      %global PEGASUS_INSTALL_LOG /var/lib/Pegasus/log/install.log
173                           
174 denise.eckstein 1.32      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
175 denise.eckstein 1.74      #
176 w.otsuka        1.69      %package devel
177 denise.eckstein 1.32      Summary: The OpenPegasus Software Development Kit
178                           Group: Systems Management/Base
179                           Requires: tog-pegasus >= %{version}
180 w.otsuka        1.69      Obsoletes: tog-pegasus-sdk
181 w.otsuka        1.1       
182 w.otsuka        1.69      %description devel
183 denise.eckstein 1.74      The OpenPegasus WBEM Services for Linux SDK is the developer's kit for the
184                           OpenPegasus WBEM Services for Linux release. It provides Linux C++ developers
185                           with the WBEM files required to build WBEM Clients and Providers. It also
186                           supports C provider developers via the CMPI interface.
187 w.otsuka        1.1       
188 w.otsuka        1.56      %if %{PEGASUS_BUILD_TEST_RPM}
189 denise.eckstein 1.32      %package test
190                           Summary: The OpenPegasus Tests
191                           Group: Systems Management/Base
192 kumpf           1.119     Requires: tog-pegasus >= %{version}
193 w.otsuka        1.1       
194 denise.eckstein 1.32      %description test
195                           The OpenPegasus WBEM tests for the OpenPegasus %{version} Linux rpm.
196 w.otsuka        1.56      %endif
197 denise.eckstein 1.74      #
198                           #End of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
199 w.otsuka        1.1       
200 denise.eckstein 1.32      %prep
201 denise.eckstein 1.74      %setup -q -n %{name}-%{version}
202 w.otsuka        1.28      
203 denise.eckstein 1.32      %build
204                           # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
205 denise.eckstein 1.74      #
206 denise.eckstein 1.32      export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
207                           export PEGASUS_HOME=%PEGASUS_RPM_HOME
208                           export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
209 denise.eckstein 1.74      export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
210 denise.eckstein 1.32      export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
211 w.otsuka        1.1       
212 denise.eckstein 1.32      export OPENSSL_HOME=%OPENSSL_HOME
213                           export OPENSSL_BIN=%OPENSSL_BIN
214                           export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
215                           export PATH=$PEGASUS_HOME/bin:$PATH
216 w.otsuka        1.1       
217 denise.eckstein 1.97      export PEGASUS_EXTRA_C_FLAGS="$RPM_OPT_FLAGS -g -Wno-unused"
218 denise.eckstein 1.32      export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS"
219 denise.eckstein 1.74      export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS"
220                           #export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS -g -pie -Wl,-z,relro,-z,now,-z,nodlopen,-z,noexecstack"
221 w.otsuka        1.1       
222 w.otsuka        1.87      %if %{PEGASUS_BUILD_TEST_RPM}
223 yi.zhou         1.111     export PEGASUS_TMP=/usr/share/Pegasus/test/tmp
224                           export PEGASUS_DISPLAYCONSUMER_DIR="$PEGASUS_TMP"
225 w.otsuka        1.87      %endif
226                           
227 s.kodali        1.119.2.3 %if %{EXTERNAL_SLP_REQUESTED}
228                           sed -i 's/PEGASUS_ENABLE_SLP=.*$/PEGASUS_ENABLE_SLP=true/' $PEGASUS_ENVVAR_FILE
229                           %else
230                           sed -i 's/PEGASUS_ENABLE_SLP=.*$/PEGASUS_ENABLE_SLP=false/' $PEGASUS_ENVVAR_FILE
231                           %endif
232                           
233 denise.eckstein 1.32      make -f $PEGASUS_ROOT/Makefile.Release create_ProductVersionFile
234 denise.eckstein 1.76      make -f $PEGASUS_ROOT/Makefile.Release create_CommonProductDirectoriesInclude
235                           make -f $PEGASUS_ROOT/Makefile.Release create_ConfigProductDirectoriesInclude
236 w.otsuka        1.92      make %{?_smp_mflags} -f $PEGASUS_ROOT/Makefile.Release all
237 yi.zhou         1.98      chmod 777 %PEGASUS_RPM_HOME
238 denise.eckstein 1.32      make -f $PEGASUS_ROOT/Makefile.Release repository
239 denise.eckstein 1.74      #
240 denise.eckstein 1.32      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
241 w.otsuka        1.27      
242 denise.eckstein 1.32      %install
243                           # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
244 denise.eckstein 1.74      #
245 denise.eckstein 1.32      export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
246                           export PEGASUS_HOME=%PEGASUS_RPM_HOME
247                           export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
248 denise.eckstein 1.74      export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
249 denise.eckstein 1.32      export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
250 w.otsuka        1.1       
251 denise.eckstein 1.32      export OPENSSL_BIN=%OPENSSL_BIN
252                           export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
253                           export PATH=$PEGASUS_HOME/bin:$PATH
254 w.otsuka        1.1       
255 denise.eckstein 1.32      export PEGASUS_STAGING_DIR=$RPM_BUILD_ROOT
256 w.otsuka        1.1       
257 w.otsuka        1.56      %if %{PEGASUS_BUILD_TEST_RPM}
258 denise.eckstein 1.74      make -f $PEGASUS_ROOT/Makefile.Release stage \
259                               PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR \
260                               PEGASUS_BUILD_TEST_RPM=%{PEGASUS_BUILD_TEST_RPM}
261 w.otsuka        1.56      %else
262 denise.eckstein 1.74      make -f $PEGASUS_ROOT/Makefile.Release stage \
263                               PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR
264 w.otsuka        1.56      %endif
265 denise.eckstein 1.74      
266                           [ "$PEGASUS_HOME" != "/" ] && [ -d $PEGASUS_HOME ] && rm -rf $PEGASUS_HOME;
267                           #
268 denise.eckstein 1.32      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
269 w.otsuka        1.1       
270 denise.eckstein 1.32      %clean
271                           # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
272 denise.eckstein 1.74      #
273 w.otsuka        1.77      [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT;
274                           [ "${RPM_BUILD_DIR}" != "/" ] && rm -rf ${RPM_BUILD_DIR}/%{name}-%{version};
275 denise.eckstein 1.74      #
276 denise.eckstein 1.32      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
277 w.otsuka        1.1       
278                           %pre
279 denise.eckstein 1.74      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
280                           #           install   remove   upgrade  reinstall
281                           # pre          1        -         2         2
282                           #
283                           # If it exists, the active OpenPegasus Repository
284                           #    directory, %PEGASUS_REPOSITORY_DIR is renamed
285                           #    to %PEGASUS_PREV_REPOSITORY_DIR.  If
286                           #    %PEGASUS_PREV_REPOSITORY_DIR already exists,
287                           #    it is saved as an archive file.
288 denise.eckstein 1.32      
289 denise.eckstein 1.74      if [ -d %PEGASUS_REPOSITORY_DIR"/root#PG_Internal" ]; then
290                              #
291                              # Save the current repository to prev_repository
292                              #
293                              if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
294                                   /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
295                                       %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
296                                       %PEGASUS_PREV_REPOSITORY_DIR_NAME
297                                   rm -rf %PEGASUS_PREV_REPOSITORY_DIR
298                              fi
299                              /bin/mv %PEGASUS_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR
300                           fi
301 w.otsuka        1.82      if [ $1 -gt 0 ]; then
302 denise.eckstein 1.74         #  Create the 'pegasus' user and group:
303                              /usr/sbin/groupadd pegasus > /dev/null 2>&1 || :;
304                              /usr/sbin/useradd -c "tog-pegasus OpenPegasus WBEM/CIM services" \
305                                   -g pegasus -s /sbin/nologin -r -d %PEGASUS_VARDATA_DIR pegasus \
306                                    > /dev/null 2>&1 || :;
307 w.otsuka        1.1       fi
308 yi.zhou         1.98      if [ $1 -eq 2 ]; then
309                               rm -f %PEGASUS_LOCAL_DOMAIN_SOCKET_PATH;
310                               rm -f %PEGASUS_CIMSERVER_START_FILE;
311 yi.zhou         1.105         rm -f %PEGASUS_CIMSERVER_START_LOCK_FILE;
312 yi.zhou         1.98      fi
313 denise.eckstein 1.74      #
314 denise.eckstein 1.32      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
315 w.otsuka        1.1       
316 kumpf           1.119     # When Privilege Separation is enabled, create the 'cimsrvr' user and
317 denise.eckstein 1.100     # 'cimsrvr' group which are used as the context of the cimservermain process
318 yi.zhou         1.98      if [ $1 -gt 0 ]; then
319 denise.eckstein 1.100         /usr/sbin/groupadd cimsrvr > /dev/null 2>&1 || :;
320 yi.zhou         1.98          /usr/sbin/useradd -c "tog-pegasus OpenPegasus WBEM/CIM services" \
321 denise.eckstein 1.100             -g cimsrvr -s /sbin/nologin -r -d %PEGASUS_VARDATA_DIR cimsrvr \
322 yi.zhou         1.98              > /dev/null 2>&1 || :;
323                           fi
324                           
325 w.otsuka        1.1       %post
326 w.otsuka        1.24      if [ $1 -eq 1 ]; then
327 denise.eckstein 1.35         echo `date` > %PEGASUS_INSTALL_LOG 2>&1
328 denise.eckstein 1.76         %define PEGASUS_CONFIG_DIR /etc/Pegasus
329                              %define PEGASUS_PEM_DIR /etc/Pegasus
330 denise.eckstein 1.32         %define PEGASUS_SSL_CERT_FILE server.pem
331                              %define PEGASUS_SSL_KEY_FILE file.pem
332                              %define PEGASUS_SSL_TRUSTSTORE client.pem
333                           
334                              # Create Symbolic Links for SDK Libraries
335                              #
336 denise.eckstein 1.81         ln -sf libpegclient.so.1 /usr/%PEGASUS_ARCH_LIB/libpegclient.so
337                              ln -sf libpegcommon.so.1 /usr/%PEGASUS_ARCH_LIB/libpegcommon.so
338                              ln -sf libpegprovider.so.1 /usr/%PEGASUS_ARCH_LIB/libpegprovider.so
339                              ln -sf libDefaultProviderManager.so.1 /usr/%PEGASUS_ARCH_LIB/libDefaultProviderManager.so
340                              ln -sf libCIMxmlIndicationHandler.so.1 /usr/%PEGASUS_ARCH_LIB/libCIMxmlIndicationHandler.so
341 yi.zhou         1.93         ln -sf libsnmpIndicationHandler.so.1 /usr/%PEGASUS_ARCH_LIB/libsnmpIndicationHandler.so
342 denise.eckstein 1.32      
343                              # Create Symbolic Links for Packaged Provider Libraries
344                              #
345 denise.eckstein 1.81         ln -sf libComputerSystemProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libComputerSystemProvider.so
346                              ln -sf libOSProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libOSProvider.so
347                              ln -sf libProcessProvider.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libProcessProvider.so
348 denise.eckstein 1.32      
349 denise.eckstein 1.110        # Create Symbolic Links for Packaged Provider Managers
350                              #
351                              ln -sf libCMPIProviderManager.so.1 /usr/%PEGASUS_ARCH_LIB/Pegasus/providerManagers/libCMPIProviderManager.so
352 s.kodali        1.119.2.3    # Create Symbolic Links for SLP library and SLP Provider
353                              #
354                            %if %{EXTERNAL_SLP_REQUESTED}
355                              ln -sf    libpegslp_client.so.1            /usr/%PEGASUS_ARCH_LIB/libpegslp_client.so
356                              ln -sf    libSLPProvider.so.1            /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libSLPProvider.so
357                            %endif 
358 denise.eckstein 1.110     
359 denise.eckstein 1.32      
360                           # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
361 denise.eckstein 1.74      #
362                           #           install   remove   upgrade  reinstall
363                           # %post        1        -         2         2
364                           #
365 denise.eckstein 1.81         export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
366                           
367 denise.eckstein 1.74         if [ $1 -eq 1 ]; then
368                           %if %{AUTOSTART}
369                                  /sbin/chkconfig --add tog-pegasus
370                           %endif
371                              :;
372                              elif [ $1 -gt 0 ]; then
373 w.otsuka        1.79             /etc/init.d/tog-pegasus condrestart
374 denise.eckstein 1.74         :;
375 denise.eckstein 1.32         fi
376 denise.eckstein 1.74      #
377 denise.eckstein 1.32      # End of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
378 w.otsuka        1.1       
379 w.otsuka        1.57      elif [ $1 -gt 1 ]; then
380 yi.zhou         1.98         # Check if the cimserver is running
381                              isRunning=`ps -el | grep cimserver | grep -v "grep cimserver"`
382                              if [ "$isRunning" ]; then
383                                  /etc/init.d/tog-pegasus stop
384                              fi
385 sushma.fernandes 1.104        if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
386                                   # The old repository was moved to /var/lib/Pegasus/prev_repository. It should now be upgraded to the new repository /var/lib/Pegasus/repository.
387                                   %PEGASUS_SBIN_DIR/repupgrade >> %PEGASUS_INSTALL_LOG 2>&1
388                                   chown -R cimsrvr %PEGASUS_REPOSITORY_DIR
389                                   chgrp -R cimsrvr %PEGASUS_REPOSITORY_DIR
390                               fi
391 yi.zhou          1.98         if [ -f %PEGASUS_TRACE_FILE_PATH ]; then
392                                 /bin/mv %PEGASUS_TRACE_FILE_PATH %PEGASUS_TRACE_FILE_PATH-`date '+%Y-%m-%d-%R'`
393                               fi
394                               if [ "$isRunning" ]; then
395                                   /etc/init.d/tog-pegasus start
396                               fi
397 w.otsuka         1.24      fi
398 denise.eckstein  1.74      
399 w.otsuka         1.1       %preun
400 denise.eckstein  1.74      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
401                            #           install   remove   upgrade  reinstall
402                            #  preun       -        0         1         -
403 w.otsuka         1.24      if [ $1 -eq 0 ]; then
404 denise.eckstein  1.32         # Check if the cimserver is running
405 denise.eckstein  1.74         isRunning=`ps -el | grep cimserver |  grep -v "grep cimserver"`
406 denise.eckstein  1.32         if [ "$isRunning" ]; then
407 denise.eckstein  1.74            %PEGASUS_SBIN_DIR/cimserver -s
408 kumpf            1.119        fi
409 denise.eckstein  1.74         /sbin/chkconfig --del tog-pegasus;
410 s.kodali         1.119.2.4    rm -f %PEGASUS_CONFIG_DIR/cimserver_current.conf;
411 denise.eckstein  1.74         [ -d %PEGASUS_REPOSITORY_DIR ]  && rm -rf %PEGASUS_REPOSITORY_DIR;
412                               [ -d %PEGASUS_VARDATA_CACHE_DIR ]  && rm -rf %PEGASUS_VARDATA_CACHE_DIR;
413                               rm -f %PEGASUS_LOCAL_DOMAIN_SOCKET_PATH;
414                               rm -f %PEGASUS_CIMSERVER_START_FILE;
415 kumpf            1.94         rm -f %PEGASUS_CIMSERVER_START_LOCK_FILE;
416 w.otsuka         1.24      fi
417 denise.eckstein  1.74      #
418                            # End of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
419 w.otsuka         1.1       
420 w.otsuka         1.69      %preun devel
421 yi.zhou          1.106     # Check if the SDK has been setup
422                            if [ -f /usr/share/Pegasus/samples/SDKIsSetup ]; then
423                               make --directory /usr/share/Pegasus/samples -s unsetupSDK
424                               if [ $? != 0 ]; then
425                                  echo "++++++++++++++++++++++++++++++++++++++++++++++" >&2
426                                  echo "ERROR: Failed to deregister sample providers." >&2
427                                  echo "To remove the SDK rpm without deregistering" >&2
428                                  echo "the sample providers, first remove file" >&2
429                                  echo "/usr/share/Pegasus/samples/SDKIsSetup," >&2
430                                  echo "then remove SDK rpm." >&2
431                                  echo "++++++++++++++++++++++++++++++++++++++++++++++" >&2
432                                  exit 1
433                               fi
434                            fi
435 denise.eckstein  1.76      make --directory /usr/share/Pegasus/samples -s clean
436 denise.eckstein  1.44      
437 w.otsuka         1.56      %if %{PEGASUS_BUILD_TEST_RPM}
438 denise.eckstein  1.46      %preun test
439 denise.eckstein  1.76      make --directory /usr/share/Pegasus/test -s unsetupTEST
440                            [ -d /var/lib/Pegasus/testrepository ] &&  rm -rf /var/lib/Pegasus/testrepository;
441 denise.eckstein  1.46      
442 w.otsuka         1.56      %endif
443 w.otsuka         1.1       %postun
444 w.otsuka         1.24      if [ $1 -eq 0 ]; then
445 denise.eckstein  1.32         export LC_ALL=C
446 w.otsuka         1.1       fi
447 denise.eckstein  1.74      # Start of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
448                            #
449                            #           install   remove   upgrade  reinstall
450                            #  postun      -        0         1         -
451                            if [ $1 -eq 0 ]; then
452                               /usr/sbin/userdel pegasus > /dev/null 2>&1 || :;
453 w.otsuka         1.78         /usr/sbin/groupdel pegasus > /dev/null 2>&1 || :;
454 denise.eckstein  1.74      fi;
455                            #
456                            # End of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
457 w.otsuka         1.1       
458 kumpf            1.119     # When Privilege Separation is enabled, delete the 'cimsrvr' user and
459 denise.eckstein  1.100     # 'cimsrvr' group which are used as the context of the cimservermain process
460 yi.zhou          1.98      if [ $1 -eq 0 ]; then
461                                /usr/sbin/userdel cimsrvr > /dev/null 2>&1 || :;
462 denise.eckstein  1.100         /usr/sbin/groupdel cimsrvr > /dev/null 2>&1 || :;
463 yi.zhou          1.98      fi
464                            
465 w.otsuka         1.1       %files
466 denise.eckstein  1.109     %defattr(600,cimsrvr,cimsrvr,700)
467 yi.zhou          1.98      /var/lib/Pegasus/repository
468 denise.eckstein  1.109     
469                            %defattr(644,root,pegasus,755)
470                            /usr/share/Pegasus/mof
471                            
472                            %defattr(600,root,pegasus,755)
473 denise.eckstein  1.113     %dir /usr/share/doc/tog-pegasus-2.9
474 denise.eckstein  1.76      %dir /usr/share/Pegasus
475                            %dir /usr/share/Pegasus/scripts
476                            %dir /var/lib/Pegasus
477                            %dir /var/lib/Pegasus/cache
478                            %dir /var/lib/Pegasus/log
479                            %dir /var/lib/Pegasus/cache/localauth
480 kumpf            1.119     %dir /usr/%PEGASUS_ARCH_LIB/Pegasus
481                            %dir /usr/%PEGASUS_ARCH_LIB/Pegasus/providers
482                            %dir /usr/%PEGASUS_ARCH_LIB/Pegasus/providerManagers
483 denise.eckstein  1.74      
484 denise.eckstein  1.109     %dir %attr(755,root,pegasus) /etc/Pegasus
485                            %dir %attr(755,cimsrvr,cimsrvr) /var/run/tog-pegasus
486 denise.eckstein  1.100     %dir %attr(1755,cimsrvr,cimsrvr) /var/run/tog-pegasus/socket
487 denise.eckstein  1.76      %dir %attr(1777,root,pegasus) /var/lib/Pegasus/cache/trace
488 denise.eckstein  1.74      
489                            %config %attr(750,root,pegasus) /etc/init.d/tog-pegasus
490 s.kodali         1.119.2.4 %config(noreplace) %attr(644,root,root) /etc/Pegasus/cimserver_planned.conf
491 denise.eckstein  1.76      %config(noreplace) /etc/Pegasus/access.conf
492 denise.eckstein  1.74      %config(noreplace) /etc/pam.d/wbem
493                            
494 denise.eckstein  1.76      %ghost %config(noreplace) /etc/Pegasus/ssl.cnf
495                            %ghost %config(noreplace) /etc/Pegasus/client.pem
496                            %ghost %config(noreplace) /etc/Pegasus/server.pem
497                            %ghost %config(noreplace) /etc/Pegasus/file.pem
498                            %ghost /var/lib/Pegasus/log/install.log
499                            
500 denise.eckstein  1.99      %attr(755,root,pegasus) /usr/sbin/*
501 denise.eckstein  1.76      %attr(755,root,pegasus) /usr/bin/*
502 denise.eckstein  1.81      %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/*.so.1
503                            %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/*.so.1
504 denise.eckstein  1.110     %attr(755,root,pegasus) /usr/%PEGASUS_ARCH_LIB/Pegasus/providerManagers/*.so.1
505 denise.eckstein  1.76      %attr(750,root,pegasus) /usr/share/Pegasus/scripts/*
506                            %attr(644,root,pegasus) /usr/share/man/man1/*
507 denise.eckstein  1.101     %attr(644,root,pegasus) /usr/share/man/man8/*
508 denise.eckstein  1.76      
509 denise.eckstein  1.113     %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.9/Admin_Guide_Release.pdf
510                            %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.9/PegasusSSLGuidelines.htm
511                            %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.9/license.txt
512 denise.eckstein  1.118     %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.9/OpenPegasusNOTICE.txt
513 denise.eckstein  1.81      /usr/%PEGASUS_ARCH_LIB/libpegclient.so
514                            /usr/%PEGASUS_ARCH_LIB/libpegcommon.so
515                            /usr/%PEGASUS_ARCH_LIB/libpegprovider.so
516                            /usr/%PEGASUS_ARCH_LIB/libDefaultProviderManager.so
517                            /usr/%PEGASUS_ARCH_LIB/libCIMxmlIndicationHandler.so
518 yi.zhou          1.93      /usr/%PEGASUS_ARCH_LIB/libsnmpIndicationHandler.so
519 denise.eckstein  1.81      /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libComputerSystemProvider.so
520                            /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libOSProvider.so
521                            /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libProcessProvider.so
522 s.kodali         1.119.2.3  %if %{EXTERNAL_SLP_REQUESTED}
523                            /usr/%PEGASUS_ARCH_LIB/libpegslp_client.so
524                            /usr/%PEGASUS_ARCH_LIB/Pegasus/providers/libSLPProvider.so
525                            %endif
526 denise.eckstein  1.110     /usr/%PEGASUS_ARCH_LIB/Pegasus/providerManagers/libCMPIProviderManager.so
527 w.otsuka         1.1       
528 w.otsuka         1.69      %files devel
529 denise.eckstein  1.76      %defattr(644,root,pegasus,755)
530 denise.eckstein  1.89      /usr/share/Pegasus/samples
531 w.otsuka         1.80      /usr/include/Pegasus
532 denise.eckstein  1.117     %doc %attr(444,root,pegasus) /usr/share/doc/tog-pegasus-2.9/SecurityGuidelinesForDevelopers.html
533 denise.eckstein  1.76      /usr/share/Pegasus/html
534 w.otsuka         1.28      
535 w.otsuka         1.56      %if %{PEGASUS_BUILD_TEST_RPM}
536 w.otsuka         1.28      %files test
537 denise.eckstein  1.74      %defattr(-,root,pegasus,-)
538 denise.eckstein  1.114     
539                            %dir /usr/share/Pegasus/test
540                            %dir /usr/share/Pegasus/test/bin
541                            %dir /usr/share/Pegasus/test/%PEGASUS_ARCH_LIB
542                            %dir /usr/share/Pegasus/test/mak
543                            %dir /usr/share/Pegasus/test/tmp
544                            
545 yi.zhou          1.111     %ghost /usr/share/Pegasus/test/tmp/procIdFile
546                            %ghost /usr/share/Pegasus/test/tmp/trapLogFile
547                            %ghost /usr/share/Pegasus/test/tmp/IndicationStressTestLog
548 denise.eckstein  1.114     %ghost /usr/share/Pegasus/test/tmp/oldIndicationStressTestLog
549                            
550                            %attr(744,root,pegasus) /usr/share/Pegasus/test/bin/*
551                            %attr(744,root,pegasus) /usr/share/Pegasus/test/%PEGASUS_ARCH_LIB/*
552                            %attr(744,root,pegasus) /usr/share/Pegasus/test/mak/*
553                            %attr(644,root,pegasus) /usr/share/Pegasus/test/Makefile
554                            
555 denise.eckstein  1.100     %defattr(600,cimsrvr, cimsrvr,700)
556 denise.eckstein  1.76      /var/lib/Pegasus/testrepository
557 w.otsuka         1.56      %endif

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2