Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Getting alloca to work in DLL

Posted on 2003-11-07
1
Medium Priority
?
408 Views
Last Modified: 2008-02-01
Hi,

I am using Visual C++ 6 to try to compile a C++ package called OpenNURBs into a DLL which can be opened by Matlab.

I am using the Matlab Add-on for Visual Studio, which lets you select "Matlab Project" as a new project. When compiling I get the error message:

"Error C2065: 'alloca' : undeclared identifier"

I figure I'm missing the C Run Time libraries. I've added msvcrt.lib to the Link settings for the project, but still no dice.

Any ideas?
0
Comment
Question by:cdunn03
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 32

Accepted Solution

by:
jhance earned 1000 total points
ID: 9700933
There is no "alloca()" function in the VC++ runtime.  It's no wonder that the compiler is complaining about it.  Try alloc() instead.  

If you mean to use _alloca() then use that, but not alloca().
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Errors will happen. It is a fact of life for the programmer. How and when errors are detected have a great impact on quality and cost of a product. It is better to detect errors at compile time, when possible and practical. Errors that make their wa…
Unlike C#, C++ doesn't have native support for sealing classes (so they cannot be sub-classed). At the cost of a virtual base class pointer it is possible to implement a pseudo sealing mechanism The trick is to virtually inherit from a base class…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question