[asterisk-scf-commits] asterisk-scf/integration/slice.git branch "sip-auth-hook" created.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Fri Feb 4 09:46:12 CST 2011


branch "sip-auth-hook" has been created
        at  efd8f9ec73bca6cd1b092a390555bad7d41d7b90 (commit)

- Log -----------------------------------------------------------------
commit efd8f9ec73bca6cd1b092a390555bad7d41d7b90
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Fri Feb 4 16:45:16 2011 +0100

    Add an initial version of the basic Hook interface and a SIP
    authentication Extension Point. This all came from the relevant
    wiki pages on wiki.asterisk.org, with some minor modifications
    along the way.

diff --git a/AsteriskSCF/SIP/SIPExtensionPointIf.ice b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
new file mode 100644
index 0000000..dffcd74
--- /dev/null
+++ b/AsteriskSCF/SIP/SIPExtensionPointIf.ice
@@ -0,0 +1,121 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+#include <Ice/BuiltinSequences.ice>
+
+#include <AsteriskSCF/System/Hook/HookIf.ice>
+
+module AsteriskSCF
+{
+
+module SIP
+{
+
+module ExtensionPoint
+{
+
+["suppress"]
+module V1
+{
+
+    dictionary<string, string> ParamDict;
+
+    enum RequestTransport
+    {
+	UDP,
+	TCP,
+	TLS
+    };
+
+    class RequestInfo
+    {
+	// The display name in the From header
+	string fromName;
+	// The URI in the From header
+	string fromURI;
+	// URI parameters in the From header
+	ParamDict fromParams;
+	// The display name in the To header
+	string toName;
+	// The URI in the To header
+	string toURI;
+	// URI parameters in the To header
+	ParamDict toParams;
+	// The request URI
+	string requestURI;
+	// request URI parameters
+	ParamDict requestURIParams;
+	// Source IP address
+	string IPAddr;
+	// Source Port
+	int port;
+	// Transport over which request was received
+	RequestTransport transport;
+    };
+
+    enum DigestAlgorithm
+    {
+	MD5,
+	MD5sess,
+	AKAv1MD5,
+	AKAv1MD5sess,
+	AKAv2MD5,
+	AKAv2MD5sess
+    };
+
+    class DigestChallenge
+    {
+	string username;
+	string password;
+	Ice::StringSeq domain;
+	string realm;
+	Ice::StringSeq nonce;
+	Ice::StringSeq opaque;
+	DigestAlgorithm algorithm;
+    };
+
+    sequence<DigestChallenge> DigestChallengeSeq;
+
+    interface AuthHook
+    {
+	AsteriskSCF::System::Hook::V1::HookResult challengeRequest(RequestInfo info, out DigestChallengeSeq challenges);
+    };
+
+    enum RequestType
+    {
+	DialogEstablishing,
+	NonDialog,
+	InDialog,
+    };
+
+    sequence<RequestType> RequestTypeSeq;
+
+    interface AuthExtensionPoint
+    {
+	AsteriskSCF::System::Hook::V1::HookId addAuthHook(AuthHook *hook, RequestTypeSeq requestTypes);
+	void removeAuthHook(AsteriskSCF::System::Hook::V1::HookId id);
+	void clearAuthHooks();
+    };
+
+}; /* End of module V1 */
+
+}; /* End of module ExtensionPoint */
+
+}; /* End of module SIP */
+
+}; /* End of module AsteriskSCF */
diff --git a/AsteriskSCF/System/Hook/HookIf.ice b/AsteriskSCF/System/Hook/HookIf.ice
new file mode 100644
index 0000000..c9693fa
--- /dev/null
+++ b/AsteriskSCF/System/Hook/HookIf.ice
@@ -0,0 +1,58 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2011, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+module AsteriskSCF
+{
+
+module System
+{
+
+module Hook
+{
+
+module V1
+{
+
+    struct HookId
+    {
+	string id;
+    };
+
+    enum HookStatus
+    {
+	/* Hook successfully processed input/returned result */
+	Succeeded,
+	/* Hook failed to process input or return result */
+	Failed,
+	/* Hook declined to process input and return result */
+	Declined
+    };
+
+    struct HookResult
+    {
+	HookStatus status;
+	string info;
+    };
+
+}; /* End of V1 */
+
+}; /* End of Hook */
+
+}; /* End of System */
+
+}; /* End of AsteriskSCF */

