[FFmpeg-devel] [PATCH] configure: produce useful uninstalled pc files.

Nicolas George nicolas.george at normalesup.org
Wed Jul 11 12:20:40 CEST 2012

The old files were scattered in several directories,
with an unusual name, but dependencies to the usual name,
and relative paths.

The new files are regrouped in a singled directory
(doc/examples/pc-uninstalled) with their usual name
and more absolute paths.

With this change, it becomes possible to compile the examples
with the ffmpeg build tree by setting the environment variable:

Signed-off-by: Nicolas George <nicolas.george at normalesup.org>
 configure |   12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

It was discussed two months ago, I said I's push it if there was no more
remarks... and I forgot. I send it again so as not to take people by
surprise and push soon.

diff --git a/configure b/configure
index 1958fa6..13ac882 100755
--- a/configure
+++ b/configure
@@ -3955,18 +3955,22 @@ Libs: -L\${libdir} -l${shortname} $(enabled shared || echo $libs)
 Libs.private: $(enabled shared && echo $libs)
 Cflags: -I\${includedir}
-cat <<EOF > $name/$name-uninstalled.pc
+mkdir -p doc/examples/pc-uninstalled
+[ "$includedir" = . ] && includedir="\${pcfiledir}/../../.."
+cat <<EOF > doc/examples/pc-uninstalled/$name.pc
 Name: $name
 Description: $comment
 Version: $version
 Requires: $requires
-Libs: \${libdir}/${LIBPREF}${shortname}${LIBSUF} $libs
+Libs: -L\${libdir} -l${shortname} $(enabled shared || echo $libs)
 Cflags: -I\${includedir}

More information about the ffmpeg-devel mailing list