diff options
author | Richard Purdie <rpurdie@linux.intel.com> | 2010-03-22 23:54:41 +0000 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2010-03-22 23:54:41 +0000 |
commit | 1d05e3aa30e890a46d5febbde00548a20031fae5 (patch) | |
tree | 05d5d4d7954a1d15c9b2141d73af0c71c38dfdfc /meta | |
parent | 006510ceda571e3183525f4ee3bd399a2d3ce7ed (diff) | |
download | poky-1d05e3aa30e890a46d5febbde00548a20031fae5.tar.gz |
pseudo: Add recipe
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/conf/distro/include/poky-default-revisions.inc | 2 | ||||
-rw-r--r-- | meta/packages/pseudo/pseudo/tweakflags.patch | 79 | ||||
-rw-r--r-- | meta/packages/pseudo/pseudo_git.bb | 24 |
3 files changed, 105 insertions, 0 deletions
diff --git a/meta/conf/distro/include/poky-default-revisions.inc b/meta/conf/distro/include/poky-default-revisions.inc index f4912ffd7f..abaa94b693 100644 --- a/meta/conf/distro/include/poky-default-revisions.inc +++ b/meta/conf/distro/include/poky-default-revisions.inc | |||
@@ -102,6 +102,8 @@ SRCREV_pn-osc-native ?= "9096" | |||
102 | SRCREV_pn-owl-video = "394" | 102 | SRCREV_pn-owl-video = "394" |
103 | SRCREV_pn-pkgconfig ?= "66d49f1375fec838bcd301bb4ca2ef76cee0e47c" | 103 | SRCREV_pn-pkgconfig ?= "66d49f1375fec838bcd301bb4ca2ef76cee0e47c" |
104 | SRCREV_pn-psplash ?= "422" | 104 | SRCREV_pn-psplash ?= "422" |
105 | SRCREV_pn-pseudo ?= "086e65c90420b3d38f30c3cd81a0f8573f6f69cf" | ||
106 | SRCREV_pn-pseudo-native ?= "086e65c90420b3d38f30c3cd81a0f8573f6f69cf" | ||
105 | QEMUSRCREV = "9eab386edbf8cf002a731f8204a156f243a47a57" | 107 | QEMUSRCREV = "9eab386edbf8cf002a731f8204a156f243a47a57" |
106 | SRCREV_pn-qemu-native ?= "${QEMUSRCREV}" | 108 | SRCREV_pn-qemu-native ?= "${QEMUSRCREV}" |
107 | SRCREV_pn-qemu-nativesdk ?= "${QEMUSRCREV}" | 109 | SRCREV_pn-qemu-nativesdk ?= "${QEMUSRCREV}" |
diff --git a/meta/packages/pseudo/pseudo/tweakflags.patch b/meta/packages/pseudo/pseudo/tweakflags.patch new file mode 100644 index 0000000000..fb31e05a1e --- /dev/null +++ b/meta/packages/pseudo/pseudo/tweakflags.patch | |||
@@ -0,0 +1,79 @@ | |||
1 | CFLAGS is overridden from the environment by Poky. We need boths sets of | ||
2 | flags so we adjust the Makefile accordingly. | ||
3 | |||
4 | Also the default target is "test" which runs install which we don't want | ||
5 | until "make install" time when DESTDIR is set. Change the first target | ||
6 | to "all" for this reason. | ||
7 | |||
8 | RP 18/3/10 | ||
9 | |||
10 | Index: git/Makefile.in | ||
11 | =================================================================== | ||
12 | --- git.orig/Makefile.in 2010-03-17 16:05:17.000000000 +0000 | ||
13 | +++ git/Makefile.in 2010-03-18 18:49:37.000000000 +0000 | ||
14 | @@ -34,7 +34,7 @@ | ||
15 | CFLAGS_DEFS=-DPSEUDO_PREFIX='"$(PREFIX)"' -DPSEUDO_SUFFIX='"$(SUFFIX)"' -DPSEUDO_VERSION='"$(VERSION)"' | ||
16 | CFLAGS_DEBUG=-O2 -g | ||
17 | CFLAGS_SQL=-L$(SQLITE)/lib -I$(SQLITE)/include | ||
18 | -CFLAGS=$(CFLAGS_BASE) $(CFLAGS_CODE) $(CFLAGS_DEFS) \ | ||
19 | +EXTRA_CFLAGS=$(CFLAGS_BASE) $(CFLAGS_CODE) $(CFLAGS_DEFS) \ | ||
20 | $(CFLAGS_DEBUG) $(CFLAGS_SQL) | ||
21 | |||
22 | GLOB_PATTERN=guts/*.c | ||
23 | @@ -47,11 +47,11 @@ | ||
24 | DBOBJS=pseudo_db.o -ldl -lpthread | ||
25 | WRAPOBJS=pseudo_wrappers.o | ||
26 | |||
27 | +all: libpseudo.so pseudo pseudodb pseudolog | ||
28 | + | ||
29 | test: install | ||
30 | @echo "No tests yet." | ||
31 | |||
32 | -all: libpseudo.so pseudo pseudodb pseudolog | ||
33 | - | ||
34 | install-lib: libpseudo.so | ||
35 | mkdir -p $(DESTDIR)$(LIBDIR) | ||
36 | cp libpseudo*.so $(DESTDIR)$(LIBDIR) | ||
37 | @@ -66,26 +66,29 @@ | ||
38 | install: all install-lib install-bin install-data | ||
39 | |||
40 | pseudo: pseudo.o $(SHOBJS) $(DBOBJS) pseudo_server.o pseudo_ipc.o | ||
41 | - $(CC) $(CFLAGS) -o pseudo \ | ||
42 | + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -o pseudo \ | ||
43 | pseudo.o pseudo_server.o pseudo_client.o pseudo_ipc.o \ | ||
44 | $(DBOBJS) $(SHOBJS) $(DBLDFLAGS) | ||
45 | |||
46 | pseudolog: pseudolog.o $(SHOBJS) $(DBOBJS) | ||
47 | - $(CC) $(CFLAGS) -o pseudolog pseudolog.o \ | ||
48 | + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -o pseudolog pseudolog.o \ | ||
49 | $(DBOBJS) $(SHOBJS) $(DBLDFLAGS) | ||
50 | |||
51 | pseudodb: pseudodb.o $(SHOBJS) $(DBOBJS) pseudo_ipc.o | ||
52 | - $(CC) $(CFLAGS) -o pseudodb pseudodb.o \ | ||
53 | + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -o pseudodb pseudodb.o \ | ||
54 | $(DBOBJS) $(SHOBJS) $(DBLDFLAGS) pseudo_ipc.o | ||
55 | |||
56 | libpseudo.so: $(WRAPOBJS) pseudo_client.o pseudo_ipc.o $(SHOBJS) | ||
57 | - $(CC) $(CFLAGS) -shared -o libpseudo.so \ | ||
58 | + $(CC) $(CFLAGS) $(EXTRA_CFLAGS) -shared -o libpseudo.so \ | ||
59 | pseudo_client.o pseudo_ipc.o \ | ||
60 | $(WRAPOBJS) $(SHOBJS) -ldl | ||
61 | if test -n "$(SUFFIX)"; then \ | ||
62 | cp libpseudo.so libpseudo$(SUFFIX).so ; \ | ||
63 | fi | ||
64 | |||
65 | +%.o: %.c | ||
66 | + $(CC) -c $(CPPFLAGS) $(CFLAGS) $(EXTRA_CFLAGS) $< | ||
67 | + | ||
68 | pseudo_client.o pseudo_server.o pseudo_ipc.o: pseudo_ipc.h | ||
69 | |||
70 | pseudo_client.o: pseudo_client.h | ||
71 | @@ -103,7 +106,7 @@ | ||
72 | |||
73 | # no-strict-aliasing is needed for the function pointer trickery. | ||
74 | pseudo_wrappers.o: pseudo_wrappers.c | ||
75 | - $(CC) -fno-strict-aliasing $(CFLAGS) -D_GNU_SOURCE -c -o pseudo_wrappers.o pseudo_wrappers.c | ||
76 | + $(CC) -fno-strict-aliasing $(CFLAGS) $(EXTRA_CFLAGS) -D_GNU_SOURCE -c -o pseudo_wrappers.o pseudo_wrappers.c | ||
77 | |||
78 | offsets32: | ||
79 | $(CC) -m32 -o offsets32 offsets.c | ||
diff --git a/meta/packages/pseudo/pseudo_git.bb b/meta/packages/pseudo/pseudo_git.bb new file mode 100644 index 0000000000..0512a955d4 --- /dev/null +++ b/meta/packages/pseudo/pseudo_git.bb | |||
@@ -0,0 +1,24 @@ | |||
1 | DESCRIPTION = "Pseudo gives fake root capabilities to a normal user" | ||
2 | SECTION = "base" | ||
3 | LICENSE = "LGPL2.1" | ||
4 | DEPENDS = "sqlite3" | ||
5 | |||
6 | PV = "0.0+git${SRCPV}" | ||
7 | PR = "r2" | ||
8 | |||
9 | SRC_URI = "git://github.com/wrpseudo/pseudo.git;protocol=git \ | ||
10 | file://tweakflags.patch;patch=1" | ||
11 | |||
12 | S = "${WORKDIR}/git" | ||
13 | |||
14 | inherit siteinfo | ||
15 | |||
16 | do_configure () { | ||
17 | ${S}/configure --prefix=${prefix} --with-sqlite=${STAGING_DIR_TARGET}${exec_prefix} --bits=${SITEINFO_BITS} | ||
18 | } | ||
19 | |||
20 | NATIVE_INSTALL_WORKS = "1" | ||
21 | |||
22 | BBCLASSEXTEND = "native" | ||
23 | |||
24 | |||