看板 b96902HW 關於我們 聯絡資訊
※ 引述《curtisyyc (大麻吉)》之銘言: : 6. Test Nachos: : * ~/nachos/NachOS-4.0/code/build.linux> ./nachos : You should see the following message: : ┌─────────────────────┐ : │Machine halting! │ : │ │ : │Ticks: total 10, idle 0, system 10, user 0│ : │Disk I/O: reads 0, writes 0 │ : │Console I/O: reads 0, writes 0 │ : │Paging: faults 0 │ : │Network I/O: packets received 0, sent 0 │ : └─────────────────────┘ : 我的只有出現 : b96026@linux12: ~/nachos/NachOS-4.0/code/build.linux> ./nachos : ./nachos: Command not found. : 請問 我做了甚麼蠢事了嗎??? 以下是我make出來的東西 有沒有人跟我一樣啊 g++ -g -Wall -I../network -I../filesys -I../userprog -I../threads -I../machine -I../lib -I- -DFILESYS_STUB -DRDATA -DSIM_FIX -Dx86 -DLINUX -DCHANGED -c ../threads/thread.cc cc1plus: note: obsolete option -I- used, please use -iquote instead ../threads/thread.cc: In member function 'void Thread::Fork(void (*)(void*), void*)': ../threads/thread.cc:98: error: cast from 'void (*)(void*)' to 'int' loses precision ../threads/thread.cc: In member function 'void Thread::StackAllocate(void (*)(void*), void*)': ../threads/thread.cc:345: error: cast from 'void (*)()' to 'int' loses precision ../threads/thread.cc: In member function 'void Thread::SelfTest()': ../threads/thread.cc:430: warning: deprecated conversion from string constant to 'char*' make: *** [thread.o] Error 1 實在看不懂他是想幹麻 有沒有強者可以幫忙解惑一下 <(_ _)> 謝謝 -- ※ 發信站: 批踢踢實業坊(ptt.cc) ◆ From: 124.8.23.196 ※ 編輯: curtisyyc 來自: 124.8.23.196 (09/24 21:52)
kalvin29:在下make depend 前先到code/test/Makefile加一下投影片 09/24 22:05
kalvin29:24頁框框里的東西之後在make depend 09/24 22:06
curtisyyc:是把那一段插到Makefile最下面嗎 我這樣做了還是一樣耶 09/24 22:43
curtisyyc:都看不出來有什麼差別 09/24 22:44
LoganChien:你是在編譯 nachos 本身的時候有問題嗎? 09/24 23:54
LoganChien:你要先下載 nachos-linux-64bit.diff 這個修正檔。 09/24 23:54
LoganChien:然後移到 Nachos-4.0 資料夾之後,執行: 09/24 23:55
LoganChien:patch -p1 < nachos-linux-64bit.diff 09/24 23:55
LoganChien:會有這樣的 Error 是因為 thread.cc 嘗試把 pointer 09/24 23:56
LoganChien:type 轉型成 int,可是這個轉型未必成立。例如在工作站 09/24 23:57
LoganChien:pointer type 是要用去 64bits,而 int 只有 32bits。 09/24 23:57
olala7846:........OS2009/files/nachos/217%2864-bit%29.htm 10/01 00:40
curtisyyc:我試成功了 謝謝大家的幫忙^^ 10/01 23:11