Solved

Problems with Borland C++4.5

Posted on 1997-03-17
4
381 Views
Last Modified: 2010-08-05
Can anyone help me?.  I recently wrote a simple graphics program using
borland 3.0 compiler consisting of 12 cpp files all in one project, all
went well and i was able to link it and create an exe file.
Now for my problem, I bought Borland C++5 and used it to compile this same
project
all went well until i tried to link it i got this error " Segment_TEXT
exceeds 64k"
can any one tell me what i'm doing wrong.
thanx in advance.
                            NEWBEE,
0
Comment
Question by:mwebster
[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
  • 2
  • 2
4 Comments
 
LVL 3

Accepted Solution

by:
gaohong earned 50 total points
ID: 1162304
Try to break largest cpp file into two or  more files
0
 

Author Comment

by:mwebster
ID: 1162305
I tried this but it still did not work here is what my project looks like
node1[cpp]code size=1596 lines=144 data size=17
node2[cpp]code size=425 lines=42 data size=483
node3[cpp]code size=537 lines=43 data size=483
node4[cpp]code size=537 lines=42 data size=483
node5[cpp]code size=2764 lines-175 data size=74
node6[cpp]code size=397 lines=34 data size=20
node7[cpp]code size=988 lines=127 data size=145
node8[cpp]code size=1412 lines=123 data size=60
node9[cpp]code size=378 lines=71 data size=2
node10[cpp]code size=1352 lines=101 data size=335
node11[cpp]code size=1508 lines=175 data size=91
node12[cpp]code size=1239 lines=172 data size=353
node13[cpp]code size=1905 lines=424 data size=48
node14[cpp]code size=2956 lines=222 data size=218
node15[cpp]code size=3046 lines=268 data size=100
node16[cpp]code size=2651 lines=200 data size=340
node17[cpp]code size=765 lines=52 data size=620
node18[cpp]code size=2961 lines=240 data size=447

from 12 to 18 and I'm still getting SEGMENT_TEXT exceeds 64k
0
 
LVL 3

Expert Comment

by:gaohong
ID: 1162306
Check your compiler settings. Make sure you select large memory
model, under memory model, check first three options, which
are put constant strings in code segment, far virtual table,
automatic far data. Set far data threashold 20000.

Under code generation, check Duplicate strings merged.

Aha, for BC5.x, use explorer find windows\system\conagent
property/memory check all auto.

good luck

gaohong xie
0
 

Author Comment

by:mwebster
ID: 1162307
thanx it worked great but this program was compiled using Small memory module in borlandc 3.0, why does'nt the same go for borlandc 5.0
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

This article shows you how to optimize memory allocations in C++ using placement new. Applicable especially to usecases dealing with creation of large number of objects. A brief on problem: Lets take example problem for simplicity: - I have a G…
Container Orchestration platforms empower organizations to scale their apps at an exceptional rate. This is the reason numerous innovation-driven companies are moving apps to an appropriated datacenter wide platform that empowers them to scale at a …
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 be introduced to the member functions push_back and pop_back of the vector class. The video will teach the difference between the two as well as how to use each one along with its functionality.

705 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