青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品

EverSpring working shop

To pursue creative ideas based on nature.

統計

留言簿(1)

他山之石

閱讀排行榜

評論排行榜

How to Compile/Test Loki source code in Linux

Previously, I review and test the source code of the Loki under the windows XP by the visual C++ express. It is easy to compile and test the Loki code in windows. Just download the zip file or the .exe file from the sourceforge website. The directory contains the Visual C++ project file, which can read the makefile automatically and compile the code in the test directory very easily. However, you may not know the dependency between the src files in this project because they are hidden in the makefile and the src code themselves.
?
Today, I update my PC to the Linux Enviroment and tried to re-install the visual C++ express in the windows based on the vmware. Unfortunately, the VC++ express failed to be installed sucessfully due to some unknown errors. So I turn to compile and test the code purely in the Linux envrioment, as the Loki states that it is completely supported by the gcc.
?
Actually, it is a little mysterial that how to compile the test code, at least generate?the .o file to run under the command line, because I am not sure how to dedicate the include path for a specified src file and futher how to include other src files on which the on-testing files are depending.
?
Select the file Factory.cpp as an example. Before I test the this src file, I have no idea that which files should this Factory.cpp use.
First step, because all the .h files this Loki project uses are all stored in the directory ../loki-0.1.7/include, even I have no compelete knowlege that which .h files are used in this test, I can indicate the g++ compiler to search the dedicated directory firstly before the current directory and the system including directory. Just like below:
?
g++ -I? /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/include/ -o /localdisk/data/alex_dyn/hello /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/test/Factory/Factory.cpp
?
However, although the .h files can be found, many errors? like "undefined reference to `Loki::SmallObjAllocator::~SmallObjAllocator()" blocks the generation of the hello.o. It is because some implementation of the methods are not found. Actually, only the .h files are inlcuded, but the implementaiton files are not found.
So, I need to find where these undefined references are, i.e, find the src files which the Factory.cpp depends on. As the all the source files are already added to the sourceinsight tool project, it is easy to find that the undefined references are from two files Singleton.cpp and SmallObj.cpp. Actually, all the libary src .cpp files (not the testing files with main() function )?are in the directory /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/src.
How to let the Factory.cpp to know where these undefined reference to be found? I ever tried to dedicate the src directory in the compiling process, but failed. When checking the priciple for writing the Makefile in the linux envriroment, it is found that I can compile the depending files to .o files firstly, with the compile option -c, which means no executive files are generated for those src files without main() function. Usage of the -c option?is usually used to make the modules which?are linked later to?other modules.?
?
So the next step?is to?compile the Singleton.cpp and SmallObj.cpp to generat the?middle product Singleton and SmallObj.
?
g++ -c -I? /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/include/ -o /localdisk/data/alex_dyn/SmallObj /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/src/SmallObj.cpp
g++ -I? /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/include/ -c -o /localdisk/data/alex_dyn/Singleton /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/src/Singleton.cpp
?
We can see two result files: SmallObj and Singleton in directory /localdisk/data/alex_dyn
[alexzh@alexzhang_lnx alex_dyn]$ ll /localdisk/data/alex_dyn
total 328
drwxr-xr-x? 2 root?? root????? 4096 Feb? 6 19:54 boost
drwxr-xr-x? 3 root?? root????? 4096 Feb 15 15:45 loki
-rw-r-----? 1 alexzh NSS_VC??? 7260 Feb 15 17:07 Singleton
-rw-r-----? 1 alexzh NSS_VC?? 57244 Feb 15 16:47 SmallObj

With these two depending files,?I tried to?linked them to Factory.cpp when compiling the Factory.cpp as:
[alexzh@alexzhang_lnx src]$ g++ -I? /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/include/ -o /localdisk/data/alex_dyn/hello /localdisk/data/alex_dyn/Singleton/localdisk/data/alex_dyn/SmallObj /localdisk/data/alex_dyn/loki/loki-0.1.7/loki-0.1.7/test/Factory/Factory.cpp
The final executive file hello are found in the /localdisk/data/alex_dyn now. Enter this?diretory and execute the hello as
[alexzh@alexzhang_lnx alex_dyn]$ pwd
/localdisk/data/alex_dyn
[alexzh@alexzhang_lnx alex_dyn]$ hello
?
creator function is a simple function:
createProductNull()
createProductParm( int a, int b )
?
creator function is a overloaded function:
createProductOver()
createProductOver( int a, int b )
?
creator function is a member function:
Creator::create()
Creator::create( int a, int b )
?
creator function is a template member function
CreatorT<T>::create()
CreatorT<T>::create( int a, int b )
?
creator function is a functor parameter
createProductParm( int a, int b )
??? called by createProductRuntime(CreateFunctor func, int a, int b)
CreatorT<T>::create( int a, int b )
??? called by createProductRuntime(CreateFunctor func, int a, int b)
?
Registered ids:
Four
One
Three
Two
?
OK, that is the way I can follow to debug the rest files in this Loki project......Opps..
?

