win32: Add a Windows OS resource file and icon
This commit is contained in:
parent
1a63663c85
commit
0742976138
17
Makefile.am
17
Makefile.am
@ -353,6 +353,20 @@ src_mpd_SOURCES = \
|
||||
src/stored_playlist.c \
|
||||
src/timer.c
|
||||
|
||||
#
|
||||
# Windows resource file
|
||||
#
|
||||
|
||||
src/win/mpd_win32_rc.$(OBJEXT): src/win/mpd_win32_rc.rc
|
||||
$(WINDRES) -i $< -o $@
|
||||
|
||||
if HAVE_WINDOWS
|
||||
noinst_DATA = src/win/mpd_win32_rc.rc
|
||||
|
||||
src_mpd_DEPENDENCIES = src/win/mpd_win32_rc.$(OBJEXT)
|
||||
src_mpd_LDFLAGS = -Wl,src/win/mpd_win32_rc.$(OBJEXT)
|
||||
endif
|
||||
|
||||
if ENABLE_DESPOTIFY
|
||||
src_mpd_SOURCES += \
|
||||
src/despotify_utils.c
|
||||
@ -1309,4 +1323,5 @@ endif
|
||||
|
||||
EXTRA_DIST = $(doc_DATA) autogen.sh \
|
||||
$(wildcard scripts/*.sh) \
|
||||
$(man_MANS) $(DOCBOOK_FILES) doc/mpdconf.example doc/doxygen.conf
|
||||
$(man_MANS) $(DOCBOOK_FILES) doc/mpdconf.example doc/doxygen.conf \
|
||||
src/win/mpd_win32_rc.rc.in
|
||||
|
19
configure.ac
19
configure.ac
@ -1,5 +1,12 @@
|
||||
AC_PREREQ(2.60)
|
||||
|
||||
AC_INIT(mpd, 0.17~git, musicpd-dev-team@lists.sourceforge.net)
|
||||
|
||||
VERSION_MAJOR=0
|
||||
VERSION_MINOR=17
|
||||
VERSION_REVISION=0
|
||||
VERSION_EXTRA=0
|
||||
|
||||
AC_CONFIG_SRCDIR([src/main.c])
|
||||
AM_INIT_AUTOMAKE([foreign 1.11 dist-bzip2 subdir-objects])
|
||||
AM_SILENT_RULES
|
||||
@ -58,6 +65,12 @@ AC_SUBST(AM_CPPFLAGS,"")
|
||||
AC_SUBST(AM_CFLAGS,"")
|
||||
AC_SUBST(AM_CXXFLAGS,"")
|
||||
|
||||
## Used for the windows resource file
|
||||
AC_SUBST(VERSION_MAJOR)
|
||||
AC_SUBST(VERSION_MINOR)
|
||||
AC_SUBST(VERSION_REVISION)
|
||||
AC_SUBST(VERSION_EXTRA)
|
||||
|
||||
dnl ---------------------------------------------------------------------------
|
||||
dnl OS Specific Defaults
|
||||
dnl ---------------------------------------------------------------------------
|
||||
@ -65,10 +78,16 @@ AC_CANONICAL_HOST
|
||||
|
||||
case "$host_os" in
|
||||
mingw32* | windows*)
|
||||
AC_CONFIG_FILES([
|
||||
src/win/mpd_win32_rc.rc
|
||||
])
|
||||
AC_CHECK_TOOL(WINDRES, windres)
|
||||
AM_CPPFLAGS="$AM_CPPFLAGS -DWINVER=0x0501"
|
||||
LIBS="$LIBS -lws2_32"
|
||||
HAVE_WINDOWS=1
|
||||
;;
|
||||
esac
|
||||
AM_CONDITIONAL([HAVE_WINDOWS], [test $HAVE_WINDOWS -eq 1])
|
||||
|
||||
if test -z "$prefix" || test "x$prefix" = xNONE; then
|
||||
local_lib=
|
||||
|
BIN
src/win/mpd.ico
Normal file
BIN
src/win/mpd.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 345 KiB |
34
src/win/mpd_win32_rc.rc.in
Normal file
34
src/win/mpd_win32_rc.rc.in
Normal file
@ -0,0 +1,34 @@
|
||||
#include <windows.h>
|
||||
|
||||
#define VERSION_NUMBER @VERSION_MAJOR@,@VERSION_MINOR@,@VERSION_REVISION@,@VERSION_EXTRA@
|
||||
#define VERSION_NUMBER_STR "@VERSION_MAJOR@,@VERSION_MINOR@,@VERSION_REVISION@,@VERSION_EXTRA@"
|
||||
|
||||
MPD_ICON ICON "@top_srcdir@/src/win/mpd.ico"
|
||||
|
||||
1 VERSIONINFO
|
||||
FILETYPE VFT_APP
|
||||
FILEOS VOS__WINDOWS32
|
||||
PRODUCTVERSION VERSION_NUMBER
|
||||
|
||||
FILEVERSION VERSION_NUMBER
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "040904B0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "Music Player Daemon Project"
|
||||
VALUE "ProductName", "Music Player Daemon"
|
||||
VALUE "ProductVersion", VERSION_NUMBER_STR
|
||||
VALUE "InternalName", "mpd"
|
||||
VALUE "OriginalFilename", "mpd.exe"
|
||||
VALUE "FileVersion", "@VERSION@"
|
||||
VALUE "FileDescription", "Music Player Daemon @VERSION@"
|
||||
VALUE "LegalCopyright", "Copyright \251 The Music Player Daemon Project"
|
||||
END
|
||||
END
|
||||
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x409, 1200
|
||||
END
|
||||
END
|
Loading…
Reference in New Issue
Block a user