Q26633: Make .EXE Option Cannot Find .LIB If Not in Current Directory
Article: Q26633
Product(s): See article
Version(s): 4.00 4.00b 4.50
Operating System(s): MS-DOS
Keyword(s): ENDUSER | B_BasicCom buglist4.00 buglist4.00b buglist4.50 | mspl13_basic
Last Modified: 31-JAN-1990
When QB is invoked with the /L switch to load a Quick library and you
choose the Make EXE File or Make Library commands from the Run menu,
LINK.EXE is unable to find the .LIB file that corresponds to the Quick
library when the Quick library and .LIB are not in the current
directory.
This LINK problem occurs even when the directory where the Quick
library and the .LIB are located is correctly pointed to with the DOS
command "SET LIB=path."
Microsoft has confirmed this to be a problem in QuickBASIC Versions
4.00, 4.00b, and 4.50 and in the version of QuickBASIC that comes with
Microsoft BASIC Compiler Versions 6.00 and 6.00b for MS-DOS and MS
OS/2 (buglist6.00, buglist6.00b). This problem was corrected in
QBX.EXE in Microsoft BASIC Professional Development System (PDS)
Version 7.00 for MS-DOS and MS OS/2 (fixlist7.00).
One workaround is to give a full pathname to the .QLB when invoking
QuickBASIC, as in the following example:
QB test.bas /L c:\direct1\qb.qlb
Another workaround is to manually perform the link from the DOS
command line, correctly putting the .LIB file as the fourth argument,
as follows:
LINK test.obj,,,qb.lib;
The following steps demonstrate the problem:
1. Assume that QB.EXE and LINK.EXE are in the root directory on Drive
C. Assume that QB.QLB and QB.LIB are located in subdirectory
c:\direct1.
2. Type the following:
SET LIB=C:\DIRECT1
3. When logged on in the root directory, type the following:
QB test.bas /L qb.qlb
4. Choose Make EXE File from the Run menu. QuickBASIC will put the
QB.LIB file in the incorrect spot in the link step. (Press F4 as a
toggle to see the DOS output window.)
THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY.
Copyright Microsoft Corporation 1986-2002.