From: Sergey Matveev Date: Sun, 29 Jun 2025 07:18:09 +0000 (+0300) Subject: Generate .pc X-Git-Tag: v0.0.0~6 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=3f90417ed98918d651a24cebabfb1d42e848971638139930b34fd4966828ff2f;p=keks.git Generate .pc --- diff --git a/c/conf/.gitignore b/c/conf/.gitignore new file mode 100644 index 0000000..ffcde75 --- /dev/null +++ b/c/conf/.gitignore @@ -0,0 +1 @@ +/version diff --git a/c/conf/version.do b/c/conf/version.do new file mode 100644 index 0000000..26420c9 --- /dev/null +++ b/c/conf/version.do @@ -0,0 +1,8 @@ +v=../../VERSION +if [ -s $v ] ; then + redo-ifchange $v + cat $v +else + redo-ifcreate $v + echo unknown +fi diff --git a/c/lib/.gitignore b/c/lib/.gitignore index c081203..1ff176c 100644 --- a/c/lib/.gitignore +++ b/c/lib/.gitignore @@ -1,3 +1,4 @@ /*.o /compile_flags.txt +/keks.pc /libkeks.a diff --git a/c/lib/clean b/c/lib/clean index e633c5a..bcbe772 100755 --- a/c/lib/clean +++ b/c/lib/clean @@ -2,4 +2,4 @@ cd "$(dirname "$(realpath -- "$0")")" cm/clean -exec rm -f *.o *.a compile_flags.txt +exec rm -f *.o *.a compile_flags.txt keks.pc diff --git a/c/lib/install.do b/c/lib/install.do index a24b107..1dfc283 100644 --- a/c/lib/install.do +++ b/c/lib/install.do @@ -1,4 +1,4 @@ -redo-ifchange *.h libkeks.a ../conf/prefix +redo-ifchange *.h libkeks.a keks.pc ../conf/prefix read PREFIX <../conf/prefix mkdir -p $PREFIX/include/keks $PREFIX/lib cp -f *.h $PREFIX/include/keks diff --git a/c/lib/keks.pc.do b/c/lib/keks.pc.do new file mode 100644 index 0000000..78d02a9 --- /dev/null +++ b/c/lib/keks.pc.do @@ -0,0 +1,17 @@ +redo-ifchange ../conf/prefix ../conf/version +read PREFIX <../conf/prefix +read VERSION <../conf/version +perl -npe "s/ +/ /g ; s/ +$//" <