commit 51ea2042feb9c0732d20f43cd83b19e24d36e0ee
Author: Kevin P. Fleming <kpfleming at digium.com>
Date:   Fri Feb 4 16:17:43 2011 +0100

    'ant' complained about a duplicate project name between build.xml
    and install-ice-jar.xml.

diff --git a/install-ice-jar.xml b/install-ice-jar.xml
index 70afb79..d1b2227 100644
--- a/install-ice-jar.xml
+++ b/install-ice-jar.xml
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
-<project name="asterisk-scf-api" default="install-ice"
+<project name="zeroc-ice-api" default="install-ice"
          xmlns:artifact="antlib:org.apache.maven.artifact.ant">
     <property environment="env"/>
     <property name="generated-pom-dir"

commit 1aa6920d1e19c88a347c09cecc38dcd6ea781ed1
Author: David M. Lee <dlee at digium.com>
Date:   Wed Feb 2 13:56:23 2011 -0600

    Extracted Ice.jar installation to its own file.

diff --git a/build.xml b/build.xml
index b6ff105..b2459bb 100644
--- a/build.xml
+++ b/build.xml
@@ -1,3 +1,4 @@
+<?xml version="1.0" encoding="utf-8"?>
 <project name="asterisk-scf-api" default="install"
          xmlns:artifact="antlib:org.apache.maven.artifact.ant">
     <property environment="env"/>
@@ -10,6 +11,8 @@
 
     <property name="mvn.version" value="2.1.1"/>
 
+    <include file="install-ice-jar.xml" as="ice"/>
+
     <taskdef name="slice2java" classpath="${env.ICE_HOME}/lib/ant-ice.jar"
              classname="Slice2JavaTask"/>
 
@@ -19,29 +22,6 @@
              uri="antlib:org.apache.maven.artifact.ant"
              classpathref="maven-ant-tasks.classpath"/>
 
-    <available property="ice-home-set" file="${env.ICE_HOME}"/>
-
-    <target name="fail-if-no-ice-home" unless="ice-home-set">
-        <fail message="ICE_HOME not set correctly (${env.ICE_HOME})"/>
-    </target>
-
-    <target name="get-ice-version" depends="fail-if-no-ice-home">
-        <exec executable="${env.ICE_HOME}/bin/slice2java"
-              outputproperty="ice-version">
-            <arg value="--version"/>
-        </exec>
-        <filter token="ice-version" value="${ice-version}"/>
-    </target>
-
-    <target name="install-ice" depends="get-ice-version"
-            description="Installs ice.jar from ICE_HOME into local Maven repo">
-        <copy file="ice-pom.xml.in" tofile="${generated-pom-dir}/ice-pom.xml"
-              filtering="true" failonerror="true"/>
-        <artifact:pom id="ice-pom" file="${generated-pom-dir}/ice-pom.xml"/>
-        <artifact:install file="${env.ICE_HOME}/lib/ice.jar"
-                          pomrefid="ice-pom"/>
-    </target>
-
     <target name="generate-sources"
             description="Generate .java files from .slice sources">
         <mkdir dir="${slice2java-dir}"/>
@@ -98,7 +78,7 @@
              basedir="${javadoc-dir}"/>
     </target>
 
-    <target name="install" depends="package,get-ice-version"
+    <target name="install" depends="package,ice.get-ice-version"
             description="installs packages into local Maven repo">
         <copy file="pom.xml.in" tofile="${generated-pom-dir}/pom.xml"
               filtering="true" failonerror="true"/>
