--- lua-rds-parser-0.0.5.orig/app.c.conf +++ lua-rds-parser-0.0.5/app.c.conf @@ -0,0 +1,9 @@ +// $Id: app.c.conf.in 902 2008-03-22 13:32:17Z gareuselesinge $ +#include "lua-rds-parser.h" + +static void app_open(lua_State* L){ + lua_getglobal(L,"package"); + lua_getfield(L,-1,"preload"); + lua_pushcfunction(L,luaopen_rds_parser); + lua_setfield(L,-2,"rds.parser"); +} --- lua-rds-parser-0.0.5.orig/Makefile +++ lua-rds-parser-0.0.5/Makefile @@ -9,14 +9,14 @@ # details. ## Linux/BSD -PREFIX ?= /usr/local +PREFIX ?= /usr LDFLAGS += -shared ## OSX (Macports) #PREFIX ?= /opt/local #LDFLAGS += -bundle -undefined dynamic_lookup -LUA_INCLUDE_DIR ?= $(PREFIX)/include +LUA_INCLUDE_DIR ?= $(PREFIX)/include/lua$(LUA_VERSION) LUA_LIB_DIR ?= $(PREFIX)/lib/lua/$(LUA_VERSION) #CFLAGS ?= -g -Wall -pedantic -fno-inline --- lua-rds-parser-0.0.5.orig/debian/watch +++ lua-rds-parser-0.0.5/debian/watch @@ -0,0 +1,5 @@ +# test this watch file using: +# uscan --watchfile debian/watch --upstream-version 0.0.1 --package lua-rds-parser +# +version=3 +http://githubredir.debian.net/github/agentzh/lua-rds-parser (.+).tar.gz --- lua-rds-parser-0.0.5.orig/debian/compat +++ lua-rds-parser-0.0.5/debian/compat @@ -0,0 +1 @@ +5 --- lua-rds-parser-0.0.5.orig/debian/control +++ lua-rds-parser-0.0.5/debian/control @@ -0,0 +1,15 @@ +Source: lua-rds-parser +Section: interpreters +Priority: optional +Maintainer: Bearnard Hibbins +Build-Depends: cdbs (>= 0.4.23-1.1), debhelper (>= 5), lua5.1-policy-dev (>= 22), quilt +Standards-Version: 3.8.2 +Homepage: http://agentzh.org +Vcs-Git: git://github.com/agentzh/lua-rds-parser.git +Vcs-Browser: https://github.com/agentzh/lua-rds-parser + +Package: liblua5.1-rds-parser0 +Architecture: any +Pre-Depends: ${misc:Pre-Depends} +Depends: ${shlibs:Depends} +Description: Resty-DBD-Stream (RDS) parser for Lua written in C --- lua-rds-parser-0.0.5.orig/debian/changelog +++ lua-rds-parser-0.0.5/debian/changelog @@ -0,0 +1,12 @@ +lua-rds-parser (0.0.5-2~ubuntu0ppa6~precise) precise; urgency=low + + * New upstream release. + + -- Bearnard Hibbins Wed, 3 Apr 2013 09:48:09 +0200 + +lua-rds-parser (0.0.5-2) precise; urgency=low + + * Initial release. + + -- Bearnard Hibbins Thu, 10 Nov 2011 17:48:09 +0200 + --- lua-rds-parser-0.0.5.orig/debian/Makefile.Debian.conf +++ lua-rds-parser-0.0.5/debian/Makefile.Debian.conf @@ -0,0 +1,20 @@ +PKG_NAME=rds.parser + +### things relative to the C library part +CLIB_CFLAGS= -I src/ +CLIB_LDFLAGS= +CLIB_OBJS= src/rds_parser.lo +VERSION_INFO=0:0:0 + +### things relative to the lua library part +LUA_HEADER= +LUA_SOURCES= +LUA_MODNAME= +LUA_TEST= #tests/test.lua + +### this part is relative to pkg-config +PKG_VERSION=$(shell dpkg-parsechangelog|grep ^Ver|cut -d ' ' -f 2|cut -d '-' -f 1) +PKG_LIBS_PRIVATE= +PKG_URL=https://github.com/agentzh/lua-rds-parser +PKG_REQUIRES= +PKG_CONFLICTS= --- lua-rds-parser-0.0.5.orig/debian/copyright +++ lua-rds-parser-0.0.5/debian/copyright @@ -0,0 +1,35 @@ +This package was debianized by Bearnard Hibbins +Thu Nov 10 21:01:13 SAST 2011. + +It was downloaded from https://github.com/agentzh/lua-rds-parser + + +This module is licenced under the BSD license. + +Copyright (C) 2011, Zhang "agentzh" Yichun (章亦春) . + +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions +are met: + + * Redistributionbutions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED +TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + --- lua-rds-parser-0.0.5.orig/debian/rules +++ lua-rds-parser-0.0.5/debian/rules @@ -0,0 +1,3 @@ +#!/usr/bin/make -f + +include /usr/share/cdbs/1/class/lua.mk --- lua-rds-parser-0.0.5.orig/debian/patches/series +++ lua-rds-parser-0.0.5/debian/patches/series @@ -0,0 +1 @@ +fix-makefile-paths.patch --- lua-rds-parser-0.0.5.orig/debian/patches/fix-makefile-paths.patch +++ lua-rds-parser-0.0.5/debian/patches/fix-makefile-paths.patch @@ -0,0 +1,20 @@ +Fix paths in Makefile to /usr/include instead of /usr/local/include +--- a/Makefile ++++ b/Makefile +@@ -9,14 +9,14 @@ + # details. + + ## Linux/BSD +-PREFIX ?= /usr/local ++PREFIX ?= /usr + LDFLAGS += -shared + + ## OSX (Macports) + #PREFIX ?= /opt/local + #LDFLAGS += -bundle -undefined dynamic_lookup + +-LUA_INCLUDE_DIR ?= $(PREFIX)/include ++LUA_INCLUDE_DIR ?= $(PREFIX)/include/lua$(LUA_VERSION) + LUA_LIB_DIR ?= $(PREFIX)/lib/lua/$(LUA_VERSION) + + #CFLAGS ?= -g -Wall -pedantic -fno-inline --- lua-rds-parser-0.0.5.orig/.pc/.version +++ lua-rds-parser-0.0.5/.pc/.version @@ -0,0 +1 @@ +2 --- lua-rds-parser-0.0.5.orig/.pc/.quilt_series +++ lua-rds-parser-0.0.5/.pc/.quilt_series @@ -0,0 +1 @@ +series --- lua-rds-parser-0.0.5.orig/.pc/applied-patches +++ lua-rds-parser-0.0.5/.pc/applied-patches @@ -0,0 +1 @@ +fix-makefile-paths.patch --- lua-rds-parser-0.0.5.orig/.pc/.quilt_patches +++ lua-rds-parser-0.0.5/.pc/.quilt_patches @@ -0,0 +1 @@ +debian/patches --- lua-rds-parser-0.0.5.orig/.pc/fix-makefile-paths.patch/Makefile +++ lua-rds-parser-0.0.5/.pc/fix-makefile-paths.patch/Makefile @@ -0,0 +1,67 @@ +version=0.09 + +name=lua-rds-parser +dist=$(name)-$(version) + +LUA_VERSION = 5.1 + +# See http://lua-users.org/wiki/BuildingModules for platform specific +# details. + +## Linux/BSD +PREFIX ?= /usr/local +LDFLAGS += -shared + +## OSX (Macports) +#PREFIX ?= /opt/local +#LDFLAGS += -bundle -undefined dynamic_lookup + +LUA_INCLUDE_DIR ?= $(PREFIX)/include +LUA_LIB_DIR ?= $(PREFIX)/lib/lua/$(LUA_VERSION) + +#CFLAGS ?= -g -Wall -pedantic -fno-inline +CFLAGS ?= -g -O -Wall +override CFLAGS += -fpic -I$(LUA_INCLUDE_DIR) + +INSTALL ?= install + +.PHONY: all clean dist test t + +#CC = gcc +RM = rm -f + +all: parser.so + +src/rds_parser.o: src/ddebug.h src/rds_parser.h src/resty_dbd_stream.h + +parser.so: src/rds_parser.o + $(CC) $(LDFLAGS) -o $@ $^ + +install: + $(INSTALL) -d $(DESTDIR)/$(LUA_LIB_DIR)/rds + $(INSTALL) parser.so $(DESTDIR)/$(LUA_LIB_DIR)/rds + +clean: + $(RM) *.so *.o rds/*.so + +test: all + $(INSTALL) -d rds + $(INSTALL) parser.so rds/ + prove -r t + +valtest: parser.so + $(INSTALL) -d rds + $(INSTALL) parser.so rds/ + TEST_LUA_USE_VALGRIND=1 prove -r t + +t: parser.so + $(INSTALL) -d rds + $(INSTALL) parser.so rds/ + TEST_LUA_USE_VALGRIND=1 prove t/sanity.t + +dist: + git archive --prefix="$(dist)/" master | \ + gzip -9 > "$(dist).tar.gz" + git archive --prefix="$(dist)/" \ + -o "$(dist).zip" master +