Message from discussion
Did the E3033 problem get resolved?
Received: by 10.42.133.135 with SMTP id h7mr21769846ict.4.1320429636175;
Fri, 04 Nov 2011 11:00:36 -0700 (PDT)
Path: p6ni71051pbn.0!nntp.google.com!news1.google.com!goblin3!goblin2!goblin.stu.neva.ru!aioe.org!.POSTED!not-for-mail
From: dpb <n...@non.net>
Newsgroups: openwatcom.users.fortran
Subject: Re: Did the E3033 problem get resolved?
Date: Fri, 04 Nov 2011 13:00:29 -0500
Organization: Aioe.org NNTP Server
Lines: 77
Message-ID: <j9197v$h26$1@speranza.aioe.org>
References: <j8vs0h$98o$2@dont-email.me>
NNTP-Posting-Host: q6emOko+rQ9aBXaIakW1JQ.user.speranza.aioe.org
Mime-Version: 1.0
X-Complaints-To: abuse@aioe.org
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2.18) Gecko/20110616 Thunderbird/3.1.11
X-Notice: Filtered by postfilter v. 0.8.2
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: 7bit
On 11/4/2011 12:08 AM, W. eWatson wrote:
...
> You could put the subroutines in a library thus
> wfl386 /c sub1.for
> wfl386 /c sub2.for
> wlib mylib.lib +sub1.obj +sub2.obj
>
> Then compile and link mainp.for to the library
> wfl386 mainp.for mylib.lib
> ==================
> (BTW, what's the /c for?
Do you _never_ read the help files? Or, execute
wfl386 |more
...
> and another for a subroutine. Using the IDE, I successfully executed the
> program. There was no obvious way there to create a lib for the
> subroutine,...
I've told you how to do this several times before, as well, and it's
also in the tutorial you didn't like.
Create a new project for the library you want to make. The IDE will
prompt for the image type to build; select "Lib". Then you reference
that library in whatever project(s) need it just like the libraries are
referenced in the "kitchen" tutorial.
It's the same principle as used in Visual Studio w/ only a very slightly
different interface.
> ... so I tried the method above. All went well until I executed
> the wlf386 command. I got the E3033 error message and a complaint about
> "Error: ... line 4:directive error near librarymylib.lib". That was
> followed by "Error: linker returned a bad status"
...
> Later others thought it might be a bug. Someone suggested using
> wfc386/wlink as a workaround, and that ended the thread.
>
> So what is the right answer? wfc386/link mainp.for mylib.lib
...
It is a bug. Did a test here. Built a test app and library
testfor.for, testlib.lib
The directive file generated was
system nt
name testfor
file testfor.obj
librarytestlib.lib
Note there's a missing space on the library directive--it should be
library testlib.lib
The same under Watcom V11 works correctly so this somehow got introduced
into the current (or an earlier and is still here) OW build. :(
wfc386 and wlink will work.
For the above
wfc386 testfor.for
wfc385 testlib.lib
wlib testlib +testlib.obj
wlink system nt name testfor file testfor[.obj] library testfor[.lib]
Normally one makes a make file or uses a batch file rather than all
manually, of course.
I didn't do the IDE version...
--