[svn-commits] dlee: branch dlee/stasis-http r382463 - in /team/dlee/stasis-http: build_tool...

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Mar 5 12:16:28 CST 2013


Author: dlee
Date: Tue Mar  5 12:16:24 2013
New Revision: 382463

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=382463
Log:
reorg

Added:
    team/dlee/stasis-http/res/stasis_http/
    team/dlee/stasis-http/res/stasis_http/resource_asterisk.c
      - copied, changed from r382407, team/dlee/stasis-http/res/stasis_http_asterisk.c
    team/dlee/stasis-http/res/stasis_http/resource_asterisk.h
      - copied, changed from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_asterisk.h
    team/dlee/stasis-http/res/stasis_http/resource_bridges.c
      - copied, changed from r382407, team/dlee/stasis-http/res/stasis_http_bridges.c
    team/dlee/stasis-http/res/stasis_http/resource_bridges.h
      - copied, changed from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_bridges.h
    team/dlee/stasis-http/res/stasis_http/resource_channels.c
      - copied, changed from r382407, team/dlee/stasis-http/res/stasis_http_channels.c
    team/dlee/stasis-http/res/stasis_http/resource_channels.h
      - copied, changed from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_channels.h
    team/dlee/stasis-http/res/stasis_http/resource_endpoints.c
      - copied, changed from r382407, team/dlee/stasis-http/res/stasis_http_endpoints.c
    team/dlee/stasis-http/res/stasis_http/resource_endpoints.h
      - copied, changed from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_endpoints.h
    team/dlee/stasis-http/res/stasis_http/resource_recordings.c
      - copied, changed from r382407, team/dlee/stasis-http/res/stasis_http_recordings.c
    team/dlee/stasis-http/res/stasis_http/resource_recordings.h
      - copied, changed from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_recordings.h
    team/dlee/stasis-http/res/stasis_http/resources.c
      - copied, changed from r382407, team/dlee/stasis-http/res/stasis_http_resources.c
Removed:
    team/dlee/stasis-http/include/asterisk/stasis_http_asterisk.h
    team/dlee/stasis-http/include/asterisk/stasis_http_bridges.h
    team/dlee/stasis-http/include/asterisk/stasis_http_channels.h
    team/dlee/stasis-http/include/asterisk/stasis_http_endpoints.h
    team/dlee/stasis-http/include/asterisk/stasis_http_recordings.h
    team/dlee/stasis-http/res/stasis_http_asterisk.c
    team/dlee/stasis-http/res/stasis_http_bridges.c
    team/dlee/stasis-http/res/stasis_http_channels.c
    team/dlee/stasis-http/res/stasis_http_endpoints.c
    team/dlee/stasis-http/res/stasis_http_recordings.c
    team/dlee/stasis-http/res/stasis_http_resources.c
Modified:
    team/dlee/stasis-http/build_tools/make_stasis_http_stubs
    team/dlee/stasis-http/cog/res_stasis_http.make.cog
    team/dlee/stasis-http/cog/stasis_cog.py
    team/dlee/stasis-http/res/Makefile
    team/dlee/stasis-http/res/res_stasis_http.make

