Giter VIP home page Giter VIP logo

qt5-sqlcipher's People

Contributors

sijk 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

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

qt5-sqlcipher's Issues

Cannot compile: qsqlcachedresult_p.h not found

I also tried using the Qt 5.2.1 sources from Qt website and my own SqlCipher plug-in but it does give me the same error. I cannot make it compile on Ubuntu 14.04 64bit. qsql_sqlite.cpp depends on an internal header, but that is not found. It resides in /qtbase/src/sql/kernel/.

/home/lars/Projects/qt5-sqlcipher/qtbase/src/sql/drivers/sqlite/qsql_sqlite.cpp:51:46: fatal error: QtSql/private/qsqlcachedresult_p.h: No such file or directory
 #include <QtSql/private/qsqlcachedresult_p.h>

Full console output:

g++ -c -m64 -pipe -O2 -fvisibility=hidden -fvisibility-inlines-hidden -std=c++0x -Wall -W -D_REENTRANT -fPIC -DNDEBUG -DSQLITE_OMIT_LOAD_EXTENSION -DSQLITE_OMIT_COMPLETE -DSQLITE_ENABLE_FTS3 -DSQLITE_ENABLE_FTS3_PARENTHESIS -DSQLITE_ENABLE_RTREE -DSQLITE_DISABLE_LFS -DQT_NO_CAST_TO_ASCII -DQT_NO_CAST_FROM_ASCII -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SQL_LIB -DQT_CORE_LIB -I/usr/lib/x86_64-linux-gnu/qt5/mkspecs/linux-g++-64 -I/home/lars/Projects/qt5-sqlcipher -I/home/lars/Projects/qt5-sqlcipher/qtbase/src/sql/drivers/sqlite -I/home/lars/Projects/qt5-sqlcipher/build/include -I/usr/include/qt5/QtSql/5.2.1 -I/usr/include/qt5/QtSql/5.2.1/QtSql -I/usr/include/qt5 -I/usr/include/qt5/QtSql -I/usr/include/qt5/QtCore/5.2.1 -I/usr/include/qt5/QtCore/5.2.1/QtCore -I/usr/include/qt5/QtCore -I. -I. -o qsql_sqlite.o /home/lars/Projects/qt5-sqlcipher/qtbase/src/sql/drivers/sqlite/qsql_sqlite.cpp
/home/lars/Projects/qt5-sqlcipher/qtbase/src/sql/drivers/sqlite/qsql_sqlite.cpp:51:46: fatal error: QtSql/private/qsqlcachedresult_p.h: No such file or directory
 #include <QtSql/private/qsqlcachedresult_p.h>
                                              ^
compilation terminated.

How to create a new encrypted database

Hello,

I have succeeded in building and loading the plugin into my App.

I am just stuck as to creating a new encrypted database...

Is there a simple example you can give me?

Kind Regards,

Drew

compile error

qsql_sqlite.cpp:339:7: error: no matching constructor for initialization of 'QSqlCachedResult' : QSqlCachedResult(db)

qsqlcipher uses sqlite instead of sqlcipher

first of all: thanks for aswering me on the PR and spending your time for this software ๐Ÿ˜Š

I followed your instruction and made the following steps:

tests will fail.

whe I run ldd against libqsqlcipher.so i see that it has been linked with sqlite, not sqlcipher.

compiling it in verbose mode I saw that the linker it's executed with -lsqlite.
running again the linker with -lsqlcipher will solve the problem and make tests to pass.

I hope that this will help you ๐Ÿ˜Š

CMake output:

-- The C compiler identification is GNU 4.8.5
-- The CXX compiler identification is GNU 4.9.3
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Found PkgConfig: /usr/bin/pkg-config (found version "0.26") 
-- checking for module 'sqlcipher'
--   found sqlcipher, version 2.2.1
-- Configuring done
-- Generating done
-- Build files have been written to: /home/nino/Documenti/qt5-sqlcipher/build

minor update - any interest?

thanks for the qsqlcipher plugin. Had to make a few minor tweaks (like use a different copy of private headers). I made a couple of changes to get the tests to compile correctly on Fedora (26/27). Cmake's convention seems to be set (CMAKE_CXX_STANDARD 14) rather than set(CMAKE_CXX_FLAGS "-std=c++14")
I also added the Qt example app sqlwidgetmapper under this project for my own verification of something tangible. Neither of these is a big deal but if you are interested, I can send over a changeset for consideration.

find_package(Qt5Sql REQUIRED) fails if Qt is installed from brew

CMake Error at CMakeLists.txt:6 (find_package):
  By not providing "FindQt5Sql.cmake" in CMAKE_MODULE_PATH this project has
  asked CMake to find a package configuration file provided by "Qt5Sql", but
  CMake did not find one.

  Could not find a package configuration file provided by "Qt5Sql" with any
  of the following names:

    Qt5SqlConfig.cmake
    qt5sql-config.cmake

  Add the installation prefix of "Qt5Sql" to CMAKE_PREFIX_PATH or set
  "Qt5Sql_DIR" to a directory containing one of the above files.  If "Qt5Sql"
  provides a separate development package or SDK, be sure it has been
  installed.


-- Configuring incomplete, errors occurred!
See also "<Your Folder>/qt5-sqlcipher-master/CMakeFiles/CMakeOutput.log".

Add ICU

Case-insensitive matching of Unicode characters does not work by default. Please add ICU support

$ wget http://www.sqlite.org/sqlite-amalgamation-XXXXX.tar.gz
$ tar xzfv sqlite*
$ cd sqlite*
$ CFLAGS='-Os -DSQLITE_ENABLE_ICU' CPPFLAGS=icu-config --cppflags LDFLAGS=icu-config --ldflags ./configure
$ make && sudo make install

Automatic acquisition of Qt sources

Dear sijk,

in my fork I implemented a download feature in CMake that automatically retrieves the correct headers/sources for the locally installed version of Qt5.
This makes building much more convenient (i.e. just do cmake && make).

I dont know whether my other changes are interesting for you, but some parts might be - please do tell me if you would like to merge some!

Cheers and thank you for this nice wrapper :)

Very good but difficult to package for distributions

Hi,

This sqlcipher plugin for Qt5 is very interesting.
But, because we need the full source code of Qt5 (not only headers), this is difficult to use it in a software that must be packaged in linux distribution.

I opened the following incident on Qt to include it in Qt:
https://bugreports.qt.io/browse/QTBUG-46150

As you can see, Qt team advices me to contact you.

What do you think? Are you ready to contribute to Qt with this really interesting plugin?

Does not compile with Qt 5.7.0

I assume that some internals have changed.
I get the following error:

qt-private\qsql_sqlite.cpp(340): error C2664: 'QSqlCachedResult::QSqlCachedResult(const QSqlCachedResult &)': cannot convert argument 1 from 'const QSQLiteDriver *' to 'QSqlCachedResultPrivate &

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.