Git Product home page Git Product logo

sqlite3-cmake's Introduction

sqlite3-cmake

Simplest CMake script + full sqlite3 amalgamation distibution to build with different compilers

Build examples:

On Windows from Visual Studio command prompt

  cmake -G "NMake Makefiles" -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=d:/libs
  nmake install

On Windows from Visual Studio IDE

  cmake -G "Visual Studio 12 Win64" -DCMAKE_INSTALL_PREFIX=d:/libs
  < open and build sqlite3.sln >

On Linux/FreeBSD without root access

  cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/home/student/libs
  make install

sqlite3-cmake's People

Contributors

alex85k avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

sqlite3-cmake's Issues

Your cmake file not work

I try add this project int my repo, but it not comping.
My CMakeLists.txt (adding libraries):

PROJECT(sqlite3)
cmake_minimum_required(VERSION 2.8)

link_libraries(pthread)
link_libraries(dl)

include_directories(${CMAKE_CURRENT_SOURCE_DIR})
add_library(sqlite3 STATIC src/sqlite3.c src/sqlite3.h src/sqlite3ext.h)
add_executable(sqlite src/sqlite3.c src/shell.c src/sqlite3.h src/sqlite3ext.h)
set_target_properties(sqlite PROPERTIES OUTPUT_NAME sqlite3)

add_definitions(-DSQLITE_ENABLE_RTREE)
add_definitions(-DSQLITE_ENABLE_FTS4)
add_definitions(-DSQLITE_ENABLE_FTS5)
add_definitions(-DSQLITE_ENABLE_JSON1)

target_link_libraries(sqlite3 ${CMAKE_DL_LIBS})
install(FILES src/sqlite3.h src/sqlite3ext.h DESTINATION include)
install(TARGETS sqlite3 LIBRARY DESTINATION lib ARCHIVE DESTINATION lib)
install(TARGETS sqlite RUNTIME DESTINATION bin)

My docker file:

FROM ubuntu:latest

RUN apt-get -qq update && apt-get -qq upgrade && apt-get -qqy install g++ libboost-all-dev cmake cmake-data libc6 libc6-dev sqlite3

WORKDIR /tmp/recast
RUN rm -rf /tmp/recast/*
COPY libs libs
COPY src src
COPY CMakeLists.txt ./

RUN mkdir build && cd build && cmake .. && make

And crash:

CMakeFiles/sqlite.dir/src/sqlite3.c.o: In function fts5Bm25GetData': /home/lionzxy/Recast/libs/sqlite/src/sqlite3.c:184444: undefined reference to log'
collect2: error: ld returned 1 exit status
libs/sqlite/CMakeFiles/sqlite.dir/build.make:120: recipe for target 'libs/sqlite/sqlite3' failed
make[2]: *** [libs/sqlite/sqlite3] Error 1
CMakeFiles/Makefile2:145: recipe for target 'libs/sqlite/CMakeFiles/sqlite.dir/all' failed
make[1]: *** [libs/sqlite/CMakeFiles/sqlite.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 33%] Linking C static library libsqlite3.a
[ 33%] Built target sqlite3
Makefile:127: recipe for target 'all' failed
make: *** [all] Error 2

In this Pull Request i try build project with sqlite glitchless/Recast#20

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.