diff --git a/install-ice-jar.xml b/install-ice-jar.xml
new file mode 100644
index 0000000..70afb79
--- /dev/null
+++ b/install-ice-jar.xml
@@ -0,0 +1,49 @@
+<?xml version="1.0" encoding="utf-8"?>
+<project name="asterisk-scf-api" default="install-ice"
+         xmlns:artifact="antlib:org.apache.maven.artifact.ant">
+    <property environment="env"/>
+    <property name="generated-pom-dir"
+              value="target/tmp/pom"/>
+    <property name="ice.jar" location="${env.ICE_HOME}/lib/Ice.jar"/>
+
+    <property name="mvn.version" value="2.1.1"/>
+
+    <path id="maven-ant-tasks.classpath"
+          path="lib/maven-ant-tasks-${mvn.version}.jar"/>
+    <typedef resource="org/apache/maven/artifact/ant/antlib.xml"
+             uri="antlib:org.apache.maven.artifact.ant"
+             classpathref="maven-ant-tasks.classpath"/>
+
+    <available property="ice-home-set" file="${env.ICE_HOME}"/>
+
+    <target name="fail-if-no-ice-home" unless="ice-home-set">
+        <fail message="ICE_HOME not set correctly (${env.ICE_HOME})"/>
+    </target>
+
+    <target name="get-ice-version" depends="fail-if-no-ice-home">
+        <exec executable="${env.ICE_HOME}/bin/slice2java"
+              outputproperty="ice-version">
+            <arg value="--version"/>
+        </exec>
+        <filter token="ice-version" value="${ice-version}"/>
+    </target>
+
+    <target name="ice-src" depends="fail-if-no-ice-home">
+        <!-- Ice.jar contains the sources.  Extract them to a separate .jar -->
+        <jar destfile="target/Ice-sources.jar">
+            <zipfileset includes="**/*.java" src="${ice.jar}"/>
+        </jar>
+    </target>
+
+    <target name="install-ice" depends="get-ice-version,ice-src"
+            description="Installs ice.jar from ICE_HOME into local Maven repo">
+        <copy file="ice-pom.xml.in" tofile="${generated-pom-dir}/ice-pom.xml"
+              filtering="true" failonerror="true"/>
+        <artifact:pom id="ice-pom" file="${generated-pom-dir}/ice-pom.xml"/>
+        <artifact:install file="${env.ICE_HOME}/lib/Ice.jar"
+                          pomrefid="ice-pom">
+            <attach file="target/Ice-sources.jar" classifier="sources"/>
+        </artifact:install>
+    </target>
+
+</project>

commit 18ffe3f2cda243ea1df79e9bc78c3d4ed15b570c
Author: David M. Lee <dlee at digium.com>
Date:   Thu Jan 20 12:33:27 2011 -0600

    Refactored out several install functions for installation.
    
    * asterisk_scf_component_install - Install a component
    * asterisk_scf_slice_headers_install - Install generated .h files
    * asterisk_scf_slice_install - Install .ice files

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5a85839..8f26841 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -20,10 +20,6 @@ asterisk_scf_component_build_library(asterisk-scf-api)
 set(API_INCLUDE_DIR ${CMAKE_CURRENT_BINARY_DIR}/generated PARENT_SCOPE)
 set(API_SLICE_DIR ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
 
-install(TARGETS asterisk-scf-api
-    LIBRARY DESTINATION ${ASTERISK_SCF_INSTALL_LIB_DIR}
-    RUNTIME DESTINATION ${ASTERISK_SCF_INSTALL_BIN_DIR})
-install(DIRECTORY AsteriskSCF DESTINATION ${ASTERISK_SCF_INSTALL_SLICE_DIR})
-install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/generated/
-    DESTINATION ${ASTERISK_SCF_INSTALL_INCLUDE_DIR}
-    FILES_MATCHING PATTERN "*.h")
+asterisk_scf_component_install(asterisk-scf-api)
+asterisk_scf_slice_headers_install()
+asterisk_scf_slice_install(AsteriskSCF)

commit a8830da8f9d4452140086a9bbf6f079274d92d46
Author: David M. Lee <dlee at digium.com>
Date:   Thu Jan 20 09:02:27 2011 -0600

    Runtime destination for regular libs should be bindir

diff --git a/CMakeLists.txt b/CMakeLists.txt
index ccbb7fb..5a85839 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -22,7 +22,7 @@ set(API_SLICE_DIR ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
 
 install(TARGETS asterisk-scf-api
     LIBRARY DESTINATION ${ASTERISK_SCF_INSTALL_LIB_DIR}
-    RUNTIME DESTINATION ${ASTERISK_SCF_INSTALL_LIB_DIR})
+    RUNTIME DESTINATION ${ASTERISK_SCF_INSTALL_BIN_DIR})
 install(DIRECTORY AsteriskSCF DESTINATION ${ASTERISK_SCF_INSTALL_SLICE_DIR})
 install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/generated/
     DESTINATION ${ASTERISK_SCF_INSTALL_INCLUDE_DIR}

