Merge lp:~dobey/u1db/pkg-fixings into lp:u1db

Proposed by dobey
Status: Merged
Approved by: dobey
Approved revision: 379
Merged at revision: 378
Proposed branch: lp:~dobey/u1db/pkg-fixings
Merge into: lp:u1db
Diff against target: 91 lines (+25/-19)
4 files modified
src/CMakeLists.txt (+4/-1)
src/u1db.c (+1/-1)
src/u1db_query.c (+6/-5)
u1db/tests/c_backend_wrapper.pyx (+14/-12)
To merge this branch: bzr merge lp:~dobey/u1db/pkg-fixings
Reviewer Review Type Date Requested Status
Eric Casteleijn (community) Approve
Review via email: mp+119634@code.launchpad.net

Commit message

Fix license header in c_backend_wrapper.pyx
Set default CFLAGS so we get a debug build, and fail on compiler warnings
Only install the u1db.h file as a public include file
Fix some compiler warnings

To post a comment you must log in.
Revision history for this message
Eric Casteleijn (thisfred) wrote :

yay!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/CMakeLists.txt'
2--- src/CMakeLists.txt 2012-07-11 17:11:07 +0000
3+++ src/CMakeLists.txt 2012-08-14 21:13:23 +0000
4@@ -1,6 +1,9 @@
5 cmake_minimum_required (VERSION 2.6)
6 project (u1db)
7
8+# Some default CFLAGS
9+SET (CMAKE_C_FLAGS "-O2 -g -Wall -Werror")
10+
11 # Allow specifying the libdir to use for the C library
12 SET (LIB_SUFFIX "" CACHE STRING "Define suffix of library directory name.")
13 SET (LIB_INSTALL_DIR "lib${LIB_SUFFIX}")
14@@ -34,5 +37,5 @@
15 )
16
17 install(DIRECTORY ${CMAKE_SOURCE_DIR}/include/u1db DESTINATION include
18- FILES_MATCHING PATTERN "*.h"
19+ FILES_MATCHING PATTERN "u1db.h"
20 )
21
22=== modified file 'src/u1db.c'
23--- src/u1db.c 2012-08-10 20:08:47 +0000
24+++ src/u1db.c 2012-08-14 21:13:23 +0000
25@@ -195,7 +195,7 @@
26 u1db_set_document_size_limit(u1database *db, int limit)
27 {
28 sqlite3_stmt *statement;
29- int status, final_status;
30+ int status;
31
32 status = sqlite3_prepare_v2(db->sql_handle,
33 "INSERT OR REPLACE INTO u1db_config VALUES ('document_size_limit', ?)",
34
35=== modified file 'src/u1db_query.c'
36--- src/u1db_query.c 2012-08-09 20:46:13 +0000
37+++ src/u1db_query.c 2012-08-14 21:13:23 +0000
38@@ -245,11 +245,12 @@
39 int arity;
40 const int *value_types;
41 } OPERATIONS[] = {
42- op_lower, "lower", json_type_string, 1, JUST_EXPRESSION,
43- op_number, "number", json_type_int, 2, EXPRESSION_INTEGER,
44- op_split_words, "split_words", json_type_string, 1, JUST_EXPRESSION,
45- op_bool, "bool", json_type_boolean, 1, JUST_EXPRESSION,
46- op_combine, "combine", json_type_string, -1, JUST_EXPRESSION};
47+ { op_lower, "lower", json_type_string, 1, JUST_EXPRESSION },
48+ { op_number, "number", json_type_int, 2, EXPRESSION_INTEGER },
49+ { op_split_words, "split_words", json_type_string, 1, JUST_EXPRESSION },
50+ { op_bool, "bool", json_type_boolean, 1, JUST_EXPRESSION },
51+ { op_combine, "combine", json_type_string, -1, JUST_EXPRESSION },
52+};
53
54 static int
55 extract_value(json_object *val, int value_type, string_list *values)
56
57=== modified file 'u1db/tests/c_backend_wrapper.pyx'
58--- u1db/tests/c_backend_wrapper.pyx 2012-07-26 16:24:39 +0000
59+++ u1db/tests/c_backend_wrapper.pyx 2012-08-14 21:13:23 +0000
60@@ -1,17 +1,19 @@
61 # Copyright 2011-2012 Canonical Ltd.
62 #
63-# This program is free software: you can redistribute it and/or modify it
64-# under the terms of the GNU General Public License version 3, as published
65-# by the Free Software Foundation.
66-#
67-# This program is distributed in the hope that it will be useful, but
68-# WITHOUT ANY WARRANTY; without even the implied warranties of
69-# MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR
70-# PURPOSE. See the GNU General Public License for more details.
71-#
72-# You should have received a copy of the GNU General Public License along
73-# with this program. If not, see <http://www.gnu.org/licenses/>.
74-
75+# This file is part of u1db.
76+#
77+# u1db is free software: you can redistribute it and/or modify
78+# it under the terms of the GNU Lesser General Public License version 3
79+# as published by the Free Software Foundation.
80+#
81+# u1db is distributed in the hope that it will be useful,
82+# but WITHOUT ANY WARRANTY; without even the implied warranty of
83+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
84+# GNU Lesser General Public License for more details.
85+#
86+# You should have received a copy of the GNU Lesser General Public License
87+# along with u1db. If not, see <http://www.gnu.org/licenses/>.
88+#
89 """A Cython wrapper around the C implementation of U1DB Database backend."""
90
91 cdef extern from "Python.h":

Subscribers

People subscribed via source and target branches