diff options
author | James Almer <jamrial@gmail.com> | 2013-12-05 17:50:14 -0300 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-12-05 23:42:07 +0100 |
commit | 56572787ae2d7e113e36d5347b3d7263b35bdf98 (patch) | |
tree | eee3f01bd03c23fe939e2e7f39d3723043222a1e /libavutil | |
parent | af7562a03556d72ac6e022067b879d0124b052ba (diff) | |
download | ffmpeg-56572787ae2d7e113e36d5347b3d7263b35bdf98.tar.gz |
Add Windows resource file support for shared libraries
Originally written by James Almer <jamrial@gmail.com>
With the following contributions by Timothy Gu <timothygu99@gmail.com>
* Use descriptions of libraries from the pkg-config file generation function
* Use "FFmpeg Project" as CompanyName (suggested by Alexander Strasser)
* Use "FFmpeg" for ProductName as MSDN says "name of the product with which the
file is distributed" [1].
* Use FFmpeg's version (N-xxxxx-gxxxxxxx) for ProductVersion per MSDN [1].
* Only build the .rc files when --enable-small is not enabled.
[1] http://msdn.microsoft.com/en-us/library/windows/desktop/aa381058.aspx
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavutil')
-rw-r--r-- | libavutil/Makefile | 3 | ||||
-rw-r--r-- | libavutil/avutilres.rc | 55 |
2 files changed, 58 insertions, 0 deletions
diff --git a/libavutil/Makefile b/libavutil/Makefile index 8b73019cd5..5e0c4aebe4 100644 --- a/libavutil/Makefile +++ b/libavutil/Makefile @@ -122,6 +122,9 @@ OBJS-$(CONFIG_OPENCL) += opencl.o opencl_internal.o OBJS += $(COMPAT_OBJS:%=../compat/%) +# Windows resource file +SLIBOBJS-$(HAVE_GNU_WINDRES) += avutilres.o + SKIPHEADERS = old_pix_fmts.h SKIPHEADERS-$(HAVE_ATOMICS_GCC) += atomic_gcc.h diff --git a/libavutil/avutilres.rc b/libavutil/avutilres.rc new file mode 100644 index 0000000000..40a75eb377 --- /dev/null +++ b/libavutil/avutilres.rc @@ -0,0 +1,55 @@ +/* + * Windows resource file for libavutil + * + * Copyright (C) 2012 James Almer + * Copyright (C) 2013 Tiancheng "Timothy" Gu + * + * This file is part of FFmpeg. + * + * FFmpeg is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * FFmpeg is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with FFmpeg; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + */ + +#include <windows.h> +#include "libavutil/version.h" +#include "libavutil/ffversion.h" +#include "config.h" + +1 VERSIONINFO +FILEVERSION LIBAVUTIL_VERSION_MAJOR, LIBAVUTIL_VERSION_MINOR, LIBAVUTIL_VERSION_MICRO, 0 +PRODUCTVERSION LIBAVUTIL_VERSION_MAJOR, LIBAVUTIL_VERSION_MINOR, LIBAVUTIL_VERSION_MICRO, 0 +FILEFLAGSMASK VS_FFI_FILEFLAGSMASK +FILEOS VOS_NT_WINDOWS32 +FILETYPE VFT_DLL +{ + BLOCK "StringFileInfo" + { + BLOCK "040904B0" + { + VALUE "CompanyName", "FFmpeg Project" + VALUE "FileDescription", "FFmpeg utility library" + VALUE "FileVersion", AV_STRINGIFY(LIBAVUTIL_VERSION) + VALUE "InternalName", "libavutil" + VALUE "LegalCopyright", "Copyright (C) 2000-" AV_STRINGIFY(CONFIG_THIS_YEAR) " FFmpeg Project" + VALUE "OriginalFilename", "avutil" BUILDSUF "-" AV_STRINGIFY(LIBAVUTIL_VERSION_MAJOR) SLIBSUF + VALUE "ProductName", "FFmpeg" + VALUE "ProductVersion", FFMPEG_VERSION + } + } + + BLOCK "VarFileInfo" + { + VALUE "Translation", 0x0409, 0x04B0 + } +} |