Modified: team/dlee/stasis-http/build_tools/make_stasis_http_stubs
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/build_tools/make_stasis_http_stubs?view=diff&rev=382463&r1=382462&r2=382463
==============================================================================
--- team/dlee/stasis-http/build_tools/make_stasis_http_stubs (original)
+++ team/dlee/stasis-http/build_tools/make_stasis_http_stubs Tue Mar  5 12:16:24 2013
@@ -25,12 +25,16 @@
 for json in rest-api/*.json; do
     echo "Cogging ${json}"
     name=$(basename ${json} .json)
-    sources="${sources} stasis_http/resource_${name}.o"
+    if test ${name} = resources; then
+	sources="${sources} stasis_http/${name}.o"
+    else
+	sources="${sources} stasis_http/resource_${name}.o"
+    fi
     if test ${name} = resources; then
         ${COG} -I cog/ -D RESOURCES=${json} -d -o res/stasis_http/resources.c cog/stasis_http_resources.c.cog
     else
         ${COG} -I cog/ -D RESOURCE=${json} -d -o res/stasis_http/resource_${name}.h cog/stasis_http_resource.h.cog
-	if ! test -e res/stasis_http/${name}.c; then
+	if ! test -e res/stasis_http/resource_${name}.c; then
 	    # Only write the file if it doesn't exist; otherwise you'll overwrite someone's hard work.
 	    echo "  Generating source stubs"
             ${COG} -I cog/ -D RESOURCE=${json} -d -o res/stasis_http/resource_${name}.c cog/stasis_http_resource.c.cog

Modified: team/dlee/stasis-http/cog/res_stasis_http.make.cog
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/cog/res_stasis_http.make.cog?view=diff&rev=382463&r1=382462&r2=382463
==============================================================================
--- team/dlee/stasis-http/cog/res_stasis_http.make.cog (original)
+++ team/dlee/stasis-http/cog/res_stasis_http.make.cog Tue Mar  5 12:16:24 2013
@@ -19,5 +19,9 @@
 # the GNU General Public License
 #
 
-# [[[cog import cog, stasis_cog; stasis_cog.do_not_edit('#'); cog.outl('%s: %s' % (TARGET, SOURCES))]]]
+# [[[cog
+# import cog, stasis_cog;
+# stasis_cog.do_not_edit('#')
+# cog.outl('%s: %s' % (TARGET, SOURCES))
+# ]]]
 # [[[end]]]

Modified: team/dlee/stasis-http/cog/stasis_cog.py
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/cog/stasis_cog.py?view=diff&rev=382463&r1=382462&r2=382463
==============================================================================
--- team/dlee/stasis-http/cog/stasis_cog.py (original)
+++ team/dlee/stasis-http/cog/stasis_cog.py Tue Mar  5 12:16:24 2013
@@ -230,7 +230,7 @@
         operations.
         """
         (name, ext) = os.path.splitext(os.path.basename(cog.outFile))
-        cog.outl('#include "asterisk/%s.h"' % name)
+        cog.outl('#include "%s.h"' % name)
         cog.outl()
         self.write_impl_stubs(self.root)
 
@@ -313,7 +313,7 @@
                 os.path.join(resource_listing_dir, path)).format(format='json')
             (basename, ext) = os.path.splitext(
                 os.path.basename(api_declaration_file))
-            self.includes.append('stasis_http/resource_%s.h' % basename)
+            self.includes.append('resource_%s.h' % basename)
             self.load_api_declaration(api_declaration_file)
 
     def load_api_declaration(self, api_declaration_file):

Modified: team/dlee/stasis-http/res/Makefile
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/Makefile?view=diff&rev=382463&r1=382462&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/Makefile (original)
+++ team/dlee/stasis-http/res/Makefile Tue Mar  5 12:16:24 2013
@@ -93,4 +93,3 @@
 
 # Dependencies for res_stasis_http.so are generated, so they're in this file
 include res_stasis_http.make
-res_stasis_http.so: stasis_http_resources.o

Modified: team/dlee/stasis-http/res/res_stasis_http.make
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/res_stasis_http.make?view=diff&rev=382463&r1=382462&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/res_stasis_http.make (original)
+++ team/dlee/stasis-http/res/res_stasis_http.make Tue Mar  5 12:16:24 2013
@@ -19,4 +19,4 @@
 # This file is generated by a Cog template. Please see the original template
 # at cog/res_stasis_http.make.cog
 #
-res_stasis_http.so:  stasis_http_asterisk.o stasis_http_bridges.o stasis_http_channels.o stasis_http_endpoints.o stasis_http_recordings.o stasis_http_resources.o
+res_stasis_http.so:  stasis_http/resource_asterisk.o stasis_http/resource_bridges.o stasis_http/resource_channels.o stasis_http/resource_endpoints.o stasis_http/resource_recordings.o stasis_http/resources.o

Copied: team/dlee/stasis-http/res/stasis_http/resource_asterisk.c (from r382407, team/dlee/stasis-http/res/stasis_http_asterisk.c)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_asterisk.c?view=diff&rev=382463&p1=team/dlee/stasis-http/res/stasis_http_asterisk.c&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_asterisk.c&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/stasis_http_asterisk.c (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_asterisk.c Tue Mar  5 12:16:24 2013
@@ -31,7 +31,7 @@
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
-#include "asterisk/stasis_http_asterisk.h"
+#include "resource_asterisk.h"
 
 void stasis_http_get_asterisk_info(struct ast_variable *headers, struct ast_get_asterisk_info_args *args, struct stasis_http_response *response)
 {

Copied: team/dlee/stasis-http/res/stasis_http/resource_asterisk.h (from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_asterisk.h)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_asterisk.h?view=diff&rev=382463&p1=team/dlee/stasis-http/include/asterisk/stasis_http_asterisk.h&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_asterisk.h&r2=382463
==============================================================================
--- team/dlee/stasis-http/include/asterisk/stasis_http_asterisk.h (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_asterisk.h Tue Mar  5 12:16:24 2013
@@ -32,8 +32,8 @@
  * This file is generated by a Cog template. Please see the original template
  * at cog/stasis_http_resource.h.cog
  */
