Common Installation Problems with the Windows 3.00 SDK

ID Number: Q68970

3.00

WINDOWS

Summary:

The information below discusses some of the common problems you may

encounter when installing the Microsoft Windows Software Development

Kit (SDK) version 3.00. The following information is divided into two

sections: "Common Issues" and "Tips and Suggestions."

More Information:

COMMON ISSUES

=============

Environment Problems

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

During the process of building one of the SDK sample applications, the

error messages "Cannot find library" and "Cannot open file" indicate

that the environment variables are not set properly.

Page 2-5 of the "Microsoft Windows Software Development Kit

Installation and Update Guide" describes the changes you must make to

your CONFIG.SYS file. The README.TXT file, installed with the SDK,

contains information about necessary changes to the environment

variables in your AUTOEXEC.BAT file.

If you have made the changes outlined in the documentation and still

experience difficulty, do the following:

1. Rename the CONFIG.SYS and AUTOEXEC.BAT files.

2. Create new CONFIG.SYS and AUTOEXEC.BAT files that contain the

minimum data required to compile Windows applications.

3. Reboot the computer.

4. Try the compilation again.

Unresolved Externals

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

During the process of linking an application, the error messages

"Unresolved Externals" or "Warning: No Stack Segment" indicate that an

incompatible version of the Microsoft linker is being used.

Windows applications must be linked with a "Segmented Executable"

linker. Each Microsoft linker displays version information with its

copyright message. Windows applications are built with LINK version

5.00 or later.

If you are using Microsoft C version 5.10, you can find the proper

version of LINK on the Utilities 1 disk. By default, Microsoft C

version 6.00 installs the proper linker into the compiler's BIN or

BINB directory.

Microsoft C version 5.00 does not include a segmented executable

linker. If you have version 2.10 of the Windows SDK, you can use the

LINK4 linker that was included with it. Otherwise, contact Microsoft

and request the free Supplemental Compiler Utilities disk. In the

United States, call the Microsoft Information Center at

(800) 426-9400. Outside the US, contact the Microsoft subsidiary that

serves your country.

Using C 6.00 with the Windows SDK Versions 2.x

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

If you are using Microsoft C version 6.00, the Windows SDK versions

2.x installation procedure will fail when it attempts to create the

Windows libraries.

If you have a copy of Microsoft C version 5.10, run its installation

program with the /L switch (type "setup /L") to install the C 5.10

libraries into a directory. Run the Windows SDK installation

procedure, and it will modify these libraries for Windows 2.x program

development.

To compile a Windows 2.x application with Microsoft C version 6.00,

you must add the /Gh compiler option to the C compiler command line.

When linking a Windows 2.x application, make sure that the LIB

environment variable points to the Windows libraries.

If you do not have a copy of Microsoft C version 5.10, a free disk

with the necessary libraries is available. Please call Microsoft

Product Support Services at (206) 637-7096, and select support for

Microsoft C (the quick-dial code is 1, 1). Inform the technician that

you need the C 5.10 libraries.

Using Microsoft QuickC or a Third-Party Compiler

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

If you want to use a non-Microsoft compiler to develop Windows

applications, please contact the compiler manufacturer to verify that

the compiler supports Windows application development.

If the third-party compiler does support Windows programming, you will

need the Supplemental Compiler Utilities disk in addition to the SDK.

If you want to use the Microsoft QuickC Compiler for Windows

programming, you will need QuickC version 2.50, as well as the

Supplemental Compiler Utilities disk.

To order the Supplemental Compiler Utilities disk, please contact

Microsoft. In the United States, call the Microsoft Information Center

at (800) 426-9400. Outside the US, contact the Microsoft subsidiary

that serves your country.

CodeView for Windows Problems

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

CodeView for Windows requires that a second, debugging monitor is

installed in your system. Your primary monitor must be either an EGA,

VGA, or an 8514/a.

On most systems, the debugging monitor should be a Hercules-compatible

monochrome monitor.

IBM PS/2 systems must have an 8514/a as the primary monitor and a VGA

as the debugging monitor. To use this configuration, specify the /8

option on the CVW command line. If a monochrome VGA is used, you must

also specify the /B option.

Any system with an 8514/a as the primary monitor can use a standard

VGA adapter and monitor for debugging.

For more information on CodeView for Windows, please see section 7.3

(beginning on page 7-5) in the "Microsoft Software Development Kit

Tools" manual.

Moving from Windows 2.x to Windows 3.00

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

To have a Windows application run under both Windows 2.x and Windows

3.00, compile the application with the Windows 2.x SDK and use the

Windows 3.00 SDK Mark utility to indicate that the application is

Windows 3.00-aware. For more information on this process, see page

4-23 of the "Microsoft Windows Software Development Kit Installation

and Update Guide."

To update an application from Windows 2.x to Windows 3.00, follow the

instructions given on page 4-25 of the SDK installation and update

guide.

An application may be built with the tools provided in the Windows

3.00 SDK, but the Windows 3.00 compatibility warning is displayed when

the application is run. This occurs if the EXE is not processed by the

Windows 3.00 Resource Compiler (RC.EXE).

The compatibility warning will also occur if an old version of the

Resource Compiler or its preprocessor (RCPP.EXE) is used. If this is

the case, delete all SDK files and reinstall the Windows 3.00 SDK.

TIPS AND SUGGESTIONS

====================

The Basic Test

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

A good test to make sure that the SDK is successfully installed is to

compile, link, and run the GENERIC sample application included with

the SDK. You should do this before trying to diagnose any more subtle

installation problems.

The Installation Guide

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

The "Microsoft Software Development Kit Installation and Update Guide"

contains complete information on installing the SDK, setting up your

Windows development environment, new features of Windows 3.00, and

moving Windows 2.x applications to Windows 3.00.

A Basic Development Environment

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

If you are just getting started in Windows development, the following

is a recommended Windows-based development environment:

1. Use a Windows-based text editor, or set up a PIF file for your

favorite DOS editor. (For more information on PIF files, see page

444, "Working with PIFs and the PIF editor," in the "Microsoft

Windows User's Guide.")

2. Use the File Manager or the MS-DOS Executive to handle files.

3. Create a PIF file for your Make utility (NMAKE or NMK).

4. Add the .MAK or .MKE extension to Make filenames. (For example,

change the name of the Make file for GENERIC from "GENERIC" to

"GENERIC.MKE".)

5. Add the corresponding entry to the [Extensions] section of the

WIN.INI file. For example, add the line

mke=nmk.com ^.mke

to WIN.INI. If this is done, double-clicking on a file with the

.MKE extension will invoke the Make utility.

These changes will allow you to edit, compile, and run programs

without leaving Windows.

The process of setting up a Windows development environment is

described more completely in Chapter 3 of the SDK installation and

update guide.

Programmer's WorkBench

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

Unless you are an experienced PWB user, we suggest that you use a

Windows-based development environment, as described above, rather than

PWB.

If you would like more information on setting up PWB as your Windows

development environment, please see the PWBINFO.WRI file that is

installed with the Windows 3.00 SDK.

Partial Installations

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

If the Windows 2.x SDK was previously installed on a machine, and you

partially install the Windows 3.00 SDK, many strange problems can

occur. The most common is that a program will compile but not be

marked as a Windows 3.00 application (this will occur if the Windows

2.x Resource Compiler is used). If problems such as this occur,

delete all files from the SDK directory and install the Windows 3.00

SDK from the beginning.