//---------------------------------------------------------------
//@file: hello.cpp
#include <stdio.h>
#include "ace/Log_Msg.h"
#include "ace/OS_main.h"
int ACE_TMAIN(int argc, ACE_TCHAR* argv[])
{
ACE_DEBUG((LM_DEBUG,ACE_TEXT("hello world./n")));
return 0;
}
//-------------------------------------------------------------
再写hello.mpc
project(hello) :aceexe{
exename = hello
after += hello
Source_Files {
hello.cpp
}
}
------------------------------------------------------------
用MPC实用工具生成Makefile文件
$ACE_ROOT/bin/mwc.pl -type make hello.mpc
您将得到Makefile和Makefile.hello两个文件
运行make
可以得到可执行文件hello
./hello
得到
Hello world.
//@file: hello.cpp
#include <stdio.h>
#include "ace/Log_Msg.h"
#include "ace/OS_main.h"
int ACE_TMAIN(int argc, ACE_TCHAR* argv[])
{
ACE_DEBUG((LM_DEBUG,ACE_TEXT("hello world./n")));
return 0;
}
//-------------------------------------------------------------
再写hello.mpc
project(hello) :aceexe{
exename = hello
after += hello
Source_Files {
hello.cpp
}
}
------------------------------------------------------------
用MPC实用工具生成Makefile文件
$ACE_ROOT/bin/mwc.pl -type make hello.mpc
您将得到Makefile和Makefile.hello两个文件
运行make
可以得到可执行文件hello
./hello
得到
Hello world.