summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristophe Fergeau <cfergeau@redhat.com>2011-07-12 16:49:39 +0200
committerChristophe Fergeau <cfergeau@redhat.com>2011-07-12 16:49:39 +0200
commitd115c1edc1c05b0c025ffe6a1586c907c51d2a53 (patch)
tree11e79878b121da5e01f31801d15ba2f42a300ec1
parentc911aea92e9dd55534c2f9480d72c79255a0cb37 (diff)
adjust to common/ moving to its own module
-rw-r--r--Makefile.am6
-rw-r--r--client/Makefile.am59
-rw-r--r--client/demarshallers.h28
-rw-r--r--client/marshallers.h63
-rw-r--r--configure.ac11
5 files changed, 24 insertions, 143 deletions
diff --git a/Makefile.am b/Makefile.am
index 853ffea..dfe03d1 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,8 +1,4 @@
-SUBDIRS = common server python_modules
-
-if SUPPORT_CLIENT
-SUBDIRS += client
-endif
+SUBDIRS = spice-common client
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = spice-server.pc
diff --git a/client/Makefile.am b/client/Makefile.am
index 2508267..ee881bf 100644
--- a/client/Makefile.am
+++ b/client/Makefile.am
@@ -2,27 +2,6 @@ NULL =
bin_PROGRAMS = spicec
-BUILT_SOURCES = \
- generated_demarshallers.cpp \
- generated_marshallers.cpp \
- generated_demarshallers1.cpp \
- generated_marshallers1.cpp \
- $(NULL)
-
-generated_demarshallers.cpp: $(top_srcdir)/spice.proto
- $(AM_V_GEN)$(PYTHON) $(top_srcdir)/spice_codegen.py --generate-demarshallers --client --include common.h --include messages.h $(top_srcdir)/spice.proto generated_demarshallers.cpp
-
-generated_demarshallers1.cpp: $(top_srcdir)/spice1.proto
- $(AM_V_GEN)$(PYTHON) $(top_srcdir)/spice_codegen.py --generate-demarshallers --client --include common.h --include messages.h --prefix 1 --ptrsize 8 $(top_srcdir)/spice1.proto generated_demarshallers1.cpp
-
-generated_marshallers.cpp: $(top_srcdir)/spice.proto
- $(AM_V_GEN)$(PYTHON) $(top_srcdir)/spice_codegen.py --generate-marshallers -P --include "common.h" --include messages.h --include marshallers.h --client $(top_srcdir)/spice.proto generated_marshallers.cpp
-
-generated_marshallers1.cpp: $(top_srcdir)/spice1.proto
- $(AM_V_GEN)$(PYTHON) $(top_srcdir)/spice_codegen.py --generate-marshallers -P --include "common.h" --include messages.h --include marshallers.h --client --prefix 1 --ptrsize 8 $(top_srcdir)/spice1.proto generated_marshallers1.cpp
-
-MAINTAINERCLEANFILES = $(BUILT_SOURCES)
-
spicec_SOURCES = \
application.cpp \
application.h \
@@ -43,7 +22,6 @@ spicec_SOURCES = \
cursor_channel.cpp \
cursor_channel.h \
debug.h \
- demarshallers.h \
display_channel.cpp \
display_channel.h \
event_sources.h \
@@ -63,7 +41,6 @@ spicec_SOURCES = \
inputs_handler.h \
jpeg_decoder.cpp \
jpeg_decoder.h \
- marshallers.h \
menu.cpp \
menu.h \
mjpeg_decoder.cpp \
@@ -209,29 +186,29 @@ endif
INCLUDES = \
- -D__STDC_LIMIT_MACROS \
- -I$(top_srcdir)/client/x11 \
- -I$(top_srcdir)/common \
- $(ALSA_CFLAGS) \
- $(CEGUI_CFLAGS) \
- $(CEGUI06_CFLAGS) \
- $(CELT051_CFLAGS) \
- $(GL_CFLAGS) \
- $(MISC_X_CFLAGS) \
- $(PIXMAN_CFLAGS) \
- $(PROTOCOL_CFLAGS) \
- $(SPICE_NONPKGCONFIG_CFLAGS) \
- $(SMARTCARD_CFLAGS) \
- $(SSL_CFLAGS) \
- $(XRANDR_CFLAGS) \
- $(XFIXES_CFLAGS) \
- $(WARN_CFLAGS) \
+ -D__STDC_LIMIT_MACROS \
+ -I$(top_srcdir)/client/x11 \
+ -I$(top_srcdir)/spice-common/common \
+ $(ALSA_CFLAGS) \
+ $(CEGUI_CFLAGS) \
+ $(CEGUI06_CFLAGS) \
+ $(CELT051_CFLAGS) \
+ $(GL_CFLAGS) \
+ $(MISC_X_CFLAGS) \
+ $(PIXMAN_CFLAGS) \
+ $(PROTOCOL_CFLAGS) \
+ $(SPICE_NONPKGCONFIG_CFLAGS) \
+ $(SMARTCARD_CFLAGS) \
+ $(SSL_CFLAGS) \
+ $(XRANDR_CFLAGS) \
+ $(XFIXES_CFLAGS) \
+ $(WARN_CFLAGS) \
$(NULL)
spicec_LDFLAGS = $(SPICEC_STATIC_LINKAGE_BSTATIC)
spicec_LDADD = \
- $(top_builddir)/common/libspice-common.la \
+ $(top_builddir)/spice-common/libspice-common.la \
$(ALSA_LIBS) \
$(CEGUI_LIBS) \
$(CEGUI06_LIBS) \
diff --git a/client/demarshallers.h b/client/demarshallers.h
deleted file mode 100644
index fc2f75a..0000000
--- a/client/demarshallers.h
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- Copyright (C) 2010 Red Hat, Inc.
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with this library; if not, see <http://www.gnu.org/licenses/>.
-*/
-#ifndef _H_DEMARSHAL
-#define _H_DEMARSHAL
-
-typedef void (*message_destructor_t)(uint8_t *message);
-typedef uint8_t * (*spice_parse_channel_func_t)(uint8_t *message_start, uint8_t *message_end, uint16_t message_type, int minor,
- size_t *size_out, message_destructor_t *free_message);
-
-spice_parse_channel_func_t spice_get_server_channel_parser(uint32_t channel, unsigned int *max_message_type);
-spice_parse_channel_func_t spice_get_server_channel_parser1(uint32_t channel, unsigned int *max_message_type);
-
-#endif
-
diff --git a/client/marshallers.h b/client/marshallers.h
deleted file mode 100644
index 47faeff..0000000
--- a/client/marshallers.h
+++ /dev/null
@@ -1,63 +0,0 @@
-/* -*- Mode: C; c-basic-offset: 4; indent-tabs-mode: nil -*- */
-/*
- Copyright (C) 2010 Red Hat, Inc.
-
- This library is free software; you can redistribute it and/or
- modify it under the terms of the GNU Lesser General Public
- License as published by the Free Software Foundation; either
- version 2.1 of the License, or (at your option) any later version.
-
- This library is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Lesser General Public License for more details.
-
- You should have received a copy of the GNU Lesser General Public
- License along with this library; if not, see <http://www.gnu.org/licenses/>.
-*/
-
-#ifndef _H_MARSHALLERS
-#define _H_MARSHALLERS
-
-#include <spice/protocol.h>
-#include <marshaller.h>
-#include <messages.h>
-
-typedef struct {
- void (*msg_SpiceMsgEmpty)(SpiceMarshaller *m, SpiceMsgEmpty *msg);
- void (*msg_SpiceMsgData)(SpiceMarshaller *m, SpiceMsgData *msg);
- void (*msg_SpiceMsgAudioVolume)(SpiceMarshaller *m, SpiceMsgAudioVolume *msg);
- void (*msg_SpiceMsgAudioMute)(SpiceMarshaller *m, SpiceMsgAudioMute *msg);
- void (*msgc_ack_sync)(SpiceMarshaller *m, SpiceMsgcAckSync *msg);
- void (*msgc_pong)(SpiceMarshaller *m, SpiceMsgPing *msg);
- void (*msgc_disconnecting)(SpiceMarshaller *m, SpiceMsgDisconnect *msg);
- void (*msgc_main_client_info)(SpiceMarshaller *m, SpiceMsgcClientInfo *msg);
- void (*msgc_main_mouse_mode_request)(SpiceMarshaller *m, SpiceMsgcMainMouseModeRequest *msg);
- void (*msgc_main_agent_start)(SpiceMarshaller *m, SpiceMsgcMainAgentStart *msg);
- void (*msgc_main_agent_token)(SpiceMarshaller *m, SpiceMsgcMainAgentTokens *msg);
- void (*msgc_display_init)(SpiceMarshaller *m, SpiceMsgcDisplayInit *msg);
- void (*msgc_inputs_key_down)(SpiceMarshaller *m, SpiceMsgcKeyDown *msg);
- void (*msgc_inputs_key_up)(SpiceMarshaller *m, SpiceMsgcKeyUp *msg);
- void (*msgc_inputs_key_modifiers)(SpiceMarshaller *m, SpiceMsgcKeyModifiers *msg);
- void (*msgc_inputs_mouse_motion)(SpiceMarshaller *m, SpiceMsgcMouseMotion *msg);
- void (*msgc_inputs_mouse_position)(SpiceMarshaller *m, SpiceMsgcMousePosition *msg);
- void (*msgc_inputs_mouse_press)(SpiceMarshaller *m, SpiceMsgcMousePress *msg);
- void (*msgc_inputs_mouse_release)(SpiceMarshaller *m, SpiceMsgcMouseRelease *msg);
- void (*msgc_record_data)(SpiceMarshaller *m, SpiceMsgcRecordPacket *msg);
- void (*msgc_record_mode)(SpiceMarshaller *m, SpiceMsgcRecordMode *msg);
- void (*msgc_record_start_mark)(SpiceMarshaller *m, SpiceMsgcRecordStartMark *msg);
- void (*msgc_tunnel_service_add)(SpiceMarshaller *m, SpiceMsgcTunnelAddGenericService *msg, SpiceMarshaller **name_out, SpiceMarshaller **description_out);
- void (*msgc_tunnel_service_remove)(SpiceMarshaller *m, SpiceMsgcTunnelRemoveService *msg);
- void (*msgc_tunnel_socket_open_ack)(SpiceMarshaller *m, SpiceMsgcTunnelSocketOpenAck *msg);
- void (*msgc_tunnel_socket_open_nack)(SpiceMarshaller *m, SpiceMsgcTunnelSocketOpenNack *msg);
- void (*msgc_tunnel_socket_fin)(SpiceMarshaller *m, SpiceMsgcTunnelSocketFin *msg);
- void (*msgc_tunnel_socket_closed)(SpiceMarshaller *m, SpiceMsgcTunnelSocketClosed *msg);
- void (*msgc_tunnel_socket_closed_ack)(SpiceMarshaller *m, SpiceMsgcTunnelSocketClosedAck *msg);
- void (*msgc_tunnel_socket_data)(SpiceMarshaller *m, SpiceMsgcTunnelSocketData *msg);
- void (*msgc_tunnel_socket_token)(SpiceMarshaller *m, SpiceMsgcTunnelSocketTokens *msg);
-} SpiceMessageMarshallers;
-
-SpiceMessageMarshallers *spice_message_marshallers_get(void);
-SpiceMessageMarshallers *spice_message_marshallers_get1(void);
-
-#endif
diff --git a/configure.ac b/configure.ac
index c058edd..41d9150 100644
--- a/configure.ac
+++ b/configure.ac
@@ -496,15 +496,14 @@ AC_SUBST([SPICEC_STATIC_LINKAGE_BSTATIC])
m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
+AM_CONDITIONAL([SPICE_CLIENT_BUILD], [true])
+AM_CONDITIONAL([SPICE_SERVER_BUILD], [false])
+AC_SUBST([spice_common_path], [spice-common])
+
AC_OUTPUT([
Makefile
spice-server.pc
-common/Makefile
-common/win/Makefile
-common/win/my_getopt-1.5/Makefile
-python_modules/Makefile
-server/Makefile
-server/tests/Makefile
+spice-common/Makefile
client/Makefile
])