Skip to content

Commit

Permalink
Merge pull request #18 from xstefanox/build-portability
Browse files Browse the repository at this point in the history
Allow the project to be built on Unix-like OSes
  • Loading branch information
andrejpavlovic committed Sep 30, 2013
2 parents 36184ca + 3b40fc8 commit d456ed3
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,14 @@
<project name="XPathJS" default="build">
<!-- properties -->
<property name="yuicompressor.file" value="lib/yuicompressor/build/yuicompressor-2.4.8pre.jar"/>
<property name="pegjs.file" value="pegjs"/>

<condition property="pegjs.file" value="pegjs">
<os family="unix" />
</condition>

<condition property="pegjs.file" value="pegjs.cmd">
<os family="windows" />
</condition>

<!-- clean -->
<target name="clean">
Expand All @@ -15,7 +22,7 @@
<target name="build" depends="clean">

<!-- generate parser from grammar -->
<apply executable="pegjs.cmd" parallel="false" dest="build" failonerror="true">
<apply executable="${pegjs.file}" parallel="false" dest="build" failonerror="true">
<fileset file="src/parser.pegjs"/>
<arg line="--export-var"/>
<arg line="XPathJS._parser"/>
Expand Down

0 comments on commit d456ed3

Please sign in to comment.