Started creating database code
This commit is contained in:
parent
b29f7c9063
commit
98967395c4
7
sql/players.sql
Normal file
7
sql/players.sql
Normal file
@ -0,0 +1,7 @@
|
||||
CREATE TABLE players (
|
||||
id integer primary key,
|
||||
login varchar(50) not null unique,
|
||||
password varchar(50),
|
||||
email varchar(150) not null unique
|
||||
);
|
||||
|
@ -1,5 +1,5 @@
|
||||
bin_PROGRAMS = wmud
|
||||
AM_CFLAGS = $(MEMCACHED_CFLAGS) $(GLIB_CFLAGS) $(GIO_CFLAGS) $(GTHREAD_CFLAGS) $(SQLITE3_CFLAGS)
|
||||
|
||||
wmud_SOURCES = main.c networking.c interpreter.c
|
||||
wmud_SOURCES = main.c networking.c interpreter.c db.c
|
||||
wmud_LDADD = $(MEMCACHED_LIBS) $(GLIB_LIBS) $(GIO_LIBS) $(GTHREAD_LIBS) $(SQLITE3_LIBS)
|
||||
|
12
src/db.c
Normal file
12
src/db.c
Normal file
@ -0,0 +1,12 @@
|
||||
#include <sqlite3.h>
|
||||
|
||||
#include "db.h"
|
||||
|
||||
sqlite3 *dbh = NULL;
|
||||
|
||||
gboolean
|
||||
wmud_db_init(void)
|
||||
{
|
||||
sqlite3_open(
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user