Author Topic: Question on installing the Platform SDK  (Read 6226 times)

Offline Bitpower

  • Single posting newcomer
  • *
  • Posts: 6
Question on installing the Platform SDK
« on: January 25, 2006, 03:24:06 pm »
I'm using Visual Studio 6.0 for learning purposes, and this is NOT compatible with the latest platform SDK. 

I have MS Visual Toolkit 2003 installed in a directory e:\compiler\.   This directory is completely seperate from the place where I have Visual Studio 6 installed.

Also I will be doing some developmental work that will involve forming a team of people from around the internet.   I haven't decided which free compiler we will be using yet, but testing multiple ones.  The only condition I have so far on the compiler, is that it NOT be a GPL-ed compiler. 

But getting back on topic now:  My point here is that when I'm testing MS Visual Toolkit 2003, I want it to be "contained" and "controlled".  I want it to use the same files that if someone else on the development team installed it on a clean system, they would have also.     So I want each compiler I test to only used files contained in the installation directory, or any additional files I install there for it.

This now brings me to the question on installing the Platform SDK.  I have never installed a Platform SDK before.   My question is, if I download the latest Platform SDK, and install it, will I have a choice as to where it installs it files?  I know many microsoft programs, just install files, without even bothering to tell you were it is installing them.  So does the latest Platform SDK give you a choice as to where you install the files?

Offline grunerite

  • Multiple posting newcomer
  • *
  • Posts: 41
Re: Question on installing the Platform SDK
« Reply #1 on: January 25, 2006, 04:17:02 pm »
It has been some time since I installed it, but I am almost certain it does ask you for a place to install it. Whether it will go sneak some files in elsewhere, I'm not sure, but I wouldn't be at all surprised if it does, and would actually assume it does.

Then, since you have VS6 installed, you'll have to get your environment variable set up correctly, depending on which compiler you use. The SDK supplies a little bat(?) file called something like setenvvar.bat. If you run it, it will add the directories to your PATH and other environment variables, might even modify your VS6 paths (not certain). The point is, think twice before running setenvvar.bat.

Offline Game_Ender

  • Lives here!
  • ****
  • Posts: 551
Re: Question on installing the Platform SDK
« Reply #2 on: January 25, 2006, 05:00:12 pm »
Unlike the linux GCC, MingW builds your program against non GPL runtime libraries so you don't have to GPL code you compile with it.  I am guessing that was your concern, you can see here for more information.

I have recently installed the VC 2003 toolkit and the Platform SDK and they both ask where to place the files, so you can set up a uniform directory layout if like.  You can tell it to install in "e:\compiler\Platform_SDK\".  This is not needed though, becuase Code::Blocks allows you to set variables in your project.  In my projects I have a variable called MS_PLATFORM_SDK and just set it equal to the root directory of the SDK (usually C:\Program Files\Microsoft Platform SDK\).  Then I just use $(MS_PLATFORM_SDK)\include or \Lib in the compiler\linker.  Now this does break you encapsulation, but you can still do the encapsulated install along with the variables to provide flexibility in your project setup.

I have also installed VS 2005 Express and it does not interfere at all with the VC toolkit.

Offline severach

  • Multiple posting newcomer
  • *
  • Posts: 44
Re: Question on installing the Platform SDK
« Reply #3 on: January 26, 2006, 03:28:58 am »
I haven't decided which free compiler we will be using yet, but testing multiple ones.  The only condition I have so far on the compiler, is that it NOT be a GPL-ed compiler.
Why not make it run with all the compilers rather than making it dependant on oddities in a particular compiler? It need not *officially* run on all the compilers, someone just tests the others from time to time to ensure that you aren't doing something bad.

Offline Bitpower

  • Single posting newcomer
  • *
  • Posts: 6
Re: Question on installing the Platform SDK
« Reply #4 on: January 26, 2006, 04:08:08 am »
Why not make it run with all the compilers rather than making it dependant on oddities in a particular compiler? It need not *officially* run on all the compilers, someone just tests the others from time to time to ensure that you aren't doing something bad.

I already thought about doing that, but it is not actually oddities in a particular compiler, but things actually working as they should, which seems to be the difference between the compilers. 

In my own testing, I tested the compilers using just what files came with the compiler's distribution.  I went to each compiler's web site, setup each compiler and tested it just using the files that came with it.    I tested it by using the "new project" option in Code Blocks and just compiling the sample code included with each type of new project under 1.0rc2.

Here are my results:
Open Watcom: (files included in distribution only)
Console Application:  Pass
Win32Gui Application: Pass
Dll Sample: Pass
Static Library Sample: Pass
SDCC Application: Pass
--------------------------------------------------
Digital Mars: (files included in distribution only)
Console Application: Fail
Win32Gui Application: Pass
Dll Sample: Fail
Static Library Sample: Pass (2 warning messages)
SDCC Application: Pass
--------------------------------------------------
MS Visual Toolkit 2003 (files included in distribution only)
Console Application: Pass (9 warning messages)
Win32Gui Application: Fail
Dll Sample: Fail
Static Library Sample: Fail
SDCC Application: Fail
--------------------------------------------------
Borland C++ (files included in distribution only)
Console application: Fail
Win32Gui Application: Fail
Dll Sample: Fail
Static Library Sample: Fail
SDCC Application: Fail
--------------------------------------------------

