2016-02-11 47 views
0

我試圖在我自己的版本中創建「Wt」庫(在版本3.3.5中),但在嘗試運行示例時失敗。Wt:致命錯誤:調用空boost :: function

我的環境是使用Boost 1.53.0的Debian,爲此我想構建這個庫。

編譯和鏈接(GCC 4.7.2)效果很好,但是當我嘗試運行重量-例(http://www.webtoolkit.eu/wt/doc/tutorial/wt.html),服務器失敗:

重量:致命錯誤:調用空升壓: :功能

完整的日誌是:

[email protected]:/tmp/$ wt_test --docroot . --http-address 0.0.0.0 --http-port 9090 
Option no-compression is implied because wthttp was built without zlib support. 
[2016-Feb-11 10:35:29.326974] 6436 - [info] "config: reading Wt config file: /etc/wt/wt_config.xml (location = 'wt_test')" 
Option no-compression is implied because wthttp was built without zlib support. 
[2016-Feb-11 10:35:29.327938] 6436 - [info] "WServer/wthttp: initializing built-in wthttpd" 
[2016-Feb-11 10:35:29.328281] 6436 - [info] "wthttp: started server: http://0.0.0.0:9090" 
[2016-Feb-11 10:35:33.971973] 6436 - [info] "Wt: session created (#sessions = 1)" 
[2016-Feb-11 10:35:33.972423] 6436 [/ mZ4BIN0ZPoVnqQTG] [info]  "WEnvironment: UserAgent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:44.0)  Gecko/20100101 Firefox/44.0" 
10.12.5.50 - - [2016-Feb-11 10:35:33.974561] "GET/HTTP/1.1" 200 4691 
[2016-Feb-11 10:35:33.974722] 6436 - [info] "WebRequest: took 3.044ms" 
[2016-Feb-11 10:35:34.026134] 6436 [/ mZ4BIN0ZPoVnqQTG] [error] "Wt: fatal error: call to empty boost::function" 
[2016-Feb-11 10:35:34.026242] 6436 - [info] "WebController: Removing session mZ4BIN0ZPoVnqQTG" 
[2016-Feb-11 10:35:34.026293] 6436 [/ mZ4BIN0ZPoVnqQTG] [info] "Wt: session destroyed (#sessions = 0)" 
10.12.5.50 - - [2016-Feb-11 10:35:34.026374] "GET /?wtd=mZ4BIN0ZPoVnqQTG&sid=2063522618&webGL=true&scrW=1680&scrH=1050&tz=60&htmlHistory=true&deployPath=%2F&request=script&rand=4063601615 HTTP/1.1" 500 84 
10.12.5.50 - - [2016-Feb-11 10:35:34.026375] "GET /?wtd=mZ4BIN0ZPoVnqQTG&request=style&page=1 HTTP/1.1" 200 0 
[2016-Feb-11 10:35:34.026414] 6436 - [info] "WebRequest: took 0.5ms" 
[2016-Feb-11 10:35:34.026430] 6436 - [info] "WebRequest: took 30.593ms" 

有誰有一個想法如何找出什麼錯誤嗎?

我知道Boost版本不是最新的,但我猜這應該不成問題?

Regads, VanDahlen

回答

0

我得到這樣的警告:

boost_1_60_0/boost/signal.hpp|17 col 4| warning: #warning "Boost.Signals is no longer being maintained and is now deprecated. Please switch to Boost.Signals2. To disable this warning message, define BOOST_SIGNALS_NO_DEPRECATION_WARNING." [-Wcpp]

這看起來像它可能有很多事情要做的事情。

這就是說,它只是工作,並在我的Ubuntu盒子上使用g ++ - 5在valgrind下乾淨地運行。 (使用libC++時確實無法鏈接)

+0

不,它在使用Boost 1.60.0和Signals2時沒有影響。該錯誤仍然相同。很奇怪.. – VanDahlen

+0

呵呵。你是如何用信號2來測試的? – sehe

+0

我設置了Boost 1.60.0並運行cmake; Wconfig.h包含'#define WT_USE_BOOST_SIGNALS2'。 – VanDahlen