summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDominik Riebeling <Dominik.Riebeling@gmail.com>2009-09-24 20:46:19 +0000
committerDominik Riebeling <Dominik.Riebeling@gmail.com>2009-09-24 20:46:19 +0000
commit55cd14f87572150e6fb4e9e9135e344883f667e2 (patch)
tree54bbbda3f7e97fea875ddd3875bc1d34e65ff7f1
parent0cab10e2f5b16d0425713c6dfe691007510c2f4a (diff)
downloadrockbox-55cd14f87572150e6fb4e9e9135e344883f667e2.zip
rockbox-55cd14f87572150e6fb4e9e9135e344883f667e2.tar.gz
rockbox-55cd14f87572150e6fb4e9e9135e344883f667e2.tar.bz2
rockbox-55cd14f87572150e6fb4e9e9135e344883f667e2.tar.xz
Make beastpatcher build with VS2005 again.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22821 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--tools/mknkboot.c12
-rw-r--r--utils/MTP/beastpatcher/vs2005/beastpatcher.vcproj16
2 files changed, 20 insertions, 8 deletions
diff --git a/tools/mknkboot.c b/tools/mknkboot.c
index e638404..6ac2642 100644
--- a/tools/mknkboot.c
+++ b/tools/mknkboot.c
@@ -42,8 +42,12 @@
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
+#if defined(_MSC_VER)
+#include "pstdint.h"
+#else
#include <unistd.h>
#include <inttypes.h>
+#endif
#include "mknkboot.h"
@@ -118,10 +122,10 @@ static uint32_t dualboot[] =
static void put_uint32le(uint32_t x, unsigned char* p)
{
- p[0] = x & 0xff;
- p[1] = (x >> 8) & 0xff;
- p[2] = (x >> 16) & 0xff;
- p[3] = (x >> 24) & 0xff;
+ p[0] = (unsigned char)(x & 0xff);
+ p[1] = (unsigned char)((x >> 8) & 0xff);
+ p[2] = (unsigned char)((x >> 16) & 0xff);
+ p[3] = (unsigned char)((x >> 24) & 0xff);
}
#if !defined(BEASTPATCHER)
diff --git a/utils/MTP/beastpatcher/vs2005/beastpatcher.vcproj b/utils/MTP/beastpatcher/vs2005/beastpatcher.vcproj
index 69925a8..295fd91 100644
--- a/utils/MTP/beastpatcher/vs2005/beastpatcher.vcproj
+++ b/utils/MTP/beastpatcher/vs2005/beastpatcher.vcproj
@@ -41,8 +41,8 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
- AdditionalIncludeDirectories="c:\wmsdk\wmfsdk95\include;c:\wmsdk\wmfsdk95\wmdm\inc"
- PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;_CRT_SECURE_NO_DEPRECATE;MTP_NODLL;WITH_BOOTOBJS"
+ AdditionalIncludeDirectories="&quot;$(ProjectDir)..&quot;;&quot;$(ProjectDir)..\..\..\..\tools&quot;;c:\wmsdk\wmfsdk95\include;c:\wmsdk\wmfsdk95\wmdm\inc"
+ PreprocessorDefinitions="WIN32;_DEBUG;_CONSOLE;_CRT_SECURE_NO_DEPRECATE;MTP_NODLL;WITH_BOOTOBJS;BEASTPATCHER"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="0"
@@ -120,8 +120,8 @@
/>
<Tool
Name="VCCLCompilerTool"
- AdditionalIncludeDirectories="c:\wmsdk\wmfsdk95\include;c:\wmsdk\wmfsdk95\wmdm\inc"
- PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_DEPRECATE;MTP_NODLL"
+ AdditionalIncludeDirectories="&quot;$(ProjectDir)..&quot;;&quot;$(ProjectDir)..\..\..\..\tools&quot;;c:\wmsdk\wmfsdk95\include;c:\wmsdk\wmfsdk95\wmdm\inc"
+ PreprocessorDefinitions="WIN32;NDEBUG;_CONSOLE;_CRT_SECURE_NO_DEPRECATE;MTP_NODLL;BEASTPATCHER"
RuntimeLibrary="2"
UsePrecompiledHeader="0"
WarningLevel="3"
@@ -191,6 +191,10 @@
>
</File>
<File
+ RelativePath="..\..\..\..\tools\mknkboot.c"
+ >
+ </File>
+ <File
RelativePath="..\mtp_win32.c"
>
</File>
@@ -225,6 +229,10 @@
>
</File>
<File
+ RelativePath="..\..\..\..\tools\mknkboot.h"
+ >
+ </File>
+ <File
RelativePath="..\mtp_common.h"
>
</File>