commit 7df639e3f8ded32acdbf25de960ede9b64d9b481
Author: David M. Lee <dlee at digium.com>
Date:   Mon Jan 17 13:37:25 2011 -0600

    A globbing we will go...

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 41b01d7..ccbb7fb 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -12,29 +12,7 @@ asterisk_scf_component_init(asterisk-scf-api CXX)
 asterisk_scf_slice_include_directories(${CMAKE_CURRENT_SOURCE_DIR})
 
 asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/Core/Discovery/ServiceLocatorEventsIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/Core/Endpoint/EndpointIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/Core/Routing/RoutingIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/Media/MediaIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/Media/RTP/MediaRTPIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/System/Component/ComponentServiceIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/System/Component/ReplicaIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/System/ExceptionsIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/System/Logger/LoggerIf.ice)
-asterisk_scf_component_add_slice(asterisk-scf-api
-    AsteriskSCF/System/Time/TimeIf.ice)
+    GLOB_RECURSE "AsteriskSCF/*.ice")
 
 asterisk_scf_add_ice_libraries(Ice IceUtil)
 asterisk_scf_component_build_library(asterisk-scf-api)

commit 72b1fe6de5982f1e1d97808e4a7c28147fb4ccd6
Author: David M. Lee <dlee at digium.com>
Date:   Mon Jan 17 09:56:36 2011 -0600

    Fixed install problem on Windows.

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6c784aa..41b01d7 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -43,7 +43,8 @@ set(API_INCLUDE_DIR ${CMAKE_CURRENT_BINARY_DIR}/generated PARENT_SCOPE)
 set(API_SLICE_DIR ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
 
 install(TARGETS asterisk-scf-api
-    LIBRARY DESTINATION ${ASTERISK_SCF_INSTALL_LIB_DIR})
+    LIBRARY DESTINATION ${ASTERISK_SCF_INSTALL_LIB_DIR}
+    RUNTIME DESTINATION ${ASTERISK_SCF_INSTALL_LIB_DIR})
 install(DIRECTORY AsteriskSCF DESTINATION ${ASTERISK_SCF_INSTALL_SLICE_DIR})
 install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/generated/
     DESTINATION ${ASTERISK_SCF_INSTALL_INCLUDE_DIR}

commit 0020a940b1c0551b72977d39ab5a90ca9f74276c
Author: David M. Lee <dlee at digium.com>
Date:   Wed Jan 12 13:34:14 2011 -0600

    Building a single API library.

