sqlite3 not (yet) working on Lollipop

1,700 views
Skip to first unread message

nanobrain

unread,
Nov 20, 2014, 8:55:22 AM11/20/14
to tas...@googlegroups.com
If you are itching to jump on the Lollipop train AND are depending on sqlite3 in your tasks, please be aware that the current bunch of sqlite3 binaries available wont work because they now the need to be PIE (position independent executables). I've been looking for the last couple of days and so far I have not been able to locate one that was compiled that way. This will change once Lollipop gets a wider user base, but be forewarned in the meantime.

Adam Lopresto

unread,
Nov 20, 2014, 12:26:17 PM11/20/14
to tas...@googlegroups.com
I created an emulator in Android Studio (emulating a Nexus 5 running Lollipop), and it came with a version of sqlite that worked when i copied it to a real Nexus 5. 

nanobrain

unread,
Nov 20, 2014, 8:59:16 PM11/20/14
to tas...@googlegroups.com
Care to share?

glimm

unread,
Nov 22, 2014, 6:27:00 AM11/22/14
to tas...@googlegroups.com
I have another workaround, if you have Titanium Backup installed on your device. It has its own sqlite3 binary, which you can use with root.
Set the variable %SQLITE3 to "/data/data/com.keramidas.TitaniumBackup/files/sqlite3".

nanobrain

unread,
Nov 22, 2014, 1:30:24 PM11/22/14
to tas...@googlegroups.com
Excellent, thanks a bunch

Rory Harnisch

unread,
Nov 25, 2014, 11:49:42 AM11/25/14
to tas...@googlegroups.com
Has anyone else tested this?
Message has been deleted

nanobrain

unread,
Nov 25, 2014, 2:27:53 PM11/25/14
to tas...@googlegroups.com
I actually copied the titanium backup sqlite3 binary to system/xbin and it has been working for me since.

On Tuesday, November 25, 2014 11:49:42 AM UTC-5, Rory Harnisch wrote:
Has anyone else tested this?

Rory Harnisch

unread,
Nov 25, 2014, 3:22:20 PM11/25/14
to tas...@googlegroups.com
Awesome, thanks nanobrain! That worked perfectly. Has this been shared across the G+ communities yet?

--
You received this message because you are subscribed to a topic in the Google Groups "Tasker" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tasker/raFenn0NJTM/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tasker+un...@googlegroups.com.
Visit this group at http://groups.google.com/group/tasker.
For more options, visit https://groups.google.com/d/optout.

nanobrain

unread,
Nov 25, 2014, 4:22:42 PM11/25/14
to tas...@googlegroups.com
Not from me. Credit goes to glimm

glimm

unread,
Nov 27, 2014, 7:31:03 PM11/27/14
to tas...@googlegroups.com
A symlink is an alternative solution, if you want the binary in your PATH (/system/xbin) and your system-rom is nearly full. For example there is only 200KB free space left in the /system of my Nexus 7 after installing Lollipop + SuperSu + Busybox.

su
mount -o remount,rw /system
ln -s /data/data/com.keramidas.TitaniumBackup/files/sqlite3 /system/xbin/sqlite3
mount -o remount,ro /system

Symlink has only 53 B and the binary has 300 KB.

Paul [sabret00the]

unread,
Dec 28, 2014, 6:57:54 PM12/28/14
to tas...@googlegroups.com
I've just run into this. Anyone know a workaround for people that haven't got/installed Titanium Backup?

nanobrain

unread,
Dec 28, 2014, 7:48:33 PM12/28/14
to tas...@googlegroups.com

Paul [sabret00the]

unread,
Feb 16, 2015, 3:37:45 PM2/16/15
to tas...@googlegroups.com

Thanks.

--

gary scarborough

unread,
Sep 13, 2015, 6:25:49 PM9/13/15
to Tasker
I just tried this and man did it relieve stress from some of my profiles not working thanks nanobrain and Glimm

Timtim1980

unread,
May 7, 2018, 6:07:02 AM5/7/18
to Tasker
Ok I am trying to do something simple, even set the variable as suggested here

sqlLiteDemoCreate (5)
A1: Variable Set [ Name:%SQLITE3 To:"/data/data/com.keramidas.TitaniumBackup/files/sqlite3" Do Maths:Off Append:Off ] 
A2: Variable Set [ Name:%Weight To:10 Do Maths:Off Append:Off ] 
A3: Test File [ Type:Size Data:/storage/sdcard0/weighttracker.db Store Result In:%filesize Use Root:Off Continue Task After Error:On ] 
A4: Run Shell [ Command:Command = sqlite3 /storage/sdcard0/weighttracker.db "CREATE TABLE weight (date TEXT, weight REAL);" Timeout (Seconds):0 Use Root:On Store Output In: Store Errors In: Store Result In: Continue Task After Error:On ] If [ %filesize eq 0 ]
A5: Run Shell [ Command:Command = sqlite3 /storage/sdcard0/weighttracker.db "INSERT INTO weight (date, weight) VALUES ('%DATE', %Weight);" Timeout (Seconds):0 Use Root:On Store Output In: Store Errors In: Store Result In: Continue Task After Error:On ] 
 but I get this error:-









nanobrain

unread,
May 7, 2018, 7:53:30 AM5/7/18
to Tasker
I can't see the error message, but in A4 and A5 you probably need to replace sqlite3 by %SQLITE3 in the shell commands. Also, since then there is now a SQLite plugin for Tasker: https://play.google.com/store/apps/details?id=com.jordanhotmann.taskersqliteplugin&hl=en_US . No need to have a full blown Titanium Backup install just for the sqlite binary (though obviously still useful for the main purpose of the app)
Reply all
Reply to author
Forward
0 new messages