473,729 Members | 2,331 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

A linking problem!

Hi,

I have encountered a linking problem while using g++ to link our
product. There are Fortran, C, C++ code in our product. The error
listed below:

/usr/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status

But no any reasons or suggestions are given, I'm so puzzled!

Anyone can give me the solutions or some suggestions?

Any comments are sincerely appreciated!

Thanks in advance!
Nov 13 '05 #1
4 3923
On 10 Aug 2003 05:35:58 -0700
jf***@vip.sina. com (Kevin Wan) wrote:
Hi,

I have encountered a linking problem while using g++ to link our
product. There are Fortran, C, C++ code in our product. The error
listed below:

/usr/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status

But no any reasons or suggestions are given, I'm so puzzled!

Anyone can give me the solutions or some suggestions?

Any comments are sincerely appreciated!

Thanks in advance!


What is your C question?

--
char*x(c,k,s)ch ar*k,*s;{if(!k) return*s-36?x(0,0,s+1):s ;if(s)if(*s)c=1 0+(c?(x(
c,k,0),x(c,k+=* s-c,s+1),*k):(x(* s,k,s+1),0));el se c=10;printf(&x( ~0,0,k)[c-~-
c+"1"[~c<-c]],c);}main(){x(0 ,"^[kXc6]dn_eaoh$%c","-34*1'.+(,03#;+, )/'///*");}
Nov 13 '05 #2
Pieter Droogendijk <gi*@binky.home unix.org> wrote in message news:<200308101 51539.34610e56. gi*@binky.homeu nix.org>...
On 10 Aug 2003 05:35:58 -0700
jf***@vip.sina. com (Kevin Wan) wrote:
Hi,

I have encountered a linking problem while using g++ to link our
product. There are Fortran, C, C++ code in our product. The error
listed below:

/usr/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status

But no any reasons or suggestions are given, I'm so puzzled!

Anyone can give me the solutions or some suggestions?

Any comments are sincerely appreciated!

Thanks in advance!


What is your C question?


First of all, thanks for your reply!

Sorry, it's not just a C question, but I was wondering if I should
post it here! I thought it's just a linking problem and maybe I can
get some help here!

Thanks again!
Nov 13 '05 #3
Kevin Wan wrote:
Hi,

I have encountered a linking problem while using g++ to link our
product. There are Fortran, C, C++ code in our product. The error
listed below:

/usr/bin/ld: final link failed: Bad value
collect2: ld returned 1 exit status

But no any reasons or suggestions are given, I'm so puzzled!

Anyone can give me the solutions or some suggestions?

You're off topic here, as your question is not about standard C.

<OT>
Try news:gnu.gcc.he lp
news:gnu.g++.he lp

or

news:comp.unix. programmer

Be sure to supply the best information you can about the error.
</OT>

HTH,
--ag

BTW - be sure to read the FAQ, at:

http://www.eskimo.com/~scs/C-faq/top.html

before posting here again.
--
Artie Gold -- Austin, Texas

Nov 13 '05 #4

Pieter Droogendijk <gi*@binky.home unix.org> wrote in message
char*x(c,k,s)ch ar*k,*s;{if(!k) return*s-36?x(0,0,s+1):s ;if(s)if(*s)c=1 0+(c?(x
( c,k,0),x(c,k+=* s-c,s+1),*k):(x(* s,k,s+1),0));el se c=10;printf(&x( ~0,0,k)[c-~-

c+"1"[~c<-c]],c);}main(){x(0 ,"^[kXc6]dn_eaoh$%c","-34*1'.+(,03#;+, )/'///*");
}

rad.c
rad.c(1) : warning C4131: 'x' : uses old-style declarator
rad.c(2) : warning C4013: 'printf' undefined; assuming extern returning int
rad.c(3) : warning C4715: 'x' : not all control paths return a value

The first warning is an easy fix, the 2nd one is forgiveable since we all
know what
to #include, the 3rd one is just not very tidy. Maybe the compiler is just
being persnickety
and honking at code that's unreachable anyway, but I haven't checked it.

Otherwise, I like it! Is there a program that takes arbitrary strings and
converts them to obfuscated C, or did you hand-craft it?

--$teve


Nov 13 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1721
by: Wolfgang | last post by:
I have a problem with linking my CPP Code under a irix6 machine (sgi, UNIX). In my CPP code I use some Functions which are written in Python. So its a kind of CPP wrapper for my Python functions In my Python Code I use threads to communicate over the network and stuff like this. Compilation and linking are working very well under Windows and Linux with the same code. Under the sgi, UNIX machine some errors occur and I don't no why....
27
3099
by: Lee Phillips | last post by:
I believe it is universally accepted that decorating your website with images from someone else's, without permission, is rude and unethical, even if the images are in the public domain, because to do so is to steal bandwidth. But I have run across a situation where people are linking to other types of resources that I offer on my website without my permission, and I was interested to know if there is a consensus on the ethics of this...
0
2246
by: gasturbtec | last post by:
please help im new at access programming and i just got this project dropped in my lap because the old programmer quit. i've been doing ok so far but now i need to add code to an existing database that is used to connect to other databases and generate reports. below is sample code of how the database does the linking i hope i give you enough info to help me but if not let me know and i will give more. Sub txtShipDataFileSub() Dim...
18
3087
by: Mark P | last post by:
I have a bit of vb code that uses Tables.Append to programatically link tables from Oracle and DB2 datasources. The problem I am having on some client machines is that the link will take anywhere from 1 to 3 minutes to link the table. When I manually link the tables,through Access, it takes no time at all. Note that only certain client have the problem, and the problem will sometimes go away. These clients will usually get an ODBC Call...
17
7006
by: Mitas Nikos | last post by:
I am trying to use the library conio2 and though I have managed with a few relatively simple examples when i try to compile a program which conio's function clrscr is not in main() i get an error from the linker. undefined reference to `clrscr' ld returned 1 exit status I include the conio2.h on top of the file where clrscr() fn is. How do I pass the -lconio parameter when I have multiple files?Isn't it:
1
2243
by: buchalino | last post by:
Hi Guys, Please can someone help me, I am having a linking problem . I am writing a socket program, the problem is just the linking . I am using VC++ In the process of the problem, I installed the MSDN service pack, but not sure if it has a specific directory to be installed in.
5
2055
by: news.microsoft.com | last post by:
We have recently upgraded from VS2002 to VS2005 and I'm having a problem with the linker always performing a full link even though nothing has changed. In searching the newsgroups I found that I could add "/test" to the linker options and it would tell me why it was causing it to re-link (full link). This is what I get. Linking... LINK : file alignment: 512, section alignment: 4096 LINK : LINK options changed; performing full link LINK...
13
6511
by: 7stud | last post by:
test1.py: -------------------- import shelve s = shelve.open("/Users/me/2testing/dir1/aaa.txt") s = "red" s.close() --------output:------ $ python test1.py
0
3980
by: xieml2007 | last post by:
Dear Madam or Sir, I encountered one problem which is quite similiar to the discussions launched at the web site: http://www.thescripts.com/forum/thread280324.html
4
8059
by: naveenmurthy | last post by:
Hello All, I have created a .mht file in following format. 1. The .mht file contains following htmls. a. MHTLinkingProblem.html b. Left.html c. Right.html d. Start.html
0
8761
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9426
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9142
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8148
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6722
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6022
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4795
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3238
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2163
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.