×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Jobs

Error loading a DLL (c++ code)

Error loading a DLL (c++ code)

Error loading a DLL (c++ code)

(OP)
I'm trying to load a c++ library called AdaptiveHuffman.

Here's some of the code:
libname = 'AdaptiveHuffman'
loadlibrary(libname, libname)

I've either the header file and dll file in this directory.

Here's the errors I got:

lcc preprocessor error: G:\src\TP2\AdaptiveHuffman.h:14 Could not find include file <iostream>
lcc preprocessor error: G:\src\TP2\AdaptiveHuffman.h:15 Could not find include file <vector>
lcc preprocessor error: G:\src\TP2\AdaptiveHuffman.h:16 Could not find include file <sstream>
lcc preprocessor error: G:\src\TP2\AdaptiveHuffman.h:17 Could not find include file <string>
lcc preprocessor error: G:\src\TP2\AdaptiveHuffman.h:18 Could not find include file <stdexcept>

Doesn't MATLAB support STL libs? <vector>, <string>, <sstream>, ...

Thanks for your time,
ows

RE: Error loading a DLL (c++ code)

I have used each of those with MATLAB on microsoft 6, 7 and with Borland 5 something.  It might be your compilers library and not MATLAB.  You Huffman library may expect the newer extensionless libraries as you listed them, but your compiler might have an older library.  Try
#include< iostream.h> and see your error list changes.


Also, I notice you use lcc.  That is not C++, it is strictly c.  So, that is definatly a problem you must fix.  MATLAB supports C++, but they do not give away a free C++ compiler.

If you decide to go to Microsoft, Borland, or g++ let me know, I might have some tips for setting up MATLAB that might save you some time.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members!


Resources