netpyoung / SqlCipher4Unity3D

💾 SqlCipher made easy for Unity3d
MIT License
163 stars 37 forks source link

WARN - SQLCipher 3.x - 4.x compatible problem #16

Closed netpyoung closed 4 years ago

netpyoung commented 5 years ago

test log on windows.

# scoop install msys
# mingw64
# pacman -Syu

# pacman -S mingw32/mingw-w64-i686-gcc
# pacman -S base-devel
# pacman -S tcl

# https://slproweb.com/products/Win32OpenSSL.html
# Win64 OpenSSL v1.0.2q # C:\OpenSSL-Win64 - check The OpenSSL binaries (/bin) directory
# Win32 OpenSSL v1.0.2q # C:\OpenSSL-Win32 - check The OpenSSL binaries (/bin) directory

  git clone https://github.com/sqlcipher/sqlcipher sqlcipher64
  git log
 commit 27d58453c6e56c3dd85e02bca379161bc69c746a (HEAD -> master, tag: v4.0.1, origin/prerelease, origin/master, origin/HEAD)

  cp /c/OpenSSL-Win64/bin/libeay32.dll ./
  ./configure --with-crypto-lib=none --disable-tcl CFLAGS="-DSQLITE_HAS_CODEC -DSQLCIPHER_CRYPTO_OPENSSL -I/c/OpenSSL-Win64/include /c/OpenSSL-Win64/bin/libeay32.dll -L/c/myHome/prj/hello/sqlcipher64 -static-libgcc" LDFLAGS="-leay32"
  make clean
  make sqlite3.c
  make
  make dll
netpyoung commented 5 years ago

https://github.com/netpyoung/SqlCipher4Unity3D/tree/master/testing_new_win64dll

netpyoung commented 5 years ago

I found the reason of that https://www.zetetic.net/blog/2018/11/30/sqlcipher-400-release/ from sqlcipher 4.x, some option of database was changed. Now SqlCipher4Unity3D using sqlcipher 3.x. Until now It's works. But there are some issue on future(ex, bugfix or something...)

netpyoung commented 5 years ago

for compile tag: v4.1.0, on x64 windows, It need to change on configure file.

for ac_option in --version -v -V -qversion; do

to

for ac_option in --version -v; do

because gcc doesn't have -V and -qversion options.

netpyoung commented 5 years ago

https://www.zetetic.net/blog/2018/12/18/sqlcipher-401-release/

PRAGMA cipher_compatibility = 3;.
netpyoung commented 4 years ago

close - duplicate with #25