Instructions on installing ACE in Linux

Source: Internet
Author: User
For instructions on installing ACE in Linux-general Linux technology-Linux programming and kernel information, see the following for details. It should be noted that:

First, set the $ ACE_ROOT environment variable and point it to the ACE_wrappers Directory: You can edit/etc/profile or. bash_profile file, such as ACE_ROOT =/works /... /ACE_wrappers, export the export ACE_ROOT, and view it with echo $ ACE_ROOT.

Next, go to the $ ACE_ROOT/ace directory and create a text config. h with the following content:
# Include "ace/config-linux.h"

Then, go to the $ ACE_ROOT/include/makeinclude directory and create a text file platform_macros.GNU with the following content:
Include $ (ACE_ROOT)/include/makeinclude/platform_linux.GNU

Return to the $ ACE_ROOT directory, create a build (other names can be used), enter the build directory, and execute

../Configure // configure the environment


After execution, run

Make

Wait.

After a long wait, ACE is compiled.

After compilation, if you want to install and use it, you can start to execute the installation. The command is as follows:

Make install

General default installation path/usr/local/include/ace --> header file
/Usr/local/lib --> Link Library File

After the installation is completed, you need to set the path.

1. Set the path for compiling the link: Use root to edit the/etc/ld. so. conf file, and add the path of the Link Library to the file, for example:
/Usr/local/lib
Then execute the command:/sbin/ldconfig

2. Set the LD_LIBRARY_PATH environment variable
This environment variable can be set as root in the/etc/profile file, or in. bash_profile. You can add the following class path wherever possible:

LD_LIBRARY_PATH = $ LD_LIBRARY_PATH:/usr/local/lib

Export LD_LIBRARY_PATH

You can directly set it to the compiled path without installation, for example, LD_LIBRARY_PATH = $ LD_LIBRARY_PATH: $ ACE_ROOT/build/ace.

By now, the entire ACE compilation and configuration are basically completed. Now we can start programming and development.

//////////////////////////////////////// /////////////////////////////////
//
// Test ACE_Hello.cpp
//
// James gu 04/03/2007
//
// ================================================ ======================================

# Include

Int main (int argc, char * argv [])
{
(Void) argc;
(Void *) argv;

ACE_ OS: printf ("======= hello, ACE world! =======\ N ");

Return 0;
}

// Compile: g ++-g-Wall-DGNU_SOURCE-packages./ACE_Hello.cpp-o./ace_hello.o

// Run:./ace_hello.o

// It's over!
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.