Permalink
Browse files

Global build

Reproduce the old build system
  • Loading branch information...
maxidor committed Jul 17, 2015
0 parents commit 02f7dcc168de54f49443fed6c438a7e399c6fb3e
Showing with 849 additions and 0 deletions.
  1. +2 −0 .gitignore
  2. +674 −0 LICENSE
  3. +2 −0 Makefile
  4. +17 −0 NOTICE
  5. +77 −0 build.xml
  6. +77 −0 configure
@@ -0,0 +1,2 @@
/out/
build.properties
674 LICENSE

Large diffs are not rendered by default.

Oops, something went wrong.
@@ -0,0 +1,2 @@
default:
ant
17 NOTICE
@@ -0,0 +1,17 @@
Hyperbox - Virtual Infrastructure Manager
Copyright (C) 2013-2015 Maxime Dor
http://kamax.io/hbox/
This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
@@ -0,0 +1,77 @@
<!--
*
* Hyperbox - Virtual Infrastructure Manager
* Copyright (C) 2015 Maxime Dor
*
* http://kamax.io/hbox/
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*
-->
<project name="Hyperbox" default="compile">
<property file="build.properties" />
<property name="hbox.api.base.dir" location="../api" />
<property name="hbox.client.base.dir" location="../client" />
<property name="hbox.server.base.dir" location="../server" />
<property file="${hbox.api.base.dir}/global.properties" />
<property name="hbox.out.dir" location="${out.dirname}" />
<property name="hbox.api.out.dir" location="${out.dirname}" />
<property name="hbox.client.out.dir" location="${out.dirname}" />
<property name="hbox.client.out.bin.dir" location="${hbox.client.out.dir}/${bin.dirname}/${client.name}" />
<property name="hbox.client.module.deploy.dir" location="${hbox.client.out.bin.dir}/${module.dirname}" />
<property name="hbox.server.out.dir" location="${out.dirname}" />
<property name="hbox.server.out.bin.dir" location="${hbox.server.out.dir}/${bin.dirname}/${server.name}" />
<property name="hbox.server.module.deploy.dir" location="${hbox.server.out.bin.dir}/${module.dirname}" />
<property name="vbox.4_2.base.dir" location="../vbox-4.2" />
<property name="vbox.4_3.base.dir" location="../vbox-4.3" />
<property name="vbox.5_0.base.dir" location="../vbox-5.0" />
<include file="${hbox.api.base.dir}/build.xml" as="hbox.api" />
<include file="${hbox.client.base.dir}/build.xml" as="hbox.client" />
<include file="${hbox.server.base.dir}/build.xml" as="hbox.server" />
<include file="${vbox.4_2.base.dir}/build.xml" as="vbox.4_2" />
<include file="${vbox.4_3.base.dir}/build.xml" as="vbox.4_3" />
<include file="${vbox.5_0.base.dir}/build.xml" as="vbox.5_0" />
<target name="clean">
<delete dir="${out.dirname}"/>
<echoproperties>
<propertyset>
<propertyref prefix="hbox."/>
<propertyref prefix="vbox."/>
<propertyref prefix="tools."/>
<propertyref prefix="platform"/>
</propertyset>
</echoproperties>
</target>
<extension-point name="compile" depends="hbox.api.compile, hbox.client.compile, hbox.server.compile, vbox.4_2.compile, vbox.4_3.compile, vbox.5_0.compile" />
<extension-point name="build" depends="compile, hbox.api.build, hbox.client.build, hbox.server.build, vbox.4_2.build, vbox.4_3.build, vbox.5_0.build" />
<extension-point name="deploy" depends="build, hbox.api.deploy, hbox.client.deploy, hbox.server.deploy, vbox.4_2.deploy, vbox.4_3.deploy, vbox.5_0.deploy" />
<extension-point name="dist" depends="deploy, hbox.api.dist, hbox.client.dist, hbox.server.dist" />
</project>
@@ -0,0 +1,77 @@
#!/bin/bash
PKG_BASE="io/kamax"
SRV_BASE_DIR="../server"
SRV_BASE_SRC_DIR="$SRV_BASE_DIR/src"
SRV_PKG_BASE_NAME="hboxd"
CLT_BASE_DIR="../client"
CLT_BASE_SRC_DIR="$CLT_BASE_DIR/src"
CLT_API_BASE_DIR="$CLT_BASE_SRC_DIR/api"
CLT_CORE_BASE_DIR="$CLT_BASE_SRC_DIR/core"
CLT_GUI_BASE_DIR="$CLT_BASE_SRC_DIR/gui"
SRV_API_BASE_DIR="$SRV_BASE_SRC_DIR/api"
SRV_CORE_BASE_DIR="$SRV_BASE_SRC_DIR/core"
err() {
echo -e >&2 "\e[1;31m$1\e[m $2"
exit 1
}
isInPath() {
hash "$1" 2> /dev/null
return $?
}
ok() {
echo -e "\e[1;32mOK\e[m"
}
checkForCommand() {
echo -n "checking for $2... "
if isInPath "$1"
then ok
else err "Not found!" "Adapt your PATH to include $1"
fi
}
checkForDirectory() {
echo -n "checking for path to $2... "
if [ -d "$1" ]
then ok
else err "Not found!" "$1"
fi
}
echo
echo "---------------------------------------"
echo " Hyperbox "
echo " Configuration script for build "
echo "---------------------------------------"
echo
checkForCommand git Git
checkForCommand ant Ant
checkForDirectory "$CLT_API_BASE_DIR" "Client API"
checkForDirectory "$CLT_CORE_BASE_DIR" "Client Core"
checkForDirectory "$CLT_GUI_BASE_DIR" "Client GUI"
checkForDirectory "$SRV_API_BASE_DIR" "Server API"
checkForDirectory "$SRV_CORE_BASE_DIR" "Server Core"
echo
echo -n "Writting setting file... "
echo "# General config file" > build.properties
echo "hbox.client.base.dir=$CLT_BASE_DIR" >> build.properties
echo "hbox.client.dir=$CLT_BASE_SRC_DIR" >> build.properties
echo "hbox.server.base.dir=$SRV_BASE_DIR" >> build.properties
echo "hbox.server.dir=$SRV_BASE_SRC_DIR" >> build.properties
ok
echo
echo "==============================="
echo "Finished configuring. Now run the following:"
echo
echo -e "\tant"
echo

0 comments on commit 02f7dcc

Please sign in to comment.