From: Jack Lange Date: Tue, 7 Oct 2008 23:35:52 +0000 (-0500) Subject: fixed ceil linking issue and net.c compile problems X-Git-Tag: 1.0~3^2~4 X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?p=palacios.git;a=commitdiff_plain;h=d2720fdaa2bb5588049e1fec7eb66960ca928b2d fixed ceil linking issue and net.c compile problems we now compile v3vee with machine local compiler while geekos is dependent on old version --- diff --git a/geekos/src/geekos/net.c b/geekos/src/geekos/net.c index 0716519..0d28088 100644 --- a/geekos/src/geekos/net.c +++ b/geekos/src/geekos/net.c @@ -79,7 +79,7 @@ void Init_Network() { } -#endif + #if 0 diff --git a/palacios/build/Makefile b/palacios/build/Makefile index 4685f11..d612435 100644 --- a/palacios/build/Makefile +++ b/palacios/build/Makefile @@ -275,11 +275,11 @@ V3_ARCH := __V3_32BIT__ #V3_ARCH := __V3_64BIT__ # Uncomment if cross compiling -TARGET_CC_PREFIX := $(PROJECT_ROOT)/../devtools/i386/bin/i386-elf- +#TARGET_CC_PREFIX := $(PROJECT_ROOT)/../devtools/i386/bin/i386-elf- #TARGET_CC_PREFIX := i386-elf- # Target C compiler. gcc 2.95.2 or later should work. -TARGET_CC := $(TARGET_CC_PREFIX)gcc +TARGET_CC := $(TARGET_CC_PREFIX)gcc -m32 #TARGET_CC := $(TARGET_CC_PREFIX)gcc34 -m32 diff --git a/palacios/include/palacios/vmm_string.h b/palacios/include/palacios/vmm_string.h index 60155a0..975a3d1 100644 --- a/palacios/include/palacios/vmm_string.h +++ b/palacios/include/palacios/vmm_string.h @@ -56,7 +56,7 @@ char *strrchr(const char *s, int c); char *strpbrk(const char *s, const char *accept); -double ceil(double x); +double v3_ceil(double x); diff --git a/palacios/src/palacios/vmm_hashtable.c b/palacios/src/palacios/vmm_hashtable.c index d5e844b..65dbca1 100644 --- a/palacios/src/palacios/vmm_hashtable.c +++ b/palacios/src/palacios/vmm_hashtable.c @@ -233,7 +233,7 @@ struct hashtable * create_hashtable(uint_t min_size, htable->entry_count = 0; htable->hash_fn = hash_fn; htable->eq_fn = eq_fn; - htable->load_limit = (uint_t) ceil((double)(size * max_load_factor)); + htable->load_limit = (uint_t) v3_ceil((double)(size * max_load_factor)); return htable; } @@ -317,7 +317,7 @@ static int hashtable_expand(struct hashtable * htable) { htable->table_length = new_size; - htable->load_limit = (uint_t) ceil(new_size * max_load_factor); + htable->load_limit = (uint_t) v3_ceil(new_size * max_load_factor); return -1; } diff --git a/palacios/src/palacios/vmm_string.c b/palacios/src/palacios/vmm_string.c index e98efd2..7107782 100644 --- a/palacios/src/palacios/vmm_string.c +++ b/palacios/src/palacios/vmm_string.c @@ -63,7 +63,7 @@ static float e = 0.00000001; -double ceil(double x) { +double v3_ceil(double x) { if ((double)(x - (int)x) == 0) { return (int)x; }