Compiling with SQLite
impatient-dev via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Mon Nov 17 17:14:25 PST 2014
I'm new to D, and I'm trying to use SQLite, but I can't get this
basic program to compile:
import etc.c.sqlite3 : sqlite3_open;
void main(string[] args){
sqlite3_open("test.sqlite", null);
}
When compiling with DMD v2.066.1, I get this error:
test.o: In function `_Dmain':
test.d:(.text._Dmain+0x2f): undefined reference to `sqlite3_open'
collect2: ld returned 1 exit status
--- errorlevel 1
Any idea what I'm doing wrong? I'm on Ubuntu 12.04 64-bit, but I
doubt that matters. I've tried a couple alternatives, but they
didn't work either.
More information about the Digitalmars-d-learn
mailing list