forked from Pich78/docfetcher
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build-daemon.xml
58 lines (53 loc) · 1.74 KB
/
build-daemon.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<project name="docfetcher-daemon" default="compile" basedir=".">
<!-- Warning: This script uses a patched up version of cpptasks 1.0 beta5 -->
<taskdef resource="cpptasks.tasks">
<classpath>
<pathelement path="cpptasks.jar"/>
</classpath>
</taskdef>
<target name="init">
<condition property="isWindows">
<os family="windows"/>
</condition>
<condition property="isLinux">
<os family="unix"/>
</condition>
</target>
<target name="compile-windows" if="isWindows" depends="init">
<delete dir="build/daemon-win32"/>
<delete file="resources/daemon/docfetcher-daemon-win.exe"/>
<mkdir dir="build/daemon-win32//obj"/>
<cc
name="g++"
outtype="executable"
subsystem="console"
outfile="build/daemon-win32/docfetcher-daemon-win.exe"
objdir="build/daemon-win32/obj">
<fileset dir="src-daemon/win32/src" includes="*.cpp"/>
<fileset dir="src-daemon/win32/src/jnotify_win32" includes="*.cpp"/>
<linker name="g++">
<linkerarg value="-mwindows"/>
</linker>
</cc>
<copy todir="resources/daemon">
<filelist dir="build/daemon-win32" files="docfetcher-daemon-win.exe"/>
</copy>
</target>
<target name="compile-linux" if="isLinux" depends="init">
<delete dir="build/daemon-linux"/>
<delete file="resources/daemon/docfetcher-daemon-linux"/>
<mkdir dir="build/daemon-linux/obj"/>
<cc
name="g++"
outtype="executable"
subsystem="console"
outfile="build/daemon-linux/docfetcher-daemon-linux"
objdir="build/daemon-linux/obj">
<fileset dir="src-daemon/linux/src" includes="*.cpp"/>
</cc>
<copy todir="resources/daemon">
<filelist dir="build/daemon-linux" files="docfetcher-daemon-linux"/>
</copy>
</target>
<target name="compile" depends="compile-windows, compile-linux"/>
</project>