-#ifndef _ASTERISK_STASIS_HTTP_ASTERISK_H
-#define _ASTERISK_STASIS_HTTP_ASTERISK_H
+#ifndef _ASTERISK_RESOURCE_ASTERISK_H
+#define _ASTERISK_RESOURCE_ASTERISK_H
 struct ast_get_asterisk_info_args {
 	/*! Filter information returned */
 	const char *only;
@@ -45,4 +45,4 @@
  * \param[out] response HTTP response
  */
 void stasis_http_get_asterisk_info(struct ast_variable *headers, struct ast_get_asterisk_info_args *args, struct stasis_http_response *response);
-#endif /* _ASTERISK_STASIS_HTTP_ASTERISK_H */
+#endif /* _ASTERISK_RESOURCE_ASTERISK_H */

Copied: team/dlee/stasis-http/res/stasis_http/resource_bridges.c (from r382407, team/dlee/stasis-http/res/stasis_http_bridges.c)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_bridges.c?view=diff&rev=382463&p1=team/dlee/stasis-http/res/stasis_http_bridges.c&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_bridges.c&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/stasis_http_bridges.c (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_bridges.c Tue Mar  5 12:16:24 2013
@@ -31,7 +31,7 @@
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
-#include "asterisk/stasis_http_bridges.h"
+#include "resource_bridges.h"
 
 void stasis_http_add_channel_to_bridge(struct ast_variable *headers, struct ast_add_channel_to_bridge_args *args, struct stasis_http_response *response)
 {

Copied: team/dlee/stasis-http/res/stasis_http/resource_bridges.h (from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_bridges.h)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_bridges.h?view=diff&rev=382463&p1=team/dlee/stasis-http/include/asterisk/stasis_http_bridges.h&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_bridges.h&r2=382463
==============================================================================
--- team/dlee/stasis-http/include/asterisk/stasis_http_bridges.h (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_bridges.h Tue Mar  5 12:16:24 2013
@@ -32,8 +32,8 @@
  * This file is generated by a Cog template. Please see the original template
  * at cog/stasis_http_resource.h.cog
  */
-#ifndef _ASTERISK_STASIS_HTTP_BRIDGES_H
-#define _ASTERISK_STASIS_HTTP_BRIDGES_H
+#ifndef _ASTERISK_RESOURCE_BRIDGES_H
+#define _ASTERISK_RESOURCE_BRIDGES_H
 struct ast_add_channel_to_bridge_args {
 	/*! Bridge's id */
 	const char *bridge_id;
@@ -123,4 +123,4 @@
  * \param[out] response HTTP response
  */
 void stasis_http_new_bridge(struct ast_variable *headers, struct ast_new_bridge_args *args, struct stasis_http_response *response);
-#endif /* _ASTERISK_STASIS_HTTP_BRIDGES_H */
+#endif /* _ASTERISK_RESOURCE_BRIDGES_H */

Copied: team/dlee/stasis-http/res/stasis_http/resource_channels.c (from r382407, team/dlee/stasis-http/res/stasis_http_channels.c)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_channels.c?view=diff&rev=382463&p1=team/dlee/stasis-http/res/stasis_http_channels.c&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_channels.c&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/stasis_http_channels.c (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_channels.c Tue Mar  5 12:16:24 2013
@@ -33,7 +33,7 @@
 
 #include "asterisk/app_stasis.h"
 #include "asterisk/channel.h"
-#include "asterisk/stasis_http_channels.h"
+#include "resource_channels.h"
 
 void stasis_http_dial(struct ast_variable *headers, struct ast_dial_args *args, struct stasis_http_response *response)
 {
@@ -69,7 +69,6 @@
 	response->message = ast_json_pack("{s: s}", "message", "Returned to dialplan");
 	ast_assert(response->message != NULL);
 }
-
 void stasis_http_reject_channel(struct ast_variable *headers, struct ast_reject_channel_args *args, struct stasis_http_response *response)
 {
 	ast_log(LOG_ERROR, "TODO: stasis_http_reject_channel\n");

Copied: team/dlee/stasis-http/res/stasis_http/resource_channels.h (from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_channels.h)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_channels.h?view=diff&rev=382463&p1=team/dlee/stasis-http/include/asterisk/stasis_http_channels.h&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_channels.h&r2=382463
==============================================================================
--- team/dlee/stasis-http/include/asterisk/stasis_http_channels.h (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_channels.h Tue Mar  5 12:16:24 2013
@@ -32,8 +32,8 @@
  * This file is generated by a Cog template. Please see the original template
  * at cog/stasis_http_resource.h.cog
  */
-#ifndef _ASTERISK_STASIS_HTTP_CHANNELS_H
-#define _ASTERISK_STASIS_HTTP_CHANNELS_H
+#ifndef _ASTERISK_RESOURCE_CHANNELS_H
+#define _ASTERISK_RESOURCE_CHANNELS_H
 struct ast_dial_args {
 	/*! Endpoint to call. If not specified, dial is routed via dialplan */
 	const char *endpoint;
@@ -177,4 +177,4 @@
  * \param[out] response HTTP response
  */
 void stasis_http_originate(struct ast_variable *headers, struct ast_originate_args *args, struct stasis_http_response *response);
-#endif /* _ASTERISK_STASIS_HTTP_CHANNELS_H */
+#endif /* _ASTERISK_RESOURCE_CHANNELS_H */

Copied: team/dlee/stasis-http/res/stasis_http/resource_endpoints.c (from r382407, team/dlee/stasis-http/res/stasis_http_endpoints.c)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_endpoints.c?view=diff&rev=382463&p1=team/dlee/stasis-http/res/stasis_http_endpoints.c&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_endpoints.c&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/stasis_http_endpoints.c (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_endpoints.c Tue Mar  5 12:16:24 2013
@@ -31,7 +31,7 @@
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
-#include "asterisk/stasis_http_endpoints.h"
+#include "resource_endpoints.h"
 
 void stasis_http_get_endpoint(struct ast_variable *headers, struct ast_get_endpoint_args *args, struct stasis_http_response *response)
 {

Copied: team/dlee/stasis-http/res/stasis_http/resource_endpoints.h (from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_endpoints.h)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_endpoints.h?view=diff&rev=382463&p1=team/dlee/stasis-http/include/asterisk/stasis_http_endpoints.h&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_endpoints.h&r2=382463
==============================================================================
--- team/dlee/stasis-http/include/asterisk/stasis_http_endpoints.h (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_endpoints.h Tue Mar  5 12:16:24 2013
@@ -32,8 +32,8 @@
  * This file is generated by a Cog template. Please see the original template
  * at cog/stasis_http_resource.h.cog
  */
-#ifndef _ASTERISK_STASIS_HTTP_ENDPOINTS_H
-#define _ASTERISK_STASIS_HTTP_ENDPOINTS_H
+#ifndef _ASTERISK_RESOURCE_ENDPOINTS_H
+#define _ASTERISK_RESOURCE_ENDPOINTS_H
 struct ast_get_endpoint_args {
 	/*! ID of the endpoint */
 	const char *endpoint_id;
@@ -56,4 +56,4 @@
  * \param[out] response HTTP response
  */
 void stasis_http_get_endpoints(struct ast_variable *headers, struct ast_get_endpoints_args *args, struct stasis_http_response *response);
-#endif /* _ASTERISK_STASIS_HTTP_ENDPOINTS_H */
+#endif /* _ASTERISK_RESOURCE_ENDPOINTS_H */

Copied: team/dlee/stasis-http/res/stasis_http/resource_recordings.c (from r382407, team/dlee/stasis-http/res/stasis_http_recordings.c)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_recordings.c?view=diff&rev=382463&p1=team/dlee/stasis-http/res/stasis_http_recordings.c&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_recordings.c&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/stasis_http_recordings.c (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_recordings.c Tue Mar  5 12:16:24 2013
@@ -31,7 +31,7 @@
 
 ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 
-#include "asterisk/stasis_http_recordings.h"
+#include "resource_recordings.h"
 
 void stasis_http_stop_recording(struct ast_variable *headers, struct ast_stop_recording_args *args, struct stasis_http_response *response)
 {

Copied: team/dlee/stasis-http/res/stasis_http/resource_recordings.h (from r382407, team/dlee/stasis-http/include/asterisk/stasis_http_recordings.h)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resource_recordings.h?view=diff&rev=382463&p1=team/dlee/stasis-http/include/asterisk/stasis_http_recordings.h&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resource_recordings.h&r2=382463
==============================================================================
--- team/dlee/stasis-http/include/asterisk/stasis_http_recordings.h (original)
+++ team/dlee/stasis-http/res/stasis_http/resource_recordings.h Tue Mar  5 12:16:24 2013
@@ -32,8 +32,8 @@
  * This file is generated by a Cog template. Please see the original template
  * at cog/stasis_http_resource.h.cog
  */
-#ifndef _ASTERISK_STASIS_HTTP_RECORDINGS_H
-#define _ASTERISK_STASIS_HTTP_RECORDINGS_H
+#ifndef _ASTERISK_RESOURCE_RECORDINGS_H
+#define _ASTERISK_RESOURCE_RECORDINGS_H
 struct ast_stop_recording_args {
 	/*! Recording's id */
 	const char *recording_id;
@@ -120,4 +120,4 @@
  * \param[out] response HTTP response
  */
 void stasis_http_get_recordings(struct ast_variable *headers, struct ast_get_recordings_args *args, struct stasis_http_response *response);
-#endif /* _ASTERISK_STASIS_HTTP_RECORDINGS_H */
+#endif /* _ASTERISK_RESOURCE_RECORDINGS_H */

Copied: team/dlee/stasis-http/res/stasis_http/resources.c (from r382407, team/dlee/stasis-http/res/stasis_http_resources.c)
URL: http://svnview.digium.com/svn/asterisk/team/dlee/stasis-http/res/stasis_http/resources.c?view=diff&rev=382463&p1=team/dlee/stasis-http/res/stasis_http_resources.c&r1=382407&p2=team/dlee/stasis-http/res/stasis_http/resources.c&r2=382463
==============================================================================
--- team/dlee/stasis-http/res/stasis_http_resources.c (original)
+++ team/dlee/stasis-http/res/stasis_http/resources.c Tue Mar  5 12:16:24 2013
@@ -41,11 +41,11 @@
  * This file is generated by a Cog template. Please see the original template
  * at cog/stasis_http_resources.c.cog
  */
-#include "asterisk/stasis_http_asterisk.h"
-#include "asterisk/stasis_http_endpoints.h"
-#include "asterisk/stasis_http_channels.h"
-#include "asterisk/stasis_http_bridges.h"
-#include "asterisk/stasis_http_recordings.h"
+#include "resource_asterisk.h"
+#include "resource_endpoints.h"
+#include "resource_channels.h"
+#include "resource_bridges.h"
+#include "resource_recordings.h"
 #include <inttypes.h>
 #include <strings.h>
 




More information about the svn-commits mailing list