Index: Makefile --- Makefile.orig 2009-07-27 09:55:23 +0200 +++ Makefile 2010-01-07 09:58:18 +0100 @@ -2,11 +2,11 @@ INSTALL_PREFIX = /usr/local -CFLAGS = -Wall -O3 -fPIC -fomit-frame-pointer -I vm -D_GNU_SOURCE -EXTFLAGS = -pthread +CFLAGS = -Wall -O2 -fPIC -fomit-frame-pointer -I vm -D_GNU_SOURCE +EXTFLAGS = MAKESO = $(CC) -shared -WBsymbolic LIBNEKO_NAME = libneko.so -LIBNEKO_LIBS = -ldl -lgc -lm +LIBNEKO_LIBS = -lgc -lm NEKOVM_FLAGS = -Lbin -lneko STD_NDLL_FLAGS = ${NEKOVM_FLAGS} INSTALL_FLAGS = Index: libs/std/process.c --- libs/std/process.c.orig 2009-07-27 09:55:13 +0200 +++ libs/std/process.c 2010-01-07 09:58:18 +0100 @@ -23,7 +23,7 @@ # include # include # ifndef NEKO_MAC -# include +# include # endif #endif Index: libs/std/sys.c --- libs/std/sys.c.orig 2009-07-27 09:55:14 +0200 +++ libs/std/sys.c 2010-01-07 09:58:18 +0100 @@ -35,7 +35,6 @@ # include # include # include -# include #endif #ifdef NEKO_MAC @@ -123,7 +122,7 @@ Set the locale for LC_TIME, returns true on success **/ static value set_time_locale( value l ) { -#ifdef NEKO_POSIX +#if 0 locale_t lc, old; val_check(l,string); lc = newlocale(LC_TIME_MASK,val_string(l),NULL); Index: src/tools/install.neko --- src/tools/install.neko.orig 2009-07-27 09:55:22 +0200 +++ src/tools/install.neko 2010-01-07 10:00:59 +0100 @@ -39,32 +39,6 @@ // LIBS DATAS libs = { - mod_neko => { - src => $array("../../vm/stats","mod_neko","cgi"), - inc => "httpd.h", - incname => "Apache 1.3.x" - }, - mod_neko2 => { - src => $array("../../vm/stats","mod_neko","cgi"), - inc => $array("httpd.h","apr.h"), - incname => "Apache 2.2.x", - cflags => "-D_LARGEFILE64_SOURCE", - realdir => "mod_neko", - apache2 => true, - }, - mysql => { - src => $array("mysql"), - inc => "mysql.h", - incname => "MySQL 4.+" - lib => "libmysqlclient_r.a", - lparams => "-lz -lssl" - }, - mysql5 => { - src => $array("../common/sha1","../common/socket","my_proto/my_proto","my_proto/my_api","mysql"), - inc => $array(), - realdir => "mysql", - cflags => "-Imy_proto -I../common", - }, regexp => { src => $array("regexp"), inc => "pcre.h", @@ -77,46 +51,18 @@ incname => "LibZ", lparams => "-lz", }, - sqlite => { - src => $array("sqlite"), - inc => "sqlite3.h", - incname => "Sqlite 3", - lparams => "-lsqlite3", - }, - ui => { - src => $array("ui"), - inc => switch system { "Mac" => "Carbon.h" default => "gtk/gtk.h" }, - incname => switch system { "Mac" => "Carbon" default => "GTK+2.0" }, - cflags => switch system { "Mac" => "" default => "`pkg-config --cflags gtk+-2.0`" }, - lparams => switch system { "Mac" => "-framework Carbon" default => "`pkg-config --libs gtk+-2.0` -lgthread-2.0" }, - }, - mod_tora => { - src => $array("../common/socket","protocol","mod_tora"), - inc => "httpd.h", - incname => "Apache 1.3.x", - cflags => "-I../common", - }, - mod_tora2 => { - src => $array("../common/socket","protocol","mod_tora"), - inc => $array("httpd.h","apr.h"), - incname => "Apache 2.2.x", - cflags => "-D_LARGEFILE64_SOURCE -I../common", - realdir => "mod_tora", - apache2 => true, - }, } // PLATFORM -cflags = "-O3 -fPIC"; -if( system == "Linux" ) cflags += " -pthread"; +cflags = "-O2 -fPIC"; cc = getenv("CC"); if( cc == null ) cc = "gcc"; linkcmd = switch system { "BSD" => "ld" default => cc }; linkneko = "-lneko"; linkoptions = switch system { "Mac" => "-bundle -undefined dynamic_lookup -L../../bin" - default => "-shared -L../../bin -pthread" + default => "-shared -L../../bin" }; nekovm = switch system { "Windows" => "..\\bin\\neko" default => "../bin/neko" }; @@ -140,38 +86,14 @@ search_includes = function(isap2) { var inc1 = $array( - "/usr/include", - "/usr/local/include/mysql", - "/usr/include/mysql", - "/usr/local/include", - "/usr/include/gtk-2.0", - "/opt/local/include", - "/opt/local/include/mysql", - "/Developer/Headers/FlatCarbon", + "@l_prefix@/include" ); var inc2; if( isap2 ) inc2 = $array( - "/usr/local/apache2/include", - "/usr/include/apache2", - "/opt/local/apache2/include", - "/usr/include/apr-1", - "/usr/include/apr-1.0", - "/usr/include/apr-0", - "/usr/local/include/apr-1", - "/usr/local/include/apr-1.0", - "/usr/local/include/apr-0", - "/opt/local/include/apr-1", - "/opt/local/include/apr-1.0", - "/opt/local/include/apr-0" ); else inc2 = $array( - "/usr/apache/include", - "/usr/include/apache-1.3", - "/usr/include/httpd", - "/opt/local/include/apache", - "/usr/local/apache/include" ); return $aconcat($array(inc1,inc2)); } @@ -180,12 +102,7 @@ cwd = $ssub(cwd,0,$ssize(cwd)-1); libraries = $array( cwd, - "/usr/lib", - "/usr/lib/mysql", - "/usr/local/lib", - "/usr/local/lib/mysql", - "/opt/local/lib", - "/opt/local/lib/mysql", + "@l_prefix@/lib" ); exec = function(cmd) { @@ -358,7 +275,7 @@ compile(data.src[i],if( data.cflags != null ) data.cflags else "", dirs); i = i + 1; } - link(data.src,name,if( data.lparams != null ) { data.lparams+" " } else ""," "+linklib); + link(data.src,name," "+linklib+" ",if( data.lparams != null ) { " "+data.lparams } else ""); chdir(".."); data.built = true; }