summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan Synacek <jsynacek@redhat.com>2013-07-26 10:33:03 +0200
committerJan Synacek <jsynacek@redhat.com>2013-07-26 12:00:39 +0200
commite5c8ae992dfaff13a1d29624464cce935373c0fb (patch)
tree8f57de618c559f00e78d099867879c0a1b280743
parent1105d99b1ff631935140809047b9eb9684c712e0 (diff)
downloadopenlmi-providers-e5c8ae992dfaff13a1d29624464cce935373c0fb.tar.gz
openlmi-providers-e5c8ae992dfaff13a1d29624464cce935373c0fb.tar.xz
openlmi-providers-e5c8ae992dfaff13a1d29624464cce935373c0fb.zip
realmd: add profile registration and class versioning in mof
-rw-r--r--mof/60_LMI_Realmd.mof6
-rw-r--r--openlmi-providers.spec9
-rw-r--r--src/realmd/90_LMI_Realmd_Profile.mof.skel20
-rw-r--r--src/realmd/CMakeLists.txt4
4 files changed, 37 insertions, 2 deletions
diff --git a/mof/60_LMI_Realmd.mof b/mof/60_LMI_Realmd.mof
index 696a1e6..ef371d6 100644
--- a/mof/60_LMI_Realmd.mof
+++ b/mof/60_LMI_Realmd.mof
@@ -1,4 +1,5 @@
-[ Description (
+[ Version("0.1.0"),
+ Description (
"Access to the Realmd Service. "
"Realmd is used to discover realms available for joining as well as "
"providing a mechanism for joining and leaving a realm."),
@@ -67,7 +68,8 @@ class LMI_RealmdService : CIM_Service
string OptionValues[]);
};
-[ Association,
+[ Version("0.1.0"),
+ Association,
Provider("cmpi:cmpiLMI_Realmd") ]
class LMI_HostedRealmdService: CIM_HostedService
{
diff --git a/openlmi-providers.spec b/openlmi-providers.spec
index 91149b1..b1fe5b5 100644
--- a/openlmi-providers.spec
+++ b/openlmi-providers.spec
@@ -495,6 +495,9 @@ if [ "$1" -gt 1 ]; then
%{_datadir}/%{name}/60_LMI_Realmd.mof \
%{_datadir}/%{name}/60_LMI_Realmd.reg \
> /dev/null 2>&1 || :;
+ %{_bindir}/openlmi-mof-register --just-mofs -n root/interop unregister \
+ %{_datadir}/%{name}/90_LMI_Realmd_Profile.mof \
+ > /dev/null 2>&1 || :;
fi
@@ -590,6 +593,9 @@ if [ "$1" -gt 1 ]; then
%{_datadir}/%{name}/60_LMI_Realmd.mof \
%{_datadir}/%{name}/60_LMI_Realmd.reg \
> /dev/null 2>&1 || :;
+ %{_bindir}/openlmi-mof-register --just-mofs -n root/interop register \
+ %{_datadir}/%{name}/90_LMI_Realmd_Profile.mof \
+ > /dev/null 2>&1 || :;
fi
%post -n openlmi-hardware
@@ -683,6 +689,9 @@ if [ "$1" -gt 1 ]; then
%{_datadir}/%{name}/60_LMI_Realmd.mof \
%{_datadir}/%{name}/60_LMI_Realmd.reg \
> /dev/null 2>&1 || :;
+ %{_bindir}/openlmi-mof-register --just-mofs -n root/interop unregister \
+ %{_datadir}/%{name}/90_LMI_Realmd_Profile.mof \
+ > /dev/null 2>&1 || :;
fi
%preun -n openlmi-hardware
diff --git a/src/realmd/90_LMI_Realmd_Profile.mof.skel b/src/realmd/90_LMI_Realmd_Profile.mof.skel
new file mode 100644
index 0000000..4b08cfc
--- /dev/null
+++ b/src/realmd/90_LMI_Realmd_Profile.mof.skel
@@ -0,0 +1,20 @@
+instance of PG_ProviderProfileCapabilities
+{
+ CapabilityID = "@CLASS@";
+
+ ProviderModuleName = "cmpiLMI_Realmd";
+
+ ProviderName = "@CLASS@";
+
+ RegisteredProfile = 0;
+
+ OtherRegisteredProfile = "OpenLMI-Realmd";
+ OtherProfileOrganization = "OpenLMI";
+
+ ProfileVersion = "@VERSION@";
+
+ ConformingElements = {
+ "@CLASS@"
+ };
+};
+
diff --git a/src/realmd/CMakeLists.txt b/src/realmd/CMakeLists.txt
index 545933c..4552382 100644
--- a/src/realmd/CMakeLists.txt
+++ b/src/realmd/CMakeLists.txt
@@ -45,4 +45,8 @@ target_link_libraries(${LIBRARY_NAME}
# Create registration file
cim_registration(${PROVIDER_NAME} ${LIBRARY_NAME} ${MOF} share/openlmi-providers)
+set(TARGET_MOF "${CMAKE_BINARY_DIR}/mof/90_LMI_Realmd_Profile.mof")
+profile_mof_generate("90_LMI_Realmd_Profile.mof.skel" "${TARGET_MOF}" "${CIM_CLASSES}")
+
install(TARGETS ${LIBRARY_NAME} DESTINATION lib${LIB_SUFFIX}/cmpi/)
+install(FILES ${TARGET_MOF} DESTINATION share/openlmi-providers/)