summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Makefile.Release414
-rw-r--r--Makefile.ReleaseTest35
-rw-r--r--env_var_Linux.status26
-rw-r--r--mak/SDKMakefile50
-rw-r--r--mak/commands.mak22
-rw-r--r--mak/config-linux.mak6
-rw-r--r--rpm/access.conf44
-rw-r--r--rpm/tog-pegasus.spec797
-rw-r--r--rpm/tog-specfiles/tog-pegasus-arch.spec29
-rw-r--r--rpm/tog-specfiles/tog-pegasus-build.spec9
-rw-r--r--rpm/tog-specfiles/tog-pegasus-clean.spec7
-rw-r--r--rpm/tog-specfiles/tog-pegasus-genSSLCerts.spec59
-rw-r--r--rpm/tog-specfiles/tog-pegasus-install.spec14
-rw-r--r--rpm/tog-specfiles/tog-pegasus-intro.spec45
-rw-r--r--rpm/tog-specfiles/tog-pegasus-packages.spec14
-rw-r--r--rpm/tog-specfiles/tog-pegasus-post.spec88
-rw-r--r--rpm/tog-specfiles/tog-pegasus-postun.spec10
-rw-r--r--rpm/tog-specfiles/tog-pegasus-pre.spec44
-rw-r--r--rpm/tog-specfiles/tog-pegasus-preun.spec19
19 files changed, 719 insertions, 1013 deletions
diff --git a/Makefile.Release b/Makefile.Release
index a7bf333..2b110af 100644
--- a/Makefile.Release
+++ b/Makefile.Release
@@ -62,6 +62,8 @@ stage: FORCE
$(MAKE) -f $(ROOT)/Makefile.Release prestage_cleanup
$(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusDirectories
$(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusFiles
+ $(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusEmptyFiles
+ $(MAKE) -f $(ROOT)/Makefile.Release stage_genOpenPegasusSSLCertsFile
$(MAKE) -f $(ROOT)/mak/SDKMakefile stageSDK
ifdef PEGASUS_BUILD_TEST_RPM
$(MAKE) -f $(ROOT)/Makefile.ReleaseTest stageTEST
@@ -166,6 +168,19 @@ PEGASUS_USER_CMDS = \
osinfo \
wbemexec
+PEGASUS_GENERATED_SCRIPTS = \
+ genOpenPegasusSSLCerts
+
+ifeq ($(OS),linux)
+ PEGASUS_CVS_SCRIPTS += \
+ settogpath
+endif
+
+PEGASUS_SCRIPT_FILES = \
+ $(PEGASUS_GENERATED_SCRIPTS) \
+ $(PEGASUS_CVS_SCRIPTS)
+
+
PEGASUS_REPOSITORY_DIRS = \
root \
root\#PG_Internal \
@@ -440,11 +455,6 @@ MANAGEDSYSTEM_MOF_FILES = \
PG_UnixProcess20.mof \
PG_UnixProcess20R.mof
-ifeq ($(OS),linux)
- INSTALL_SCRIPT_FILES = \
- settogpath
-endif
-
prestage_verifyInstallEnabled: FORCE
ifndef PEGASUS_ENABLE_MAKE_INSTALL
@$(ECHO) "Makefile.Release is not enabled."
@@ -457,10 +467,10 @@ prestage_cleanup: FORCE
$(RMDIRHIER) $(PEGASUS_STAGING_DIR)$(PEGASUS_LOCAL_AUTH_DIR)
stage_PegasusProductDirectories: FORCE
- $(foreach i, $(PRODUCT_DIRECTORY_STRUCTURE), $(MKDIRHIER) $(PEGASUS_STAGING_DIR)$(i);)
+ $(foreach i, $(PEGASUS_SPECIFIC_DIRECTORIES), $(MKDIRHIER) $(PEGASUS_STAGING_DIR)$(i);)
setpermissions_PegasusProductDirectories: FORCE
- $(foreach i, $(PRODUCT_DIRECTORY_STRUCTURE), $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr_xr_xr_x)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(i);)
+ $(foreach i, $(PEGASUS_SPECIFIC_DIRECTORIES), $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr_xr_xr_x)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(i);)
stage_PegasusProductDirectoryFiles: FORCE
$(foreach i, $(PEGASUS_LICENSE), $(COPY) $(ROOT)/doc/$(i) $(PEGASUS_STAGING_DIR)$(PEGASUS_PROD_DIR)/$(i);)
@@ -495,7 +505,7 @@ setpermissions_PegasusProviderLibraryDirectoryFiles: FORCE
stage_PegasusAdminCmdsDirectoryFiles: FORCE
$(foreach i, $(PEGASUS_ADMIN_CMDS), $(COPY) $(PEGASUS_HOME)/bin/$(i)$(EXE) $(PEGASUS_STAGING_DIR)$(PEGASUS_SBIN_DIR)/$(i)$(EXE);)
- $(foreach i, $(INSTALL_SCRIPT_FILES), $(COPY) $(PEGASUS_ROOT)/installs/scripts/$(i) $(PEGASUS_STAGING_DIR)$(PEGASUS_SBIN_DIR)/$(i);)
+ $(foreach i, $(PEGASUS_CVS_SCRIPTS), $(COPY) $(PEGASUS_ROOT)/installs/scripts/$(i) $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/$(i);)
@$(RM) $(PEGASUS_STAGING_DIR)$(PEGASUS_SBIN_DIR)/init_repository
@$(ECHO-E) "PEGASUS_MOF_DIR=$(PEGASUS_MOF_DIR)" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_SBIN_DIR)/init_repository
@$(ECHO-E) "PEGASUS_CIMXX_MOF_DIR=$(PEGASUS_MOF_DIR)/$(PEGASUS_CIM_SCHEMA)" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_SBIN_DIR)/init_repository
@@ -506,7 +516,7 @@ stage_PegasusAdminCmdsDirectoryFiles: FORCE
setpermissions_PegasusAdminCmdsDirectoryFiles: FORCE
$(foreach i, $(PEGASUS_ADMIN_CMDS), $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr_xr__r__)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_SBIN_DIR)/$(i)$(EXE);)
- $(foreach i, $(INSTALL_SCRIPT_FILES), $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr_xr__r__)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_SBIN_DIR)/$(i);)
+ $(foreach i, $(PEGASUS_SCRIPT_FILES), $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr_xr__r__)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/$(i);)
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Prwxr__r__)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_BIN_DIR)/init_repository
stage_PegasusUserCmdsDirectoryFiles: FORCE
@@ -578,22 +588,26 @@ stage_PegasusVarDataDirectoryFiles: FORCE
setpermissions_PegasusVarDataDirectoryFiles: FORCE
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr________)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)
-stage_SSLConfigurationFile: FORCE
- $(RM) $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(TOUCH) $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "[ req ]" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "distinguished_name = req_distinguished_name" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "prompt = no" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "[ req_distinguished_name ]" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "C = UK" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "ST = Berkshire" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "L = Reading" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "O = The Open Group" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "OU = The OpenPegasus Project" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
- $(ECHO) "CN = \`uname -n\`" >> $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
-
-setpermissions_SSLConfigurationFile: FORCE
- $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Pr________)" OWNER="$(INSTALL_USR)" GROUP="$(INSTALL_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
+stage_genOpenPegasusSSLCertsFile: FORCE
+ @$(RM) $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "#!/bin/bash" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "#" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "PEGASUS_PEM_DIR=$(PEGASUS_PEM_DIR)" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "PEGASUS_CONFIG_DIR=$(PEGASUS_CONFIG_DIR)" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "PEGASUS_INSTALL_LOG=$(PEGASUS_INSTALL_LOG)" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "PEGASUS_SSL_CERT_FILE=$(PEGASUS_SSL_CERT_FILE)" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "PEGASUS_SSL_KEY_FILE=$(PEGASUS_SSL_KEY_FILE)" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(ECHO-E) "PEGASUS_SSL_TRUSTSTORE=$(PEGASUS_SSL_TRUSTSTORE)" >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-genSSLCerts.spec >> \
+ $(PEGASUS_STAGING_DIR)$(PEGASUS_SCRIPT_DIR)/genOpenPegasusSSLCerts
stage_SSLRandomSeedFiles: FORCE
$(MAKE) -f $(ROOT)/Makefile.Release createrandomseed FILENAME=$(PEGASUS_STAGING_DIR)$(PEGASUS_VARDATA_DIR)/$(PEGASUS_CIMSERVER_RANDOMFILE)
@@ -641,7 +655,6 @@ stage_PegasusFiles: FORCE
$(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusUnixManPageDirectoryFiles
$(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusDocFiles
$(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusMOFDirectoryFiles
- $(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusSSLFiles
$(MAKE) -f $(ROOT)/Makefile.Release stage_PegasusSystemFiles
setpermissions_PegasusFiles: FORCE
@@ -655,35 +668,14 @@ setpermissions_PegasusFiles: FORCE
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions_PegasusUnixManPageDirectoryFiles
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions_PegasusDocFiles
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions_PegasusMOFDirectoryFiles
- $(MAKE) -f $(ROOT)/Makefile.Release setpermissions_PegasusSSLFiles
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions_PegasusSystemFiles
-stage_PegasusSSLFiles: FORCE
-ifdef PEGASUS_HAS_SSL
- $(MAKE) -f $(ROOT)/Makefile.Release stage_SSLConfigurationFile
-ifdef PEGASUS_SSL_RANDOMFILE
- $(MAKE) -f $(ROOT)/Makefile.Release stage_SSLRandomSeedFiles
-endif
- $(MAKE) -f $(ROOT)/Makefile.Release stage_ServerCertificateFiles
- $(MAKE) -f $(ROOT)/Makefile.Release stage_ClientCertificateFiles
-endif
-
-setpermissions_PegasusSSLFiles: FORCE
-ifdef PEGASUS_HAS_SSL
- $(MAKE) -f $(ROOT)/Makefile.Release setpermissions_SSLConfigurationFile
-ifdef PEGASUS_SSL_RANDOMFILE
- $(MAKE) -f $(ROOT)/Makefile.Release setpermissions_SSLRandomSeedFiles
-endif
- $(MAKE) -f $(ROOT)/Makefile.Release setpermissions_ServerCertificateFiles
- $(MAKE) -f $(ROOT)/Makefile.Release setpermissions_ClientCertificateFiles
-endif
-
-
stage_PegasusSystemFiles: FORCE
ifeq ($(OS),linux)
ifdef PEGASUS_PAM_AUTHENTICATION
$(MKDIRHIER) $(PEGASUS_STAGING_DIR)$(PAM_CONFIG_DIR)
$(COPY) $(ROOT)/rpm/wbem $(PEGASUS_STAGING_DIR)$(PAM_CONFIG_DIR)/wbem
+ $(COPY) $(ROOT)/rpm/access.conf $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/access.conf
endif
$(MKDIRHIER) $(PEGASUS_STAGING_DIR)/etc/init.d
$(COPY) $(ROOT)/rpm/tog-pegasus.rc $(PEGASUS_STAGING_DIR)/etc/init.d/tog-pegasus
@@ -693,10 +685,18 @@ setpermissions_PegasusSystemFiles: FORCE
ifeq ($(OS),linux)
ifdef PEGASUS_PAM_AUTHENTICATION
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Prw_r__r__)" OWNER="$(CIMSERVER_USR)" GROUP="$(CIMSERVER_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PAM_CONFIG_DIR)/wbem
+ $(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Prw_______)" OWNER="$(CIMSERVER_USR)" GROUP="$(CIMSERVER_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/access.conf
endif
$(MAKE) -f $(ROOT)/Makefile.Release setpermissions PERMISSIONS="$(Prwxr_xr_x)" OWNER="$(CIMSERVER_USR)" GROUP="$(CIMSERVER_GRP)" OBJECT=$(PEGASUS_STAGING_DIR)etc/init.d/tog-pegasus
endif
+stage_PegasusEmptyFiles: FORCE
+ $(TOUCH) $(PEGASUS_STAGING_DIR)$(PEGASUS_CONFIG_DIR)/ssl.cnf
+ $(TOUCH) $(PEGASUS_STAGING_DIR)$(PEGASUS_PEM_DIR)/$(PEGASUS_SSL_CERT_FILE)
+ $(TOUCH) $(PEGASUS_STAGING_DIR)$(PEGASUS_PEM_DIR)/$(PEGASUS_SSL_KEY_FILE)
+ $(TOUCH) $(PEGASUS_STAGING_DIR)$(PEGASUS_PEM_DIR)/$(PEGASUS_SSL_TRUSTSTORE)
+ $(TOUCH) $(PEGASUS_STAGING_DIR)$(PEGASUS_INSTALL_LOG)
+
create_ProductVersionFile: FORCE
ifdef PEGASUS_OVERRIDE_PRODUCT_ID
ifdef PEGASUS_PRODUCT_NAME
@@ -723,7 +723,6 @@ create_OpenPegasusRPMSpecFile: FORCE
@$(MAKE) -f $(ROOT)/Makefile.Release _append_PreambleToSpecFile
@$(MAKE) -f $(ROOT)/Makefile.Release _append_PackagesToSpecFile
@$(MAKE) -f $(ROOT)/Makefile.Release _append_prepSectionToSpecFile
- @$(MAKE) -f $(ROOT)/Makefile.Release _append_setupSectionToSpecFile
@$(MAKE) -f $(ROOT)/Makefile.Release _append_buildSectionToSpecFile
@$(MAKE) -f $(ROOT)/Makefile.Release _append_installSectionToSpecFile
@$(MAKE) -f $(ROOT)/Makefile.Release _append_cleanSectionToSpecFile
@@ -743,191 +742,129 @@ _append_OpenPegasusLicenseToSpecFile: FORCE
@$(ECHO-E) "#" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "# WARNING: This file is automatically generated by executing " >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "# make -f pegasus/Makefile.Release create_OpenPegasusRPMSpecFile" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Any changes made directly to this file will be lost the next " >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# time this file is generated." >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "# Any changes made directly to this file in the OpenPegasus source will" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "# be lost the next time this file is regenerated and submitted to CVS." >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "#" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_PreambleToSpecFile: FORCE
- @$(ECHO-E) "%define srcRelease 1" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "Version: $(PEGASUS_PRODUCT_VERSION)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "Release: 1%{?LINUX_VERSION:.%{LINUX_VERSION}}" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "Epoch: 1" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-intro.spec >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# End of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-intro.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global OPENSSL_HOME $(OPENSSL_HOME)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global OPENSSL_BIN $(OPENSSL_BIN)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PEGASUS_PEM_DIR $(PEGASUS_PEM_DIR)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PEGASUS_SSL_CERT_FILE $(PEGASUS_SSL_CERT_FILE)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PEGASUS_SSL_KEY_FILE $(PEGASUS_SSL_KEY_FILE)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_SSL_TRUSTSTORE $(PEGASUS_SSL_TRUSTSTORE)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_SSL_TRUSTSTORE $(PEGASUS_SSL_TRUSTSTORE)" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PAM_CONFIG_DIR /etc/pam.d" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PEGASUS_CONFIG_DIR $(PEGASUS_CONFIG_DIR)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_REPOSITORY_DIR $(PEGASUS_REPOSITORY_DIR)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_VARDATA_DIR $(PEGASUS_VARDATA_DIR)" >> \
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) \
+ "%global PEGASUS_VARDATA_CACHE_DIR $(PEGASUS_VARDATA_CACHE_DIR)" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_LOCAL_DOMAIN_SOCKET_PATH " \
+ "$(PEGASUS_LOCAL_DOMAIN_SOCKET_PATH)" >> \
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_CIMSERVER_START_FILE $(PEGASUS_CIMSERVER_START_FILE)" >> \
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_REPOSITORY_DIR $(PEGASUS_REPOSITORY_DIR)" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_PREV_REPOSITORY_DIR_NAME \
+ $(PEGASUS_PREV_REPOSITORY_DIR_NAME)" >> \
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_REPOSITORY_PARENT_DIR \
+ $(PEGASUS_REPOSITORY_PARENT_DIR)" >> \
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PEGASUS_PREV_REPOSITORY_DIR $(PEGASUS_PREV_REPOSITORY_DIR)" >> \
$(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PEGASUS_SBIN_DIR $(PEGASUS_SBIN_DIR)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%global PEGASUS_DOC_DIR $(PEGASUS_DOC_DIR)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_RPM_ROOT \044RPM_BUILD_DIR/\044RPM_PACKAGE_NAME-\044RPM_PACKAGE_VERSION" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_RPM_HOME \044RPM_BUILD_ROOT/build/tog-pegasus" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_INSTALL_LOG $(PEGASUS_LOG_DIR)/install.log" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%ifarch ia64" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_HARDWARE_PLATFORM LINUX_IA64_GNU" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%else" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%ifarch x86_64" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_HARDWARE_PLATFORM LINUX_X86_64_GNU" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%else" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%ifarch ppc" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_HARDWARE_PLATFORM LINUX_PPC_GNU" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%else" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%ifarch ppc64 pseries" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_HARDWARE_PLATFORM LINUX_PPC64_GNU" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%else" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%ifarch s390" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES_GNU" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%else" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%ifarch s390x zseries" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES64_GNU" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%else" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%global PEGASUS_HARDWARE_PLATFORM LINUX_IX86_GNU" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%endif" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%endif" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%endif" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%endif" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%endif" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_RPM_ROOT "\
+ "\044RPM_BUILD_DIR/\044RPM_PACKAGE_NAME-\044RPM_PACKAGE_VERSION"\
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) \
+ "%global PEGASUS_RPM_HOME \044RPM_BUILD_ROOT/build/tog-pegasus"\
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%global PEGASUS_INSTALL_LOG $(PEGASUS_LOG_DIR)/install.log"\
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%endif" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-arch.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_PackagesToSpecFile: FORCE
- @$(ECHO-E) "# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-packages.spec >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# End of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-packages.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_prepSectionToSpecFile: FORCE
@$(ECHO-E) "%prep" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "[ \"\044RPM_BUILD_ROOT\" != \"/\" ] && [ -d \044RPM_BUILD_ROOT ] && rm -rf \044RPM_BUILD_ROOT;" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
-
-_append_setupSectionToSpecFile: FORCE
- @$(ECHO-E) "%setup -n %{name}-%{version}" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "export PEGASUS_ROOT=%PEGASUS_RPM_ROOT" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%setup -q -n %{name}-%{version}" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_buildSectionToSpecFile: FORCE
@$(ECHO-E) "%build" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%ifarch s390 s390x zseries" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "export PEGASUS_EXTRA_C_FLAGS=\"\044PEGASUS_EXTRA_C_FLAGS -fsigned-char\"" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%endif" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-build.spec >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# End of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-build.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_installSectionToSpecFile: FORCE
@$(ECHO-E) "%install" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-install.spec >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# End of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "[ \"\044PEGASUS_STAGING_DIR\" != \"/\" ] && [ -d \044PEGASUS_STAGING_DIR ] && \
- [ -d \044PEGASUS_STAGING_DIR%PEGASUS_PEM_DIR ] && \
- rm -f \044PEGASUS_STAGING_DIR/%PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE \
- \044PEGASUS_STAGING_DIR/%PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE \
- \044PEGASUS_STAGING_DIR/%PEGASUS_PEM_DIR/%PEGASUS_SSL_KEY_FILE \
- \044PEGASUS_STAGING_DIR/%PEGASUS_CONFIG_DIR/ssl.cnf;" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "[ \"\044PEGASUS_HOME\" != \"/\" ] && [ -d \044PEGASUS_HOME ] && rm -rf \044PEGASUS_HOME;" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-install.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_cleanSectionToSpecFile: FORCE
@$(ECHO-E) "%clean" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-clean.spec >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# End of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-clean.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_preSectionToSpecFile: FORCE
@$(ECHO-E) "%pre" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-pre.spec >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# End of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-pre.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_postSectionToSpecFile: FORCE
@$(ECHO-E) "%post" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "if [ \044\061 -eq 1 ]; then" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(MAKE) -f $(ROOT)/Makefile.Release _append_postSectionToSpecFile_createLog
- @$(MAKE) -f $(ROOT)/Makefile.Release _append_postSectionToSpecFile_createSymbolicLinks
+ @$(ECHO-E) "if [ \044\061 -eq 1 ]; then" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(MAKE) -f $(ROOT)/Makefile.Release \
+ _append_postSectionToSpecFile_createLog
+ @$(MAKE) -f $(ROOT)/Makefile.Release \
+ _append_postSectionToSpecFile_createSymbolicLinks
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-post.spec >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# End of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-post.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "elif [ \044\061 -gt 1 ]; then" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " then" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) " if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) " # Running Repository Upgrade utility" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) " %PEGASUS_SBIN_DIR/repupgrade 2>>%PEGASUS_INSTALL_LOG" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) " fi" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "/sbin/service tog-pegasus condrestart" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) ":;" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) " /sbin/service tog-pegasus condrestart" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) " :;" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "fi" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_postSectionToSpecFile_createSymbolicLinks: FORCE
@$(ECHO-E) " # Create Symbolic Links for SDK Libraries" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@@ -943,108 +880,81 @@ _append_postSectionToSpecFile_createSymbolicLinks: FORCE
_append_postSectionToSpecFile_createLog: FORCE
@$(ECHO-E) " echo \`date\` > %PEGASUS_INSTALL_LOG 2>&1" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " %define PEGASUS_CONFIG_DIR $(PEGASUS_CONFIG_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) " %define PEGASUS_CONFIG_DIR $(PEGASUS_CONFIG_DIR)" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) " %define PEGASUS_PEM_DIR $(PEGASUS_PEM_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " %define PEGASUS_SSL_CERT_FILE $(PEGASUS_SSL_CERT_FILE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " %define PEGASUS_SSL_KEY_FILE $(PEGASUS_SSL_KEY_FILE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " %define PEGASUS_SSL_TRUSTSTORE $(PEGASUS_SSL_TRUSTSTORE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) " %define PEGASUS_SSL_CERT_FILE $(PEGASUS_SSL_CERT_FILE)" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) " %define PEGASUS_SSL_KEY_FILE $(PEGASUS_SSL_KEY_FILE)" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) " %define PEGASUS_SSL_TRUSTSTORE $(PEGASUS_SSL_TRUSTSTORE)" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_preunSectionToSpecFile: FORCE
@$(ECHO-E) "%preun" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "if [ \044\061 -eq 0 ]; then" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " # Check if the cimserver is running" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " isRunning=\140ps -el | grep cimserver | grep -v \"grep cimserver\"\140" \
- >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " if [ \"\044isRunning\" ]; then" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " $(PEGASUS_SBIN_DIR)/cimserver -s" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " fi" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " [ -f $(PEGASUS_VARDATA_DIR)/$(PEGASUS_CURRENT_CONFIG_FILE) ] && \
- rm $(PEGASUS_VARDATA_DIR)/$(PEGASUS_CURRENT_CONFIG_FILE);" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " [ -f %PEGASUS_INSTALL_LOG ] && rm %PEGASUS_INSTALL_LOG;" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " [ -d $(PEGASUS_REPOSITORY_DIR) ] && rm -rf $(PEGASUS_REPOSITORY_DIR);" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " [ -d $(PEGASUS_VARDATA_CACHE_DIR) ] && rm -rf $(PEGASUS_VARDATA_CACHE_DIR);" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " rm -f $(PEGASUS_LOCAL_DOMAIN_SOCKET_PATH);" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " rm -f $(PEGASUS_CIMSERVER_START_FILE)" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " # Delete the Link to the rc.* Startup Directories" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " /usr/lib/lsb/remove_initd /etc/init.d/tog-pegasus;" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "fi" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-preun.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
_append_postunSectionToSpecFile: FORCE
@$(ECHO-E) "%postun" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "if [ \044\061 -eq 0 ]; then" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " [ -f %PEGASUS_PEM_DIR/key-2048.pem ] && rm %PEGASUS_PEM_DIR/key-2048.pem;" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " [ -f %PEGASUS_PEM_DIR/cert-2048.pem ] && rm %PEGASUS_PEM_DIR/cert-2048.pem;" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) " [ -f %PEGASUS_PEM_DIR/truststore-2048.pem ] && rm %PEGASUS_PEM_DIR/truststore-2048.pem;" >> \
- $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "if [ \044\061 -eq 0 ]; then" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) " export LC_ALL=C">> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "fi" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(CAT) $(ROOT)/rpm/tog-specfiles/tog-pegasus-postun.spec \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+# %defattr(file permissions, owner, group, directory permissions)
+# The %ghost directive instructs RPM not to install the specified file(s).
+# They will be owned by that package and removed if they exists when
+# the package is removed. This can be useful for things like log files
+# and state files.
+
_append_filesSectionToSpecFile: FORCE
@$(ECHO-E) "%files" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(PRODUCT_DIRECTORY_STRUCTURE), if [ $(i) != $(PEGASUS_LOCAL_DOMAIN_SOCKET_DIR) ]; then \
+ @$(ECHO-E) "%defattr($(Prw_______),$(INSTALL_USR),$(INSTALL_GRP),$(Prwxr_x___))" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(foreach i, $(PEGASUS_SPECIFIC_DIRECTORIES), if [ $(i) != $(PEGASUS_LOCAL_DOMAIN_SOCKET_DIR) ]; then \
if [ $(i) != $(PEGASUS_REPOSITORY_DIR) ]; then \
if [ $(i) != $(PEGASUS_TRACE_DIR) ]; then \
- $(ECHO-E) "%dir %attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH); fi; fi; fi;)
+ $(ECHO-E) "%dir $(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH); fi; fi; fi;)
+ @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%dir %attr(1555,$(CIMSERVER_USR),$(CIMSERVER_GRP)) $(PEGASUS_LOCAL_DOMAIN_SOCKET_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MOF_DIR)/$(PEGASUS_CIM_SCHEMA)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%dir %attr($(Prwxrwxrwt),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TRACE_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MOF_DIR)/Pegasus" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_REPOSITORY_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_MOF_DIR)/$(PEGASUS_CIM_SCHEMA)/*" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_MOF_DIR)/Pegasus/*" \
+ >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Prwxrwxrwt),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TRACE_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%config %attr($(Prwxr_x___),$(INSTALL_USR),$(INSTALL_GRP)) /etc/init.d/tog-pegasus" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%config(noreplace) $(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%config(noreplace) $(PEGASUS_CONFIG_DIR)/access.conf" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%config(noreplace) $(PAM_CONFIG_DIR)/wbem" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%ghost %config(noreplace) $(PEGASUS_CONFIG_DIR)/ssl.cnf" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%ghost %config(noreplace) $(PEGASUS_PEM_DIR)/$(PEGASUS_SSL_TRUSTSTORE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%ghost %config(noreplace) $(PEGASUS_PEM_DIR)/$(PEGASUS_SSL_CERT_FILE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%ghost %config(noreplace) $(PEGASUS_PEM_DIR)/$(PEGASUS_SSL_KEY_FILE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%ghost $(PEGASUS_INSTALL_LOG)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%attr(-,$(CIMSERVER_USR),$(CIMSERVER_GRP)) $(PEGASUS_REPOSITORY_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%attr($(Prwxr_x___),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SBIN_DIR)/*" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%attr($(Prwxr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_BIN_DIR)/*" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%attr($(Prwxr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_DEST_LIB_DIR)/*$(LIB_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%attr($(Prwxr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_PROVIDER_LIB_DIR)/*$(LIB_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%attr($(Prwxr_x___),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SCRIPT_DIR)/*" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_MANUSER_DIR)/*" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_MANADMIN_DIR)/*" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(foreach i, $(PEGASUS_LICENSE), \
$(ECHO-E) "%doc %attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_PROD_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PEGASUS_UNIX_MAN_USER_PAGES), \
- $(ECHO-E) "%doc %attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MANUSER_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PEGASUS_UNIX_MAN_ADMIN_PAGES), \
- $(ECHO-E) "%doc %attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MANADMIN_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
@$(foreach i, $(PEGASUS_DOC_FILES), \
$(ECHO-E) "%doc %attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_DOC_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $($(PEGASUS_CIM_SCHEMA)_MOF_FILES), \
- $(ECHO-E) "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MOF_DIR)/$(PEGASUS_CIM_SCHEMA)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(INTERNAL_MOF_FILES), \
- $(ECHO-E) "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MOF_DIR)/Pegasus/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(INTEROP_MOF_FILES), \
- $(ECHO-E) "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MOF_DIR)/Pegasus/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(MANAGEDSYSTEM_MOF_FILES), \
- $(ECHO-E) "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_MOF_DIR)/Pegasus/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%config(noreplace) %attr($(Prw_r__r__),$(CIMSERVER_USR),$(CIMSERVER_GRP)) \
- $(PEGASUS_VARDATA_DIR)/$(PEGASUS_PLANNED_CONFIG_FILE)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%config(noreplace) %attr($(Pr_x______),$(INSTALL_USR),$(INSTALL_GRP)) /etc/init.d/tog-pegasus" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%config(noreplace) %attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) %PAM_CONFIG_DIR/wbem" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(PEGASUS_ADMIN_CMDS), \
- $(ECHO-E) "%attr($(Pr_x______),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SBIN_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "%attr($(Pr_x______),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SBIN_DIR)/init_repository" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(INSTALL_SCRIPT_FILES), \
- $(ECHO-E) "%attr($(Pr_x______),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SBIN_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(PEGASUS_USER_CMDS), \
- $(ECHO-E) "%attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_BIN_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(PEGASUS_LIBRARIES), \
- $(ECHO-E) "%attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_DEST_LIB_DIR)/$(i)$(LIB_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
@$(foreach i, $(PEGASUS_LIBRARY_LINKS), \
$(ECHO-E) "$(PEGASUS_DEST_LIB_DIR)/$(i)$(LIB_LINK_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(PEGASUS_PROVIDERS), \
- $(ECHO-E) "%attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_PROVIDER_LIB_DIR)/$(i)$(LIB_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
@$(foreach i, $(PEGASUS_PROVIDERS), \
$(ECHO-E) "$(PEGASUS_PROVIDER_LIB_DIR)/$(i)$(LIB_LINK_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
diff --git a/Makefile.ReleaseTest b/Makefile.ReleaseTest
index 1af2d0f..1f79fc0 100644
--- a/Makefile.ReleaseTest
+++ b/Makefile.ReleaseTest
@@ -1,4 +1,4 @@
-#//%2005////////////////////////////////////////////////////////////////////////
+#//%2005///////////////////////////////////////////////////////////////////////
#//
#// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
#// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
@@ -99,17 +99,23 @@ PRESTARTTEST_FILES = \
PEGASUS_TEST_PROVIDERS = \
libSampleInstanceProvider \
libSampleMethodProvider \
- libFamilyProvider
+ libFamilyProvider \
+ libIndicationStressTestConsumer \
+ libIndicationStressTestProvider
POSTSTARTTEST_FILES = \
TestClient \
OSTestClient \
- InvokeMethod2
+ InvokeMethod2 \
+ TestIndicationStressTest
POSTSTARTTEST_CMDS = \
$(PEGASUS_TEST_DIR)/bin/TestClient@@-local \
$(PEGASUS_TEST_DIR)/bin/OSTestClient \
- $(PEGASUS_TEST_DIR)/bin/InvokeMethod2
+ $(PEGASUS_TEST_DIR)/bin/InvokeMethod2 \
+ $(PEGASUS_TEST_DIR)/bin/TestIndicationStressTest@@setup@@WQL \
+ $(PEGASUS_TEST_DIR)/bin/TestIndicationStressTest@@run@@100@@1 \
+ $(PEGASUS_TEST_DIR)/bin/TestIndicationStressTest@@cleanup
TESTSUITE_CMDS_1 = \
$(MAKE)@@poststarttests
@@ -249,24 +255,9 @@ _append_preunSectionToSpecFile:
_append_filesSectionToSpecFile:
@$(ECHO-E) "%if %{PEGASUS_BUILD_TEST_RPM}" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%files test" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# Test Files" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "#" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Pr_xr_xr_x), $(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Pr_xr_xr_x), $(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/lib" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Pr_xr_xr_x), $(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/bin" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Pr_xr_xr_x), $(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/mak" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(MAK_FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/mak/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PEGASUS_TEST_PROVIDERS), $(ECHO-E) \
- "%attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/lib/$(i)$(LIB_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PRESTARTTEST_FILES), $(ECHO-E) \
- "%attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/bin/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(POSTSTARTTEST_FILES), $(ECHO-E) \
- "%attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/bin/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_TEST_DIR)/Makefile" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%attr(-,$(CIMSERVER_USR),$(CIMSERVER_GRP)) $(PEGASUS_TEST_REPOSITORY_DIR)/$(PEGASUS_TEST_REPOSITORY_NAME)" \
+ @$(ECHO-E) "%defattr(-,$(INSTALL_USR),$(INSTALL_GRP),-)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_TEST_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_TEST_REPOSITORY_DIR)/$(PEGASUS_TEST_REPOSITORY_NAME)" \
>> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "%endif" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
diff --git a/env_var_Linux.status b/env_var_Linux.status
index a38611f..b2eb08a 100644
--- a/env_var_Linux.status
+++ b/env_var_Linux.status
@@ -6,9 +6,15 @@ PEGASUS_ENABLE_MAKE_INSTALL = yes
#OPENSSL_BIN=
#PEGASUS_PLATFORM=
+ifeq ($(PEGASUS_PLATFORM), LINUX_X86_64_GNU)
+PEGASUS_ARCH_LIB=lib64
+else
+PEGASUS_ARCH_LIB=lib
+endif
+
PEGASUS_OVERRIDE_PRODUCT_ID=yes
PEGASUS_PRODUCT_NAME="OpenPegasus"
-PEGASUS_PRODUCT_VERSION="2.5.0"
+PEGASUS_PRODUCT_VERSION="2.5RC1"
PEGASUS_PRODUCT_STATUS=""
PAM_CONFIG_DIR=/etc/pam.d
@@ -38,15 +44,18 @@ PEGASUS_MAN_DIR = $(PEGASUS_PRODSHARE_DIR)/man
PEGASUS_MANUSER_DIR = $(PEGASUS_MAN_DIR)/man1
PEGASUS_MANADMIN_DIR = $(PEGASUS_MAN_DIR)/man8
PEGASUS_MOF_DIR = $(PEGASUS_PROD_DIR)/mof
-PEGASUS_DEST_LIB_DIR = $(PEGASUS_PROD_DIR)/lib
+PEGASUS_DEST_LIB_DIR = $(PEGASUS_PROD_DIR)/$(PEGASUS_ARCH_LIB)
PEGASUS_PROVIDER_DIR = $(PEGASUS_PROD_DIR)/providers
-PEGASUS_PROVIDER_LIB_DIR = $(PEGASUS_PROVIDER_DIR)/lib
+PEGASUS_PROVIDER_LIB_DIR = $(PEGASUS_PROVIDER_DIR)/$(PEGASUS_ARCH_LIB)
PEGASUS_SBIN_DIR = $(PEGASUS_PROD_DIR)/sbin
PEGASUS_BIN_DIR = $(PEGASUS_PROD_DIR)/bin
+PEGASUS_SCRIPT_DIR = $(PEGASUS_PROD_DIR)/scripts
PEGASUS_VARDATA_DIR = /var/opt/tog-pegasus
PEGASUS_REPOSITORY_PARENT_DIR = $(PEGASUS_VARDATA_DIR)
-PEGASUS_REPOSITORY_DIR = $(PEGASUS_REPOSITORY_PARENT_DIR)/repository
-PEGASUS_PREV_REPOSITORY_DIR = $(PEGASUS_REPOSITORY_PARENT_DIR)/prev_repository
+PEGASUS_REPOSITORY_DIR_NAME = repository
+PEGASUS_REPOSITORY_DIR = $(PEGASUS_REPOSITORY_PARENT_DIR)/$(PEGASUS_REPOSITORY_DIR_NAME)
+PEGASUS_PREV_REPOSITORY_DIR_NAME = prev_repository
+PEGASUS_PREV_REPOSITORY_DIR = $(PEGASUS_REPOSITORY_PARENT_DIR)/$(PEGASUS_PREV_REPOSITORY_DIR_NAME)
PEGASUS_CONFIG_DIR = /etc/opt/tog-pegasus
PEGASUS_VARRUN_DIR = /var/run/tog-pegasus
PEGASUS_CIMSERVER_START_FILE = $(PEGASUS_VARRUN_DIR)/cimserver.pid
@@ -63,6 +72,8 @@ PEGASUS_SSL_KEY_FILE = file.pem
PEGASUS_SSL_CERT_FILE = server.pem
PEGASUS_SSL_TRUSTSTORE = client.pem
+PEGASUS_INSTALL_LOG = $(PEGASUS_LOG_DIR)/install.log
+
PEGASUS_SAMPLES_DIR = $(PEGASUS_PROD_DIR)/samples
PEGASUS_INCLUDE_DIR = $(PEGASUS_PROD_DIR)/include
PEGASUS_HTML_DIR = $(PEGASUS_PROD_DIR)/html
@@ -71,7 +82,7 @@ PEGASUS_TEST_DIR = $(PEGASUS_PROD_DIR)/test
PEGASUS_TEST_REPOSITORY_DIR = $(PEGASUS_VARDATA_DIR)
PEGASUS_TEST_REPOSITORY_NAME = testrepository
-PRODUCT_DIRECTORY_STRUCTURE = \
+PEGASUS_SPECIFIC_DIRECTORIES = \
$(PEGASUS_PROD_DIR) \
$(PEGASUS_PRODSHARE_DIR) \
$(PEGASUS_DOC_DIR) \
@@ -83,7 +94,10 @@ PRODUCT_DIRECTORY_STRUCTURE = \
$(PEGASUS_PROVIDER_LIB_DIR) \
$(PEGASUS_SBIN_DIR) \
$(PEGASUS_BIN_DIR) \
+ $(PEGASUS_SCRIPT_DIR) \
$(PEGASUS_MOF_DIR) \
+ $(PEGASUS_MOF_DIR)/$(PEGASUS_CIM_SCHEMA) \
+ $(PEGASUS_MOF_DIR)/Pegasus \
$(PEGASUS_VARDATA_DIR) \
$(PEGASUS_REPOSITORY_DIR) \
$(PEGASUS_VARDATA_CACHE_DIR) \
diff --git a/mak/SDKMakefile b/mak/SDKMakefile
index 1fc333d..5fdc6c1 100644
--- a/mak/SDKMakefile
+++ b/mak/SDKMakefile
@@ -1,4 +1,3 @@
-#//%2005////////////////////////////////////////////////////////////////////////
#//
#// Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
#// Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
@@ -326,49 +325,12 @@ _append_preunSectionToSpecFile:
_append_filesSectionToSpecFile:
@$(ECHO-E) "%files devel" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# SDK Include Files" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "#" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_INCLUDE_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(INCLUDE_DIRS), $(ECHO-E) \
- "%dir %attr($(Pr_xr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_INCLUDE_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(INCLUDE_FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_INCLUDE_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_INCLUDE_DIR)/Pegasus/Common/Platform_%PEGASUS_HARDWARE_PLATFORM.h" \
- >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# SDK Sample Files" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "#" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "%dir %attr($(Prwxrwxrwx),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(SAMPLES_DIRS), $(ECHO-E) \
- "%dir %attr($(Prwxrwxrwx),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(CLIENTSRCPATH1FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/mak/%PEGASUS_HARDWARE_PLATFORM.mak" \
- >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(CLIENTSRCPATH2FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Clients/DefaultC++/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(CLIENTSRCPATH3FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Clients/DefaultC++/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(CLIENTSRCPATH4FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Clients/DefaultC++/Associations/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PROVIDERSRCPATH1FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Providers/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PROVIDERSRCPATH2FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Providers/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PROVIDERSRCPATH3FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Providers/DefaultC++/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PROVIDERSRCPATH4FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Providers/DefaultC++/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(foreach i, $(PROVIDERSRCPATH5FILES), $(ECHO-E) \
- "%attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_SAMPLES_DIR)/Providers/DefaultC++/$(i)" >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "# SDK Documentation" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(ECHO-E) "#" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
- @$(foreach i, $(DOCSRCPATH1FILES), \
- $(ECHO-E) "%doc %attr($(Pr__r__r__),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_DOC_DIR)/$(i)" \
- >> $(PEGASUS_RPM_SPEC_FILE_PATH);)
- @$(ECHO-E) "%attr(-,$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_HTML_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%defattr($(Prw_______),$(INSTALL_USR),$(INSTALL_GRP),$(Prwxr_x___))" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_INCLUDE_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_SAMPLES_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_DOC_DIR)/*" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "$(PEGASUS_HTML_DIR)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
+ @$(ECHO-E) "%attr($(Prwxr_xr_x),$(INSTALL_USR),$(INSTALL_GRP)) $(PEGASUS_PROVIDER_LIB_DIR)/*$(LIB_LINK_SUFFIX)" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
@$(ECHO-E) "" >> $(PEGASUS_RPM_SPEC_FILE_PATH)
removeSampleProviderNamespace:
diff --git a/mak/commands.mak b/mak/commands.mak
index ee9df31..437c61e 100644
--- a/mak/commands.mak
+++ b/mak/commands.mak
@@ -26,9 +26,12 @@
#// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#//
#//==============================================================================
-# commands.mak is a helper Makefile that is intended to be included in an upper level Makefile.
+# commands.mak is a helper Makefile that is intended to be
+# included in an upper level Makefile.
+
+# Ensure that config.mak is included (so that the ROOT
+# variable is set correctly)
-# Ensure that config.mak is included (so that the ROOT variable is set correctly)
ifndef ROOT
ifdef PEGASUS_ROOT
@@ -102,6 +105,7 @@ ifeq ($(OS),HPUX)
endif
Prwxr_xr_x = 755
+ Prwx______ = 700
Prwxrwxrwx = 777
Prwxrwxrwt = 1777
Pr_xr__r__ = 744
@@ -109,6 +113,7 @@ ifeq ($(OS),HPUX)
Pr________ = 400
Pr_xr_xr_x = 555
Prw_r__r__ = 644
+ Prw_______ = 640
CHMODDIRHIER = chmod -R
INSTALL_USR = bin
@@ -188,18 +193,21 @@ ifeq ($(OS),linux)
Prwxrwxrwx = 777
Prwxrwxrwt = 1777
Prwxr_xr_x = 755
+ Prwxr_x___ = 750
Pr_xr__r__ = 744
+ Prwx______ = 700
Pr__r__r__ = 444
Pr________ = 400
Pr_xr_xr_x = 555
Pr_x______ = 500
Prw_r__r__ = 644
+ Prw_______ = 640
CHMODDIRHIER = chmod -R
INSTALL_USR = root
- INSTALL_GRP = root
+ INSTALL_GRP = pegasus
CIMSERVER_USR = root
- CIMSERVER_GRP = root
+ CIMSERVER_GRP = pegasus
CHMOD = chmod
CHOWN = chown
CHGRP = chgrp
@@ -347,6 +355,7 @@ ifndef TMP_DIR
endif
endif
+
CMDSFORCE:
##
@@ -414,7 +423,6 @@ rmdirhier_IgnoreError: CMDSFORCE
mkdirhier_IgnoreError: CMDSFORCE
@$(MAKE) $(MAKEOPTIONS) -i mkdirhier
-
# The runTestSuite option starts the CIM Server
# with a designated set of configuration options (i.e.,
# CIMSERVER_CONFIG_OPTIONS) and then runs a specified
@@ -448,10 +456,10 @@ mkdirhier_IgnoreError: CMDSFORCE
## cimstart command.
##
runTestSuite: CMDSFORCE
- $(MAKE) --directory $(PEGASUS_ROOT) -f TestMakefile cimstart
+ $(CIMSERVER_START_SERVICE)
$(WINDOWS_ONLY_SLEEP)
$(foreach i, $(TESTSUITE_CMDS), $(subst @@, ,$(i)))
- $(MAKE) --directory $(PEGASUS_ROOT) -f TestMakefile cimstop
+ $(CIMSERVER_STOP_SERVICE)
ifndef PEGASUS_SSLCNF_FULLY_QUALIFIED_DSN
PEGASUS_SSLCNF_FULLY_QUALIFIED_DSN=$(GET_HOSTNAME)
diff --git a/mak/config-linux.mak b/mak/config-linux.mak
index 0f744c5..56c5228 100644
--- a/mak/config-linux.mak
+++ b/mak/config-linux.mak
@@ -76,12 +76,6 @@ DEFINES += -DPEGASUS_HAS_SIGNALS
SYS_LIBS = -ldl -lpthread
-# Build using fixed release settings
-#
-ifdef PEGASUS_USE_RELEASE_DIRS
- PEGASUS_DEST_LIB_DIR=/opt/tog-pegasus/lib
-endif
-
# PAM support
ifdef PEGASUS_PAM_AUTHENTICATION
ifeq ($(HPUX_IA64_VERSION), yes)
diff --git a/rpm/access.conf b/rpm/access.conf
new file mode 100644
index 0000000..1341ef2
--- /dev/null
+++ b/rpm/access.conf
@@ -0,0 +1,44 @@
+##############################################################################
+# Pegasus WBEM HTTP/HTTPS Network Service User Access Control Table:
+#
+# This file controls access to the Pegasus WBEM Network services by users
+# with the PAM pam_access module .
+#
+# The format of the access control table is three fields separated by a
+# ":" character:
+#
+# permission : users : origins
+#
+# The first field should be a "+" (access granted) or "-" (access denied)
+# character.
+#
+# The second field should be a list of one or more login names, group
+# names, or ALL (always matches). A pattern of the form user@host is
+# matched when the login name matches the "user" part, and when the
+# "host" part matches the local machine name.
+#
+# If you run NIS you can use @netgroupname in host or user patterns; this
+# even works for @usergroup@@hostgroup patterns. Weird.
+#
+# The EXCEPT operator makes it possible to write very compact rules.
+#
+# The group file is searched only when a name does not match that of the
+# logged-in user. Both the user's primary group is matched, as well as
+# groups in which users are explicitly listed.
+#
+# The third field must be 'wbemNetwork', to control access by users from
+# remote hosts, or 'wbemLocal', to control access by users from the local host.
+##############################################################################
+#
+# Pegasus PAM Access Rules:
+# 1. The Remote host user access rule:
+# By default, ONLY the pegasus user can use remote network HTTP/S service:
+#
+-: ALL EXCEPT pegasus:wbemNetwork
+#
+#
+# 2. The Local host user access rule:
+# By default, ONLY the pegasus and root users can use pegasus local HTTP/S service:
+#
+-: ALL EXCEPT pegasus root:wbemLocal
+
diff --git a/rpm/tog-pegasus.spec b/rpm/tog-pegasus.spec
index e9f1786..95c6b73 100644
--- a/rpm/tog-pegasus.spec
+++ b/rpm/tog-pegasus.spec
@@ -35,28 +35,51 @@
#
# WARNING: This file is automatically generated by executing
# make -f pegasus/Makefile.Release create_OpenPegasusRPMSpecFile
-# Any changes made directly to this file will be lost the next
-# time this file is generated.
+# Any changes made directly to this file in the OpenPegasus source will
+# be lost the next time this file is regenerated and submitted to CVS.
#
-%define srcRelease 1
-Version: 2.5.0
+Version: 2.5RC1
Release: 1%{?LINUX_VERSION:.%{LINUX_VERSION}}
Epoch: 1
# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
+#
%{?!PEGASUS_BUILD_TEST_RPM: %define PEGASUS_BUILD_TEST_RPM 0}
-# do "rpmbuild --define 'PEGASUS_BUILD_TEST_RPM 1'" to build test RPM .
-Summary: OpenPegasus WBEM Services for Linux
-Name: tog-pegasus
-Group: Systems Management/Base
-License: Open Group Pegasus Open Source
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}
-Source: ftp://www.opengroup.org/pegasus/tog-pegasus-%{version}-%{srcRelease}.tar.gz
-Requires: openssl >= 0.9.6 lsb >= 1.3
+# do "rpmbuild --define 'PEGASUS_BUILD_TEST_RPM 1'" to build test RPM.
+#
+%{?!AUTOSTART: %define AUTOSTART 0}
+# Use "rpm -[iU]vh --define 'AUTOSTART 1'" in order to have cimserver enabled
+# (chkconfig --level=345 tog-pegasus on) after installation.
+#
+
+Summary: OpenPegasus WBEM Services for Linux
+Name: tog-pegasus
+Group: Systems Management/Base
+License: Open Group Pegasus Open Source
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
+URL: http://www.openpegasus.org
+
+Source: ftp://www.opengroup.org/pegasus/%{name}-%{version}-%{release}.tar.gz
+
+BuildRequires: bash, sed, grep, coreutils, procps, gcc, gcc-c++
+BuildRequires: libstdc++, make, pam-devel
+BuildRequires: openssl-devel >= 0.9.6, e2fsprogs
+Requires: bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires: krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires: e2fsprogs, bind-utils, net-tools
+Requires(post): bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires(post): krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires(post): e2fsprogs, bind-utils, net-tools
+Requires(pre): bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires(pre): krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires(pre): e2fsprogs, bind-utils, net-tools
+Requires(postun): bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires(postun): krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires(postun): e2fsprogs, bind-utils, net-tools
+
Conflicts: openwbem
Provides: tog-pegasus-cimserver
-BuildRequires: openssl-devel >= 0.9.6
BuildConflicts: tog-pegasus
%description
@@ -65,6 +88,7 @@ increased control of enterprise resources. WBEM is a platform and resource
independent DMTF standard that defines a common information model and
communication protocol for monitoring and controlling resources from diverse
sources.
+#
# End of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
%global OPENSSL_HOME /usr/include/openssl
@@ -75,15 +99,23 @@ sources.
%global PEGASUS_SSL_TRUSTSTORE client.pem
%global PAM_CONFIG_DIR /etc/pam.d
%global PEGASUS_CONFIG_DIR /etc/opt/tog-pegasus
+%global PEGASUS_VARDATA_DIR /var/opt/tog-pegasus
+%global PEGASUS_VARDATA_CACHE_DIR /var/opt/tog-pegasus/cache
+%global PEGASUS_LOCAL_DOMAIN_SOCKET_PATH /var/run/tog-pegasus/socket/cimxml.socket
+%global PEGASUS_CIMSERVER_START_FILE /var/run/tog-pegasus/cimserver.pid
%global PEGASUS_REPOSITORY_DIR /var/opt/tog-pegasus/repository
+%global PEGASUS_PREV_REPOSITORY_DIR_NAME prev_repository
+%global PEGASUS_REPOSITORY_PARENT_DIR /var/opt/tog-pegasus
%global PEGASUS_PREV_REPOSITORY_DIR /var/opt/tog-pegasus/prev_repository
%global PEGASUS_SBIN_DIR /opt/tog-pegasus/sbin
%global PEGASUS_DOC_DIR /opt/tog-pegasus/share/doc
-%global PEGASUS_RPM_ROOT $RPM_BUILD_DIR/$RPM_PACKAGE_NAME-$RPM_PACKAGE_VERSION
+%global PEGASUS_RPM_ROOT $RPM_BUILD_DIR/$RPM_PACKAGE_NAME-$RPM_PACKAGE_VERSION
%global PEGASUS_RPM_HOME $RPM_BUILD_ROOT/build/tog-pegasus
%global PEGASUS_INSTALL_LOG /var/opt/tog-pegasus/log/install.log
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
+#
%ifarch ia64
%global PEGASUS_HARDWARE_PLATFORM LINUX_IA64_GNU
%else
@@ -103,56 +135,51 @@ sources.
%global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES64_GNU
%else
%global PEGASUS_HARDWARE_PLATFORM LINUX_IX86_GNU
+%endif
+%endif
+%endif
+%endif
%endif
%endif
-%endif
-%endif
-%endif
-
-%endif
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
+#
%package devel
Summary: The OpenPegasus Software Development Kit
Group: Systems Management/Base
-Autoreq: 0
Requires: tog-pegasus >= %{version}
Obsoletes: tog-pegasus-sdk
%description devel
-The OpenPegasus WBEM Services for Linux SDK is the developer's kit for the OpenPegasus WBEM
-Services for Linux release. It provides Linux C++ developers with the WBEM files required to
-build WBEM Clients and Providers. It also supports C provider developers via the CMPI interface.
+The OpenPegasus WBEM Services for Linux SDK is the developer's kit for the
+OpenPegasus WBEM Services for Linux release. It provides Linux C++ developers
+with the WBEM files required to build WBEM Clients and Providers. It also
+supports C provider developers via the CMPI interface.
%if %{PEGASUS_BUILD_TEST_RPM}
%package test
Summary: The OpenPegasus Tests
Group: Systems Management/Base
-Autoreq: 0
Requires: tog-pegasus >= %{version}
%description test
The OpenPegasus WBEM tests for the OpenPegasus %{version} Linux rpm.
%endif
-
-# End of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
+#
+#End of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
%prep
-[ "$RPM_BUILD_ROOT" != "/" ] && [ -d $RPM_BUILD_ROOT ] && rm -rf $RPM_BUILD_ROOT;
-
-%setup -n %{name}-%{version}
-export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
+%setup -q -n %{name}-%{version}
%build
-
-%ifarch s390 s390x zseries
-export PEGASUS_EXTRA_C_FLAGS="$PEGASUS_EXTRA_C_FLAGS -fsigned-char"
-%endif
-
# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
+#
export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
export PEGASUS_HOME=%PEGASUS_RPM_HOME
export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
+export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
export OPENSSL_HOME=%OPENSSL_HOME
@@ -160,20 +187,24 @@ export OPENSSL_BIN=%OPENSSL_BIN
export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
export PATH=$PEGASUS_HOME/bin:$PATH
-export PEGASUS_EXTRA_C_FLAGS="-g $RPM_OPT_FLAGS"
+export PEGASUS_EXTRA_C_FLAGS="$RPM_OPT_FLAGS -g"
export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS"
+export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS"
+#export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS -g -pie -Wl,-z,relro,-z,now,-z,nodlopen,-z,noexecstack"
make -f $PEGASUS_ROOT/Makefile.Release create_ProductVersionFile
make -f $PEGASUS_ROOT/Makefile.Release all
make -f $PEGASUS_ROOT/Makefile.Release repository
+#
# End of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
%install
-
# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
+#
export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
export PEGASUS_HOME=%PEGASUS_RPM_HOME
export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
+export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
export OPENSSL_BIN=%OPENSSL_BIN
@@ -183,38 +214,57 @@ export PATH=$PEGASUS_HOME/bin:$PATH
export PEGASUS_STAGING_DIR=$RPM_BUILD_ROOT
%if %{PEGASUS_BUILD_TEST_RPM}
-make -f $PEGASUS_ROOT/Makefile.Release stage PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR PEGASUS_BUILD_TEST_RPM=%{PEGASUS_BUILD_TEST_RPM}
+make -f $PEGASUS_ROOT/Makefile.Release stage \
+ PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR \
+ PEGASUS_BUILD_TEST_RPM=%{PEGASUS_BUILD_TEST_RPM}
%else
-make -f $PEGASUS_ROOT/Makefile.Release stage PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR
+make -f $PEGASUS_ROOT/Makefile.Release stage \
+ PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR
%endif
-# End of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
-[ "$PEGASUS_STAGING_DIR" != "/" ] && [ -d $PEGASUS_STAGING_DIR ] && [ -d $PEGASUS_STAGING_DIR%PEGASUS_PEM_DIR ] && rm -f $PEGASUS_STAGING_DIR/%PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE $PEGASUS_STAGING_DIR/%PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE $PEGASUS_STAGING_DIR/%PEGASUS_PEM_DIR/%PEGASUS_SSL_KEY_FILE $PEGASUS_STAGING_DIR/%PEGASUS_CONFIG_DIR/ssl.cnf;
+
[ "$PEGASUS_HOME" != "/" ] && [ -d $PEGASUS_HOME ] && rm -rf $PEGASUS_HOME;
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
%clean
-
# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
-[ "$RPM_BUILD_ROOT" != "/" ] && [ -d $RPM_BUILD_ROOT ] && rm -rf $RPM_BUILD_ROOT;
+#
+#[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT;
+#[ "${RPM_BUILD_DIR}" != "/" ] && rm -rf ${RPM_BUILD_DIR}/%{name}-%{version};
+#
# End of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
%pre
-
# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
-if [ -d %PEGASUS_REPOSITORY_DIR"/root#PG_Internal" ]
-then
- #
- # Save the current repository to prev_repository
- #
- if [[ -d %PEGASUS_REPOSITORY_DIR ]]
- then
- if [[ -d %PEGASUS_PREV_REPOSITORY_DIR ]]
- then
- mv %PEGASUS_PREV_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.rpmsave;
- fi
- mv %PEGASUS_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR
- mkdir %PEGASUS_REPOSITORY_DIR
- fi
+# install remove upgrade reinstall
+# pre 1 - 2 2
+#
+# If it exists, the active OpenPegasus Repository
+# directory, %PEGASUS_REPOSITORY_DIR is renamed
+# to %PEGASUS_PREV_REPOSITORY_DIR. If
+# %PEGASUS_PREV_REPOSITORY_DIR already exists,
+# it is saved as an archive file.
+
+if [ -d %PEGASUS_REPOSITORY_DIR"/root#PG_Internal" ]; then
+ #
+ # Save the current repository to prev_repository
+ #
+ if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
+ /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
+ %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
+ %PEGASUS_PREV_REPOSITORY_DIR_NAME
+ rm -rf %PEGASUS_PREV_REPOSITORY_DIR
+ fi
+ /bin/mv %PEGASUS_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR
fi
+if [ $1 -eq 1 ]; then
+ # Create the 'pegasus' user and group:
+ /usr/sbin/groupadd pegasus > /dev/null 2>&1 || :;
+ /usr/sbin/useradd -c "tog-pegasus OpenPegasus WBEM/CIM services" \
+ -g pegasus -s /sbin/nologin -r -d %PEGASUS_VARDATA_DIR pegasus \
+ > /dev/null 2>&1 || :;
+fi
+#
# End of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
%post
@@ -243,100 +293,60 @@ if [ $1 -eq 1 ]; then
# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
-
- # Create OpenSSL Configuration File (ssl.cnf)
- #
- if [ -f %PEGASUS_CONFIG_DIR/ssl.cnf ]
- then
- echo "WARNING: %PEGASUS_CONFIG_DIR/ssl.cnf already exists."
- else
- echo " Generating SSL Certificate..."
- echo "[ req ]" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "distinguished_name = req_distinguished_name" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "prompt = no" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "[ req_distinguished_name ]" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "C = UK" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "ST = Berkshire" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "L = Reading" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "O = The Open Group" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "OU = The OpenPegasus Project" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "CN = `host \`hostname\`|cut -d\" \" -f1`" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- chmod 400 %PEGASUS_CONFIG_DIR/ssl.cnf
- chown root %PEGASUS_CONFIG_DIR/ssl.cnf
- fi
-
- %OPENSSL_BIN/openssl req -x509 -days 3650 -newkey rsa:2048 \
- -nodes -config %PEGASUS_CONFIG_DIR/ssl.cnf \
- -keyout %PEGASUS_PEM_DIR/key.pem -out %PEGASUS_PEM_DIR/cert.pem \
- 2>>%PEGASUS_INSTALL_LOG
-
- cat %PEGASUS_PEM_DIR/key.pem > %PEGASUS_PEM_DIR/key-2048.pem
- chmod 400 %PEGASUS_PEM_DIR/key-2048.pem
- cat %PEGASUS_PEM_DIR/cert.pem > %PEGASUS_PEM_DIR/cert-2048.pem
- chmod 400 %PEGASUS_PEM_DIR/cert-2048.pem
- cat %PEGASUS_PEM_DIR/cert.pem > %PEGASUS_PEM_DIR/truststore-2048.pem
- chmod 400 %PEGASUS_PEM_DIR/truststore-2048.pem
- rm -f %PEGASUS_PEM_DIR/key.pem %PEGASUS_PEM_DIR/cert.pem
-
- if [ -f %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE ]
- then
- echo "WARNING: %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE SSL Certificate file already exists."
- else
- cp %PEGASUS_PEM_DIR/cert-2048.pem %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE
- chmod 444 %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE
- cp %PEGASUS_PEM_DIR/key-2048.pem %PEGASUS_PEM_DIR/%PEGASUS_SSL_KEY_FILE
- chmod 400 %PEGASUS_PEM_DIR/%PEGASUS_SSL_KEY_FILE
- fi
-
- if [ -f %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE ]
- then
- echo "WARNING: %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE SSL Certificate trust store already exists."
- else
- cp %PEGASUS_PEM_DIR/truststore-2048.pem %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE
- chmod 444 %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE
+#
+# install remove upgrade reinstall
+# %post 1 - 2 2
+#
+ if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
+ # Running Repository Upgrade utility
+ %PEGASUS_SBIN_DIR/repupgrade %PEGASUS_PREV_REPOSITORY_DIR \
+ %PEGASUS_REPOSITORY_DIR 2>>%PEGASUS_INSTALL_LOG
+ /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
+ %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
+ %PEGASUS_PREV_REPOSITORY_DIR_NAME
+ rm -rf %PEGASUS_PREV_REPOSITORY_DIR
fi
- if [[ -d %PEGASUS_PREV_REPOSITORY_DIR ]]
- then
- # Running Repository Upgrade utility
- %PEGASUS_SBIN_DIR/repupgrade %PEGASUS_PREV_REPOSITORY_DIR %PEGASUS_REPOSITORY_DIR 2>>%PEGASUS_INSTALL_LOG
+ if [ $1 -eq 1 ]; then
+%if %{AUTOSTART}
+ /sbin/chkconfig --add tog-pegasus
+%endif
+ :;
+ elif [ $1 -gt 0 ]; then
+ /sbin/service tog-pegasus condrestart
+ :;
fi
-
-
- /usr/lib/lsb/install_initd /etc/init.d/tog-pegasus
-
- echo " To start Pegasus manually:"
- echo " /etc/init.d/tog-pegasus start"
- echo " Stop it:"
- echo " /etc/init.d/tog-pegasus stop"
- echo " To set up PATH and MANPATH in /etc/profile"
- echo " run /opt/tog-pegasus/sbin/settogpath."
+#
# End of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
elif [ $1 -gt 1 ]; then
- if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]
- then
+ if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
# Running Repository Upgrade utility
%PEGASUS_SBIN_DIR/repupgrade 2>>%PEGASUS_INSTALL_LOG
fi
-/sbin/service tog-pegasus condrestart
-:;
+ /sbin/service tog-pegasus condrestart
+ :;
fi
+
%preun
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
+# install remove upgrade reinstall
+# preun - 0 1 -
if [ $1 -eq 0 ]; then
# Check if the cimserver is running
- isRunning=`ps -el | grep cimserver | grep -v "grep cimserver"`
+ isRunning=`ps -el | grep cimserver | grep -v "grep cimserver"`
if [ "$isRunning" ]; then
- /opt/tog-pegasus/sbin/cimserver -s
- fi
- [ -f /var/opt/tog-pegasus/cimserver_current.conf ] && rm /var/opt/tog-pegasus/cimserver_current.conf;
- [ -f %PEGASUS_INSTALL_LOG ] && rm %PEGASUS_INSTALL_LOG;
- [ -d /var/opt/tog-pegasus/repository ] && rm -rf /var/opt/tog-pegasus/repository;
- [ -d /var/opt/tog-pegasus/cache ] && rm -rf /var/opt/tog-pegasus/cache;
- rm -f /var/run/tog-pegasus/socket/cimxml.socket;
- rm -f /var/run/tog-pegasus/cimserver.pid
- # Delete the Link to the rc.* Startup Directories
- /usr/lib/lsb/remove_initd /etc/init.d/tog-pegasus;
+ %PEGASUS_SBIN_DIR/cimserver -s
+ fi
+ /sbin/chkconfig --del tog-pegasus;
+ rm -f %PEGASUS_VARDATA_DIR/cimserver_current.conf;
+ rm -f %PEGASUS_INSTALL_LOG;
+ [ -d %PEGASUS_REPOSITORY_DIR ] && rm -rf %PEGASUS_REPOSITORY_DIR;
+ [ -d %PEGASUS_VARDATA_CACHE_DIR ] && rm -rf %PEGASUS_VARDATA_CACHE_DIR;
+ rm -f %PEGASUS_LOCAL_DOMAIN_SOCKET_PATH;
+ rm -f %PEGASUS_CIMSERVER_START_FILE;
fi
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
%preun devel
make --directory /opt/tog-pegasus/samples -s clean
@@ -349,462 +359,93 @@ make --directory /opt/tog-pegasus/test -s unsetupTEST
%endif
%postun
if [ $1 -eq 0 ]; then
- [ -f %PEGASUS_PEM_DIR/key-2048.pem ] && rm %PEGASUS_PEM_DIR/key-2048.pem;
- [ -f %PEGASUS_PEM_DIR/cert-2048.pem ] && rm %PEGASUS_PEM_DIR/cert-2048.pem;
- [ -f %PEGASUS_PEM_DIR/truststore-2048.pem ] && rm %PEGASUS_PEM_DIR/truststore-2048.pem;
export LC_ALL=C
fi
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
+#
+# install remove upgrade reinstall
+# postun - 0 1 -
+if [ $1 -eq 0 ]; then
+ /usr/sbin/userdel pegasus > /dev/null 2>&1 || :;
+ /usr/sbin/groudel pegasus > /dev/null 2>&1 || :;
+fi;
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
%files
-%dir %attr(555,root,root) /opt/tog-pegasus
-%dir %attr(555,root,root) /opt/tog-pegasus/share
-%dir %attr(555,root,root) /opt/tog-pegasus/share/doc
-%dir %attr(555,root,root) /opt/tog-pegasus/share/man
-%dir %attr(555,root,root) /opt/tog-pegasus/share/man/man1
-%dir %attr(555,root,root) /opt/tog-pegasus/share/man/man8
-%dir %attr(555,root,root) /opt/tog-pegasus/lib
-%dir %attr(555,root,root) /opt/tog-pegasus/providers
-%dir %attr(555,root,root) /opt/tog-pegasus/providers/lib
-%dir %attr(555,root,root) /opt/tog-pegasus/sbin
-%dir %attr(555,root,root) /opt/tog-pegasus/bin
-%dir %attr(555,root,root) /opt/tog-pegasus/mof
-%dir %attr(555,root,root) /var/opt/tog-pegasus
-%dir %attr(555,root,root) /var/opt/tog-pegasus/cache
-%dir %attr(555,root,root) /var/opt/tog-pegasus/log
-%dir %attr(555,root,root) /var/opt/tog-pegasus/cache/localauth
-%dir %attr(555,root,root) /var/run/tog-pegasus
-%dir %attr(555,root,root) /etc/opt/tog-pegasus
-%dir %attr(1555,root,root) /var/run/tog-pegasus/socket
-%dir %attr(555,root,root) /opt/tog-pegasus/mof/CIM29
-
-%dir %attr(555,root,root) /opt/tog-pegasus/mof/Pegasus
-
-%dir %attr(1777,root,root) /var/opt/tog-pegasus/cache/trace
-
-%attr(-,root,root) /var/opt/tog-pegasus/repository
-
-%doc %attr(444,root,root) /opt/tog-pegasus/license.txt
-%doc %attr(444,root,root) /opt/tog-pegasus/share/man/man1/cimmof.1
-%doc %attr(444,root,root) /opt/tog-pegasus/share/man/man1/cimprovider.1
-%doc %attr(444,root,root) /opt/tog-pegasus/share/man/man1/osinfo.1
-%doc %attr(444,root,root) /opt/tog-pegasus/share/man/man1/wbemexec.1
-%doc %attr(444,root,root) /opt/tog-pegasus/share/man/man8/cimauth.8
-%doc %attr(444,root,root) /opt/tog-pegasus/share/man/man8/cimconfig.8
-%doc %attr(444,root,root) /opt/tog-pegasus/share/man/man8/cimserver.8
-%doc %attr(444,root,root) /opt/tog-pegasus/share/doc/Admin_Guide_Release.pdf
-%doc %attr(444,root,root) /opt/tog-pegasus/share/doc/PegasusSSLGuidelines.htm
-
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_AppRuntime.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_BIOS.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_CheckAction.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_DeploymentModel.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_InstalledProduct.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_J2eeAppServer.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_J2eeAppServerStats.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Application_SystemSoftware.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Application.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Core.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Database.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Device.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Event.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_IPsecPolicy.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Interop.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Metrics.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Network.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Physical.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Policy.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Schema.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_Support.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_System.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/CIM_User.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Capabilities.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Collection.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_CoreElements.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Device.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_MethodParms.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Physical.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_PowerMgmt.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_ProductFRU.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Qualifiers.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Redundancy.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Service.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Settings.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Software.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_Statistics.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Core_StorageExtent.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Database_Statistics.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Database_Storage.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Database_System.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_Controller.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_CoolingAndPower.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_DeviceElements.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_DiskGroup.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_FC.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_IB.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_Memory.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_Modems.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_NetworkAdapter.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_Ports.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_Printing.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_Processor.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_ProtocolController.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_SccExtents.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_Sensors.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_StorageDevices.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_StorageExtents.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_StorageLib.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_StorageServices.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_USB.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Device_UserDevices.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Metrics_BaseMetric.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Metrics_UnitOfWork.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_BGP.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_Buffers.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_Collections.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_Filtering.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_IPsec.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_OSPF.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_Pipes.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_ProtocolEndpoints.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_QoS.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_Routes.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_RoutingForwarding.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_SNMP.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_SwitchingBridging.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_Systems.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Network_VLAN.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Physical_Component.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Physical_Connector.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Physical_Link.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Physical_Misc.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Physical_Package.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Physical_PhysicalMedia.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/Physical_StoragePackage.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_Boot.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_Diagnostics.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_FileElements.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_Help.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_Logs.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_OperatingSystem.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_Processing.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_SystemElements.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_SystemResources.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_Time.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/System_Unix.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_AccessControl.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Account.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_AuthenticationReqmt.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Credential.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Group.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Identity.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Kerberos.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Org.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Privilege.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_PrivilegeManagementService.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_PublicKey.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_Role.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_SecurityLevel.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_SecurityServices.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_SharedSecret.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_StorageHardwareID.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/CIM29/User_UsersAccess.mof
-
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_Authorization20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_ConfigSetting20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_InternalSchema20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_ShutdownService20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_User20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_Events20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_InterOpSchema20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_ProviderModule20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_ComputerSystem20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_ComputerSystem20R.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_ManagedSystemSchema20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_ManagedSystemSchema20R.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_OperatingSystem20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_OperatingSystem20R.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_UnixProcess20.mof
-%attr(444,root,root) /opt/tog-pegasus/mof/Pegasus/PG_UnixProcess20R.mof
-
-%config(noreplace) %attr(644,root,root) /var/opt/tog-pegasus/cimserver_planned.conf
-%config(noreplace) %attr(500,root,root) /etc/init.d/tog-pegasus
-%config(noreplace) %attr(444,root,root) %PAM_CONFIG_DIR/wbem
-
-%attr(500,root,root) /opt/tog-pegasus/sbin/cimauth
-%attr(500,root,root) /opt/tog-pegasus/sbin/cimconfig
-%attr(500,root,root) /opt/tog-pegasus/sbin/cimserver
-%attr(500,root,root) /opt/tog-pegasus/sbin/cimuser
-%attr(500,root,root) /opt/tog-pegasus/sbin/cimprovagt
-%attr(500,root,root) /opt/tog-pegasus/sbin/cimservera
-%attr(500,root,root) /opt/tog-pegasus/sbin/repupgrade
-%attr(500,root,root) /opt/tog-pegasus/sbin/init_repository
-%attr(500,root,root) /opt/tog-pegasus/sbin/settogpath
-
-%attr(555,root,root) /opt/tog-pegasus/bin/cimmof
-%attr(555,root,root) /opt/tog-pegasus/bin/cimmofl
-%attr(555,root,root) /opt/tog-pegasus/bin/cimprovider
-%attr(555,root,root) /opt/tog-pegasus/bin/osinfo
-%attr(555,root,root) /opt/tog-pegasus/bin/wbemexec
-
-%attr(555,root,root) /opt/tog-pegasus/lib/libCIMxmlIndicationHandler.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libConfigSettingProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libNamespaceProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libProviderRegistrationProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libUserAuthProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegauthentication.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegclient.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegcliutils.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegcommon.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegcompiler.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegconfig.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegexportclient.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegexportserver.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpeggetoopt.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpeghandlerservice.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegindicationservice.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpeglistener.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegprm.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegprovider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegprovidermanager.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegrepository.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegserver.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpeguser.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegwql.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libDefaultProviderManager.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libCertificateProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegqueryexpression.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegquerycommon.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libInteropProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libCIMOMStatDataProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libpegservice.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libCMPIProviderManager.so.1
-%attr(555,root,root) /opt/tog-pegasus/lib/libcmpiCppImpl.so.1
+%defattr(640,root,pegasus,750)
+%dir /opt/tog-pegasus
+%dir /opt/tog-pegasus/share
+%dir /opt/tog-pegasus/share/doc
+%dir /opt/tog-pegasus/share/man
+%dir /opt/tog-pegasus/share/man/man1
+%dir /opt/tog-pegasus/share/man/man8
+%dir /opt/tog-pegasus/lib
+%dir /opt/tog-pegasus/providers
+%dir /opt/tog-pegasus/providers/lib
+%dir /opt/tog-pegasus/sbin
+%dir /opt/tog-pegasus/bin
+%dir /opt/tog-pegasus/scripts
+%dir /opt/tog-pegasus/mof
+%dir /opt/tog-pegasus/mof/CIM29
+%dir /opt/tog-pegasus/mof/Pegasus
+%dir /var/opt/tog-pegasus
+%dir /var/opt/tog-pegasus/cache
+%dir /var/opt/tog-pegasus/log
+%dir /var/opt/tog-pegasus/cache/localauth
+%dir /var/run/tog-pegasus
+%dir /etc/opt/tog-pegasus
+
+%dir %attr(1555,root,pegasus) /var/run/tog-pegasus/socket
+%dir %attr(1777,root,pegasus) /var/opt/tog-pegasus/cache/trace
+
+/var/opt/tog-pegasus/repository
+/opt/tog-pegasus/mof/CIM29/*
+/opt/tog-pegasus/mof/Pegasus/*
+
+%config %attr(750,root,pegasus) /etc/init.d/tog-pegasus
+%config(noreplace) /var/opt/tog-pegasus/cimserver_planned.conf
+%config(noreplace) /etc/opt/tog-pegasus/access.conf
+%config(noreplace) /etc/pam.d/wbem
+
+%ghost %config(noreplace) /etc/opt/tog-pegasus/ssl.cnf
+%ghost %config(noreplace) /etc/opt/tog-pegasus/client.pem
+%ghost %config(noreplace) /etc/opt/tog-pegasus/server.pem
+%ghost %config(noreplace) /etc/opt/tog-pegasus/file.pem
+%ghost /var/opt/tog-pegasus/log/install.log
+
+%attr(750,root,pegasus) /opt/tog-pegasus/sbin/*
+%attr(755,root,pegasus) /opt/tog-pegasus/bin/*
+%attr(755,root,pegasus) /opt/tog-pegasus/lib/*.so.1
+%attr(755,root,pegasus) /opt/tog-pegasus/providers/lib/*.so.1
+%attr(750,root,pegasus) /opt/tog-pegasus/scripts/*
+/opt/tog-pegasus/share/man/man1/*
+/opt/tog-pegasus/share/man/man8/*
+
+%doc %attr(444,root,pegasus) /opt/tog-pegasus/license.txt
+%doc %attr(444,root,pegasus) /opt/tog-pegasus/share/doc/Admin_Guide_Release.pdf
+%doc %attr(444,root,pegasus) /opt/tog-pegasus/share/doc/PegasusSSLGuidelines.htm
/opt/tog-pegasus/lib/libpegclient.so
/opt/tog-pegasus/lib/libpegcommon.so
/opt/tog-pegasus/lib/libpegprovider.so
/opt/tog-pegasus/lib/libDefaultProviderManager.so
/opt/tog-pegasus/lib/libCIMxmlIndicationHandler.so
/opt/tog-pegasus/lib/libCMPIProviderManager.so
-
-%attr(555,root,root) /opt/tog-pegasus/providers/lib/libComputerSystemProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/providers/lib/libOSProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/providers/lib/libProcessProvider.so.1
/opt/tog-pegasus/providers/lib/libComputerSystemProvider.so
/opt/tog-pegasus/providers/lib/libOSProvider.so
/opt/tog-pegasus/providers/lib/libProcessProvider.so
%files devel
-
-# SDK Include Files
-#
-%dir %attr(555,root,root) /opt/tog-pegasus/include
-%dir %attr(555,root,root) /opt/tog-pegasus/include/Pegasus
-%dir %attr(555,root,root) /opt/tog-pegasus/include/Pegasus/Client
-%dir %attr(555,root,root) /opt/tog-pegasus/include/Pegasus/Common
-%dir %attr(555,root,root) /opt/tog-pegasus/include/Pegasus/Consumer
-%dir %attr(555,root,root) /opt/tog-pegasus/include/Pegasus/Provider
-%dir %attr(555,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CMPI
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Client/CIMClientException.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Client/CIMClient.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Client/Linkage.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/Array.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/ArrayInter.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/Char16.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMClass.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMDateTime.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMFlavor.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMIndication.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMInstance.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMMethod.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMName.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMObject.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMObjectPath.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMParameter.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMParamValue.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMProperty.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMPropertyList.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMQualifierDecl.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMQualifier.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMScope.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMStatusCode.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMType.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMValue.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/Config.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/Exception.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/Linkage.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/OperationContext.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/ResponseHandler.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/SSLContext.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/String.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Consumer/CIMIndicationConsumer.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Consumer/Linkage.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CIMAssociationProvider.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CIMIndicationConsumerProvider.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CIMIndicationProvider.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CIMInstanceProvider.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CIMMethodProvider.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CIMOMHandle.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CIMProvider.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/Linkage.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/ProviderException.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/AcceptLanguages.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/MessageLoader.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/ContentLanguages.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/LanguageElementContainer.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/AcceptLanguageElement.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/Formatter.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/ContentLanguageElement.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/LanguageElement.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Client/ClientOpPerformanceDataHandler.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/CIMOperationType.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CMPI/cmpift.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CMPI/cmpidt.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CMPI/cmpimacs.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CMPI/cmpios.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CMPI/cmpipl.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Provider/CMPI/cmpi_cql.h
-%attr(444,root,root) /opt/tog-pegasus/include/Pegasus/Common/Platform_%PEGASUS_HARDWARE_PLATFORM.h
-
-# SDK Sample Files
-#
-%dir %attr(777,root,root) /opt/tog-pegasus/samples
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Clients
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/EnumInstances
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/InvokeMethod
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/SendTestIndications
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/Associations
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/IndicationProvider
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/InstanceProvider
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/MethodProvider
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/SimpleDisplayConsumer
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/AssociationProvider
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/CMPI
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/Providers/Load
-%dir %attr(777,root,root) /opt/tog-pegasus/samples/mak
-%attr(444,root,root) /opt/tog-pegasus/samples/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/mak/config.mak
-%attr(444,root,root) /opt/tog-pegasus/samples/mak/program.mak
-%attr(444,root,root) /opt/tog-pegasus/samples/mak/recurse.mak
-%attr(444,root,root) /opt/tog-pegasus/samples/mak/library.mak
-%attr(444,root,root) /opt/tog-pegasus/samples/mak/common.mak
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/EnumInstances/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/InvokeMethod/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/SendTestIndications/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/Associations/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/mak/%PEGASUS_HARDWARE_PLATFORM.mak
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/EnumInstances/EnumInstances.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/InvokeMethod/InvokeMethod.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/SendTestIndications/SendTestIndications.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Clients/DefaultC++/Associations/AssociationTestClient.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/SampleProviderSchema.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/IndicationProviderR.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/InstanceProvider/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/MethodProvider/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/IndicationProvider/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/IndicationProvider/IndicationProvider.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/IndicationProvider/IndicationProvider.h
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/IndicationProvider/IndicationProviderMain.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/SimpleDisplayConsumer/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/AssociationProvider/Makefile
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/InstanceProviderR.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/MethodProviderR.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/SimpleDisplayConsumerR.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/CWS_FilesAndDir.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/CWS_FilesAndDirR.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/AssociationProvider.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/Load/AssociationProviderR.mof
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/cwssimdata.c
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/cwsutil.h
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/CWS_Directory.c
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/CWS_DirectoryContainsFile.c
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/cwsutil.c
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/CWS_FileUtils.c
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/CWS_PlainFile.c
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/CMPI/FilesAndDirectories/CWS_FileUtils.h
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/InstanceProvider/InstanceProvider.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/InstanceProvider/InstanceProviderMain.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/InstanceProvider/InstanceProvider.h
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/InstanceProvider/EnumerateInstancesrspgood.xml
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/InstanceProvider/EnumerateInstances.xml
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/MethodProvider/MethodProvider.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/MethodProvider/MethodProviderMain.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/MethodProvider/MethodProvider.h
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/MethodProvider/InvokeMethod.xml
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/MethodProvider/InvokeMethodrspgood.xml
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/SimpleDisplayConsumer/SimpleDisplayConsumerMain.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/SimpleDisplayConsumer/SimpleDisplayConsumer.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/SimpleDisplayConsumer/SimpleDisplayConsumer.h
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/AssociationProvider/AssociationProvider.cpp
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/AssociationProvider/AssociationProvider.h
-%attr(444,root,root) /opt/tog-pegasus/samples/Providers/DefaultC++/AssociationProvider/AssociationProviderMain.cpp
-
-# SDK Documentation
-#
-%doc %attr(444,root,root) /opt/tog-pegasus/share/doc/SecurityGuidelinesForDevelopers.html
-%attr(-,root,root) /opt/tog-pegasus/html
+%defattr(640,root,pegasus,750)
+/opt/tog-pegasus/include
+/opt/tog-pegasus/samples
+/opt/tog-pegasus/share/doc/*
+/opt/tog-pegasus/html
+%attr(755,root,pegasus) /opt/tog-pegasus/providers/lib/*.so
%if %{PEGASUS_BUILD_TEST_RPM}
%files test
-
-# Test Files
-#
-%dir %attr(555, root,root) /opt/tog-pegasus/test
-%dir %attr(555, root,root) /opt/tog-pegasus/test/lib
-%dir %attr(555, root,root) /opt/tog-pegasus/test/bin
-%dir %attr(555, root,root) /opt/tog-pegasus/test/mak
-%attr(444,root,root) /opt/tog-pegasus/test/mak/commands.mak
-%attr(555,root,root) /opt/tog-pegasus/test/lib/libSampleInstanceProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/test/lib/libSampleMethodProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/test/lib/libFamilyProvider.so.1
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestAbstract
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestArray
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestBase64
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestClassDecl
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestDateTime
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestFlavor
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestFormatter
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestHashTable
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestInstanceDecl
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestLogger
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestMethod
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestObject
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestOperationContext
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestParamValue
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestParameter
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestProperty
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestQualifier
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestQualifierDecl
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestQualifierList
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestQueue
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestReference
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestResolve
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestResponseHandler
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestScope
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestStack
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestStopwatch
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestStrToInstName
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestString
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestTimeValue
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestToMof
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestValidateClass
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestValue
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TracerTest
-%attr(555,root,root) /opt/tog-pegasus/test/bin/IPC
-%attr(555,root,root) /opt/tog-pegasus/test/bin/TestClient
-%attr(555,root,root) /opt/tog-pegasus/test/bin/OSTestClient
-%attr(555,root,root) /opt/tog-pegasus/test/bin/InvokeMethod2
-%attr(444,root,root) /opt/tog-pegasus/test/Makefile
-%attr(-,root,root) /var/opt/tog-pegasus/testrepository
-
+%defattr(-,root,pegasus,-)
+/opt/tog-pegasus/test
+/var/opt/tog-pegasus/testrepository
%endif
diff --git a/rpm/tog-specfiles/tog-pegasus-arch.spec b/rpm/tog-specfiles/tog-pegasus-arch.spec
new file mode 100644
index 0000000..f096ee8
--- /dev/null
+++ b/rpm/tog-specfiles/tog-pegasus-arch.spec
@@ -0,0 +1,29 @@
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
+#
+%ifarch ia64
+%global PEGASUS_HARDWARE_PLATFORM LINUX_IA64_GNU
+%else
+%ifarch x86_64
+%global PEGASUS_HARDWARE_PLATFORM LINUX_X86_64_GNU
+%else
+%ifarch ppc
+%global PEGASUS_HARDWARE_PLATFORM LINUX_PPC_GNU
+%else
+%ifarch ppc64 pseries
+%global PEGASUS_HARDWARE_PLATFORM LINUX_PPC64_GNU
+%else
+%ifarch s390
+%global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES_GNU
+%else
+%ifarch s390x zseries
+%global PEGASUS_HARDWARE_PLATFORM LINUX_ZSERIES64_GNU
+%else
+%global PEGASUS_HARDWARE_PLATFORM LINUX_IX86_GNU
+%endif
+%endif
+%endif
+%endif
+%endif
+%endif
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-arch.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-build.spec b/rpm/tog-specfiles/tog-pegasus-build.spec
index 595b42a..62192a2 100644
--- a/rpm/tog-specfiles/tog-pegasus-build.spec
+++ b/rpm/tog-specfiles/tog-pegasus-build.spec
@@ -1,6 +1,9 @@
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
+#
export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
export PEGASUS_HOME=%PEGASUS_RPM_HOME
export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
+export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
export OPENSSL_HOME=%OPENSSL_HOME
@@ -8,9 +11,13 @@ export OPENSSL_BIN=%OPENSSL_BIN
export LD_LIBRARY_PATH=$PEGASUS_HOME/lib
export PATH=$PEGASUS_HOME/bin:$PATH
-export PEGASUS_EXTRA_C_FLAGS="-g $RPM_OPT_FLAGS"
+export PEGASUS_EXTRA_C_FLAGS="$RPM_OPT_FLAGS -g"
export PEGASUS_EXTRA_CXX_FLAGS="$PEGASUS_EXTRA_C_FLAGS"
+export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS"
+#export PEGASUS_EXTRA_LINK_FLAGS="$RPM_OPT_FLAGS -g -pie -Wl,-z,relro,-z,now,-z,nodlopen,-z,noexecstack"
make -f $PEGASUS_ROOT/Makefile.Release create_ProductVersionFile
make -f $PEGASUS_ROOT/Makefile.Release all
make -f $PEGASUS_ROOT/Makefile.Release repository
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-build.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-clean.spec b/rpm/tog-specfiles/tog-pegasus-clean.spec
index 9bc5a15..58f4f12 100644
--- a/rpm/tog-specfiles/tog-pegasus-clean.spec
+++ b/rpm/tog-specfiles/tog-pegasus-clean.spec
@@ -1 +1,6 @@
-[ "$RPM_BUILD_ROOT" != "/" ] && [ -d $RPM_BUILD_ROOT ] && rm -rf $RPM_BUILD_ROOT;
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
+#
+#[ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT;
+#[ "${RPM_BUILD_DIR}" != "/" ] && rm -rf ${RPM_BUILD_DIR}/%{name}-%{version};
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-clean.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-genSSLCerts.spec b/rpm/tog-specfiles/tog-pegasus-genSSLCerts.spec
new file mode 100644
index 0000000..81e6635
--- /dev/null
+++ b/rpm/tog-specfiles/tog-pegasus-genSSLCerts.spec
@@ -0,0 +1,59 @@
+#
+# Set up OpenSSL certificates for the tog-pegasus cimserver
+#
+# Creates a default ssl.cnf file.
+# Generates a self-signed certificate for use by the cimserver.
+#
+cnfChanged=0;
+if [ ! -e $PEGASUS_CONFIG_DIR/ssl.cnf ]; then
+ mkdir -p ${PEGASUS_INSTALL_LOG%/*}
+ mkdir -p $PEGASUS_CONFIG_DIR
+ echo "[ req ]" > $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "distinguished_name = req_distinguished_name" >> \
+ $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "prompt = no" >> $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "[ req_distinguished_name ]" >> $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "C = UK" >> $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "ST = Berkshire" >> $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "L = Reading" >> $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "O = The Open Group" >> \
+ $PEGASUS_CONFIG_DIR/ssl.cnf
+ echo "OU = The OpenPegasus Project" >> \
+ $PEGASUS_CONFIG_DIR/ssl.cnf
+ DN=`hostname`;
+ if [ -z "$DN" ] || [ "$DN" = "(none)" ]; then
+ DN='localhost.localdomain';
+ fi;
+ FQDN=`{ host -W1 $DN 2>/dev/null || echo "$DN has address "; } |\
+ grep 'has address' | head -1 | sed 's/\ .*$//'`;
+ if [ -z "$FQDN" ] ; then
+ FQDN="$DN";
+ fi;
+ # cannot use 'hostname --fqdn' because this can hang indefinitely
+ echo "CN = $FQDN" >> $PEGASUS_CONFIG_DIR/ssl.cnf
+ chmod 400 $PEGASUS_CONFIG_DIR/ssl.cnf
+ chown root $PEGASUS_CONFIG_DIR/ssl.cnf
+ chgrp root $PEGASUS_CONFIG_DIR/ssl.cnf
+ cnfChanged=1;
+fi
+if [ $cnfChanged -eq 1 ] || \
+ [ ! -e $PEGASUS_PEM_DIR/$PEGASUS_SSL_CERT_FILE ] || \
+ [ ! -e $PEGASUS_PEM_DIR/$PEGASUS_SSL_KEY_FILE ]; then
+ /usr/bin/openssl req -x509 -days 3650 -newkey rsa:2048 \
+ -nodes -config $PEGASUS_CONFIG_DIR/ssl.cnf \
+ -keyout $PEGASUS_PEM_DIR/key.pem \
+ -out $PEGASUS_PEM_DIR/cert.pem 2>>$PEGASUS_INSTALL_LOG
+ chmod 700 $PEGASUS_PEM_DIR/*.pem
+ cp -fp $PEGASUS_PEM_DIR/cert.pem \
+ $PEGASUS_PEM_DIR/$PEGASUS_SSL_CERT_FILE
+ cp -fp $PEGASUS_PEM_DIR/key.pem \
+ $PEGASUS_PEM_DIR/$PEGASUS_SSL_KEY_FILE
+ chmod 400 $PEGASUS_PEM_DIR/$PEGASUS_SSL_KEY_FILE
+ chmod 444 $PEGASUS_PEM_DIR/$PEGASUS_SSL_CERT_FILE
+ rm -f $PEGASUS_PEM_DIR/key.pem $PEGASUS_PEM_DIR/cert.pem
+fi;
+if [ ! -e $PEGASUS_PEM_DIR/$PEGASUS_SSL_TRUSTSTORE ]; then
+ cp -fp $PEGASUS_PEM_DIR/$PEGASUS_SSL_CERT_FILE \
+ $PEGASUS_PEM_DIR/$PEGASUS_SSL_TRUSTSTORE
+ chmod 444 $PEGASUS_PEM_DIR/$PEGASUS_SSL_TRUSTSTORE;
+fi;
diff --git a/rpm/tog-specfiles/tog-pegasus-install.spec b/rpm/tog-specfiles/tog-pegasus-install.spec
index 73328db..52ede05 100644
--- a/rpm/tog-specfiles/tog-pegasus-install.spec
+++ b/rpm/tog-specfiles/tog-pegasus-install.spec
@@ -1,6 +1,9 @@
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
+#
export PEGASUS_ROOT=%PEGASUS_RPM_ROOT
export PEGASUS_HOME=%PEGASUS_RPM_HOME
export PEGASUS_PLATFORM=%PEGASUS_HARDWARE_PLATFORM
+export PEGASUS_ARCH_LIB=%PEGASUS_ARCH_LIB
export PEGASUS_ENVVAR_FILE=$PEGASUS_ROOT/env_var_Linux.status
export OPENSSL_BIN=%OPENSSL_BIN
@@ -10,7 +13,14 @@ export PATH=$PEGASUS_HOME/bin:$PATH
export PEGASUS_STAGING_DIR=$RPM_BUILD_ROOT
%if %{PEGASUS_BUILD_TEST_RPM}
-make -f $PEGASUS_ROOT/Makefile.Release stage PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR PEGASUS_BUILD_TEST_RPM=%{PEGASUS_BUILD_TEST_RPM}
+make -f $PEGASUS_ROOT/Makefile.Release stage \
+ PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR \
+ PEGASUS_BUILD_TEST_RPM=%{PEGASUS_BUILD_TEST_RPM}
%else
-make -f $PEGASUS_ROOT/Makefile.Release stage PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR
+make -f $PEGASUS_ROOT/Makefile.Release stage \
+ PEGASUS_STAGING_DIR=$PEGASUS_STAGING_DIR
%endif
+
+[ "$PEGASUS_HOME" != "/" ] && [ -d $PEGASUS_HOME ] && rm -rf $PEGASUS_HOME;
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-install.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-intro.spec b/rpm/tog-specfiles/tog-pegasus-intro.spec
index ef2a729..712c65a 100644
--- a/rpm/tog-specfiles/tog-pegasus-intro.spec
+++ b/rpm/tog-specfiles/tog-pegasus-intro.spec
@@ -1,15 +1,40 @@
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
+#
%{?!PEGASUS_BUILD_TEST_RPM: %define PEGASUS_BUILD_TEST_RPM 0}
-# do "rpmbuild --define 'PEGASUS_BUILD_TEST_RPM 1'" to build test RPM .
-Summary: OpenPegasus WBEM Services for Linux
-Name: tog-pegasus
-Group: Systems Management/Base
-License: Open Group Pegasus Open Source
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}
-Source: ftp://www.opengroup.org/pegasus/tog-pegasus-%{version}-%{srcRelease}.tar.gz
-Requires: openssl >= 0.9.6 lsb >= 1.3
+# do "rpmbuild --define 'PEGASUS_BUILD_TEST_RPM 1'" to build test RPM.
+#
+%{?!AUTOSTART: %define AUTOSTART 0}
+# Use "rpm -[iU]vh --define 'AUTOSTART 1'" in order to have cimserver enabled
+# (chkconfig --level=345 tog-pegasus on) after installation.
+#
+
+Summary: OpenPegasus WBEM Services for Linux
+Name: tog-pegasus
+Group: Systems Management/Base
+License: Open Group Pegasus Open Source
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
+URL: http://www.openpegasus.org
+
+Source: ftp://www.opengroup.org/pegasus/%{name}-%{version}-%{release}.tar.gz
+
+BuildRequires: bash, sed, grep, coreutils, procps, gcc, gcc-c++
+BuildRequires: libstdc++, make, pam-devel
+BuildRequires: openssl-devel >= 0.9.6, e2fsprogs
+Requires: bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires: krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires: e2fsprogs, bind-utils, net-tools
+Requires(post): bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires(post): krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires(post): e2fsprogs, bind-utils, net-tools
+Requires(pre): bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires(pre): krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires(pre): e2fsprogs, bind-utils, net-tools
+Requires(postun): bash, sed, grep, coreutils, procps, openssl >= 0.9.6, pam
+#Requires(postun): krb5-libs, redhat-lsb, chkconfig, SysVinit, bind-libs
+Requires(postun): e2fsprogs, bind-utils, net-tools
+
Conflicts: openwbem
Provides: tog-pegasus-cimserver
-BuildRequires: openssl-devel >= 0.9.6
BuildConflicts: tog-pegasus
%description
@@ -18,3 +43,5 @@ increased control of enterprise resources. WBEM is a platform and resource
independent DMTF standard that defines a common information model and
communication protocol for monitoring and controlling resources from diverse
sources.
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-intro.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-packages.spec b/rpm/tog-specfiles/tog-pegasus-packages.spec
index 759e3c6..5d4e9cd 100644
--- a/rpm/tog-specfiles/tog-pegasus-packages.spec
+++ b/rpm/tog-specfiles/tog-pegasus-packages.spec
@@ -1,23 +1,25 @@
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
+#
%package devel
Summary: The OpenPegasus Software Development Kit
Group: Systems Management/Base
-Autoreq: 0
Requires: tog-pegasus >= %{version}
Obsoletes: tog-pegasus-sdk
%description devel
-The OpenPegasus WBEM Services for Linux SDK is the developer's kit for the OpenPegasus WBEM
-Services for Linux release. It provides Linux C++ developers with the WBEM files required to
-build WBEM Clients and Providers. It also supports C provider developers via the CMPI interface.
+The OpenPegasus WBEM Services for Linux SDK is the developer's kit for the
+OpenPegasus WBEM Services for Linux release. It provides Linux C++ developers
+with the WBEM files required to build WBEM Clients and Providers. It also
+supports C provider developers via the CMPI interface.
%if %{PEGASUS_BUILD_TEST_RPM}
%package test
Summary: The OpenPegasus Tests
Group: Systems Management/Base
-Autoreq: 0
Requires: tog-pegasus >= %{version}
%description test
The OpenPegasus WBEM tests for the OpenPegasus %{version} Linux rpm.
%endif
-
+#
+#End of section pegasus/rpm/tog-specfiles/tog-pegasus-packages.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-post.spec b/rpm/tog-specfiles/tog-pegasus-post.spec
index ce97b10..54d4f6c 100644
--- a/rpm/tog-specfiles/tog-pegasus-post.spec
+++ b/rpm/tog-specfiles/tog-pegasus-post.spec
@@ -1,67 +1,25 @@
-
- # Create OpenSSL Configuration File (ssl.cnf)
- #
- if [ -f %PEGASUS_CONFIG_DIR/ssl.cnf ]
- then
- echo "WARNING: %PEGASUS_CONFIG_DIR/ssl.cnf already exists."
- else
- echo " Generating SSL Certificate..."
- echo "[ req ]" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "distinguished_name = req_distinguished_name" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "prompt = no" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "[ req_distinguished_name ]" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "C = UK" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "ST = Berkshire" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "L = Reading" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "O = The Open Group" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "OU = The OpenPegasus Project" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- echo "CN = `host \`hostname\`|cut -d\" \" -f1`" >> %PEGASUS_CONFIG_DIR/ssl.cnf
- chmod 400 %PEGASUS_CONFIG_DIR/ssl.cnf
- chown root %PEGASUS_CONFIG_DIR/ssl.cnf
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
+#
+# install remove upgrade reinstall
+# %post 1 - 2 2
+#
+ if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
+ # Running Repository Upgrade utility
+ %PEGASUS_SBIN_DIR/repupgrade %PEGASUS_PREV_REPOSITORY_DIR \
+ %PEGASUS_REPOSITORY_DIR 2>>%PEGASUS_INSTALL_LOG
+ /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
+ %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
+ %PEGASUS_PREV_REPOSITORY_DIR_NAME
+ rm -rf %PEGASUS_PREV_REPOSITORY_DIR
fi
-
- %OPENSSL_BIN/openssl req -x509 -days 3650 -newkey rsa:2048 \
- -nodes -config %PEGASUS_CONFIG_DIR/ssl.cnf \
- -keyout %PEGASUS_PEM_DIR/key.pem -out %PEGASUS_PEM_DIR/cert.pem \
- 2>>%PEGASUS_INSTALL_LOG
-
- cat %PEGASUS_PEM_DIR/key.pem > %PEGASUS_PEM_DIR/key-2048.pem
- chmod 400 %PEGASUS_PEM_DIR/key-2048.pem
- cat %PEGASUS_PEM_DIR/cert.pem > %PEGASUS_PEM_DIR/cert-2048.pem
- chmod 400 %PEGASUS_PEM_DIR/cert-2048.pem
- cat %PEGASUS_PEM_DIR/cert.pem > %PEGASUS_PEM_DIR/truststore-2048.pem
- chmod 400 %PEGASUS_PEM_DIR/truststore-2048.pem
- rm -f %PEGASUS_PEM_DIR/key.pem %PEGASUS_PEM_DIR/cert.pem
-
- if [ -f %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE ]
- then
- echo "WARNING: %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE SSL Certificate file already exists."
- else
- cp %PEGASUS_PEM_DIR/cert-2048.pem %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE
- chmod 444 %PEGASUS_PEM_DIR/%PEGASUS_SSL_CERT_FILE
- cp %PEGASUS_PEM_DIR/key-2048.pem %PEGASUS_PEM_DIR/%PEGASUS_SSL_KEY_FILE
- chmod 400 %PEGASUS_PEM_DIR/%PEGASUS_SSL_KEY_FILE
+ if [ $1 -eq 1 ]; then
+%if %{AUTOSTART}
+ /sbin/chkconfig --add tog-pegasus
+%endif
+ :;
+ elif [ $1 -gt 0 ]; then
+ /sbin/service tog-pegasus condrestart
+ :;
fi
-
- if [ -f %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE ]
- then
- echo "WARNING: %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE SSL Certificate trust store already exists."
- else
- cp %PEGASUS_PEM_DIR/truststore-2048.pem %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE
- chmod 444 %PEGASUS_PEM_DIR/%PEGASUS_SSL_TRUSTSTORE
- fi
- if [[ -d %PEGASUS_PREV_REPOSITORY_DIR ]]
- then
- # Running Repository Upgrade utility
- %PEGASUS_SBIN_DIR/repupgrade %PEGASUS_PREV_REPOSITORY_DIR %PEGASUS_REPOSITORY_DIR 2>>%PEGASUS_INSTALL_LOG
- fi
-
-
- /usr/lib/lsb/install_initd /etc/init.d/tog-pegasus
-
- echo " To start Pegasus manually:"
- echo " /etc/init.d/tog-pegasus start"
- echo " Stop it:"
- echo " /etc/init.d/tog-pegasus stop"
- echo " To set up PATH and MANPATH in /etc/profile"
- echo " run /opt/tog-pegasus/sbin/settogpath."
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-post.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-postun.spec b/rpm/tog-specfiles/tog-pegasus-postun.spec
new file mode 100644
index 0000000..7ba790e
--- /dev/null
+++ b/rpm/tog-specfiles/tog-pegasus-postun.spec
@@ -0,0 +1,10 @@
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
+#
+# install remove upgrade reinstall
+# postun - 0 1 -
+if [ $1 -eq 0 ]; then
+ /usr/sbin/userdel pegasus > /dev/null 2>&1 || :;
+ /usr/sbin/groudel pegasus > /dev/null 2>&1 || :;
+fi;
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-postun.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-pre.spec b/rpm/tog-specfiles/tog-pegasus-pre.spec
index 0006294..0b08def 100644
--- a/rpm/tog-specfiles/tog-pegasus-pre.spec
+++ b/rpm/tog-specfiles/tog-pegasus-pre.spec
@@ -1,15 +1,31 @@
-if [ -d %PEGASUS_REPOSITORY_DIR"/root#PG_Internal" ]
-then
- #
- # Save the current repository to prev_repository
- #
- if [[ -d %PEGASUS_REPOSITORY_DIR ]]
- then
- if [[ -d %PEGASUS_PREV_REPOSITORY_DIR ]]
- then
- mv %PEGASUS_PREV_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.rpmsave;
- fi
- mv %PEGASUS_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR
- mkdir %PEGASUS_REPOSITORY_DIR
- fi
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
+# install remove upgrade reinstall
+# pre 1 - 2 2
+#
+# If it exists, the active OpenPegasus Repository
+# directory, %PEGASUS_REPOSITORY_DIR is renamed
+# to %PEGASUS_PREV_REPOSITORY_DIR. If
+# %PEGASUS_PREV_REPOSITORY_DIR already exists,
+# it is saved as an archive file.
+
+if [ -d %PEGASUS_REPOSITORY_DIR"/root#PG_Internal" ]; then
+ #
+ # Save the current repository to prev_repository
+ #
+ if [ -d %PEGASUS_PREV_REPOSITORY_DIR ]; then
+ /bin/tar -C %PEGASUS_REPOSITORY_PARENT_DIR -cf \
+ %PEGASUS_PREV_REPOSITORY_DIR`date '+%Y-%m-%d-%s.%N'`.tar \
+ %PEGASUS_PREV_REPOSITORY_DIR_NAME
+ rm -rf %PEGASUS_PREV_REPOSITORY_DIR
+ fi
+ /bin/mv %PEGASUS_REPOSITORY_DIR %PEGASUS_PREV_REPOSITORY_DIR
fi
+if [ $1 -eq 1 ]; then
+ # Create the 'pegasus' user and group:
+ /usr/sbin/groupadd pegasus > /dev/null 2>&1 || :;
+ /usr/sbin/useradd -c "tog-pegasus OpenPegasus WBEM/CIM services" \
+ -g pegasus -s /sbin/nologin -r -d %PEGASUS_VARDATA_DIR pegasus \
+ > /dev/null 2>&1 || :;
+fi
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-pre.spec
diff --git a/rpm/tog-specfiles/tog-pegasus-preun.spec b/rpm/tog-specfiles/tog-pegasus-preun.spec
new file mode 100644
index 0000000..50d12bf
--- /dev/null
+++ b/rpm/tog-specfiles/tog-pegasus-preun.spec
@@ -0,0 +1,19 @@
+# Start of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec
+# install remove upgrade reinstall
+# preun - 0 1 -
+if [ $1 -eq 0 ]; then
+ # Check if the cimserver is running
+ isRunning=`ps -el | grep cimserver | grep -v "grep cimserver"`
+ if [ "$isRunning" ]; then
+ %PEGASUS_SBIN_DIR/cimserver -s
+ fi
+ /sbin/chkconfig --del tog-pegasus;
+ rm -f %PEGASUS_VARDATA_DIR/cimserver_current.conf;
+ rm -f %PEGASUS_INSTALL_LOG;
+ [ -d %PEGASUS_REPOSITORY_DIR ] && rm -rf %PEGASUS_REPOSITORY_DIR;
+ [ -d %PEGASUS_VARDATA_CACHE_DIR ] && rm -rf %PEGASUS_VARDATA_CACHE_DIR;
+ rm -f %PEGASUS_LOCAL_DOMAIN_SOCKET_PATH;
+ rm -f %PEGASUS_CIMSERVER_START_FILE;
+fi
+#
+# End of section pegasus/rpm/tog-specfiles/tog-pegasus-preun.spec