win32/makefile.mk Win32 makefile for DMAKE (BC++, VC++ builds)
win32/mdelete.bat multifile delete
win32/perlexe.ico perlexe.ico image file
+win32/perlexe.manifest Assembly manifest file
win32/perlexe.rc associated perl binary with icon
win32/perlglob.c Win32 port
win32/perlhost.h Perl "host" implementation
oldnames.lib kernel32.lib user32.lib gdi32.lib winspool.lib \
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib \
netapi32.lib uuid.lib ws2_32.lib mpr.lib winmm.lib \
- version.lib odbc32.lib odbccp32.lib
+ version.lib odbc32.lib odbccp32.lib comctl32.lib
# The 64 bit Platform SDK compilers contain a runtime library that doesn't
# include the buffer overrun verification code used by the /GS switch.
CFLAGS_O = $(CFLAGS) $(BUILDOPT)
+!IF "$(CCTYPE)" == "MSVC80" || "$(CCTYPE)" == "MSVC80FREE" || \
+ "$(CCTYPE)" == "MSVC90" || "$(CCTYPE)" == "MSVC90FREE"
+LINK_FLAGS = $(LINK_FLAGS) "/manifestdependency:type='Win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'"
+!ELSE
+RSC_FLAGS = -DINCLUDE_MANIFEST
+!ENDIF
+
+
#################### do not edit below this line #######################
############# NO USER-SERVICEABLE PARTS BEYOND THIS POINT ##############
$(EMBED_DLL_MANI)
.rc.res:
- $(RSC) -i.. $<
+ $(RSC) -i.. $(RSC_FLAGS) $<
#
# various targets
UNIDATADIR1 = ..\lib\unicore\To
UNIDATADIR2 = ..\lib\unicore\lib
+PERLEXE_MANIFEST= .\perlexe.manifest
PERLEXE_ICO = .\perlexe.ico
PERLEXE_RES = .\perlexe.res
PERLDLL_RES =
<<
$(XCOPY) $(PERLSTATICLIB) $(COREDIR)
-$(PERLEXE_RES): perlexe.rc $(PERLEXE_ICO)
+$(PERLEXE_RES): perlexe.rc $(PERLEXE_MANIFEST) $(PERLEXE_ICO)
$(MINIMOD) : $(MINIPERL) ..\minimod.pl
cd ..
-del /f ..\lib\Config_git.pl
-del /f bin\*.bat
-del /f perllibst.h
- -del /f perl.base
+ -del /f $(PERLEXE_RES) perl.base
-cd .. && del /s *.lib *.map *.pdb *.ilk *.bs *$(o) .exists pm_to_blib ppport.h
-cd $(EXTDIR) && del /s *.def Makefile Makefile.old
-cd $(DISTDIR) && del /s *.def Makefile Makefile.old
kernel32.lib user32.lib gdi32.lib winspool.lib \
comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib \
netapi32.lib uuid.lib ws2_32.lib mpr.lib winmm.lib \
- version.lib odbc32.lib odbccp32.lib \
+ version.lib odbc32.lib odbccp32.lib comctl32.lib \
import32.lib $(LIBC)
.IF "$(CFG)" == "Debug"
-lmoldname -lkernel32 -luser32 -lgdi32 \
-lwinspool -lcomdlg32 -ladvapi32 -lshell32 -lole32 \
-loleaut32 -lnetapi32 -luuid -lws2_32 -lmpr \
- -lwinmm -lversion -lodbc32 -lodbccp32
+ -lwinmm -lversion -lodbc32 -lodbccp32 -lcomctl32
.IF "$(CFG)" == "Debug"
OPTIMIZE = -g -O2 -DDEBUGGING
CFLAGS_O = $(CFLAGS) $(BUILDOPT)
+.IF "$(CCTYPE)" == "MSVC80" || "$(CCTYPE)" == "MSVC80FREE" || \
+ "$(CCTYPE)" == "MSVC90" || "$(CCTYPE)" == "MSVC90FREE"
+LINK_FLAGS = $(LINK_FLAGS) "/manifestdependency:type='Win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' processorArchitecture='*' publicKeyToken='6595b64144ccf1df' language='*'"
+.ELSE
+RSC_FLAGS = -DINCLUDE_MANIFEST
+.ENDIF
+
+
# used to allow local linking flags that are not propogated into Config.pm,
# currently unused
# -- BKS, 12-12-1999
.rc.res:
.IF "$(CCTYPE)" == "GCC"
- $(RSC) --use-temp-file --include-dir=. --include-dir=.. -O COFF -i $< -o $@
+ $(RSC) --use-temp-file --include-dir=. --include-dir=.. -O COFF -D INCLUDE_MANIFEST -i $< -o $@
.ELSE
- $(RSC) -i.. $<
+ $(RSC) -i.. -DINCLUDE_MANIFEST $<
.ENDIF
#
UNIDATADIR1 = ..\lib\unicore\To
UNIDATADIR2 = ..\lib\unicore\lib
+PERLEXE_MANIFEST= .\perlexe.manifest
PERLEXE_ICO = .\perlexe.ico
PERLEXE_RES = .\perlexe.res
PERLDLL_RES =
.ENDIF
$(XCOPY) $(PERLSTATICLIB) $(COREDIR)
-$(PERLEXE_RES): perlexe.rc $(PERLEXE_ICO)
+$(PERLEXE_RES): perlexe.rc $(PERLEXE_MANIFEST) $(PERLEXE_ICO)
$(MINIMOD) : $(MINIPERL) ..\minimod.pl
cd .. && miniperl minimod.pl > lib\ExtUtils\Miniperl.pm
-del /f ..\lib\Config_git.pl
-del /f bin\*.bat
-del /f perllibst.h
- -del /f perl.base
+ -del /f $(PERLEXE_RES) perl.base
-cd .. && del /s *$(a) *.map *.pdb *.ilk *.tds *.bs *$(o) .exists pm_to_blib ppport.h
-cd $(EXTDIR) && del /s *.def Makefile Makefile.old
-cd $(DISTDIR) && del /s *.def Makefile Makefile.old
--- /dev/null
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+ <assemblyIdentity version="0.0.0.0" name="Perl" type="Win32" />
+ <description>Perl</description>
+ <trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
+ <security>
+ <requestedPrivileges>
+ <requestedExecutionLevel level="asInvoker" uiAccess="false" />
+ </requestedPrivileges>
+ </security>
+ </trustInfo>
+ <dependency>
+ <dependentAssembly>
+ <assemblyIdentity type="Win32" name="Microsoft.Windows.Common-Controls" version="6.0.0.0"
+ processorArchitecture="*" publicKeyToken="6595b64144ccf1df" language="*" />
+ </dependentAssembly>
+ </dependency>
+</assembly>
PERLEXE ICON perlexe.ico
+
+#define CREATEPROCESS_MANIFEST_RESOURCE_ID 1
+#define RT_MANIFEST 24
+
+#ifdef INCLUDE_MANIFEST
+CREATEPROCESS_MANIFEST_RESOURCE_ID RT_MANIFEST "perlexe.manifest"
+#endif
# define WC_NO_BEST_FIT_CHARS 0x00000400 /* requires Windows 2000 or later */
#endif
#include <winnt.h>
+#include <commctrl.h>
#include <tlhelp32.h>
#include <io.h>
#include <signal.h>
{
HMODULE module;
+ /* When the manifest resource requests Common-Controls v6 then
+ * user32.dll no longer registers all the Windows classes used for
+ * standard controls but leaves some of them to be registered by
+ * comctl32.dll. InitCommonControls() doesn't do anything but calling
+ * it makes sure comctl32.dll gets loaded into the process and registers
+ * the standard control classes. Without this even normal Windows APIs
+ * like MessageBox() can fail under some versions of Windows XP.
+ */
+ InitCommonControls();
+
#ifdef SET_INVALID_PARAMETER_HANDLER
_invalid_parameter_handler oldHandler, newHandler;
newHandler = my_invalid_parameter_handler;