diff options
author | Kristian Høgsberg <krh@bitplanet.net> | 2010-06-04 21:46:50 -0400 |
---|---|---|
committer | Kristian Høgsberg <krh@bitplanet.net> | 2010-06-04 21:46:55 -0400 |
commit | b2a432ef18f400dd40d5f7904e56a42b97dab780 (patch) | |
tree | 3e0e64bc9a4d767004dd9254f48a224a4596f14a | |
parent | c9e208899b84895072ba171f9e6013ac28a06747 (diff) |
Move clients to subdirectory
-rw-r--r-- | .gitignore | 2 | ||||
-rw-r--r-- | Makefile | 52 | ||||
-rw-r--r-- | Makefile.in | 73 | ||||
-rw-r--r-- | clients/Makefile | 27 | ||||
-rw-r--r-- | clients/flower.c (renamed from flower.c) | 0 | ||||
-rw-r--r-- | clients/gears.c (renamed from gears.c) | 0 | ||||
-rw-r--r-- | clients/image.c (renamed from image.c) | 0 | ||||
-rw-r--r-- | clients/screenshot.c (renamed from screenshot.c) | 0 | ||||
-rw-r--r-- | clients/terminal.c (renamed from terminal.c) | 0 | ||||
-rw-r--r-- | clients/view.c (renamed from view.c) | 0 | ||||
-rw-r--r-- | config.mk.in | 25 | ||||
-rw-r--r-- | configure.ac | 6 |
12 files changed, 108 insertions, 77 deletions
@@ -14,4 +14,4 @@ autom4te.cache/ config.log config.status configure -Makefile +config.mk diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..afee0c3 --- /dev/null +++ b/Makefile @@ -0,0 +1,52 @@ +include config.mk + +subdirs = clients +libs = libwayland-server.so libwayland.so +compositors = wayland-system-compositor + +all : $(libs) $(compositors) subdirs + +libwayland-server.so : \ + wayland.o \ + event-loop.o \ + connection.o \ + wayland-util.o \ + wayland-hash.o \ + wayland-protocol.o + +libwayland.so : \ + wayland-client.o \ + connection.o \ + wayland-util.o \ + wayland-hash.o \ + wayland-protocol.o + +$(libs) : CFLAGS += -fPIC $(FFI_CFLAGS) +$(libs) : LDLIBS += $(FFI_LIBS) +$(libs) : + gcc -shared $^ $(LDLIBS) -o $@ + +wayland-system-compositor : \ + wayland-system-compositor.o \ + evdev.o \ + cairo-util.o \ + wayland-util.o + +wayland-system-compositor : CFLAGS += $(EGL_COMPOSITOR_CFLAGS) +wayland-system-compositor : LDLIBS += ./libwayland-server.so $(EGL_COMPOSITOR_LIBS) -rdynamic -lrt -lEGL + +subdirs-all subdirs-clean : + for f in $(subdirs); do $(MAKE) -C $$f $(@:subdirs-%=%); done + +install : $(libs) $(compositors) + install -d $(libdir) $(libdir)/pkgconfig ${udev_rules_dir} + install $(libs) $(libdir) + install wayland-server.pc wayland.pc $(libdir)/pkgconfig + install wayland-util.h wayland-client.h $(includedir) + install 70-wayland.rules ${udev_rules_dir} + +clean : subdirs-clean + rm -f $(compositors) *.o *.so + +config.mk : config.mk.in + ./config.status diff --git a/Makefile.in b/Makefile.in deleted file mode 100644 index 72b5e6a..0000000 --- a/Makefile.in +++ /dev/null @@ -1,73 +0,0 @@ -CFLAGS = @GCC_CFLAGS@ - -prefix = @prefix@ -exec_prefix = @exec_prefix@ -udev_rules_dir = @sysconfdir@/udev/rules.d - -libs = libwayland-server.so libwayland.so -egl_clients = gears -cairo_clients = flower screenshot terminal image view -compositors = wayland-system-compositor -clients = $(egl_clients) $(cairo_clients) - -all : $(libs) $(compositors) $(clients) - -libwayland-server.so : \ - wayland.o \ - event-loop.o \ - connection.o \ - wayland-util.o \ - wayland-hash.o \ - wayland-protocol.o - -libwayland.so : \ - wayland-client.o \ - connection.o \ - wayland-util.o \ - wayland-hash.o \ - wayland-protocol.o - -$(libs) : CFLAGS += -fPIC @FFI_CFLAGS@ -$(libs) : LDLIBS += @FFI_LIBS@ -$(libs) : - gcc -shared $^ $(LDLIBS) -o $@ - -wayland-system-compositor : \ - wayland-system-compositor.o \ - evdev.o \ - cairo-util.o \ - wayland-util.o - -wayland-system-compositor : CFLAGS += @EGL_COMPOSITOR_CFLAGS@ -wayland-system-compositor : LDLIBS += ./libwayland-server.so @EGL_COMPOSITOR_LIBS@ -rdynamic -lrt -lEGL - -flower : flower.o wayland-glib.o -gears : gears.o window.o wayland-glib.o cairo-util.o -screenshot : screenshot.o wayland-glib.o -terminal : terminal.o window.o wayland-glib.o cairo-util.o -image : image.o window.o wayland-glib.o cairo-util.o -view : view.o window.o wayland-glib.o cairo-util.o - -terminal : LDLIBS += -lutil -image : CFLAGS += @GDK_PIXBUF_CFLAGS@ -image : LDLIBS += @GDK_PIXBUF_LIBS@ -view : CFLAGS += @POPPLER_CFLAGS@ -view : LDLIBS += @POPPLER_LIBS@ - -$(egl_clients) : CFLAGS += @EGL_CLIENT_CFLAGS@ -$(egl_clients) : LDLIBS += -L. -lwayland @EGL_CLIENT_LIBS@ -lrt -lEGL -$(cairo_clients) : CFLAGS += @CAIRO_CLIENT_CFLAGS@ -$(cairo_clients) : LDLIBS += ./libwayland.so @CAIRO_CLIENT_LIBS@ -lrt - -install : $(libs) $(compositors) - install -d @libdir@ @libdir@/pkgconfig ${udev_rules_dir} - install $(libs) @libdir@ - install wayland-server.pc wayland.pc @libdir@/pkgconfig - install wayland-util.h wayland-client.h @includedir@ - install 70-wayland.rules ${udev_rules_dir} - -clean : - rm -f $(clients) $(compositors) *.o *.so - -Makefile : Makefile.in - ./config.status diff --git a/clients/Makefile b/clients/Makefile new file mode 100644 index 0000000..4771439 --- /dev/null +++ b/clients/Makefile @@ -0,0 +1,27 @@ +include ../config.mk + +egl_clients = gears +cairo_clients = flower screenshot terminal image view + +all : $(egl_clients) $(cairo_clients) + +clean : + rm -f $(egl_clients) $(cairo_clients) *.o + +flower : flower.o wayland-glib.o +gears : gears.o window.o wayland-glib.o cairo-util.o +screenshot : screenshot.o wayland-glib.o +terminal : terminal.o window.o wayland-glib.o cairo-util.o +image : image.o window.o wayland-glib.o cairo-util.o +view : view.o window.o wayland-glib.o cairo-util.o + +terminal : LDLIBS += -lutil +image : CFLAGS += $(GDK_PIXBUF_CFLAGS) +image : LDLIBS += $(GDK_PIXBUF_LIBS) +view : CFLAGS += $(POPPLER_CFLAGS) +view : LDLIBS += $(POPPLER_LIBS) + +$(egl_clients) : CFLAGS += $(EGL_CLIENT_CFLAGS) +$(egl_clients) : LDLIBS += -L.. -lwayland $(EGL_CLIENT_LIBS) -lrt +$(cairo_clients) : CFLAGS += $(CAIRO_CLIENT_CFLAGS) +$(cairo_clients) : LDLIBS += -L.. -lwayland $(CAIRO_CLIENT_LIBS) -lrt diff --git a/flower.c b/clients/flower.c index adbb0cb..adbb0cb 100644 --- a/flower.c +++ b/clients/flower.c diff --git a/gears.c b/clients/gears.c index 0059d07..0059d07 100644 --- a/gears.c +++ b/clients/gears.c diff --git a/image.c b/clients/image.c index 3f206fc..3f206fc 100644 --- a/image.c +++ b/clients/image.c diff --git a/screenshot.c b/clients/screenshot.c index 2ae38a7..2ae38a7 100644 --- a/screenshot.c +++ b/clients/screenshot.c diff --git a/terminal.c b/clients/terminal.c index b4800d5..b4800d5 100644 --- a/terminal.c +++ b/clients/terminal.c diff --git a/config.mk.in b/config.mk.in new file mode 100644 index 0000000..c633655 --- /dev/null +++ b/config.mk.in @@ -0,0 +1,25 @@ +CFLAGS = @GCC_CFLAGS@ + +prefix = @prefix@ +exec_prefix = @exec_prefix@ +udev_rules_dir = @sysconfdir@/udev/rules.d +libdir = @libdir@ +includedir = @includedir@ + +EGL_COMPOSITOR_CFLAGS = @EGL_COMPOSITOR_CFLAGS@ +EGL_COMPOSITOR_LIBS = @EGL_COMPOSITOR_LIBS@ + +FFI_CFLAGS = @FFI_CFLAGS@ +FFI_LIBS = @FFI_LIBS@ + +EGL_CLIENT_CFLAGS = @EGL_CLIENT_CFLAGS@ +EGL_CLIENT_LIBS = @EGL_CLIENT_LIBS@ + +CAIRO_CLIENT_CFLAGS = @CAIRO_CLIENT_CFLAGS@ +CAIRO_CLIENT_LIBS = @CAIRO_CLIENT_LIBS@ + +GDK_PIXBUF_CFLAGS = @GDK_PIXBUF_CFLAGS@ +GDK_PIXBUF_LIBS = @GDK_PIXBUF_LIBS@ + +POPPLER_CFLAGS = @POPPLER_CFLAGS@ +POPPLER_LIBS = @POPPLER_LIBS@ diff --git a/configure.ac b/configure.ac index f7e4663..bf3c669 100644 --- a/configure.ac +++ b/configure.ac @@ -5,8 +5,8 @@ PKG_PROG_PKG_CONFIG() PKG_CHECK_MODULES(FFI, [libffi]) PKG_CHECK_MODULES(EGL_COMPOSITOR, - [gl libpng cairo gdk-pixbuf-2.0 libudev >= 136 libdrm >= 2.4.17]) -PKG_CHECK_MODULES(EGL_CLIENT, [gl cairo glib-2.0 libudev]) + [egl gl libpng cairo gdk-pixbuf-2.0 libudev >= 136 libdrm >= 2.4.17]) +PKG_CHECK_MODULES(EGL_CLIENT, [egl gl cairo glib-2.0 libudev]) PKG_CHECK_MODULES(CAIRO_CLIENT, [cairo-drm glib-2.0]) PKG_CHECK_MODULES(GDK_PIXBUF, [gdk-pixbuf-2.0]) PKG_CHECK_MODULES(POPPLER, [poppler-glib gdk-2.0]) @@ -16,5 +16,5 @@ if test $CC = gcc; then fi AC_SUBST(GCC_CFLAGS) -AC_CONFIG_FILES([Makefile wayland-server.pc wayland.pc]) +AC_CONFIG_FILES([config.mk wayland-server.pc wayland.pc]) AC_OUTPUT |