123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196 |
- <?xml version="1.0" encoding="UTF-8"?>
- <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
- <!--
- /**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
- -->
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <groupId>org.apache.zookeeper</groupId>
- <artifactId>zookeeper-client</artifactId>
- <version>3.10.0-SNAPSHOT</version>
- </parent>
- <artifactId>zookeeper-client-c</artifactId>
- <packaging>pom</packaging>
- <name>Apache ZooKeeper - Client - C</name>
- <description>ZooKeeper c client</description>
- <properties>
- <c-test-coverage-arg> </c-test-coverage-arg>
- </properties>
- <build>
- <plugins>
- <plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>exec-maven-plugin</artifactId>
- <executions>
- <execution>
- <id>autoreconf</id>
- <phase>process-sources</phase>
- <goals>
- <goal>exec</goal>
- </goals>
- <configuration>
- <workingDirectory>${project.basedir}</workingDirectory>
- <executable>autoreconf</executable>
- <environmentVariables>
- <ACLOCAL>aclocal -I /usr/share/aclocal</ACLOCAL>
- </environmentVariables>
- <arguments>
- <argument>-if</argument>
- </arguments>
- </configuration>
- </execution>
- <execution>
- <id>configure</id>
- <phase>process-sources</phase>
- <goals>
- <goal>exec</goal>
- </goals>
- <configuration>
- <workingDirectory>${project.build.directory}/c</workingDirectory>
- <executable>${project.basedir}/configure</executable>
- <environmentVariables>
- <base_dir>${project.basedir}/../..</base_dir>
- <CALLER>ANT</CALLER>
- </environmentVariables>
- <arguments>
- <argument>--with-openssl=${c-client-openssl}</argument>
- <argument>--with-sasl=${c-client-sasl}</argument>
- <argument>--prefix=${project.build.directory}/c</argument>
- <argument>${c-test-coverage-arg}</argument>
- </arguments>
- </configuration>
- </execution>
- </executions>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-antrun-plugin</artifactId>
- <executions>
- <execution>
- <id>generate-sources</id>
- <phase>generate-sources</phase>
- <configuration>
- <target>
- <mkdir dir="target/c" />
- </target>
- </configuration>
- <goals>
- <goal>run</goal>
- </goals>
- </execution>
- <execution>
- <id>build-c-client</id>
- <phase>compile</phase>
- <configuration>
- <target>
- <exec dir="${basedir}/target/c" executable="make" failonerror="true">
- <env key="LD_LIBRARY_PATH" value="${env.LD_LIBRARY_PATH};/usr/lib" />
- <env key="PATH" path="${env.PATH};${basedir};" />
- <env key="CALLER" value="ANT" />
- <env key="CLOVER_HOME" value="${basedir}/../../zookeeper-server/target" />
- <env key="base_dir" value="${basedir}/../.." />
- <arg line="clean install" />
- </exec>
- </target>
- </configuration>
- <goals>
- <goal>run</goal>
- </goals>
- </execution>
- <execution>
- <id>replace-cclient-files-during-release</id>
- <phase>none</phase>
- <goals>
- <goal>run</goal>
- </goals>
- <configuration>
- <target>
- <replaceregexp file="include/zookeeper_version.h" match="project.*" replace="project(zookeeper VERSION ${project.version})" byline="true" />
- <replace file="include/zookeeper_version.h" value="">
- <replaceToken>-SNAPSHOT</replaceToken>
- </replace>
- <replaceregexp file="CMakeLists.txt" match="project.*" replace="project(zookeeper VERSION ${project.version})" byline="true" />
- <replace file="CMakeLists.txt" value="">
- <replaceToken>-SNAPSHOT</replaceToken>
- </replace>
- <replaceregexp file="configure.ac" match="AC_INIT.*" replace="AC_INIT([zookeeper C client],${project.version},[user@zookeeper.apache.org],[zookeeper])" byline="true" />
- <replace file="configure.ac" value="">
- <replaceToken>-SNAPSHOT</replaceToken>
- </replace>
- </target>
- </configuration>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- <profiles>
- <profile>
- <id>c-test-coverage</id>
- <properties>
- <c-test-coverage-arg>--enable-gcov</c-test-coverage-arg>
- </properties>
- </profile>
- <profile>
- <!-- can be skipped by deactivating the profile with -P!cppunit (may need to escape or quote exclamation on command-line) -->
- <id>cppunit</id>
- <activation>
- <property>
- <!-- can also be skipped by -DskipCppUnit or with -DskipTests (see below) -->
- <name>!skipCppUnit</name>
- </property>
- </activation>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-antrun-plugin</artifactId>
- <executions>
- <execution>
- <id>test-cppunit</id>
- <phase>test</phase>
- <configuration>
- <!-- do not run cpp tests if tests are globally skipped -->
- <skip>${skipTests}</skip>
- <target>
- <exec dir="${basedir}/target/c" executable="make" failonerror="true">
- <env key="LD_LIBRARY_PATH" value="${env.LD_LIBRARY_PATH};/usr/lib" />
- <env key="PATH" path="${env.PATH};${basedir};" />
- <env key="CALLER" value="ANT" />
- <env key="CLOVER_HOME" value="${basedir}/../../zookeeper-server/target" />
- <env key="base_dir" value="${basedir}/../.." />
- <arg line="check" />
- </exec>
- </target>
- </configuration>
- <goals>
- <goal>run</goal>
- </goals>
- </execution>
- </executions>
- </plugin>
- </plugins>
- </build>
- </profile>
- </profiles>
- </project>
|