diff --git a/AsteriskSCF/CMakeLists.txt b/AsteriskSCF/CMakeLists.txt
deleted file mode 100644
index cfa7f97..0000000
--- a/AsteriskSCF/CMakeLists.txt
+++ /dev/null
@@ -1,22 +0,0 @@
-#
-# Asterisk Scalable Communications Framework
-#
-# Copyright (C) 2010 -- Digium, Inc.
-#
-# All rights reserved.
-#
-
-# Make all of our slice definitions available to... themselves!
-asterisk_scf_slice_include_directories(${CMAKE_CURRENT_SOURCE_DIR})
-
-# Slice definitions for system infrastructure
-add_subdirectory(System)
-
-# Slice definitions for core functionality
-add_subdirectory(Core)
-
-# Slice definitions for media functionality
-add_subdirectory(Media)
-
-# Slice definitions for session-oriented communications
-add_subdirectory(SessionCommunications)
diff --git a/AsteriskSCF/Core/CMakeLists.txt b/AsteriskSCF/Core/CMakeLists.txt
deleted file mode 100644
index fd4994c..0000000
--- a/AsteriskSCF/Core/CMakeLists.txt
+++ /dev/null
@@ -1,9 +0,0 @@
-# Slice definitions for Discovery functionality
-add_subdirectory(Discovery)
-
-# Slice definitions for Endpoint functionality
-add_subdirectory(Endpoint)
-
-# Slice definitions for Routing functionality
-add_subdirectory(Routing)
-
diff --git a/AsteriskSCF/Core/Discovery/CMakeLists.txt b/AsteriskSCF/Core/Discovery/CMakeLists.txt
deleted file mode 100644
index 3412680..0000000
--- a/AsteriskSCF/Core/Discovery/CMakeLists.txt
+++ /dev/null
@@ -1,5 +0,0 @@
-# Compile our service locator slice definition so we can then use it
-asterisk_scf_compile_slice(ServiceLocatorIf.ice lib "Slice Defined API" Core)
-
-# Can't forget about events
-asterisk_scf_compile_slice(ServiceLocatorEventsIf.ice lib "Slice Defined API" Core)
diff --git a/AsteriskSCF/Core/Endpoint/CMakeLists.txt b/AsteriskSCF/Core/Endpoint/CMakeLists.txt
deleted file mode 100644
index 4695acf..0000000
--- a/AsteriskSCF/Core/Endpoint/CMakeLists.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-# Compile routing service API
-asterisk_scf_compile_slice(EndpointIf.ice lib "Endpoint API" Core)
-
-
diff --git a/AsteriskSCF/Core/Routing/CMakeLists.txt b/AsteriskSCF/Core/Routing/CMakeLists.txt
deleted file mode 100644
index 9e39749..0000000
--- a/AsteriskSCF/Core/Routing/CMakeLists.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-# Compile routing service API
-asterisk_scf_compile_slice(RoutingIf.ice lib "Routing Service API" Core)
-
-
diff --git a/AsteriskSCF/Media/CMakeLists.txt b/AsteriskSCF/Media/CMakeLists.txt
deleted file mode 100644
index 3092e18..0000000
--- a/AsteriskSCF/Media/CMakeLists.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-asterisk_scf_compile_slice(MediaIf.ice lib "Slice Defined API" Core)
-
-add_subdirectory(RTP)
diff --git a/AsteriskSCF/Media/RTP/CMakeLists.txt b/AsteriskSCF/Media/RTP/CMakeLists.txt
deleted file mode 100644
index 0b9ce82..0000000
--- a/AsteriskSCF/Media/RTP/CMakeLists.txt
+++ /dev/null
@@ -1 +0,0 @@
-asterisk_scf_compile_slice(MediaRTPIf.ice lib "RTP Media API" Core)
diff --git a/AsteriskSCF/SessionCommunications/CMakeLists.txt b/AsteriskSCF/SessionCommunications/CMakeLists.txt
deleted file mode 100644
index f7324d6..0000000
--- a/AsteriskSCF/SessionCommunications/CMakeLists.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-# Compile Session Oriented APIs
-asterisk_scf_compile_slice(SessionCommunicationsIf.ice lib "Session Oriented Communications API" SessionCommunications)
diff --git a/AsteriskSCF/System/CMakeLists.txt b/AsteriskSCF/System/CMakeLists.txt
deleted file mode 100644
index 5f01e53..0000000
--- a/AsteriskSCF/System/CMakeLists.txt
+++ /dev/null
@@ -1,10 +0,0 @@
-# Slice definitions for Component functionality
-add_subdirectory(Component)
-
-# Slice definitions for Time services functionality
-add_subdirectory(Time)
-
-# Slice definitions for the Logger service
-add_subdirectory(Logger)
-
-asterisk_scf_compile_slice(ExceptionsIf.ice lib "System-wide Exceptions" System)
diff --git a/AsteriskSCF/System/Component/CMakeLists.txt b/AsteriskSCF/System/Component/CMakeLists.txt
deleted file mode 100644
index c68f74d..0000000
--- a/AsteriskSCF/System/Component/CMakeLists.txt
+++ /dev/null
@@ -1,3 +0,0 @@
-# Compile Component API
-asterisk_scf_compile_slice(ComponentServiceIf.ice lib "ComponentService API" System)
-asterisk_scf_compile_slice(ReplicaIf.ice lib "ComponentService API" System)
diff --git a/AsteriskSCF/System/Logger/CMakeLists.txt b/AsteriskSCF/System/Logger/CMakeLists.txt
deleted file mode 100644
index 8453c03..0000000
--- a/AsteriskSCF/System/Logger/CMakeLists.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-# Compile Time API
-asterisk_scf_compile_slice(LoggerIf.ice lib "Logger service API" System)
diff --git a/AsteriskSCF/System/Time/CMakeLists.txt b/AsteriskSCF/System/Time/CMakeLists.txt
deleted file mode 100644
index bf732cb..0000000
--- a/AsteriskSCF/System/Time/CMakeLists.txt
+++ /dev/null
@@ -1,2 +0,0 @@
-# Compile Time API
-asterisk_scf_compile_slice(TimeIf.ice lib "Time services API" System)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 8049668..6c784aa 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,8 +6,45 @@
 # All rights reserved.
 #
 
+asterisk_scf_component_init(asterisk-scf-api CXX)
+
 # Make all of our slice definitions available to... themselves!
 asterisk_scf_slice_include_directories(${CMAKE_CURRENT_SOURCE_DIR})
 
