Commit 8d5fe7bd authored by Bradley C. Kuszmaul's avatar Bradley C. Kuszmaul

up

git-svn-id: file:///svn/tokudb@517 c7de825b-a66e-492c-adef-691d508d4ae1
parent 45eac674
# On OSX do: # On OSX do:
# make OSX=OSX # make OSX=OSX
CFLAGS = -W -Wall -Wno-unused -g -fPIC -O2 LIBNAME=libdb
OPTFLAGS = -O2
CFLAGS = -W -Wall -Wno-unused -g -fPIC $(OPTFLAGS)
CPPFLAGS = -I../include -I../newbrt CPPFLAGS = -I../include -I../newbrt
CPPFLAGS += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE CPPFLAGS += -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE
...@@ -15,15 +18,20 @@ LIBEXT=so ...@@ -15,15 +18,20 @@ LIBEXT=so
SHARED=-shared SHARED=-shared
endif endif
LIBNAME=libdb.$(LIBEXT) install: $(LIBNAME).$(LIBEXT) $(LIBNAME).a
cp $(LIBNAME).$(LIBEXT) ../lib/
install: $(LIBNAME) cp $(LIBNAME).a ../lib
cp $(LIBNAME) ../lib/
clean: clean:
rm -rf *.$(LIBEXT) *.o rm -rf $(LIBNAME).$(LIBEXT) $(LIBNAME).a *.o
ydb.o: ../include/db.h ../newbrt/cachetable.h ../newbrt/brt.h ../newbrt/log.c ydb.o: ../include/db.h ../newbrt/cachetable.h ../newbrt/brt.h ../newbrt/log.c
DBBINS = ydb.o ../newbrt/brt.o ../newbrt/brt-serialize.o ../newbrt/cachetable.o ../newbrt/hashtable.o ../newbrt/header-io.o ../newbrt/key.o ../newbrt/memory.o ../newbrt/pma.o ../newbrt/ybt.o ../newbrt/primes.o ../newbrt/log.o ../newbrt/mempool.o DBBINS = ydb.o ../newbrt/brt.o ../newbrt/brt-serialize.o ../newbrt/brt-verify.o ../newbrt/cachetable.o ../newbrt/hashtable.o ../newbrt/header-io.o ../newbrt/key.o ../newbrt/memory.o ../newbrt/mempool.o ../newbrt/pma.o ../newbrt/ybt.o ../newbrt/primes.o ../newbrt/log.o ../newbrt/fingerprint.o
$(LIBNAME): $(DBBINS)
cc $(CPPFLAGS) $(DBBINS) $(SHARED) -o $@ $(CFLAGS) $(LIBNAME).$(LIBEXT): $(DBBINS)
cc $(CPPFLAGS) $(DBBINS) $(SHARED) -o $@ $(CFLAGS) -lz
$(LIBNAME).a: $(DBBINS)
$(AR) rv $@ $(DBBINS)
libdb.a(ydb.o): ydb.o libdb.a(ydb.o): ydb.o
...@@ -13,17 +13,14 @@ struct db_header { ...@@ -13,17 +13,14 @@ struct db_header {
struct __toku_db_internal { struct __toku_db_internal {
int freed; int freed;
int (*bt_compare)(DB *, const DBT *, const DBT *);
struct db_header *header; struct db_header *header;
int database_number; // -1 if it is the single unnamed database. Nonnengative number otherwise. int database_number; // -1 if it is the single unnamed database. Nonnengative number otherwise.
DB_ENV *env;
char *full_fname; char *full_fname;
char *database_name; char *database_name;
//int fd; //int fd;
u_int32_t open_flags; u_int32_t open_flags;
int open_mode; int open_mode;
BRT brt; BRT brt;
int is_db_dup; FILENUM fileid;
unsigned long long fileid;
}; };
#endif #endif
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment