gunnar: server/sqlite .cvsignore, NONE, 1.1 Makefile, NONE, 1.1 sqlite.patch, NONE, 1.1 sqlite.spec, NONE, 1.1
cvs at kolab.org
cvs at kolab.org
Fri Sep 19 22:54:58 CEST 2008
Author: gunnar
Update of /kolabrepository/server/sqlite
In directory doto:/tmp/cvs-serv17842/sqlite
Added Files:
.cvsignore Makefile sqlite.patch sqlite.spec
Log Message:
We actually need sqlite2 as the base PHP function work with this version.
--- NEW FILE: .cvsignore ---
openldap-*.tgz
*.src.rpm
--- NEW FILE: Makefile ---
NAME = sqlite
PACKAGE = $(NAME)
VERSION = $(shell grep "^Version:" *.spec | sed -e "s/^Version:\s*\([0-9.]*\).*/\1/")
RELEASE = $(shell grep "^Release:" *.spec | sed -e "s/^Release:\s*\([0-9]*\).*/\1/")
KOLABRELEASE = $(RELEASE)
ifeq "x$(RPM)" "x"
RPM = $(HOME)/bin/openpkg rpm
endif
ifeq "x$(KOLABRPMSRC)" "x"
KOLABRPMSRC = $(HOME)/RPM/SRC
endif
ifeq "x$(KOLABRPMPKG)" "x"
KOLABRPMPKG = $(HOME)/RPM/PKG
endif
ifeq "x$(KOLABRPMTMP)" "x"
KOLABRPMTMP = $(HOME)/RPM/TMP
endif
SOURCE_0=http://www.sqlite.org/sqlite-2.8.17.tar.gz
.PHONY: all
all: $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm
.PHONY: dist
dist: all
cp $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm ../stage/
.PHONY: clean
clean:
rm -rf $(KOLABRPMTMP)/$(NAME)*
rm -rf $(KOLABRPMTMP)/$(PACKAGE)
rm -rf $(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm
rm -rf *~
$(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm: Makefile $(PACKAGE).spec
test -d $(KOLABRPMSRC)/$(PACKAGE) || mkdir $(KOLABRPMSRC)/$(PACKAGE)
cd $(KOLABRPMSRC)/$(PACKAGE) && wget -c "$(SOURCE_0)"
cp $(PACKAGE).spec $(PACKAGE).patch $(KOLABRPMSRC)/$(PACKAGE)
cd $(KOLABRPMSRC)/$(PACKAGE) && $(RPM) -ba $(PACKAGE).spec --define 'with_pth no'
cp -p $(KOLABRPMPKG)/$(PACKAGE)-$(VERSION)-$(RELEASE).src.rpm .
--- NEW FILE: sqlite.patch ---
Index: sqlite-2.8.17/configure
--- sqlite-2.8.17/configure.orig 2005-04-24 00:43:23 +0200
+++ sqlite-2.8.17/configure 2006-12-18 09:51:03 +0100
@@ -20450,7 +20450,10 @@
TARGET_HAVE_READLINE=0
fi
-
+if [ "$ac_cv_lib_readline_readline" = "no" ]
+then
+ TARGET_HAVE_READLINE=0
+fi
#########
# Figure out whether or not we have a "usleep()" function.
Index: sqlite-2.8.17/src/encode.c
--- sqlite-2.8.17/src/encode.c.orig 2005-04-24 00:43:22 +0200
+++ sqlite-2.8.17/src/encode.c 2007-02-23 15:28:03 +0100
@@ -176,6 +176,8 @@
int i, e;
unsigned char c;
e = *(in++);
+ if (e == 0)
+ return 0;
i = 0;
while( (c = *(in++))!=0 ){
if( c==1 ){
--- NEW FILE: sqlite.spec ---
##
## sqlite.spec -- OpenPKG RPM Package Specification
## Copyright (c) 2000-2007 OpenPKG Foundation e.V. <http://openpkg.net/>
## Copyright (c) 2000-2007 Ralf S. Engelschall <http://engelschall.com/>
##
## Permission to use, copy, modify, and distribute this software for
## any purpose with or without fee is hereby granted, provided that
## the above copyright notice and this permission notice appear in all
## copies.
##
## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED 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 AUTHORS AND COPYRIGHT HOLDERS AND THEIR
## 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.
##
%define V_Version 2.8.17
# package information
Name: sqlite
Summary: SQL Lite
URL: http://www.sqlite.org/
Vendor: D. Richard Hipp
Packager: OpenPKG Foundation e.V.
Distribution: OpenPKG Community
Class: BASE
Group: Database
License: PD
Version: 2.8.17
Release: 20080919
# package options
%option with_utf8 no
%option with_assert no
%option with_readline no
%option with_threads no
# list of sources
Source0: http://www.sqlite.org/sqlite-%{V_Version}.tar.gz
Patch0: sqlite.patch
# build information
Prefix: %{l_prefix}
BuildRoot: %{l_buildroot}
BuildPreReq: OpenPKG, openpkg >= 20040130, make, gawk
PreReq: OpenPKG, openpkg >= 20040130
%if "%{with_readline}" == "yes"
BuildPreReq: readline, pkgconfig
PreReq: readline
%endif
AutoReq: no
AutoReqProv: no
%description
SQLite is a C library that implements an embeddable SQL database
engine. Programs that link with the SQLite library can have SQL
database access without running a separate RDBMS process. The
distribution comes with a standalone command-line access program
(sqlite) that can be used to administer an SQLite database and which
serves as an example of how to use the SQLite library. SQLite is not
a client library used to connect to a big database server. SQLite is
the server. The SQLite library reads and writes directly to and from
the database files on disk.
%prep
%setup -q -c
%patch -p0
# post-adjust sources
chmod a+x sqlite-%{V_Version}/install-sh
%{l_shtool} subst \
-e '/LINENO: error: C[+]* preprocessor/{N;N;N;N;s/.*/:/;}' \
sqlite-%{V_Version}/configure
%build
# configure and build SQLite 3 and optionally SQLite 2
for v in %{V_Version}; do
( cd sqlite-$v
CC="%{l_cc}"
export CC
CPPFLAGS="%{l_cppflags}"
export CPPFLAGS
CFLAGS="%{l_cflags -O}"
export CFLAGS
LDFLAGS="%{l_ldflags}"
export LDFLAGS
LIBS=""
export LIBS
%if "%{with_assert}" == "no"
CFLAGS="$CFLAGS -DNDEBUG=1"
%endif
%if "%{with_readline}" == "yes"
config_TARGET_READLINE_INC="%{l_cppflags readline} `%{l_prefix}/bin/pkg-config --cflags readline`"
export config_TARGET_READLINE_INC
config_TARGET_READLINE_LIBS="%{l_ldflags} `%{l_prefix}/bin/pkg-config --libs readline`"
export config_TARGET_READLINE_LIBS
%endif
./configure \
--prefix=%{l_prefix} \
%if "%{with_utf8}" == "yes"
--enable-utf8 \
%endif
%if "%{with_threads}" == "yes"
--enable-threadsafe \
%endif
--disable-shared
%if "%{with_assert}" == "yes"
%{l_shtool} subst \
-e 's;-DNDEBUG;;' \
Makefile
%endif
MFLAGS=""
%{l_make} %{l_mflags -O} $MFLAGS
) || exit $?
done
%install
# create installation hierarchy
rm -rf $RPM_BUILD_ROOT
%{l_shtool} mkdir -f -p -m 755 \
$RPM_BUILD_ROOT%{l_prefix}/bin \
$RPM_BUILD_ROOT%{l_prefix}/lib \
$RPM_BUILD_ROOT%{l_prefix}/include \
$RPM_BUILD_ROOT%{l_prefix}/man/man1
( cd sqlite-%{V_Version}
%{l_make} %{l_mflags} install \
prefix=$RPM_BUILD_ROOT%{l_prefix}
%{l_shtool} install -c -m 644 \
sqlite.1 $RPM_BUILD_ROOT%{l_prefix}/man/man1/sqlite.1
) || exit $?
# strip down installation files
strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
# determine installation files
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
%{l_files_std} \
'%not %dir %{l_prefix}/lib/pkgconfig'
%files -f files
%clean
rm -rf $RPM_BUILD_ROOT
More information about the commits
mailing list