🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.java
Article #47

Re: Borland/Native methods query...

#47
From: Sean Doyle
Date: Mon, 13 Nov 1995 01:18
37 lines
2101 bytes
Sean Doyle wrote:
> 
> Sun's documentation for linking native methods
>  [http://java.sun.com/progGuide/native/stepbystep/_dynalib.html]
> says that:
> 
> "Note: You must have Microsoft Visual C++ Version 2.x to compile and
> link DLLs (Dynamic Link Libraries). "
> 
> I am new to the Windows world, but don't other compilers (such as
> Borland's) compile DLLs as well? Or are there some dependencies on the
> MFC that aren't apparent from a glance?
> 
> Thanks
> Sean Doyle
Ok.. so I'm responding to my own original question with more questions. 

I'm trying to compile a simple C file to use in Java as a native method. 

It appears (although I am no expert) that Borland C++ 4.5 will *not* work for Java native 
methods because there are compile errors in the standard java\include\win32 include files. 
Since I'm new to this enviroment {Borland, C++, and Windows95} I could *easily* have made a 
simple error in setting environment variables. I'm trying to compile this as a Win32 DLL. 
Apparently Borland is stricter than MVC++?

In the "HelloWorld" native example from Sun, the first few compile errors are:

Error:..\..\JAVA\INCLUDE\WIN32\TYPEDEFS.H 34:,expected
Error:..\..\JAVA\INCLUDE\WIN32\TYPEDEFS.H 35:Multiple declaration for '__int64'
Error:..\..\JAVA\INCLUDE\WIN32\TYPEDEFS.H 79:'int64_t' cannot start a parameter declaration
Error:..\..\JAVA\INCLUDE\WIN32\TYPEDEFS.H 80:Declaration syntax error
& etc...

Sorry if I'm too clueless.. I know in the future that Sun & Borland are planning to work 
together more closely :-)

Sean Doyle
Technical Details
Message-ID: <30A69CE9.3E40@mit.edu>
Path: arc1-ca.pugleaf.net!senator-bedfellow.mit.edu!usenet
References: <30A6891B.59C3@mit.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!senator-bedfellow.mit.edu!usenet
From: Sean Doyle <mesozoic@mit.edu>
Newsgroups: comp.lang.java,comp.lang.c++
Subject: Re: Borland/Native methods query...
Date: Sun, 12 Nov 1995 20:18:34 -0500
Organization: MIT LCS Clinical Decision-Making Group
Message-ID: <30A69CE9.3E40@mit.edu>
References: <30A6891B.59C3@mit.edu>
NNTP-Posting-Host: bakker.lcs.mit.edu
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
X-Mailer: Mozilla 2.0b2 (Windows; I; 32bit)