diff options
author | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2009-06-08 18:04:10 +0000 |
---|---|---|
committer | Dominik Riebeling <Dominik.Riebeling@gmail.com> | 2009-06-08 18:04:10 +0000 |
commit | eebde2a3676f7dd11011fabd7c4d74f0cb6532d5 (patch) | |
tree | c8568e4f398f5a1e2fcfc1c937dbbbc18d0f1aeb /utils/MTP/MTP_DLL/MTP_DLL.h | |
parent | 5575f425d64b555ad2399ef6e4ae3d1efcb6627d (diff) | |
download | rockbox-eebde2a3676f7dd11011fabd7c4d74f0cb6532d5.tar.gz rockbox-eebde2a3676f7dd11011fabd7c4d74f0cb6532d5.zip |
Major W32 beastpatcher rework (FS#10220).
Update beastpatcher to scan for the device separately, rework MTP_DLL and modify to allow building with VS2005.
- include pstdint.h when building with VS2005 as VS doesn't have inttypes.h
- don't use bool in the DLL as VS doesn't support type bool in C.
- rearrange DLL files to avoid filename ambiguities with sendfirm.
- include MTP_DLL.h instead of duplicating prototypes. Adjust header for easy inclusion.
- make MTP_DLL project file also copy the resulting dll to MTP folder for convenience.
- extend MTP_DLL API for separate device scanning. Note that this (intentionally) breaks compatibility of the dll.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21221 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'utils/MTP/MTP_DLL/MTP_DLL.h')
-rw-r--r-- | utils/MTP/MTP_DLL/MTP_DLL.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/utils/MTP/MTP_DLL/MTP_DLL.h b/utils/MTP/MTP_DLL/MTP_DLL.h index eeee72a87b..2793c936e1 100644 --- a/utils/MTP/MTP_DLL/MTP_DLL.h +++ b/utils/MTP/MTP_DLL/MTP_DLL.h | |||
@@ -1,10 +1,21 @@ | |||
1 | |||
2 | #ifndef MTP_DLL_H | ||
3 | #define MTP_DLL_H | ||
4 | |||
1 | #ifdef MTP_DLL_EXPORTS | 5 | #ifdef MTP_DLL_EXPORTS |
2 | #define MTP_DLL_API __declspec(dllexport) | 6 | #define MTP_DLL_API __declspec(dllexport) |
3 | #else | 7 | #else |
4 | #define MTP_DLL_API __declspec(dllimport) | 8 | #define MTP_DLL_API __declspec(dllimport) |
5 | #endif | 9 | #endif |
6 | 10 | ||
11 | #ifdef __cplusplus | ||
7 | extern "C" | 12 | extern "C" |
8 | { | 13 | { |
9 | __declspec(dllexport) bool send_fw(LPWSTR file, int filesize, void (*callback)(unsigned int progress, unsigned int max)); | 14 | #endif |
15 | MTP_DLL_API int mtp_sendnk(LPWSTR file, int filesize, void (*callback)(unsigned int progress, unsigned int max)); | ||
16 | MTP_DLL_API int mtp_description(wchar_t* name, wchar_t* manufacturer, DWORD* version); | ||
17 | #ifdef __cplusplus | ||
10 | } | 18 | } |
19 | #endif | ||
20 | |||
21 | #endif | ||