官术网_书友最值得收藏!

Creating the installer from the source code

The recipe describes the steps involved in building the ADempiere source code and creating an installer out of it, which is ready for you to install on your own system or any other system. These installer images are installable on MS Windows as well as Linux systems.

This is the basic recipe and a pre-requisite for any other recipe mentioned in this book.

How to do it...

  1. Check out the ADempiere code from the following SVN URL:

    https://adempiere.svn.sourceforge.net/svnroot/adempiere/tags/adempiere360lts.

    • Say, we have checked out the ADempiere code in the C:\adempiere_svn\ tags\adempiere360lts folder. We'll refer to the C:\adempiere_svn folder by name, say, ADEMPIERE_SVN
  2. Start Eclipse.
  3. Click on File menu and select Import...
  4. Select the Existing Projects into Workspace option under the General category and click on the Next button. Dialog with the title Import Projects appears with the Select root directory radio button.
    How to do it...
  5. Click on the Browse button next to the Select root directory radio button and select the adempiere360lts folder under the<ADEMPIERE_SVN>\tags folder. This will add adempiere_360 to the Projects list.
    How to do it...
  6. Click on the Finish button. This will import the project adempiere_360 into your Eclipse Workspace and build it, if the Build Automatically option is set in your Eclipse. If not, build the project.
    How to do it...
  7. Expand the adempiere_360 project in Eclipse. You will see the utils_dev folder.
  8. Expand the utils_dev folder and you will find build.xml. This is the Ant build script to compile the ADempiere source code and create the installable binaries.
  9. Right click on build.xml and select Run As | Ant Build. This will start the build process.
How to do it...

The following message appears in the console at the end of the build:

How to do it...

A successful build will create the adempiere folder under the project folder and the following binary installers are created, which can be used to install ADempiere on MS Windows or Linux:

  • Adempiere_360LTS.zip
  • Adempiere_360LTS.tar.gz
How to do it...

How it works...

In step 1, we first get the ADempiere code from its SVN repository. In steps 2 through to 6, we compile the code. In steps 7 through to 9, we create the distributions (Linux as well as MS Windows) by running the default Ant target inside the build.xml file, present under the utils_dev folder

There's more...

In this recipe, we saw how we can use the Ant build file build.xml to compile the code and create the installation packages (.zip and .tar.gz files). The same can be achieved by running a batch file.

Using RUN_Build.bat to create the installer

If you like working with command prompt, then you can use the<ADEMPIERE_SVN>\ tags\adempiere360lts\utils_dev\RUN_Build.bat script from the command prompt. This script, after a successful build, will create the installers.

Note

For the Linux users, there is an equivalent script with the extension .sh. For all the .bat script for MS Windows, there is a corresponding .sh shell script available.

主站蜘蛛池模板: 宁安市| 花莲县| 海丰县| 图们市| 鄂伦春自治旗| 隆尧县| 大化| 永顺县| 益阳市| 汕头市| 邛崃市| 枣庄市| 多伦县| 宣武区| 峨眉山市| 克拉玛依市| 衡阳县| 浦东新区| 望城县| 翼城县| 攀枝花市| 讷河市| 稷山县| 奉节县| 郧西县| 吉隆县| 翁牛特旗| 陆良县| 通山县| 万安县| 任丘市| 布尔津县| 巴塘县| 高碑店市| 安远县| 安吉县| 虹口区| 抚顺县| 富锦市| 田东县| 延吉市|