posted on 2009-02-15 19:43 everspring79 閱讀(1673) 評論(4)  編輯 收藏 引用 所屬分類: Notes

評論

# re: How to Compile/Test Loki source code in Linux 2009-02-15 20:08 everspring79

For any suggestion or experience of you on this pratice, please kindly reply this tip directly. Thanks!  回復  更多評論   

# re: How to Compile/Test Loki source code in Linux 2009-02-16 09:25 zuhd

nice English, how can you do this, really amazing!  回復  更多評論   

# re: How to Compile/Test Loki source code in Linux 2009-02-16 11:53 true

ni de ying yu hen hao ,ru he zuo dao de?mao si ni zai wai qi  回復  更多評論   

# re: How to Compile/Test Loki source code in Linux[未登錄] 2009-02-16 11:58 Everspring79

@true
Yes, English is our working language, which is mandatory in all kinds of communications like email, conference, presentation, document, etc. Actually, it is quite simple to use English for technical communication, compared with the daily English.  回復  更多評論   

青青草原综合久久大伊人导航_色综合久久天天综合_日日噜噜夜夜狠狠久久丁香五月_热久久这里只有精品
  • <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>
            午夜电影亚洲| 欧美一区二区在线免费观看 | 欧美高清在线观看| 亚洲高清精品中出| 亚洲电影av在线| 欧美国产精品v| 亚洲一二区在线| 亚洲欧美在线磁力| 精品69视频一区二区三区| 欧美成人精品不卡视频在线观看| 免费一级欧美片在线观看| 亚洲理伦在线| 亚洲午夜激情在线| 激情婷婷久久| 亚洲精品自在久久| 国产视频在线观看一区二区三区 | 99在线精品免费视频九九视| 亚洲久久在线| 国产曰批免费观看久久久| 欧美大片免费观看在线观看网站推荐| 欧美国产一区视频在线观看 | 一色屋精品视频在线看| 亚洲第一中文字幕| 国产精品亚洲片夜色在线| 久久在线精品| 欧美午夜激情视频| 欧美本精品男人aⅴ天堂| 欧美日韩一区二区欧美激情| 久久久久久久97| 欧美日韩国产首页| 麻豆精品在线视频| 国产精品二区影院| 欧美激情视频一区二区三区免费| 欧美婷婷六月丁香综合色| 老色鬼精品视频在线观看播放| 欧美日韩另类在线| 免费人成网站在线观看欧美高清| 欧美先锋影音| 亚洲国产精品久久久久婷婷884| 国产精品日韩精品欧美精品| 欧美激情视频一区二区三区不卡| 国产日韩av高清| 日韩午夜在线电影| 亚洲精品一区二区三区av| 午夜久久久久久| 中国成人亚色综合网站| 久久综合久久综合久久综合| 欧美一区二区国产| 国产精品高潮在线| 亚洲人成在线免费观看| 亚洲高清不卡一区| 久久久久看片| 久久精品99国产精品日本| 欧美日韩在线免费视频| 亚洲国产综合视频在线观看| 尹人成人综合网| 欧美一区二区三区在线看| 亚洲欧美日本国产有色| 欧美精品日韩一区| 亚洲国产精品一区二区尤物区| 国语精品一区| 久久久蜜桃一区二区人| 久久久在线视频| 国产综合香蕉五月婷在线| 亚洲综合国产激情另类一区| 亚洲影视在线播放| 欧美视频中文在线看| 一区二区欧美国产| 亚洲欧美亚洲| 国产精品亚洲欧美| 性色av一区二区怡红| 久久av一区二区三区漫画| 国产美女精品视频免费观看| 亚洲一级一区| 久久精品99无色码中文字幕| 国产欧美精品日韩精品| 亚洲欧美日韩精品久久| 欧美在线国产| 韩国av一区二区三区| 国产日韩欧美电影在线观看| 亚洲欧美精品在线| 久久精品国产亚洲精品| 精久久久久久| 欧美1区视频| 99爱精品视频| 久久精品动漫| 亚洲欧洲在线一区| 欧美日韩一区二区在线| 亚洲字幕一区二区| 免费日韩av| 99国产精品久久久| 国产精品一区二区在线观看| 翔田千里一区二区| 亚洲丶国产丶欧美一区二区三区| 99国内精品久久久久久久软件| 欧美性猛交xxxx免费看久久久| 亚洲一区二区三区四区在线观看 | 亚洲激情偷拍| 国产精品久久久久一区| 久久精品99| 最新中文字幕一区二区三区| 亚洲欧美日韩在线一区| 国产在线精品自拍| 欧美日韩精品一区二区三区四区 | 日韩一级在线| 久久久亚洲高清| 99re8这里有精品热视频免费| 国产精品男人爽免费视频1| 久久久久久久成人| 亚洲一区欧美激情| 亚洲欧洲精品一区二区| 久久免费黄色| 亚洲综合欧美日韩| 亚洲区欧美区| 国内偷自视频区视频综合| 欧美久久久久久蜜桃| 久久精品系列| 亚洲一区二区3| 亚洲激情啪啪| 蜜臀av性久久久久蜜臀aⅴ四虎| 亚洲一区一卡| 亚洲最快最全在线视频| 亚洲大胆在线| 国产视频久久久久| 欧美精品三级| 西西裸体人体做爰大胆久久久| 亚洲福利久久| 亚洲欧美日本精品| 欧美日韩在线播放一区二区| 亚洲精品一区二区三区99| 久久精视频免费在线久久完整在线看| 亚洲国产欧美一区二区三区久久 | 鲁大师成人一区二区三区 | 亚洲精品孕妇| 麻豆视频一区二区| 欧美综合77777色婷婷| 日韩亚洲欧美成人| 亚洲国产精品va在线看黑人| 国产精品视频yy9099| 欧美性猛交xxxx乱大交退制版| 欧美成人精品在线观看| 久久人人爽人人爽爽久久| 久久精品亚洲一区二区三区浴池| 亚洲一区二区在线视频| 亚洲私人影院在线观看| 一区二区三区精品在线| 一本久久青青| 99riav1国产精品视频| 日韩视频在线观看免费| 亚洲精品系列| 一区二区高清视频| 亚洲色在线视频| 亚洲视频免费在线| 亚洲欧美日韩精品| 久久国产精品久久精品国产| 欧美一区二区在线观看| 久久精彩视频| 久久综合国产精品| 欧美精品情趣视频| 国产精品久久久久毛片大屁完整版| 欧美日韩在线综合| 国产精品一二三| 国产无一区二区| 黄色影院成人| 亚洲毛片播放| 亚洲专区在线| 久久精品国产亚洲aⅴ| 麻豆精品精品国产自在97香蕉| 欧美高清自拍一区| 日韩亚洲不卡在线| 亚洲欧美区自拍先锋| 久久九九热re6这里有精品| 老鸭窝91久久精品色噜噜导演| 欧美 亚欧 日韩视频在线| 欧美视频亚洲视频| 国产午夜精品全部视频播放| 亚洲春色另类小说| 亚洲一区高清| 欧美不卡福利| 亚洲天堂第二页| 久久性色av| 国产精品大片wwwwww| 怡红院精品视频| 亚洲午夜av在线| 免费国产自线拍一欧美视频| 亚洲伦理网站| 久久久999精品免费| 欧美视频免费在线观看| 在线播放日韩欧美| 午夜精品成人在线视频| 欧美1区免费| 亚洲男女自偷自拍图片另类| 免费亚洲视频| 国产在线观看一区| 亚洲欧美日韩一区在线| 亚洲国产欧美一区二区三区丁香婷| 香蕉久久精品日日躁夜夜躁| 欧美精品手机在线| 在线播放豆国产99亚洲| 欧美一区视频|