diff options
Diffstat (limited to 'make')
-rw-r--r-- | make/build.xml | 22 | ||||
-rwxr-xr-x | make/gluegen-cpptasks-base.xml | 19 |
2 files changed, 25 insertions, 16 deletions
diff --git a/make/build.xml b/make/build.xml index d243a2d..3fa7c3c 100644 --- a/make/build.xml +++ b/make/build.xml @@ -459,20 +459,6 @@ <antcall target="gluegen.build.c.impl" inheritAll="true" inheritRefs="true" /> </target> - <target name="gluegen.build.a.symbols" depends="" if="${build.staticlibs}" unless="gluegen.build.skip.native"> - <!-- invoke nm in a most compatible way, tested on GNU/Linux and MacOS --> - <exec executable="nm" dir="${build}" output="${gluegen.lib.dir}/lib${output.lib.name}.symbols.raw"> - <arg value="--extern-only"/> - <arg value="--defined-only"/> - <arg value="${gluegen.lib.dir}/${output.lib.name.os}"/> - </exec> - <exec executable="awk" dir="${build}" output="${gluegen.lib.dir}/lib${output.lib.name}.symbols"> - <arg value="{ print $3 }"/> - <arg value="${gluegen.lib.dir}/lib${output.lib.name}.symbols.raw"/> - </exec> - <delete file="${gluegen.lib.dir}/lib${output.lib.name}.symbols.raw" quiet="true" failonerror="false" /> - </target> - <target name="gluegen.build.c.impl" depends="init, c.configure" unless="gluegen.build.skip.native"> <echo message="clearing gluegen.build.shasum.done (2) - was ${gluegen.build.shasum.done}"/> <var name="gluegen.build.shasum.done" unset="true"/> @@ -531,9 +517,12 @@ <linker extends="${linker.cfg.id}" /> </cc> - <antcall target="gluegen.build.a.symbols" inheritAll="true" inheritRefs="true" /> <antcall target="c.rename.lib.mingw" inheritRefs="true" /> + <gluegen.make.libsymbols builddir="${build}" + nativelib="${gluegen.lib.dir}/${output.lib.name.os}" + symbolsfile="${gluegen.lib.dir}/${native.library.prefix}${output.lib.name}.symbols" /> + <antcall target="gluegen.cpptasks.striplibs" inheritRefs="true"> <param name="libdir" value="${gluegen.lib.dir}"/> </antcall> @@ -1250,8 +1239,9 @@ <target name="all.ide" description="Debug IDE build including all junit tests, but don't tag the build or create archives" depends="init.debug, base.compile, tag.build, junit.compile" /> <target name="clean" depends="init"> - <delete includeEmptyDirs="true"> + <delete includeEmptyDirs="true" failonerror="false"> <fileset dir="${build}" /> + <fileset dir="${project.root}/build-temp" /> <fileset dir="${project.root}" includes="make/GnuCTreeParserTokenTypes.txt make/STDCTokenTypes.txt" /> </delete> </target> diff --git a/make/gluegen-cpptasks-base.xml b/make/gluegen-cpptasks-base.xml index 20e2a75..05f648a 100755 --- a/make/gluegen-cpptasks-base.xml +++ b/make/gluegen-cpptasks-base.xml @@ -1877,4 +1877,23 @@ </delete> </sequential> </macrodef> + + <macrodef name="gluegen.make.libsymbols"> + <attribute name="builddir" /> + <attribute name="nativelib" /> + <attribute name="symbolsfile" /> + <sequential> + <!-- invoke nm in a most compatible way, tested on GNU/Linux and MacOS --> + <exec executable="nm" dir="@{builddir}" output="@{symbolsfile}.raw"> + <arg value="--extern-only"/> + <arg value="--defined-only"/> + <arg value="@{nativelib}"/> + </exec> + <exec executable="awk" dir="@{builddir}" output="@{symbolsfile}"> + <arg value="{ print $3 }"/> + <arg value="@{symbolsfile}.raw"/> + </exec> + <delete file="@{symbolsfile}.raw" quiet="true" failonerror="false" /> + </sequential> + </macrodef> </project> |