diff options
Diffstat (limited to 'meta/recipes-devtools/opkg/opkg/0001-add-opkg_compare_versions-function.patch')
-rw-r--r-- | meta/recipes-devtools/opkg/opkg/0001-add-opkg_compare_versions-function.patch | 54 |
1 files changed, 0 insertions, 54 deletions
diff --git a/meta/recipes-devtools/opkg/opkg/0001-add-opkg_compare_versions-function.patch b/meta/recipes-devtools/opkg/opkg/0001-add-opkg_compare_versions-function.patch deleted file mode 100644 index 5dc76d4004..0000000000 --- a/meta/recipes-devtools/opkg/opkg/0001-add-opkg_compare_versions-function.patch +++ /dev/null | |||
@@ -1,54 +0,0 @@ | |||
1 | From 029cf99fd44645b5fe1b6491355c631da3096e09 Mon Sep 17 00:00:00 2001 | ||
2 | From: Martin Jansa <Martin.Jansa@gmail.com> | ||
3 | Date: Sat, 17 Dec 2011 12:51:07 +0100 | ||
4 | Subject: [PATCH 1/7] add opkg_compare_versions function | ||
5 | |||
6 | * not used in opkg but can be usefull, e.g. instead of | ||
7 | opkg-utils/opkg-compare-versions.c | ||
8 | |||
9 | Upstream-Status: Submitted | ||
10 | http://code.google.com/p/opkg/issues/detail?id=93 | ||
11 | |||
12 | Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> | ||
13 | --- | ||
14 | libopkg/opkg.c | 15 +++++++++++++++ | ||
15 | libopkg/opkg.h | 2 ++ | ||
16 | 2 files changed, 17 insertions(+) | ||
17 | |||
18 | diff --git a/libopkg/opkg.c b/libopkg/opkg.c | ||
19 | index 92f61f4..eaea529 100644 | ||
20 | --- a/libopkg/opkg.c | ||
21 | +++ b/libopkg/opkg.c | ||
22 | @@ -870,3 +870,18 @@ opkg_repository_accessibility_check(void) | ||
23 | |||
24 | return ret; | ||
25 | } | ||
26 | + | ||
27 | +int | ||
28 | +opkg_compare_versions (const char *ver1, const char *ver2) | ||
29 | +{ | ||
30 | + pkg_t *pkg1, *pkg2; | ||
31 | + | ||
32 | + pkg1 = pkg_new(); | ||
33 | + pkg2 = pkg_new(); | ||
34 | + | ||
35 | + parse_version(pkg1, ver1); | ||
36 | + parse_version(pkg2, ver2); | ||
37 | + | ||
38 | + return pkg_compare_versions(pkg1, pkg2); | ||
39 | +} | ||
40 | + | ||
41 | diff --git a/libopkg/opkg.h b/libopkg/opkg.h | ||
42 | index 4fbd404..7aa86eb 100644 | ||
43 | --- a/libopkg/opkg.h | ||
44 | +++ b/libopkg/opkg.h | ||
45 | @@ -58,4 +58,6 @@ pkg_t* opkg_find_package (const char *name, const char *version, const char *arc | ||
46 | |||
47 | int opkg_repository_accessibility_check(void); | ||
48 | |||
49 | +int opkg_compare_versions (const char *ver1, const char *ver2); | ||
50 | + | ||
51 | #endif /* OPKG_H */ | ||
52 | -- | ||
53 | 1.7.12 | ||
54 | |||