-# Slice definitions for system infrastructure
-add_subdirectory(AsteriskSCF)
\ No newline at end of file
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/Core/Discovery/ServiceLocatorEventsIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/Core/Endpoint/EndpointIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/Core/Routing/RoutingIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/Media/MediaIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/Media/RTP/MediaRTPIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/System/Component/ComponentServiceIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/System/Component/ReplicaIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/System/ExceptionsIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/System/Logger/LoggerIf.ice)
+asterisk_scf_component_add_slice(asterisk-scf-api
+    AsteriskSCF/System/Time/TimeIf.ice)
+
+asterisk_scf_add_ice_libraries(Ice IceUtil)
+asterisk_scf_component_build_library(asterisk-scf-api)
+
+set(API_INCLUDE_DIR ${CMAKE_CURRENT_BINARY_DIR}/generated PARENT_SCOPE)
+set(API_SLICE_DIR ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE)
+
+install(TARGETS asterisk-scf-api
+    LIBRARY DESTINATION ${ASTERISK_SCF_INSTALL_LIB_DIR})
+install(DIRECTORY AsteriskSCF DESTINATION ${ASTERISK_SCF_INSTALL_SLICE_DIR})
+install(DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/generated/
+    DESTINATION ${ASTERISK_SCF_INSTALL_INCLUDE_DIR}
+    FILES_MATCHING PATTERN "*.h")

commit 968acad3916e463eac055f832288c990fd15ef11
Author: Ken Hunt <ken.hunt at digium.com>
Date:   Fri Jan 7 15:00:40 2011 -0600

    Adjust #includes to use <> and prefix paths with AsteriskSCF.

diff --git a/CMakeLists.txt b/AsteriskSCF/CMakeLists.txt
similarity index 100%
copy from CMakeLists.txt
copy to AsteriskSCF/CMakeLists.txt
diff --git a/Core/CMakeLists.txt b/AsteriskSCF/Core/CMakeLists.txt
similarity index 99%
rename from Core/CMakeLists.txt
rename to AsteriskSCF/Core/CMakeLists.txt
index 710a8b9..fd4994c 100644
--- a/Core/CMakeLists.txt
+++ b/AsteriskSCF/Core/CMakeLists.txt
@@ -6,3 +6,4 @@ add_subdirectory(Endpoint)
 
 # Slice definitions for Routing functionality
 add_subdirectory(Routing)
+
diff --git a/Core/Discovery/CMakeLists.txt b/AsteriskSCF/Core/Discovery/CMakeLists.txt
similarity index 100%
rename from Core/Discovery/CMakeLists.txt
rename to AsteriskSCF/Core/Discovery/CMakeLists.txt
diff --git a/Core/Discovery/ServiceLocatorEventsIf.ice b/AsteriskSCF/Core/Discovery/ServiceLocatorEventsIf.ice
similarity index 100%
rename from Core/Discovery/ServiceLocatorEventsIf.ice
rename to AsteriskSCF/Core/Discovery/ServiceLocatorEventsIf.ice
diff --git a/Core/Discovery/ServiceLocatorIf.ice b/AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice
similarity index 100%
rename from Core/Discovery/ServiceLocatorIf.ice
rename to AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice
diff --git a/Core/Endpoint/CMakeLists.txt b/AsteriskSCF/Core/Endpoint/CMakeLists.txt
similarity index 100%
rename from Core/Endpoint/CMakeLists.txt
rename to AsteriskSCF/Core/Endpoint/CMakeLists.txt
diff --git a/Core/Endpoint/EndpointIf.ice b/AsteriskSCF/Core/Endpoint/EndpointIf.ice
similarity index 100%
rename from Core/Endpoint/EndpointIf.ice
rename to AsteriskSCF/Core/Endpoint/EndpointIf.ice
diff --git a/Core/Routing/CMakeLists.txt b/AsteriskSCF/Core/Routing/CMakeLists.txt
similarity index 100%
rename from Core/Routing/CMakeLists.txt
rename to AsteriskSCF/Core/Routing/CMakeLists.txt
diff --git a/Core/Routing/RoutingIf.ice b/AsteriskSCF/Core/Routing/RoutingIf.ice
similarity index 99%
rename from Core/Routing/RoutingIf.ice
rename to AsteriskSCF/Core/Routing/RoutingIf.ice
index d4edf9c..4dc6993 100644
--- a/Core/Routing/RoutingIf.ice
+++ b/AsteriskSCF/Core/Routing/RoutingIf.ice
@@ -16,7 +16,7 @@
 
 #pragma once
 
