The MASM Forum

Projects => MASM32 => Full SDK Include Project => Topic started by: TouEnMasm on August 11, 2012, 10:04:25 PM

Title: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on August 11, 2012, 10:04:25 PM
EDIT: 2020 get it here https://github.com/ToutEnMasm71100 (https://github.com/ToutEnMasm71100)

Translate of the Windows 10 header files,Those ones are a REAL translate:
You can build 64 bits or 32 bits prog with it
The .sdk files can be used with jwasm and ml  (after some corrections )
Jwasm HJWASM (http://www.terraspace.co.uk/hjwasm.html)
To solve ml internal Error http://masm32.com/board/index.php?topic=3694.msg38983#msg38983 (http://masm32.com/board/index.php?topic=3694.msg38983#msg38983)
Works exactly as the original one.That is:
Alignment is the same as c++ (QWORD default)
32 64 bits is supported.
All versions of windows (win95 to Win 10.0)
All interfaces translated (- a few number,count on one hand doights)
All structures
All constantes
Functions      (a very few number can be missing)
All conditions  (constants switchs are put on windows 10.0,see translate.inc)
            This allow UNICODE support
              This allow various material adaptations

Translate is now in this form:
QuoteUpdateLayeredWindow PROTO hWnd:HWND ,hdcDst:HDC ,pptDst:XMASM ,psize:XMASM ,hdcSrc:HDC ,\
            pptSrc:XMASM ,crKey:COLORREF ,pblend:XMASM ,dwFlags:DWORD

The ready to use grant you the use of the list below  without problems.Others files can need a few minor corrections.Tested by compiled of my ide.
Included libraries are for the inline functions (printf..).

Quoteinclude sdk64.inc
                or
      include sdk32.inc
;**************************************************************************************
Full package with crt 2013
SDK 10.0 header's file (https://github.com/ToutEnMasm71100/FullSdkTranslate)
;*****************************************************************************************************
NOTES:
Adapting constants switchs to your system,use this tool:
sdkrc81\Before_use_me.exe.He will give you the correct swiths for your system.
Modify translate.inc with this switchs.The defaut system is windows 10.0

With a correct alignment,all translated structures,can be used as they are.
There is no need of any modifie.

Modifies made on the sdk for Jwasm
QuoteJWasm v2.08rc3, Aug  9 2012, Masm-compatible assembler.
QuoteThe ERROR macro in adoint.sdk must be renamed Ierror
The ERROR equate (ERROR equ <0>) must be put in comment in Wingdi.sdk
If you don't do that,you give this error message from jwasm
Quote.data ;------ here the error ---------
Error A2069: Segment, group or segment register expected

The following files had been tested,other can need some modifies
The before_use_me.exe allow you to adapt constants switchs to your version of windows

\sdkrc81\shared\rpc.sdk Nombre d'Include: 12       
\sdkrc81\um\amstream.sdk Nombre d'Include: 13       
\sdkrc81\um\AtscPsipParser.sdk Nombre d'Include: 10   
\sdkrc81\um\Audioclient.sdk Nombre d'Include: 11   
\sdkrc81\um\audioenginebaseapo.sdk Nombre d'Include: 10
\sdkrc81\um\AudioEngineEndpoint.sdk Nombre d'Include: 11
\sdkrc81\um\audiopolicy.sdk Nombre d'Include: 10   
\sdkrc81\um\Bits3_0.sdk Nombre d'Include: 10       
\sdkrc81\um\bits4_0.sdk Nombre d'Include: 11       
\sdkrc81\um\bits5_0.sdk Nombre d'Include: 11       
\sdkrc81\um\CertSrv.sdk Nombre d'Include: 10       
\sdkrc81\um\combaseapi.sdk Nombre d'Include: 10   
\sdkrc81\um\ComSvcs.sdk Nombre d'Include: 12       
\sdkrc81\um\d2d1.sdk Nombre d'Include: 10       
\sdkrc81\um\d3d10.sdk Nombre d'Include: 13       
\sdkrc81\um\d3d11.sdk Nombre d'Include: 15       
\sdkrc81\um\d3d11_2.sdk Nombre d'Include: 10       
\sdkrc81\um\devicetopology.sdk Nombre d'Include: 10   
\sdkrc81\um\dshow.sdk Nombre d'Include: 17       
\sdkrc81\um\DvbSiParser.sdk Nombre d'Include: 10   
\sdkrc81\um\ehstorapi.sdk Nombre d'Include: 10       
\sdkrc81\um\evr9.sdk Nombre d'Include: 10       
\sdkrc81\um\fsrmtlb.sdk Nombre d'Include: 12       
\sdkrc81\um\functiondiscoveryapi.sdk Include: 14   
\sdkrc81\um\FwCommon.sdk Nombre d'Include: 15       
\sdkrc81\um\gdiplus.sdk Nombre d'Include: 31       
\sdkrc81\um\Iadmw.sdk Nombre d'Include: 10       
\sdkrc81\um\LM.sdk Nombre d'Include: 19               
\sdkrc81\um\locationapi.sdk Nombre d'Include: 11   
\sdkrc81\um\minidrv.sdk Nombre d'Include: 20       
\sdkrc81\um\msctf.sdk Nombre d'Include: 10       
\sdkrc81\um\MsHTML.sdk Nombre d'Include: 12       
\sdkrc81\um\Mshtmlc.sdk Nombre d'Include: 11       
\sdkrc81\um\msopc.sdk Nombre d'Include: 11       
\sdkrc81\um\oledb.sdk Nombre d'Include: 93       
\sdkrc81\um\oledbdep.sdk Nombre d'Include: 22       
\sdkrc81\um\propsys.sdk Nombre d'Include: 11       
\sdkrc81\um\sapi.sdk Nombre d'Include: 11       
\sdkrc81\um\SearchAPI.sdk Nombre d'Include: 24   
\sdkrc81\um\segment.sdk Nombre d'Include: 12       
\sdkrc81\um\shdeprecated.sdk Nombre d'Include: 12   
\sdkrc81\um\ShObjIdl.sdk Nombre d'Include: 18   
\sdkrc81\um\sphelper.sdk Nombre d'Include: 14       
\sdkrc81\um\strmif.sdk Nombre d'Include: 18       
\sdkrc81\um\Tapi3.sdk Nombre d'Include: 13       
\sdkrc81\um\tuner.sdk Nombre d'Include: 10       
\sdkrc81\um\UtilLib.sdk Nombre d'Include: 10       
\sdkrc81\um\vds.sdk Nombre d'Include: 13       
\sdkrc81\um\vdshwprv.sdk Nombre d'Include: 13       
\sdkrc81\um\wiamindr_lh.sdk Nombre d'Include: 10   
\sdkrc81\um\wiamindr_xp.sdk Nombre d'Include: 10   
\sdkrc81\um\WinBase.sdk Nombre d'Include: 34       
\sdkrc81\um\wincodec.sdk Nombre d'Include: 10       
\sdkrc81\um\Windows.sdk Nombre d'Include: 38       
\sdkrc81\um\winnt.sdk Nombre d'Include: 13       
\sdkrc81\um\Wsdapi.sdk Nombre d'Include: 10       
KM\wdm.sdk
KM\miniport.sdk
KM\cifs.sdk
..



Title: Re: Full SDK translate and ready to used
Post by: ragdog on August 12, 2012, 08:23:11 PM
Thanks ToutEnMasm for your work  :t
Title: Re: Full SDK translate and ready to used
Post by: dedndave on August 13, 2012, 01:30:41 AM
 :t
Title: Re: Full SDK translate and ready to used
Post by: Gunther on August 14, 2012, 06:26:18 AM
Good job.  :t

Gunther
Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on September 08, 2012, 04:46:26 PM
I have modified the pack with the alignment of structures.
Now the alignment is made as the c++ do.
The defaut alignment (DWORD) must be change for (QWORD) in the translate.inc
file.
see following posts.
This solve all  the problems with structures.
Quote
   ;@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   DefaultAlignement equ <QWORD>
   DEFALIGNMASM TEXTEQU  DefaultAlignement
   ;@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@


Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on September 09, 2012, 12:01:34 AM

The good defaut alignment for the c++ is QWORD.
The proof is made by the PARTITION_INFORMATION.
This structure change of size with the alignment.
ASk to masm      with DWORD align sizeof PARTITION_INFORMATION == 28
                          with QWORD align sizeof PARTITION_INFORMATION == 32
Ask to c++     sizeof PARTITION_INFORMATION == 32
Thanks to japheth to point me on it.
This structure had a defaut alignment in the c++.
Proof is made,that defaut alignement for c++ = 8   
Title: Re: Full SDK translate and ready to used
Post by: MichaelW on September 09, 2012, 05:26:33 AM
The alignment is QWORD and the structure is padded at the end to make the length a multiple of 8 bytes because the largest member is a QWORD. And at least for the PARTITION_INFORMATION structure the same alignment applies for C.

#include <windows.h>
#include <conio.h>
#include <stdio.h>
#include <stddef.h>

/*
typedef struct _PARTITION_INFORMATION {
  LARGE_INTEGER StartingOffset;
  LARGE_INTEGER PartitionLength;
  DWORD HiddenSectors;
  DWORD PartitionNumber;
  BYTE PartitionType;
  BOOLEAN BootIndicator;
  BOOLEAN RecognizedPartition;
  BOOLEAN RewritePartition;
} PARTITION_INFORMATION, *PPARTITION_INFORMATION;

typedef union _LARGE_INTEGER {
  struct {
    DWORD LowPart;
    LONG HighPart;
  };
  LONGLONG QuadPart;
} LARGE_INTEGER, *PLARGE_INTEGER;
*/

int main(void)
{
    printf( "sizeof(PARTITION_INFORMATION) %d\n", sizeof(PARTITION_INFORMATION) );
    printf( "offsetof(PARTITION_INFORMATION,StartingOffset) %d\n", offsetof(PARTITION_INFORMATION,StartingOffset) );
    printf( "offsetof(PARTITION_INFORMATION,PartitionLength) %d\n", offsetof(PARTITION_INFORMATION,PartitionLength) );
    printf( "offsetof(PARTITION_INFORMATION,HiddenSectors) %d\n", offsetof(PARTITION_INFORMATION,HiddenSectors) );
    printf( "offsetof(PARTITION_INFORMATION,PartitionNumber) %d\n", offsetof(PARTITION_INFORMATION,PartitionNumber) );
    printf( "offsetof(PARTITION_INFORMATION,PartitionType) %d\n", offsetof(PARTITION_INFORMATION,PartitionType) );
    printf( "offsetof(PARTITION_INFORMATION,BootIndicator) %d\n", offsetof(PARTITION_INFORMATION,BootIndicator) );
    printf( "offsetof(PARTITION_INFORMATION,RecognizedPartition) %d\n", offsetof(PARTITION_INFORMATION,RecognizedPartition) );
    printf( "offsetof(PARTITION_INFORMATION,RewritePartition) %d\n", offsetof(PARTITION_INFORMATION,RewritePartition) );
    getch();
    return 0;
}


sizeof(PARTITION_INFORMATION) 32
offsetof(PARTITION_INFORMATION,StartingOffset) 0
offsetof(PARTITION_INFORMATION,PartitionLength) 8
offsetof(PARTITION_INFORMATION,HiddenSectors) 16
offsetof(PARTITION_INFORMATION,PartitionNumber) 20
offsetof(PARTITION_INFORMATION,PartitionType) 24
offsetof(PARTITION_INFORMATION,BootIndicator) 25
offsetof(PARTITION_INFORMATION,RecognizedPartition) 26
offsetof(PARTITION_INFORMATION,RewritePartition) 27

Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on September 09, 2012, 05:33:35 PM
Thanks to you,
I have made the same thing with the "ready to use sdk" and find the same thing.
Quote
sizeof PARTITION_INFORMATION 32
offset PARTITION_INFORMATION.StartingOffset 0
offset PARTITION_INFORMATION.PartitionLengt 8
offset PARTITION_INFORMATION.HiddenSectors 16
offset PARTITION_INFORMATION.PartitionNumber 20
offset PARTITION_INFORMATION.PartitionType 24
offset PARTITION_INFORMATION.BootIndicator 25
offset PARTITION_INFORMATION.RecognizedPartition 26
offset PARTITION_INFORMATION.RewritePartition 27
translate.inc
Quote
   ;@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
   DefaultAlignement equ <QWORD>
   DEFALIGNMASM TEXTEQU  DefaultAlignement
   ;@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

Nothing is perfect:
You can have a problem like this one:
http://masm32.com/board/index.php?topic=642.msg5658#msg5658 (http://masm32.com/board/index.php?topic=642.msg5658#msg5658)
The tool in D:\sdkrc7\examples\cherche.exe could made a list of used functions.
dir /S/B *.sdk >  somename.sch           (list of FULL path *.sdk)
Put this file in the directory of "cherche".He will give you the same list that in the post. Menu "cherche">>"listes a rechercher"   select "somename.sch"
Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on September 22, 2012, 04:42:12 AM

Posted a new version working exactly as the original windows sdk 7.1.
32 64 bits allowed and same alignment as c++ (QWORD DEFAULT).
Many changes to make it the 7.1 without to much problem.
The if statement are controled.Only one file show a problem,adoctint.h with a sum of if and end if = -1 (one if is missing).This is not given by the translate but by the header.h.
Title: Re: Full SDK translate and ready to used
Post by: japheth on September 22, 2012, 10:49:11 PM
I downloaded the version from 21.9.2012. Tried examples\exampl01\listbox. It works!

However, if I want to create a listing ( adding /Fl to masm cmdline arguments ), I get very strange errors ( Masm v8, 9 and 10 ):


Assembling: listbox.asm
ULONG_PTR defined
\SDKRC7\rpcdcep.SDK(133) : error A2020:identifier not a record : RPC_SYNTAX_IDENTIFIER
\SDKRC7\rpcdcep.SDK(147) : error A2020:identifier not a record : RPC_SYNTAX_IDENTIFIER
\SDKRC7\rpcasync.SDK(191) : error A2009:syntax error in expression
\SDKRC7\winioctl.SDK(3137) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(89) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(115) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(350) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(368) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(401) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(429) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(474) : error A2009:syntax error in expression
\SDKRC7\winspool.SDK(503) : error A2009:syntax error in expression


I have no idea what the first two error msgs might cause. With Jwasm, there's no problem with /Fl.


Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on September 23, 2012, 01:35:13 AM

I have made the same test and get the same problem with the listing.
I had try to made it with my ide , there is a pipe and a thread,No problem,the listing show no error.
The error is only under dos.
The jwasm haven't also this internal error of ml.
Quote
.NOLIST         ;signifie: ne rien mettre dans le listing
;------ emplacement des déclarations
   .486
   .model flat, stdcall
   option casemap :none   ; case sensitive

   ;include translate.inc   ;SDK translate include files (voir mon site)
   ExitProcess PROTO :DWORD
   ;include windows.sdk
   ;------- librairie courantes ,identiques masm32rt   
   includelib kernel32.lib
   .const
GUID   STRUCT
    Data1    dd ?
    Data2    dw ?
    Data3    dw ?
    Data4    db 8 dup(?)
GUID ENDS   
DEFALIGNMASM TEXTEQU <QWORD>   
PARTITION_INFORMATION_GPT   STRUCT   DEFALIGNMASM
   PartitionType GUID <>  ; Partition type. See table 16-3.
   PartitionId GUID <>  ; Unique GUID for this partition.
   Attributes QWORD ? ; See table 16-4.
   Name1 BYTE ? ; Partition Name in Unicode.
PARTITION_INFORMATION_GPT      ENDS

IFDEF (MIDL_PASS)
LARGE_INTEGER   STRUCT   DEFALIGNMASM
ELSE   
LARGE_INTEGER   UNION
   STRUCT   DUMMYSTRUCTNAME
   LowPart DWORD ?
   HighPart DWORD ?
   ENDS
   STRUCT   u
   LowPart DWORD ?
   HighPart DWORD ?
   ENDS
ENDIF ;MIDL_PASS
   QuadPart QWORD ?
LARGE_INTEGER      ENDS
PARTITION_INFORMATION_MBR   STRUCT DEFALIGNMASM
   PartitionType BYTE ?
   BootIndicator BYTE ?
   RecognizedPartition BYTE ?
   HiddenSectors DWORD ?
PARTITION_INFORMATION_MBR      ENDS   
   
DRIVE_LAYOUT_INFORMATION_GPT   STRUCT DEFALIGNMASM
   DiskId GUID <>
   StartingUsableOffset LARGE_INTEGER <>
   UsableLength LARGE_INTEGER <>
   MaxPartitionCount DWORD ?
DRIVE_LAYOUT_INFORMATION_GPT      ENDS

DRIVE_LAYOUT_INFORMATION_MBR   STRUCT DEFALIGNMASM
   Signature DWORD ?
DRIVE_LAYOUT_INFORMATION_MBR      ENDS
   
PARTITION_INFORMATION_EX   STRUCT DEFALIGNMASM
   PartitionStyle DWORD ?
   StartingOffset LARGE_INTEGER <>
   PartitionLength LARGE_INTEGER <>
   PartitionNumber DWORD ?
   RewritePartition BYTE ?
   union   DUMMYUNIONNAME
   Mbr PARTITION_INFORMATION_MBR <>
   Gpt PARTITION_INFORMATION_GPT <>
   ENDS
PARTITION_INFORMATION_EX      ENDS
   
DRIVE_LAYOUT_INFORMATION_EX   STRUCT DEFALIGNMASM
   PartitionStyle DWORD ?
   PartitionCount DWORD ?
   union   DUMMYUNIONNAME
   Mbr DRIVE_LAYOUT_INFORMATION_MBR <>
   Gpt DRIVE_LAYOUT_INFORMATION_GPT <>
   ENDS
   PartitionEntry PARTITION_INFORMATION_EX 1 dup (<>)
DRIVE_LAYOUT_INFORMATION_EX      ENDS   
   .data
   .code

   start:
   invoke ExitProcess,0

;################################################################   
   end start      
At each version of ml  i hope this one corrected but not.the 6.15 have it also but give more usefull information than ml 10..
Give the file path and the number of the line.



Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on September 23, 2012, 01:58:15 AM

To avoid the internal error , there is need to explode the  PARTITION_INFORMATION_EX  structure like this:
Quote
EXPORT_PARTITION_INFORMATION_EX UNION
       Mbr PARTITION_INFORMATION_MBR <>
       Gpt PARTITION_INFORMATION_GPT <>
EXPORT_PARTITION_INFORMATION_EX ENDS

PARTITION_INFORMATION_EX   STRUCT   DEFALIGNMASM
   PartitionStyle DWORD ?
   StartingOffset LARGE_INTEGER <>
   PartitionLength LARGE_INTEGER <>
   PartitionNumber DWORD ?
   RewritePartition BYTE ?
   export_union EXPORT_PARTITION_INFORMATION_EX <>   
PARTITION_INFORMATION_EX      ENDS

Title: Re: Full SDK translate and ready to used
Post by: bsdsource on November 05, 2012, 04:27:29 PM
Keep up this excellent work! :t :t I'll be following you on the forums. This is truly a great contribution to the community in addition to your translation tool Thank you so much.
Title: Re: Full SDK translate and ready to used
Post by: asmcoder on August 31, 2013, 11:19:51 AM
Good Job !  Could you do me a favor to translate WDK7600?
Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on September 26, 2014, 04:16:22 PM

Ready to use SDK 8.1 added in the first post,more easy to use than the 7.1.
many filters have been added in this version.

Title: Re: Full SDK translate and ready to used
Post by: Gunther on September 26, 2014, 05:41:44 PM
Hi ToutEnMasm,

thank you for that contribution. Well done.  :t

Gunther
Title: Re: Full SDK translate and ready to used
Post by: Siekmanski on September 26, 2014, 06:12:49 PM
ToutEnMasm,

Thank you very much.
Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on October 03, 2014, 04:54:04 PM
Corrected a big mistake in the first post for the 8.1 version
Three files are named     windows... ,I rename them in windows_ _ _.h et .sdk
The new package give the new features of the translator (conditionnal prototypes and ++).
Tested with JWasm v2.12pre, Nov 27 2013,
Title: Re: Full SDK translate and ready to used
Post by: Gunther on October 03, 2014, 07:02:02 PM
Hi ToutEnMasm,

Quote from: ToutEnMasm on October 03, 2014, 04:54:04 PM
Tested with JWasm v2.12pre, Nov 27 2013,

is that the one which Habran built?

Gunther
Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on October 03, 2014, 10:18:24 PM

It isn't ,but if you can made a try,put the result here.
If you find corrections to do,feel free to post them here.

Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on October 13, 2014, 06:57:58 PM

After a certain number of tests,the translated sdk 8.1 replace the 7.1.
Duplicate name,incompatible names .. have been corrected on the more current files.
The Winnt have been replace by one translated with the 8.3 version of the translator.
Winnt use the full set of alignment allowed (BYTE to QWORD) and only the last version of the translator do it well.
Reload the sdkrc8.1 with the crt headers,they are needed

http://masm32.com/board/index.php?topic=563.msg4563#msg4563 (http://masm32.com/board/index.php?topic=563.msg4563#msg4563)   
Title: Re: Full SDK translate and ready to used
Post by: TouEnMasm on November 05, 2014, 03:45:38 AM

corrected the wingdi ( #define   (DWORD) ...)
added coinvoke macro and "_APISET_MMISC_VER equ 99h ;not 8.1" in translate.inc
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 22, 2014, 08:06:37 PM

NEW
The zip in the first post give a full sdk translate who allow to build 64 and 32 bits prog.
+++++ More typedef
              Typedef are used in the header where they are declared.
              Some typedef get a general usage when they are in the  COMMONTYPEDEF
              To extend there use , modify the COMMONTYPEDEF section in egales.txt
+++++ callback (more easily usable)
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 22, 2014, 09:59:21 PM
Hi ToutEnMasm :biggrin:
I downloaded and tried to run cpusys.exe and got this message from my machine:
Quote
Windows protected your PC
Windows SmartScreen prevented an Unrecognized app from starting.
Running this app might put your PC at risk
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 22, 2014, 11:19:45 PM
It's windows 8.1 who claim he want signed prog (signed with payment) .
Just answer "YES" to run it .
There is no virus,perhaps a rebuild of it can stop this ask.
The sdk 32 and 64 have constants switchs for windows 8.1,you can skip this step if you have it


Later:
I have put a cpusys_build8.1.zip  on the first post,perhaps he ask no question.
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 23, 2014, 12:06:09 AM
Full package with crt 2013 is a not link :icon_eek:
the link that you created for info leads to some page which shows this:
Quote
Page introuvable
Vous venez d'être redirigé vers une page d'erreur.
L'adresse URL que vous avez saisie ou le lien que vous avez cliqué sont erronés.

Vous pouvez poursuivre votre navigation en lançant une nouvelle recherche:

are you kidding us :dazzled:
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 23, 2014, 05:57:43 AM
Hello,
Not a joke,but surely a mistake,corrected:
Full package with crt 2013
see first post for correct link,this one change at each update
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 23, 2014, 06:43:25 AM
Hi ToutEnMasm,
that's better :biggrin:
Now, your info about usage is pretty confusing.
where do you put SDK?
can you give an example of usage for Windows 8.1
show as a simple code with the overhead
post sdk64.inc whichyou use for Windows 8.1
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 23, 2014, 05:04:11 PM

Quote
where do you put SDK?
You put it where you want,assuming you put it in MyFullPath,made a batch
Here jwasm is put in further  VC\--\--\bin directory   (further for 32 and 64)
Quote
   @echo off
   CLS
        :call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\x86_amd64\vcvarsx86_amd64.bat"
   call "C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\bin\amd64\vcvars64.bat"
        SET INCLUDE= MyFullPath\sdkrc81\um;MyFullPath\sdkrc81\shared;MyFullPath\sdkrc81\VC
       ............................
next you can use
Quote
       include sdk64.inc or sdk32.inc
For the little history,sdk??.inc is in the sdkrc81\shared directory  with translate??.inc
I will add samples of  64 bits in the first post as soon as possible.


Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: Siekmanski on December 23, 2014, 07:20:57 PM
Excellent work! :t
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 23, 2014, 10:21:03 PM
Thanks

I have added a demo64 in the first post
It's a window and an interface in 64 bits.
The zip have also two littles modifies made. (duplicate def of Hcursor)
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 24, 2014, 06:38:47 AM
I was unable to setup your SDK for use on my computer :(
I am curious if anybody else except you succeeded to set it up
I think that it requires to much work and I am wondering how someone new in programming can use it
I will stick to WinInc, it is simple to use and runs without flow :t
Why use XMASM
It is more clear like this in WinInc:

@DefProto WINOLEAPI, OleCreate, stdcall, ,<:REFCLSID,:REFIID,:DWORD,:LPFORMATETC,:LPOLECLIENTSITE,:LPSTORAGE,:ptr LPVOID>, 28

than this in SDK:
OleCreate PROTO :DWORD ,:DWORD ,:DWORD ,:XMASM ,:XMASM ,:XMASM ,:XMASM
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 24, 2014, 06:39:30 PM
Quote
I was unable to setup your SDK for use on my computer
using a batch with INCLUDE path and a single line in the code is not a setup,he can be use as it is on windows 8.1.
You can't use an API without the msdn help , the translated form don't give you enough help .
The form given by wininc just allow you to search for defines elsewhere and anywhere.this is not the case in the translated sdk who grant usable defines.
There is 161 files in the wininc and no alignment of the structure, no UNICODE
There is 1700  files in the full sdk,alignment is the same as vc++,UNICODE is supported
More,if i can say that the translated sdk can work on all windows,wininc couldn't say that (miss system switck)
More where are the defined GUID in wininc ?,from wich windows version are those files (winerror is truncated ).
It's too much generous to call the wininc a usable translate.

Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 25, 2014, 12:10:49 AM
QuoteIt's too much generous to call the wininc a usable translate.
I would say that for SDK, because I have been using WinInc for years successfully
but I can't use SDK at all
I wish that someone tells me here that they were able to use it without difficulties

If you want someone to use it you should probably make an installer for it

I am curious why have you separated it in 3 folders, why not one?

Why XMASM?
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 25, 2014, 08:15:00 PM

Quote
I am curious why have you separated it in 3 folders, why not one?
It is the choice of microsoft,not mine.With the subdiretories,there is more than three path in the windows sdk.
Further include paths seems to be a problem for you,not for me.Perhaps have you an IDE who don't allow this?
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 25, 2014, 08:29:25 PM
I use Microsoft Visual Studio Community 13 
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 26, 2014, 06:56:01 PM
Quote
Microsoft Visual Studio Community 13
For asm file couldn't be a good choice.
If you have the soluce to build an asm project with it,post it.
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 26, 2014, 07:07:52 PM
I have no problem to build asm pfrojects with it as long as I use WinInc
However, I can not setup your SDK to do that
I don't think that your SDK is a bad idea but IMO you should not use .sdk extension but .inc
and you should put all headers in 1 folder and also use proper names for vars and not XASM
Do not complicate things but simplify

I'll send you one asm project later tonight :biggrin:
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 27, 2014, 05:27:16 PM
Quote
Microsoft Visual Studio Community 13
I'll send you one asm project later tonight
I wait for it (hope it will be not to much later,before the next version)
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 27, 2014, 05:36:46 PM
Did you look in 64 Bit Assembler topic?
I couldn't post it here because of the limitation ::)
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on December 27, 2014, 06:34:44 PM

It's a joke ?

Give me a link where it is!
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: habran on December 27, 2014, 09:31:31 PM
http://masm32.com/board/index.php?topic=3902.0 (http://masm32.com/board/index.php?topic=3902.0)
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: satpro on July 19, 2015, 04:53:51 PM
Give the guy a break.
Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on August 07, 2015, 03:54:46 PM
For those who want to use visual studio to build an asm project,there is a problem to solve explain here.
http://masm32.com/board/index.php?topic=4470.msg47890#msg47890 (http://masm32.com/board/index.php?topic=4470.msg47890#msg47890)
The include paths are not send  to the compiler.
The use of an IDE dedicated to masm is better than visual studio,there is more help and windbg is an excellent debugger.

---------------------------------------------------------------------------------------------------------------

Quote
jwasm.exe /c -win64 -Zp8 /nologo /Zi /Fo"x64\Release\Win64_8.obj" /Fl"" /I "H:\sdkrc81\shared" /I "H:\sdkrc81\um" /I "H:\sdkrc81\vc" /W2 /coff 
All seems OK but:
At compile , couldn't find ...

The debug log file show this command line received:
Quote
fenetre.log
         jwasm.exe /c /nologo /Zi /Fo"Debug\Win64_8.obj" /W2 /coff   Win64_8.asm
The include paths had diseappeared from the command line,Any idea ?????????
Modify message


Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on August 08, 2015, 01:22:59 AM
This file is enough to do a test
Quote
    .486                                    ; create 32 bit code
    .model flat, stdcall                    ; 32 bit memory model
    option casemap :none                    ; case sensitive

    include \masm32\include\kernel32.inc


    .code                       ; Tell MASM where the code starts

; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««

start:                          ; The CODE entry point to the program

invoke ExitProcess,0
; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««

end start                       ; Tell MASM where the program ends
The upper code had no problem at compile
Now this one ......
Quote
    .486                                    ; create 32 bit code
    .model flat, stdcall                    ; 32 bit memory model
    option casemap :none                    ; case sensitive

    include kernel32.inc


    .code                       ; Tell MASM where the code starts

; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««

start:                          ; The CODE entry point to the program

invoke ExitProcess,0
; «««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««««

end start                       ; Tell MASM where the program ends


The upper code need an include path working


Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on August 08, 2015, 08:35:07 PM
answer:

For the include path problem,I had found the soluce.
QuoteIn the property page of the project "Include Path"= H:\sdkrc81\shared;H:\sdkrc81\um;H:\sdkrc81\vc;

That all, if the list is not ended by a ; it is shown in the property command line but not done.
headers files extensions are the one you want

Title: Re: Full SDK 8.1 translate for 64 and 32 bits
Post by: TouEnMasm on September 28, 2015, 06:38:14 PM
Added lib of inline c++ function for the crt
New also:
The following files had been tested,other can need some modifies
The before_use_me.exe allow you to adapt constants switchs to your version of windows

\sdkrc81\shared\rpc.sdk Nombre d'Include: 12       
\sdkrc81\um\amstream.sdk Nombre d'Include: 13       
\sdkrc81\um\AtscPsipParser.sdk Nombre d'Include: 10    
\sdkrc81\um\Audioclient.sdk Nombre d'Include: 11   
\sdkrc81\um\audioenginebaseapo.sdk Nombre d'Include: 10
\sdkrc81\um\AudioEngineEndpoint.sdk Nombre d'Include: 11
\sdkrc81\um\audiopolicy.sdk Nombre d'Include: 10   
\sdkrc81\um\Bits3_0.sdk Nombre d'Include: 10      
\sdkrc81\um\bits4_0.sdk Nombre d'Include: 11       
\sdkrc81\um\bits5_0.sdk Nombre d'Include: 11       
\sdkrc81\um\CertSrv.sdk Nombre d'Include: 10       
\sdkrc81\um\combaseapi.sdk Nombre d'Include: 10    
\sdkrc81\um\ComSvcs.sdk Nombre d'Include: 12      
\sdkrc81\um\d2d1.sdk Nombre d'Include: 10      
\sdkrc81\um\d3d10.sdk Nombre d'Include: 13      
\sdkrc81\um\d3d11.sdk Nombre d'Include: 15      
\sdkrc81\um\d3d11_2.sdk Nombre d'Include: 10      
\sdkrc81\um\devicetopology.sdk Nombre d'Include: 10   
\sdkrc81\um\dshow.sdk Nombre d'Include: 17      
\sdkrc81\um\DvbSiParser.sdk Nombre d'Include: 10   
\sdkrc81\um\ehstorapi.sdk Nombre d'Include: 10      
\sdkrc81\um\evr9.sdk Nombre d'Include: 10      
\sdkrc81\um\fsrmtlb.sdk Nombre d'Include: 12      
\sdkrc81\um\functiondiscoveryapi.sdk Include: 14    
\sdkrc81\um\FwCommon.sdk Nombre d'Include: 15      
\sdkrc81\um\gdiplus.sdk Nombre d'Include: 31      
\sdkrc81\um\Iadmw.sdk Nombre d'Include: 10      
\sdkrc81\um\LM.sdk Nombre d'Include: 19            
\sdkrc81\um\locationapi.sdk Nombre d'Include: 11   
\sdkrc81\um\minidrv.sdk Nombre d'Include: 20      
\sdkrc81\um\msctf.sdk Nombre d'Include: 10      
\sdkrc81\um\MsHTML.sdk Nombre d'Include: 12      
\sdkrc81\um\Mshtmlc.sdk Nombre d'Include: 11      
\sdkrc81\um\msopc.sdk Nombre d'Include: 11      
\sdkrc81\um\oledb.sdk Nombre d'Include: 93      
\sdkrc81\um\oledbdep.sdk Nombre d'Include: 22      
\sdkrc81\um\propsys.sdk Nombre d'Include: 11      
\sdkrc81\um\sapi.sdk Nombre d'Include: 11      
\sdkrc81\um\SearchAPI.sdk Nombre d'Include: 24   
\sdkrc81\um\segment.sdk Nombre d'Include: 12      
\sdkrc81\um\shdeprecated.sdk Nombre d'Include: 12   
\sdkrc81\um\ShObjIdl.sdk Nombre d'Include: 18    
\sdkrc81\um\sphelper.sdk Nombre d'Include: 14      
\sdkrc81\um\strmif.sdk Nombre d'Include: 18      
\sdkrc81\um\Tapi3.sdk Nombre d'Include: 13      
\sdkrc81\um\tuner.sdk Nombre d'Include: 10      
\sdkrc81\um\UtilLib.sdk Nombre d'Include: 10      
\sdkrc81\um\vds.sdk Nombre d'Include: 13      
\sdkrc81\um\vdshwprv.sdk Nombre d'Include: 13      
\sdkrc81\um\wiamindr_lh.sdk Nombre d'Include: 10   
\sdkrc81\um\wiamindr_xp.sdk Nombre d'Include: 10   
\sdkrc81\um\WinBase.sdk Nombre d'Include: 34      
\sdkrc81\um\wincodec.sdk Nombre d'Include: 10      
\sdkrc81\um\Windows.sdk Nombre d'Include: 38       
\sdkrc81\um\winnt.sdk Nombre d'Include: 13      
\sdkrc81\um\Wsdapi.sdk Nombre d'Include: 10      
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on October 12, 2015, 04:01:55 AM

WINDOWS 10.0 translated  in the new form,see first post
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on December 15, 2015, 07:48:27 PM
added strsafe functions (inline) to the crt lib (Windows 10 inline functions)
macros_forum.inc added ,macros of the masm32 package usable with the translated sdk
small modifies.
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: Grincheux on January 28, 2016, 08:00:19 PM
QuotePage Introuvable

http://luce.yves.pagesperso-orange.fr/sdkrc81.zip
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on January 28, 2016, 08:08:05 PM
EDIT: Correct link is NOW in the first post.

Always refer to this one:

 Full sdk translate download link  (http://masm32.com/board/index.php?topic=563.msg4563#msg4563/)


Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on February 26, 2016, 08:15:35 PM
corrected d2xxx.sdk,they are now with the translated interfaces.
added km directory (drivers),mmos
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: fearless on July 25, 2016, 04:03:58 AM
I managed to get this partially working. I copied all files into a single folder, pointed the radasm path to that folder, included:

include translate64.inc
include windows.sdk


Modified translate64.inc slightly based on the run me exe in the root folder that generated win version etc in a new window.

Compiles fine with jwasm/hjwasm, but when i try to link it came up with errors about unresolved references and listed all the functions: GetMessage, CreateWindowEx, DefWindowProc etc etc. Im using the microsoft linker v12 (x64 version). If i use the WinInc includes it seems to link fine, so not sure why it wouldnt link.

Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on August 03, 2016, 07:18:52 PM
If there is unresolved reference at link can be only a bad path to the lib not to the include.
You need first to verify the path to the lib (64 bits libraries with correct machine)
You can also use "include sdk64.inc" to decrease the number of lines.
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: LiaoMi on August 12, 2016, 01:09:42 AM
Hallo,

I can not run this program fenetre_window, program terminates with an error, in the debugger can be seen that an exception occurs when you call

00007FF6FAC610E0 | E8 9F 13 00 00                                       | CALL <JMP.&RegisterClassExA>                             |

And here is an exception ...

00007FFFB3E63CF0 | 0F 29 45 C0                                          | MOVAPS DQWORD PTR SS:[RBP-40],XMM0                       |

program that I compiled myself, also fails in this place.

The next problem, the following error message -
HJWasm v2.14, Jun  9 2016, Masm-compatible assembler.
Portions Copyright (c) 1992-2002 Sybase, Inc. All Rights Reserved.
Source code is available under the Sybase Open Watcom Public License.

Translated Windows SDK 8.1 64 bits
windef WIN_INTERNAL manque ENDIF
Win64_8.asm: 126 lines, 3 passes, 284 ms, 0 warnings, 0 errors
Press any key to continue . . .
Microsoft (R) Windows (R) Resource Compiler Version 10.0.10011.16384
Copyright (C) Microsoft Corporation.  All rights reserved.

Using codepage 1251 as default
Creating Win64_8.res

Win64_8.rc.
Writing MENU:100,       lang:0x409,     size 34.
Writing BITMAP:101,     lang:0x409,     size 29112
Microsoft (R) Windows Resource To Object Converter Version 14.00.24210.0
Copyright (C) Microsoft Corporation.  All rights reserved.

----------------------------
******* avec RESSOURCE ******
-----------------------------
Microsoft (R) Incremental Linker Version 14.00.24210.0
Copyright (C) Microsoft Corporation.  All rights reserved.

Win64_8.obj : fatal error LNK1318: Unexpected PDB error; OK (0) ''

There has been an error while linking this project.

Press any key to continue . . .


which occurs due to /DEBUG /debugtype:cv

Maybe someone already had the same problem ?! Thank you in advance!

P.S. Why do my procedure calls pass through a stub?

00007FF6FAC61344 | 33 C9                                                | XOR ECX,ECX                                              |
00007FF6FAC61346 | E8 15 11 00 00                                       | CALL <JMP.&GetModuleHandleAStub>                         |
00007FF6FAC6134B | 48 89 05 DE 3D 00 00                                 | MOV QWORD PTR DS:[7FF6FAC65130],RAX                      |
00007FF6FAC61352 | E8 FD 10 00 00                                       | CALL <JMP.&GetCommandLineAStub>                          |
00007FF6FAC61357 | 48 89 05 E2 3D 00 00                                 | MOV QWORD PTR DS:[7FF6FAC65140],RAX                      |


Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on August 17, 2016, 03:02:36 PM
Quote
Win64_8.obj : fatal error LNK1318: Unexpected PDB error; OK (0) ''
try to compile in release mode,not in debug mode
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: LiaoMi on August 17, 2016, 05:46:40 PM
Quote from: ToutEnMasm on August 17, 2016, 03:02:36 PM
Quote
Win64_8.obj : fatal error LNK1318: Unexpected PDB error; OK (0) ''
try to compile in release mode,not in debug mode

Hallo,

in the release build works well, but the program falls on my system, windows 10 Ent ...

P.S. What is written in the file jobapi2.SDK, some programs going with an error in the file jobapi2.SDK, after include Winbase.SDK

Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on August 18, 2016, 04:38:55 PM
You are in 64 bits,fail of the debug build is the fault of the compiler.
With a correct release build,you have to suspect a bad alignment,verify this.
Put your source code on another post and sub-forum will be of great help.
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: ragdog on January 14, 2017, 02:46:40 AM
Hello

Has anyone to settings up this sdk to use it with Masm32 or hJwasm x86/x64 builds?
I have run before_use_me.exe but

and inlude sdk64.inc or sdk32.inc

Has anyone examples for Masm32 or hJwasm x86/x64 ?

Greets,
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on January 19, 2017, 07:10:27 PM

In the first post,you have demo64.zip who give you all you need + a batch file.
The paths given by the batch must be changed by yours (makeit.bat)
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: ragdog on March 02, 2018, 08:17:50 AM
Hello Yves

I try to download cpusys_build8.1.zip  Firefox say this file contain a virus or malware?!?

Regards,
Title: Re: Full SDK 10.0 translate for 64 and 32 bits
Post by: TouEnMasm on May 17, 2018, 01:48:37 AM
It must be a false positive.Unactive your antivirus.
OR
use the before_use_me.exe included in the zip,it do the same thing.