The funny thing are things like the SDCC application, that when you click on "new project" it gives you 3 lines of code.  Only 3 lines of code, and 2 compilers manage to fail on compiling 3 lines of code? 


Offline takeshi miya

  • Lives here!
  • ****
  • Posts: 1487
Re: Question on installing the Platform SDK
« Reply #5 on: January 26, 2006, 05:27:09 am »
Well, all of those failed obviously because the templates (the ones that are in New Project...) have the compiler flags only for GCC (some are for MSVC also).

But you also obviously don't have the setup working, because Console Application can't fail in DMars for example. You may have forgotten to include STLport for example.
Same goes for MSVC, which without Platform SDK is almost useless.

You really want to read this page on the Wiki: http://wiki.codeblocks.org/index.php?title=Installing_a_supported_compiler
« Last Edit: January 26, 2006, 05:31:19 am by Takeshi Miya »

Offline Bitpower

  • Single posting newcomer
  • *
  • Posts: 6
Re: Question on installing the Platform SDK
« Reply #6 on: January 26, 2006, 06:59:16 am »
As stated in my message, this test was just testing how well each compiler works when only using what was included by each compiler's distribution.  In other words, if you go to the compilers website and download and install it and only it.    Obviously, several of the fails are because of not having the necessary libaries installed.  But it was an interesting test to see which compilers worked the best without needing to install additional libraries.

Each compiler is setup correctly, but was setup using only what was included within the manufacturer's download, since I was testing only what was included with the compiler when you downloaded it.



Offline takeshi miya

  • Lives here!
  • ****
  • Posts: 1487
Re: Question on installing the Platform SDK
« Reply #7 on: January 26, 2006, 08:10:37 am »
You really can't expect even a C++ hello world to work if you don't even have the STL.

A compiler doesn't have to come with any library, some comes with their own STL implementation (ie. GCC's libstdc++), but some others don't, like DMars, but you can use STLport, which is a very good implementation and works on almost all compilers.
« Last Edit: January 26, 2006, 08:12:18 am by Takeshi Miya »

Offline severach

  • Multiple posting newcomer
  • *
  • Posts: 44
Re: Question on installing the Platform SDK
« Reply #8 on: February 05, 2006, 06:34:09 am »
>I tested it by using the "new project" option in Code Blocks and just compiling the sample code included with each type of new project under 1.0rc2.

You're expecting too much. MinGW is the only compiler fully supported by Code::Blocks at this time. MSVT support is fair and the rest are bad. It isn't the compilers' faults that the IDE hasn't yet been programmed to support them. It took me almost 4 days to get my DLL to compile in all 5 compilers:

http://forums.codeblocks.org/index.php?topic=946.0

Once you figure out the best switches and the proper command lines, it's nothing to compile and run in all 5 compilers to ensure that you're on the straight and narrow. I've added a sixth compiler/IDE which caught yet more errant behavior and now provides me with a fully functional debugger.

http://smorgasbordet.com/pellesc/

>Same goes for MSVC, which without Platform SDK is almost useless.

Digital Mars without an updated platform SDK is minimally useful. Fortunately it is easy to upgrade. I whipped up a .BAT file installer from:

http://cmeerw.org/prog/dm/ms_sdk.html

Offline grunerite

  • Multiple posting newcomer
  • *
  • Posts: 41
Re: Question on installing the Platform SDK
« Reply #9 on: February 05, 2006, 03:30:29 pm »
You're expecting too much. MinGW is the only compiler fully supported by Code::Blocks at this time.
Project->Properties->This_is_a_custom_makefile   

So, actually, if you have a makefile that works, Code::Blocks fully supports it.  :)

Of course, it might not have all the bells and whistles for some it supports. Your point is well taken though.

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: Question on installing the Platform SDK
« Reply #10 on: February 05, 2006, 09:35:17 pm »
>I tested it by using the "new project" option in Code Blocks and just compiling the sample code included with each type of new project under 1.0rc2.

You're expecting too much. MinGW is the only compiler fully supported by Code::Blocks at this time. MSVT support is fair and the rest are bad. It isn't the compilers' faults that the IDE hasn't yet been programmed to support them. It took me almost 4 days to get my DLL to compile in all 5 compilers:

http://forums.codeblocks.org/index.php?topic=946.0

Once you figure out the best switches and the proper command lines, it's nothing to compile and run in all 5 compilers to ensure that you're on the straight and narrow. I've added a sixth compiler/IDE which caught yet more errant behavior and now provides me with a fully functional debugger.

http://smorgasbordet.com/pellesc/

>Same goes for MSVC, which without Platform SDK is almost useless.

Digital Mars without an updated platform SDK is minimally useful. Fortunately it is easy to upgrade. I whipped up a .BAT file installer from:

http://cmeerw.org/prog/dm/ms_sdk.html

Hello,

That is not fully true that the only compiler fully supported by C::B is MinGW. I worked fine with M$ Toolkit 2003 and SDCC compiler. A variable amount of time is needed to know a compiler, how it works, how to use it, and so on. Some compilers are easier to use, other more difficult. For example, M$ Toolkit 2003 requires additional tools to work, e.g., Windows SDK, .Net SDK and may be others to work.

C::B is still in development and IMHO in the future compiler support will be improved.

Best wishes,
Michael