Thread: No module definition file specified:using defaults

  1. #1
    Registered User
    Join Date
    Jun 2011
    Location
    Bolpur, India
    Posts
    42

    No module definition file specified:using defaults

    I am currently using Turbo C++4.5 compiler under windows 7 OS.Frequenly I see this message while running a program.Its given as "linker warning:No module definition file specified:using defaults".
    What does this mean?Though It makes no problem....Often the program does not run without any reason.
    What does this mean?.

  2. #2
    Registered User
    Join Date
    May 2009
    Location
    Look in your attic, I am there...
    Posts
    92
    I do not use Turbo C++, but a quick google search turned this up (this quote references other steps in the link):

    Turbo C++ 4.5 Instructions
    Several problems which might have the same solution:
    - I get a linker warning
    No module definition file specified: using defaults.
    - I get a stack fault error when I try to run the program.
    - When I click on the lightning bolt, I get a blank screen. When I close the window, I am warned of a general processor fault.

    You may not have correctly typed crr.def in step 2 or did not add it to the project in step 6. Check these steps if you have not changed anything in the original code.

    If you have changed the code, then the variable MAXTERNODES may be too large. Memory allocated for arrays linked to this variable may exceed the 64K stack + heap + data group memory allocation allowed by a 16-bit compiler and straight-forward memory management. Try reducing MAXTERNODES to 3000 or so. If you have added new arrays of size MAXTERNODES, you may need to divide 3000 by the number of arrays. If you have a real need to access more memory, check out the "Which Compiler Should I Use" link. I have documentation on a advanced method which mitigates this problem in Turbo C++, but it is not recommended.
    Sorry if this isn't helpful

  3. #3
    Registered User
    Join Date
    Nov 2010
    Location
    Long Beach, CA
    Posts
    5,909
    Google your error message. There are plenty of solutions that turn up including several on this board (you should have done a search here before asking your question). Frankly, nobody here likes supporting that ancient piece of junk compiler. Borland only produces lousy 16 bit applications that let you do horrible things to memory, yet restrict you from producing anything terribly useful since you're limited to a tiny memory footprint. And it totally disregards the standards and makes up it's own rules for some things. Upgrade to something new like Pelles C or Code::Blocks with MinGW. Both are totally free and up to date. Even Visual Studio is better (yep, there's a free version of that too), though they refuse to implement the C standard set back in 1999, so they're only a little better than Borland.

  4. #4
    Registered User
    Join Date
    Jun 2011
    Location
    Bolpur, India
    Posts
    42
    Quote Originally Posted by anduril462 View Post
    Google your error message. There are plenty of solutions that turn up including several on this board (you should have done a search here before asking your question). Frankly, nobody here likes supporting that ancient piece of junk compiler. Borland only produces lousy 16 bit applications that let you do horrible things to memory, yet restrict you from producing anything terribly useful since you're limited to a tiny memory footprint. And it totally disregards the standards and makes up it's own rules for some things. Upgrade to something new like Pelles C or Code::Blocks with MinGW. Both are totally free and up to date. Even Visual Studio is better (yep, there's a free version of that too), though they refuse to implement the C standard set back in 1999, so they're only a little better than Borland.
    thank you anduril462 as you suggested I downloaded Code::Blocks and I can say it is far better than boreland's.

  5. #5
    Registered User
    Join Date
    Jun 2011
    Location
    Bolpur, India
    Posts
    42
    Quote Originally Posted by anduril462 View Post
    Google your error message. There are plenty of solutions that turn up including several on this board (you should have done a search here before asking your question). Frankly, nobody here likes supporting that ancient piece of junk compiler. Borland only produces lousy 16 bit applications that let you do horrible things to memory, yet restrict you from producing anything terribly useful since you're limited to a tiny memory footprint. And it totally disregards the standards and makes up it's own rules for some things. Upgrade to something new like Pelles C or Code::Blocks with MinGW. Both are totally free and up to date. Even Visual Studio is better (yep, there's a free version of that too), though they refuse to implement the C standard set back in 1999, so they're only a little better than Borland.
    thank you anduril462 as you suggested I downloaded Code::Blocks and I can say it is far better than boreland's.

  6. #6
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    Also, try to make the jump into the 21st century in terms of IDE+compiler solutions. A lot of people are looking forward to grabbing your hand.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

  7. #7
    Registered User
    Join Date
    Jun 2011
    Location
    Bolpur, India
    Posts
    42
    Turbo C++ once more proved its fame.I downloaded pellas c,but it do not support C++.I downloaded Code Block but when executing C++ file in Win7 it is built and compiler successfully but no output is shown.Currently except But it is not free.So I decided to keep going with Turbo C++

  8. #8
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    28,413
    Quote Originally Posted by mistu4u
    I downloaded pellas c,but it do not support C++.
    If you intend to program in C, then this is not actually a problem. Note that you posted in the C programming forum, not the C++ programming forum.

    Quote Originally Posted by mistu4u
    I downloaded Code Block but when executing C++ file in Win7 it is built and compiler successfully but no output is shown.
    You probably ran into a problem where the console window closed before you could view it. I believe Code Blocks normally pauses to prevent this, but if for some reason it did not, you have various options, e.g., run the program from a command prompt or insert some code to pause the program.

    By the way, Code Blocks is an IDE. You probably used the MinGW port of gcc or g++ as the compiler.

    Quote Originally Posted by mistu4u
    So I decided to keep going with Turbo C++
    If you intend to program in C++ using modern tools and techniques, then this is potentially a problem. Likewise if you intend to use more recent features of C.
    Last edited by laserlight; 06-15-2011 at 02:16 AM.
    Quote Originally Posted by Bjarne Stroustrup (2000-10-14)
    I get maybe two dozen requests for help with some sort of programming or design problem every day. Most have more sense than to send me hundreds of lines of code. If they do, I ask them to find the smallest example that exhibits the problem and send me that. Mostly, they then find the error themselves. "Finding the smallest program that demonstrates the error" is a powerful debugging tool.
    Look up a C++ Reference and learn How To Ask Questions The Smart Way

  9. #9
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by mistu4u View Post
    Turbo C++ once more proved its fame.I downloaded pellas c,but it do not support C++.I downloaded Code Block but when executing C++ file in Win7 it is built and compiler successfully but no output is shown.Currently except But it is not free.So I decided to keep going with Turbo C++
    Not to be insulting... but when the slightest little thing goes awry you run back to the familiar?

    Code::Blocks IDE doesn't artificially hold the command window open... Most likely it opened and closed too fast for you to see, as laserlight has suggested. This is a terrible reason to condemn a good compiler/IDE... and an even worse one to praise a non-standard, outdated pile of goo like Turbo C++.

  10. #10
    Registered User
    Join Date
    Jun 2011
    Location
    Bolpur, India
    Posts
    42
    So you guys say how to hold the command window open as i am new to this compiler!! I always like to match myself with the new!!

  11. #11
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by mistu4u View Post
    So you guys say how to hold the command window open as i am new to this compiler!! I always like to match myself with the new!!
    Code:
    #define _TESTING_
    
    int main (void)
      { 
         // lots of souce code
    
    
    #ifdef _TESTING_
       getchar();
    #endif
    
        return 0; }
    Comment the first line for release versions....

  12. #12
    Registered User
    Join Date
    Jun 2011
    Location
    Bolpur, India
    Posts
    42
    Problem is Solved!!And you will laugh knowing it was the compiler type which was causing problem!!!MS Visual c++ became default in case of my codeblock.I changed MS VC and made GNU as my default and everything worked fine!!

  13. #13
    Registered User claudiu's Avatar
    Join Date
    Feb 2010
    Location
    London, United Kingdom
    Posts
    2,094
    Quote Originally Posted by mistu4u View Post
    Problem is Solved!!And you will laugh knowing it was the compiler type which was causing problem!!!MS Visual c++ became default in case of my codeblock.I changed MS VC and made GNU as my default and everything worked fine!!
    It wasn't the compiler causing problems. It was your inability to configure the IDE to choose the appropriate compiler.
    1. Get rid of gets(). Never ever ever use it again. Replace it with fgets() and use that instead.
    2. Get rid of void main and replace it with int main(void) and return 0 at the end of the function.
    3. Get rid of conio.h and other antiquated DOS crap headers.
    4. Don't cast the return value of malloc, even if you always always always make sure that stdlib.h is included.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Header /file module issues
    By rogster001 in forum C++ Programming
    Replies: 7
    Last Post: 10-21-2009, 06:48 AM
  2. module definition file
    By Sajal in forum C Programming
    Replies: 4
    Last Post: 06-01-2009, 05:04 PM
  3. Module definition file
    By George2 in forum C++ Programming
    Replies: 1
    Last Post: 11-25-2007, 05:07 PM
  4. module definition file
    By George2 in forum C++ Programming
    Replies: 3
    Last Post: 11-03-2007, 02:48 AM
  5. Diff between Header file and Module
    By john212 in forum C Programming
    Replies: 4
    Last Post: 12-09-2002, 03:13 AM