473,320 Members | 1,955 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

GCC4.1.1 file name with the same directory name

41
Hi all ,

I have the following scenario where i ma trying to build a program that has the same name as the subdir and within that subdir it needs to build and link in the those objects to create the PROG .
but GCC get all confused and complains saying that it's a directory and bombs out.

has anyone seen this befor with GCC
the PROG name is t
cc -O -DNOODBC -I/home/t/cvs/FB1023/src/include -I/usr/local64/include -I/usr/local64/include -D_PTHREADS -D_REENTRANT -DHAVE_VPRINTF -DHAVE_SYS_TIME_H -DHAVE_TERMIO_H -D_64BIT -DPOWERPC -D_GNU_SOURCE -m64 -Wall -Wno-parentheses -Wno-format -Wno-char-subscripts -DINLINE="static inline" -DBUILD_INFO="\"Developer build - not for release\"" -L/home/t/cvs/FB1023/src/lib/obj.ppc64 -L/usr/X11R6/lib64 -L /home/t/cvs/FB1023/src/lib/obj.ppc64 -L /home/t/cvs/FB1023/src/dsd/obj.ppc64 -L /usr/X11R6/lib64 -m64 -L /usr/local64/lib -L /usr/local64/lib -L /usr/local64/lib -o /home/t/cvs/FB1023/src/zap/zap /home/t/cvs/FB1023/src/zap/zap.c

/usr/bin/ld: cannot open output file /home/t/cvs/FB1023/src/zap/zap: Is a directory
collect2: ld returned 1 exit status

my dir structure is /home/t/cvs/FB1023/src/zap/zap.c
/home/t/cvs/FB1023/src/zap/zap/obj/*.o where I want to link in zap.o to produce zap program ...

My Makefile has the following
Makefile
==========
PROG=zap
SRCS= zap.c

$(CXX) $(LDFLAGS) -Wall -o $@ $(OBJS) $(NONLOCAL_OBJS)



Anyone with any ideas how i can do this in my makefile?

Thanks any help much appreciated !
Nov 8 '07 #1
3 1853
RRick
463 Expert 256MB
my dir structure is /home/t/cvs/FB1023/src/zap/zap.c
/home/t/cvs/FB1023/src/zap/zap/obj/*.o where I want to link in zap.o to produce zap program ...
It looks like you are creating a zap/zap directory. If so, then whoever gets created first wins: either the directory or the program. You can't have both with the same name.
Nov 9 '07 #2
nano2
41
I have used hp CC compiler and Sun compiler and it works fine , Is this some fault with GNU CC do you know ?
Nov 12 '07 #3
RRick
463 Expert 256MB
In unix, you only get one file with a distinct name per directory. This is true for hp, sun and linux.

I suspect the problem lies in the makefile. Does the makefile add a suffix to your program name? If it did, then you wouldn't have the name conflict.
Nov 13 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Dave Smithz | last post by:
Hi There, I have a PHP script that sends an email with attachment and works great when provided the path to the file to send. However this file needs to be on the same server as the script. ...
11
by: BoonHead, The Lost Philosopher | last post by:
I think the .NET framework is great! It's nice, clean and logical; in contradiction to the old Microsoft. It only saddens me that the new Microsoft still doesn't under stand there own...
34
by: Marcel van Kervinck | last post by:
Dear all, I would like to confirm my suspicion of a compiler bug in gcc4 for MacOSX. The code example below expects that the initializer of 'v' sets all elements in v.u.bytes to zero, as...
13
by: Sky Sigal | last post by:
I have created an IHttpHandler that waits for uploads as attachments for a webmail interface, and saves it to a directory that is defined in config.xml. My question is the following: assuming...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

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.