Daily Archive for 十二月 23rd, 2005

compile MudOS using gcc41

為了讓 compile 時不要看到那麼多 warning
因此依照下列方式作了一些修改
GNUmakefile
  compile lex.c 使用 -trigraphs 參數

system_libs
  增加 -L/usr/local/lib -liconv (for PACKAGE_ICONV)
  增加 -L/usr/local/lib/mysql lmysqlclient  (for PACKAGE_DB)

sprintf.c
  195: if (error && state->obuff.buffer) {
  刪除 error

edit_source.c
  增加 #include stdlib.h

comm.c
  init_user_conn()
  size_t declaration problem
  
  new_user_handler()
  size_t declaration problem

socket_efuns.c
  socket_bind()
  size_t declaration problem
  
  socket_accept()
  size_t declaration problem
  
  socket_read_select_handler()
  size_t declaration problem

packages/chinese.c
  g2b()
  b2g()
  unsigned char declaration problem
  
packages/chinese.h
  g2b()
  b2g()
  unsigned char declaration problem
  
packages/contrib.c
  f_remove_fringe_blanks() unsigned char declaration problem
  
packages/ansi.c
  f_kill_repeat_ansi()
  f_remove_ansi()
  rally_ansi()
  unsigned char declaration problem

packages/iconv.c
  f_iconv_string()
  unsigned char, size_t declaration problem

packages/db.c
  554: return string_copy((char *)mysql_error(c->mysql.handle), "MySQL_errormsg:2");
  674: tmp = mysql_init(tmp);
  675: c->mysql.handle = (MYSQL *)mysql_real_connect(tmp, (const char *)host, (const char *)username, (const char *)password, (const char *)database, 3306, 0, 0);

addr_server.c
  new_conn_handler()
  size_t declaration problem

  init_conn_sock()
  size_t declaration problem