-#include <Core/Endpoint/EndpointIf.ice>
+#include <AsteriskSCF/Core/Endpoint/EndpointIf.ice>
 
 module AsteriskSCF
 {
diff --git a/Media/CMakeLists.txt b/AsteriskSCF/Media/CMakeLists.txt
similarity index 100%
rename from Media/CMakeLists.txt
rename to AsteriskSCF/Media/CMakeLists.txt
diff --git a/Media/MediaIf.ice b/AsteriskSCF/Media/MediaIf.ice
similarity index 99%
rename from Media/MediaIf.ice
rename to AsteriskSCF/Media/MediaIf.ice
index efcc982..59e1846 100644
--- a/Media/MediaIf.ice
+++ b/AsteriskSCF/Media/MediaIf.ice
@@ -17,7 +17,7 @@
 #pragma once
 
 #include <Ice/BuiltinSequences.ice>
-#include <Core/Discovery/ServiceLocatorIf.ice>
+#include <AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice>
 
 module AsteriskSCF
 {
diff --git a/Media/RTP/CMakeLists.txt b/AsteriskSCF/Media/RTP/CMakeLists.txt
similarity index 100%
rename from Media/RTP/CMakeLists.txt
rename to AsteriskSCF/Media/RTP/CMakeLists.txt
diff --git a/Media/RTP/MediaRTPIf.ice b/AsteriskSCF/Media/RTP/MediaRTPIf.ice
similarity index 97%
rename from Media/RTP/MediaRTPIf.ice
rename to AsteriskSCF/Media/RTP/MediaRTPIf.ice
index 816dfc6..3bad522 100644
--- a/Media/RTP/MediaRTPIf.ice
+++ b/AsteriskSCF/Media/RTP/MediaRTPIf.ice
@@ -14,8 +14,8 @@
  * at the top of the source tree.
  */
 
-#include <Core/Discovery/ServiceLocatorIf.ice>
-#include <Media/MediaIf.ice>
+#include <AsteriskSCF/Core/Discovery/ServiceLocatorIf.ice>
+#include <AsteriskSCF/Media/MediaIf.ice>
 
 module AsteriskSCF
 {
diff --git a/SessionCommunications/CMakeLists.txt b/AsteriskSCF/SessionCommunications/CMakeLists.txt
similarity index 100%
rename from SessionCommunications/CMakeLists.txt
rename to AsteriskSCF/SessionCommunications/CMakeLists.txt
diff --git a/SessionCommunications/SessionCommunicationsIf.ice b/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
similarity index 98%
rename from SessionCommunications/SessionCommunicationsIf.ice
rename to AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
index 92a7642..614479c 100644
--- a/SessionCommunications/SessionCommunicationsIf.ice
+++ b/AsteriskSCF/SessionCommunications/SessionCommunicationsIf.ice
@@ -16,11 +16,11 @@
 
 #pragma once
 
-#include <Core/Endpoint/EndpointIf.ice>
-#include <Core/Routing/RoutingIf.ice>
-#include <System/Component/ComponentServiceIf.ice>
-#include <System/Time/TimeIf.ice>
-#include <Media/MediaIf.ice>
+#include <AsteriskSCF/Core/Endpoint/EndpointIf.ice>
+#include <AsteriskSCF/Core/Routing/RoutingIf.ice>
+#include <AsteriskSCF/System/Component/ComponentServiceIf.ice>
+#include <AsteriskSCF/System/Time/TimeIf.ice>
+#include <AsteriskSCF/Media/MediaIf.ice>
 
 module AsteriskSCF
 {
diff --git a/System/CMakeLists.txt b/AsteriskSCF/System/CMakeLists.txt
similarity index 100%
rename from System/CMakeLists.txt
rename to AsteriskSCF/System/CMakeLists.txt
diff --git a/System/Component/CMakeLists.txt b/AsteriskSCF/System/Component/CMakeLists.txt
similarity index 100%
rename from System/Component/CMakeLists.txt
rename to AsteriskSCF/System/Component/CMakeLists.txt
diff --git a/System/Component/ComponentServiceIf.ice b/AsteriskSCF/System/Component/ComponentServiceIf.ice
similarity index 100%
rename from System/Component/ComponentServiceIf.ice
rename to AsteriskSCF/System/Component/ComponentServiceIf.ice
diff --git a/System/Component/ReplicaIf.ice b/AsteriskSCF/System/Component/ReplicaIf.ice
similarity index 98%
rename from System/Component/ReplicaIf.ice
rename to AsteriskSCF/System/Component/ReplicaIf.ice
index 6151454..4164b7a 100644
--- a/System/Component/ReplicaIf.ice
+++ b/AsteriskSCF/System/Component/ReplicaIf.ice
@@ -16,7 +16,7 @@
 
 #pragma once
 
-#include <System/Component/ComponentServiceIf.ice>
+#include <AsteriskSCF/System/Component/ComponentServiceIf.ice>
 
 module AsteriskSCF
 {
diff --git a/System/ExceptionsIf.ice b/AsteriskSCF/System/ExceptionsIf.ice
similarity index 100%
rename from System/ExceptionsIf.ice
rename to AsteriskSCF/System/ExceptionsIf.ice
diff --git a/System/Logger/CMakeLists.txt b/AsteriskSCF/System/Logger/CMakeLists.txt
similarity index 100%
rename from System/Logger/CMakeLists.txt
rename to AsteriskSCF/System/Logger/CMakeLists.txt
diff --git a/System/Logger/LoggerIf.ice b/AsteriskSCF/System/Logger/LoggerIf.ice
similarity index 100%
rename from System/Logger/LoggerIf.ice
rename to AsteriskSCF/System/Logger/LoggerIf.ice
diff --git a/System/Time/CMakeLists.txt b/AsteriskSCF/System/Time/CMakeLists.txt
similarity index 100%
rename from System/Time/CMakeLists.txt
rename to AsteriskSCF/System/Time/CMakeLists.txt
diff --git a/System/Time/TimeIf.ice b/AsteriskSCF/System/Time/TimeIf.ice
similarity index 100%
rename from System/Time/TimeIf.ice
rename to AsteriskSCF/System/Time/TimeIf.ice
diff --git a/CMakeLists.txt b/CMakeLists.txt
index cfa7f97..8049668 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -10,13 +10,4 @@
 asterisk_scf_slice_include_directories(${CMAKE_CURRENT_SOURCE_DIR})
 
 # Slice definitions for system infrastructure
-add_subdirectory(System)
-
-# Slice definitions for core functionality
-add_subdirectory(Core)
-
-# Slice definitions for media functionality
-add_subdirectory(Media)
-
-# Slice definitions for session-oriented communications
-add_subdirectory(SessionCommunications)
+add_subdirectory(AsteriskSCF)
\ No newline at end of file

commit b2c1ccb92363ec8e99d295843b6529efd73e0a03
Author: Brent Eagles <beagles at digium.com>
Date:   Mon Jan 3 16:10:51 2011 -0330

    Adding a Slice file for system-wide exceptions and add slice file to
    CMakeLists.txt

diff --git a/System/CMakeLists.txt b/System/CMakeLists.txt
index 705b63a..5f01e53 100644
--- a/System/CMakeLists.txt
+++ b/System/CMakeLists.txt
@@ -6,3 +6,5 @@ add_subdirectory(Time)
 
 # Slice definitions for the Logger service
 add_subdirectory(Logger)
+
+asterisk_scf_compile_slice(ExceptionsIf.ice lib "System-wide Exceptions" System)
diff --git a/System/ExceptionsIf.ice b/System/ExceptionsIf.ice
new file mode 100644
index 0000000..fc57441
--- /dev/null
+++ b/System/ExceptionsIf.ice
@@ -0,0 +1,38 @@
+/*
+ * Asterisk SCF -- An open-source communications framework.
+ *
+ * Copyright (C) 2010, Digium, Inc.
+ *
+ * See http://www.asterisk.org for more information about
+ * the Asterisk SCF project. Please do not directly contact
+ * any of the maintainers of this project for assistance;
+ * the project provides a web site, mailing lists and IRC
+ * channels for your use.
+ *
+ * This program is free software, distributed under the terms of
+ * the GNU General Public License Version 2. See the LICENSE.txt file
+ * at the top of the source tree.
+ */
+
+#pragma once
+
+module AsteriskSCF
+{
+
+module System
+{
+
+module V1
+{
+    /** 
+     * Exception thrown when a "null" proxy is passed in where it is invalid to do so.
+     **/
+    exception NullProxyException
+    {
+    };
+
+}; /*  End of V1 */
+
+}; /*  End of System */
+
+}; /*  End of AsteriskSCF */

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/slice.git



More information about the asterisk-scf-commits mailing list