From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57364) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VHWgQ-0005qM-JW for qemu-devel@nongnu.org; Thu, 05 Sep 2013 06:21:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VHWgI-0002ee-1v for qemu-devel@nongnu.org; Thu, 05 Sep 2013 06:21:02 -0400 Received: from mx1.redhat.com ([209.132.183.28]:24346) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VHWgH-0002eY-PL for qemu-devel@nongnu.org; Thu, 05 Sep 2013 06:20:53 -0400 From: Fam Zheng Date: Thu, 5 Sep 2013 18:20:42 +0800 Message-Id: <1378376448-29036-1-git-send-email-famz@redhat.com> Subject: [Qemu-devel] [RFC PATCH 0/6] Shared Library Module Support List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: pbonzini@redhat.com, mjt@tls.msk.ru, famz@redhat.com, stefanha@redhat.com This series implements feature of shared object building as described in: http://wiki.qemu.org/Features/Modules It's achieved in three steps, with extra bonus to change curl to a shared library module in the end (only to demonstrate the usage, no "make install" support of .so files yet). 1. Allow per object cflags and libs: [01/06] make.rule: fix $(obj) to a real relative path [02/06] rule.mak: allow per object cflags and libs 2. Rules for building .so: [03/06] Makefile: define curl cflags and libs with object 3. Code to load module. All .so files are scanned and loaded when program starts: [04/06] Makefile: introduce common-obj-m and block-obj-m for DSO 4. curl adoption: [05/06] module: load modules at start [06/06] curl: build as shared library Fam Zheng (6): make.rule: fix $(obj) to a real relative path rule.mak: allow per object cflags and libs Makefile: define curl cflags and libs with object Makefile: introduce common-obj-m and block-obj-m for DSO module: load modules at start curl: build as shared library Makefile | 24 +++++++++++++++++++++--- Makefile.objs | 10 +++++++++- Makefile.target | 3 ++- block/Makefile.objs | 3 ++- configure | 28 ++++++++++++++++------------ include/qemu/module.h | 2 ++ qemu-img.c | 2 ++ qemu-io.c | 1 + qemu-nbd.c | 1 + rules.mak | 20 ++++++++++++++------ scripts/create_config | 3 +++ util/Makefile.objs | 2 ++ util/module.c | 40 ++++++++++++++++++++++++++++++++++++++++ vl.c | 1 + 14 files changed, 116 insertions(+), 24 deletions(-) -- 1.8.3.1