build.xml
changeset 20 29361e026fa3
parent 15 cfb2fc0ca242
child 22 65afc0483ef5
equal deleted inserted replaced
19:b81b96475fe0 20:29361e026fa3
    12 	
    12 	
    13 	<target	name="generuj" description="Vygeneruje kompletní web." depends="kompiluj-funkce,stránky,agregace">
    13 	<target	name="generuj" description="Vygeneruje kompletní web." depends="kompiluj-funkce,stránky,agregace">
    14 	</target>
    14 	</target>
    15 	
    15 	
    16 	<target name="stránky" description="Vygeneruje samotné XHTML webové stránky." depends="statický-obsah">		
    16 	<target name="stránky" description="Vygeneruje samotné XHTML webové stránky." depends="statický-obsah">		
    17 		<xslt basedir="${vstup}" destdir="${výstup}" includes="*${vstupníPřípona}" extension="${výstupníPřípona}" style="${šablona}/stránka.xsl">
    17 		<xslt basedir="${vstup}" destdir="${výstup}" includes="*${vstupníPřípona}" extension="${výstupníPřípona}" style="${šablona}/stránka.xsl" processor="org.apache.tools.ant.taskdefs.optional.TraXLiaison">
    18 			<param name="konfigurák" expression="../${vstup}/"/>		
    18 			<param name="konfigurák" expression="../${vstup}/"/>		
    19 			<param name="podporaZaostalýchProhlížečů" expression="false"/>
    19 			<param name="podporaZaostalýchProhlížečů" expression="false"/>
    20 			<param name="vstupníPřípona" expression="${vstupníPřípona}"/>
    20 			<param name="vstupníPřípona" expression="${vstupníPřípona}"/>
    21 			<param name="výstupníPřípona" expression="${výstupníPřípona}"/>
    21 			<param name="výstupníPřípona" expression="${výstupníPřípona}"/>
    22 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    22 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    29 	
    29 	
    30 	<target name="agregace" description="Vytvoří agregované výstupy: RSS, Atom, Sitemap.xml.">
    30 	<target name="agregace" description="Vytvoří agregované výstupy: RSS, Atom, Sitemap.xml.">
    31 		<!-- TODO: sloučit, zjednodušit, parametrizovat -->
    31 		<!-- TODO: sloučit, zjednodušit, parametrizovat -->
    32 	
    32 	
    33 		<!-- Atom -->
    33 		<!-- Atom -->
    34 		<xslt in="${vstup}/web.conf" out="${výstup}/atom.xml" style="${šablona}/atom.xsl">
    34 		<xslt in="${vstup}/web.conf" out="${výstup}/atom.xml" style="${šablona}/atom.xsl" processor="org.apache.tools.ant.taskdefs.optional.TraXLiaison">
    35 			<param name="vstupníPřípona" expression="${vstupníPřípona}"/>
    35 			<param name="vstupníPřípona" expression="${vstupníPřípona}"/>
    36 			<param name="výstupníPřípona" expression="${výstupníPřípona}"/>
    36 			<param name="výstupníPřípona" expression="${výstupníPřípona}"/>
    37 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    37 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    38 			<classpath location="${funkce}"/>
    38 			<classpath location="${funkce}"/>
    39 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    39 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    40 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    40 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    41 			</factory>
    41 			</factory>
    42 		</xslt>
    42 		</xslt>
    43 		
    43 		
    44 		<!-- RSS --> 
    44 		<!-- RSS --> 
    45 		<xslt in="${výstup}/atom.xml" out="${výstup}/rss.xml" style="${šablona}/rss.xsl">			
    45 		<xslt in="${výstup}/atom.xml" out="${výstup}/rss.xml" style="${šablona}/rss.xsl"  processor="org.apache.tools.ant.taskdefs.optional.TraXLiaison">			
    46 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    46 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    47 			<classpath location="${funkce}"/>
    47 			<classpath location="${funkce}"/>
    48 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    48 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    49 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    49 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    50 			</factory>
    50 			</factory>
    51 		</xslt>
    51 		</xslt>
    52 		
    52 		
    53 		<!-- Sitemap.xml -->
    53 		<!-- Sitemap.xml -->
    54 		<xslt in="${výstup}/atom.xml" out="${výstup}/sitemap.xml" style="${šablona}/sitemap.xsl">			
    54 		<xslt in="${výstup}/atom.xml" out="${výstup}/sitemap.xml" style="${šablona}/sitemap.xsl"  processor="org.apache.tools.ant.taskdefs.optional.TraXLiaison">			
    55 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    55 			<classpath location="/usr/share/java/saxonb-9.0.jar"/>
    56 			<classpath location="${funkce}"/>
    56 			<classpath location="${funkce}"/>
    57 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    57 			<factory name="net.sf.saxon.TransformerFactoryImpl">
    58 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    58 				<attribute name="http://saxon.sf.net/feature/allow-external-functions" value="true"/>				
    59 			</factory>
    59 			</factory>
    70 		</javac>
    70 		</javac>
    71 	</target>
    71 	</target>
    72 	
    72 	
    73 	<target name="statický-obsah" description="Kopíruje JS, CSS, obrázky atd.">
    73 	<target name="statický-obsah" description="Kopíruje JS, CSS, obrázky atd.">
    74 		<copy todir="${výstup}">
    74 		<copy todir="${výstup}">
    75 			<fileset dir="${vstup}" excludes="*.xml,*.inc,web.conf"/>
    75 			<fileset dir="${vstup}" excludes="*.xml,makra.xsl,*.inc,web.conf"/>
    76 		</copy>
    76 		</copy>
    77 	</target>
    77 	</target>
    78 	
    78 	
    79 	<target name="čisti" description="Smaže vygenerovaný obsah.">
    79 	<target name="čisti" description="Smaže vygenerovaný obsah.">
    80 		<delete includeemptydirs="true">
    80 		<delete includeemptydirs="true">