From c8962d9fc0e44e90dbb6606baa33014c0818782cc84d873abb19a1fad1317c80 Mon Sep 17 00:00:00 2001 From: Ilya Chernykh Date: Thu, 26 Jul 2012 12:59:28 +0000 Subject: [PATCH] Accepting request 128986 from home:k0da:ppc - defining inline causes problems trying to build against libvisual headers OBS-URL: https://build.opensuse.org/request/show/128986 OBS-URL: https://build.opensuse.org/package/show/KDE:KDE3/libvisual?expand=0&rev=16 --- libvisual-0.4.0-inlinedefineconflict.patch | 60 ++++++++++++++++++++++ libvisual.changes | 6 +++ libvisual.spec | 2 + 3 files changed, 68 insertions(+) create mode 100644 libvisual-0.4.0-inlinedefineconflict.patch diff --git a/libvisual-0.4.0-inlinedefineconflict.patch b/libvisual-0.4.0-inlinedefineconflict.patch new file mode 100644 index 0000000..f6a6c08 --- /dev/null +++ b/libvisual-0.4.0-inlinedefineconflict.patch @@ -0,0 +1,60 @@ +diff -ru libvisual-0.4.0.orig/libvisual/lv_cache.c libvisual-0.4.0/libvisual/lv_cache.c +--- libvisual-0.4.0.orig/libvisual/lv_cache.c 2009-03-07 17:17:38.000000000 +0000 ++++ libvisual-0.4.0/libvisual/lv_cache.c 2009-03-07 17:25:26.000000000 +0000 +@@ -32,7 +32,7 @@ + static int cache_dtor (VisObject *object); + static int cache_remove_list_entry (VisCache *cache, VisListEntry **le); + +-static inline void handle_request_reset (VisCache *cache, VisListEntry *le); ++static lv_inline void handle_request_reset (VisCache *cache, VisListEntry *le); + + static int cache_dtor (VisObject *object) + { +@@ -74,7 +74,7 @@ + } + + +-static inline void handle_request_reset (VisCache *cache, VisListEntry *le) ++static lv_inline void handle_request_reset (VisCache *cache, VisListEntry *le) + { + VisCacheEntry *centry; + +diff -ru libvisual-0.4.0.orig/libvisual/lv_defines.h libvisual-0.4.0/libvisual/lv_defines.h +--- libvisual-0.4.0.orig/libvisual/lv_defines.h 2009-03-07 17:17:38.000000000 +0000 ++++ libvisual-0.4.0/libvisual/lv_defines.h 2009-03-07 17:24:17.000000000 +0000 +@@ -63,13 +63,13 @@ + + /* Compiler specific optimalization macros */ + #if __GNUC__ >= 3 +-# define inline inline __attribute__ ((always_inline)) ++# define lv_inline inline __attribute__ ((always_inline)) + # define __malloc __attribute__ ((malloc)) + # define __packed __attribute__ ((packed)) + # define VIS_LIKELY(x) __builtin_expect (!!(x), 1) + # define VIS_UNLIKELY(x) __builtin_expect (!!(x), 0) + #else +-# define inline /* no inline */ ++# define lv_inline /* no inline */ + # define __malloc /* no malloc */ + # define __packed /* no packed */ + # define VIS_LIKELY(x) (x) +diff -ru libvisual-0.4.0.orig/libvisual/lv_time.h libvisual-0.4.0/libvisual/lv_time.h +--- libvisual-0.4.0.orig/libvisual/lv_time.h 2009-03-07 17:17:38.000000000 +0000 ++++ libvisual-0.4.0/libvisual/lv_time.h 2009-03-07 17:25:15.000000000 +0000 +@@ -101,7 +101,7 @@ + * + * @return Nothing. + */ +-static inline void visual_timer_tsc_get (uint32_t *lo, uint32_t *hi) ++static lv_inline void visual_timer_tsc_get (uint32_t *lo, uint32_t *hi) + { + #if defined(VISUAL_ARCH_X86) || defined(VISUAL_ARCH_X86_64) + __asm __volatile +@@ -115,7 +115,7 @@ + } + + /* FIXME use uint64_t here, make sure type exists */ +-static inline unsigned long long visual_timer_tsc_get_returned () ++static lv_inline unsigned long long visual_timer_tsc_get_returned () + { + uint32_t lo, hi; diff --git a/libvisual.changes b/libvisual.changes index a57f739..4e66ba0 100644 --- a/libvisual.changes +++ b/libvisual.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Thu Jul 26 11:11:11 UTC 2012 - dvaleev@suse.com + +- defining inline causes problems trying to build against + libvisual headers + ------------------------------------------------------------------- Mon Feb 13 10:49:33 UTC 2012 - coolo@suse.com diff --git a/libvisual.spec b/libvisual.spec index 71df2b4..18c36ce 100644 --- a/libvisual.spec +++ b/libvisual.spec @@ -41,6 +41,7 @@ Patch1: %name-%{version}-compiler_warnings.diff Patch2: libvisual.visual_cpu_get_altivec.patch Patch3: %name-%{version}-unref-static.diff Patch4: libvisual-0.4.0-2.1-nmu.diff +Patch5: libvisual-0.4.0-inlinedefineconflict.patch %description Libvisual is a library that acts as a middle layer between applications @@ -87,6 +88,7 @@ Authors: %patch2 -p1 %patch3 %patch4 -p1 +%patch5 -p1 %build autoreconf -fiv