Hello community,

here is the log from the commit of package lua for openSUSE:Factory checked in 
at 2013-02-20 09:28:52
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/lua (Old)
 and      /work/SRC/openSUSE:Factory/.lua.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "lua", Maintainer is "[email protected]"

Changes:
--------
--- /work/SRC/openSUSE:Factory/lua/lua.changes  2013-02-07 10:39:14.000000000 
+0100
+++ /work/SRC/openSUSE:Factory/.lua.new/lua.changes     2013-02-20 
09:28:53.000000000 +0100
@@ -1,0 +2,10 @@
+Tue Feb 19 11:30:57 UTC 2013 - [email protected]
+
+- fix visibility of global variables [bnc#803791]
+  * modified lua-suse.diff
+- added LUA_SO target as dependency to LUAC_T and LUA_T to fix
+  parallel build
+  * modified lua-suse.diff
+- added regresion check for this error into %check
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ lua.spec ++++++
--- /var/tmp/diff_new_pack.DxgX8E/_old  2013-02-20 09:28:54.000000000 +0100
+++ /var/tmp/diff_new_pack.DxgX8E/_new  2013-02-20 09:28:54.000000000 +0100
@@ -27,6 +27,10 @@
 Source1:        macros.lua
 Source2:        baselibs.conf
 # prefix and build shared libraries (upstream don't want this in Makefile)
+# visibility: I don't see the point why divert from upstream except that
+#             luaU_dump, luaP_opmodes and luaP_opnames need to be visible
+#             to luac; if you will divert, don't forgot that LUAI_DDEC
+#             prefixes declaration of _variables_
 Patch0:         %{name}-suse.diff
 %define major_version 5.2
 %define libsuf        5_2
@@ -110,7 +114,6 @@
 
 %build
 sed -i -e "s@lib/lua/@%{_lib}/lua/@g" src/luaconf.h
-grep LUA_CDIR src/luaconf.h 
 make %{?_smp_mflags} -C src CC="gcc" MYCFLAGS="%{optflags} -std=gnu99 
-D_GNU_SOURCE -fPIC -DLUA_USE_LINUX" MYLIBS="-Wl,-E -ldl -lreadline -lhistory 
-lncurses" V=%{major_version} all
 
 %install
@@ -136,6 +139,10 @@
 EOF
 install -D -m 644 lua.pc %{buildroot}/%{_libdir}/pkgconfig/lua.pc
 
+%check
+cd src
+LD_LIBRARY_PATH=`pwd` ./lua -e 'print(0)' > /dev/null
+
 %post
 /usr/sbin/update-alternatives --install                                        
           \
             %{_bindir}/lua            lua       %{_bindir}/lua%{major_version} 
        15 \

++++++ lua-suse.diff ++++++
--- /var/tmp/diff_new_pack.DxgX8E/_old  2013-02-20 09:28:54.000000000 +0100
+++ /var/tmp/diff_new_pack.DxgX8E/_new  2013-02-20 09:28:54.000000000 +0100
@@ -53,12 +53,14 @@
        $(AR) $@ $(BASE_O)
        $(RANLIB) $@
  
- $(LUA_T): $(LUA_O) $(LUA_A)
+-$(LUA_T): $(LUA_O) $(LUA_A)
 -      $(CC) -o $@ $(LDFLAGS) $(LUA_O) $(LUA_A) $(LIBS)
++$(LUA_T): $(LUA_O) $(LUA_SO)
 +      $(CC) $(MYCFLAGS) -o $@ $(MYLDFLAGS) $(LUA_O) -L. -llua $(LIBS)
  
- $(LUAC_T): $(LUAC_O) $(LUA_A)
+-$(LUAC_T): $(LUAC_O) $(LUA_A)
 -      $(CC) -o $@ $(LDFLAGS) $(LUAC_O) $(LUA_A) $(LIBS)
++$(LUAC_T): $(LUAC_O) $(LUA_SO)
 +      $(CC) $(MYCFLAGS) -o $@ $(MYLDFLAGS) $(LUAC_O) -L. -llua $(LIBS)
  
  clean:
@@ -83,27 +85,6 @@
  #define LUA_LDIR      LUA_ROOT "share/lua/" LUA_VDIR
  #define LUA_CDIR      LUA_ROOT "lib/lua/" LUA_VDIR
  #define LUA_PATH_DEFAULT  \
-@@ -150,7 +150,7 @@
- 
- #else                         /* }{ */
- 
--#define LUA_API               extern
-+#define LUA_API               __attribute__ ((visibility ("default")))
- 
- #endif                                /* } */
- 
-@@ -176,9 +176,9 @@
- */
- #if defined(__GNUC__) && ((__GNUC__*100 + __GNUC_MINOR__) >= 302) && \
-     defined(__ELF__)          /* { */
--#define LUAI_FUNC     __attribute__((visibility("hidden"))) extern
-+#define LUAI_FUNC     __attribute__ ((visibility ("hidden")))
- #define LUAI_DDEC     LUAI_FUNC
--#define LUAI_DDEF     /* empty */
-+#define LUAI_DDEF     LUAI_FUNC /* empty */
- 
- #else                         /* }{ */
- #define LUAI_FUNC     extern
 Index: lua-5.2.1/src/lundump.h
 ===================================================================
 --- lua-5.2.1.orig/src/lundump.h
@@ -113,7 +94,29 @@
  
  /* dump one chunk; from ldump.c */
 -LUAI_FUNC int luaU_dump (lua_State* L, const Proto* f, lua_Writer w, void* 
data, int strip);
-+__attribute__ ((visibility ("default"))) int luaU_dump (lua_State* L, const 
Proto* f, lua_Writer w, void* data, int strip);
++LUA_API int luaU_dump (lua_State* L, const Proto* f, lua_Writer w, void* 
data, int strip);
  
  /* data to catch conversion errors */
  #define LUAC_TAIL             "\x19\x93\r\n\x1a\n"
+Index: lua-5.2.1/src/lopcodes.h
+===================================================================
+--- lua-5.2.1.orig/src/lopcodes.h
++++ lua-5.2.1/src/lopcodes.h
+@@ -269,7 +269,7 @@ enum OpArgMask {
+   OpArgK   /* argument is a constant or register/constant */
+ };
+ 
+-LUAI_DDEC const lu_byte luaP_opmodes[NUM_OPCODES];
++LUA_API const lu_byte luaP_opmodes[NUM_OPCODES];
+ 
+ #define getOpMode(m)  (cast(enum OpMode, luaP_opmodes[m] & 3))
+ #define getBMode(m)   (cast(enum OpArgMask, (luaP_opmodes[m] >> 4) & 3))
+@@ -278,7 +278,7 @@ LUAI_DDEC const lu_byte luaP_opmodes[NUM
+ #define testTMode(m)  (luaP_opmodes[m] & (1 << 7))
+ 
+ 
+-LUAI_DDEC const char *const luaP_opnames[NUM_OPCODES+1];  /* opcode names */
++LUA_API const char *const luaP_opnames[NUM_OPCODES+1];  /* opcode names */
+ 
+ 
+ /* number of list items to accumulate before a SETLIST instruction */

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to