Strange compiling problem
by Jeff Trier · in Technical Issues · 03/19/2004 (10:15 am) · 9 replies
Hi all,
I am finally taking a crack at creating a custom C++ gui object, and I am having a strange problem when compiling it.
What I did:
1) Created a Header File called guiBitmapArrayCtrl.h, and added it to the project.
2) Copied the data from guiArrayCtrl.h and pasted it into the above made file.
3) Created a file called GuiBitmapArrayCtrl.cpp, and added it to the project.
4) Copied the data from guiArrayCtrl.cc and pasted it into the above made file.
5) Realized that not only was the first "g" in gui not in lowercase as I wanted it, but the extention was cpp and not cc.
6) I went into the folder where the GuiBitmapArrayCtrl.cpp file was kept and renamed it to guiBitmapArrayCtrl.cc.
7) Added the changed file to the project.
8) Ran "Clean" in VC++.
9) Ran "build all".
10) Got an error that said that both "D:/torque/engine/gui/GuiBitmapArrayCtrl.cpp" and "D:/torque/engine/gui/guiBitmapArrayCtrl.cc" are set to create the same object file. Compile aborted.
I did a scan, and GuiBitmapArrayCtrl.cpp does not exist in my computer. Also, I can not find it in my Work Space.
Has anyone ran into this before?
EDIT:
I forgot to mention that after I pasted all the info, I made changes in the pasted info to reflect the new control I am working on... basically replaceing all instances of guiArrayCtrl with guiBitmapArrayCtrl. Not sure if this matters with the problem at hand, but I thought I should mention it.
Thanks guys!
-Jeff
I am finally taking a crack at creating a custom C++ gui object, and I am having a strange problem when compiling it.
What I did:
1) Created a Header File called guiBitmapArrayCtrl.h, and added it to the project.
2) Copied the data from guiArrayCtrl.h and pasted it into the above made file.
3) Created a file called GuiBitmapArrayCtrl.cpp, and added it to the project.
4) Copied the data from guiArrayCtrl.cc and pasted it into the above made file.
5) Realized that not only was the first "g" in gui not in lowercase as I wanted it, but the extention was cpp and not cc.
6) I went into the folder where the GuiBitmapArrayCtrl.cpp file was kept and renamed it to guiBitmapArrayCtrl.cc.
7) Added the changed file to the project.
8) Ran "Clean" in VC++.
9) Ran "build all".
10) Got an error that said that both "D:/torque/engine/gui/GuiBitmapArrayCtrl.cpp" and "D:/torque/engine/gui/guiBitmapArrayCtrl.cc" are set to create the same object file. Compile aborted.
I did a scan, and GuiBitmapArrayCtrl.cpp does not exist in my computer. Also, I can not find it in my Work Space.
Has anyone ran into this before?
EDIT:
I forgot to mention that after I pasted all the info, I made changes in the pasted info to reflect the new control I am working on... basically replaceing all instances of guiArrayCtrl with guiBitmapArrayCtrl. Not sure if this matters with the problem at hand, but I thought I should mention it.
Thanks guys!
-Jeff
About the author
Originally a Classical/Metal musician, I've always been attracted to anything involving computers, including: Networking, PC Building and Repair, software design and coding. I've been involved with game design and development for over 10 years.
#2
Thank you for your cooperation :)
03/19/2004 (12:48 pm)
Private SDK Forums for ALL TGE topics involving C++ codeThank you for your cooperation :)
#3
@Nic: Ooops! I figured it would be ok since I am not listing any code. I thought it might be a VC++ problem.
Anyway, assuming it's not a Torque related code problem, I would appreciate any help... If you think it is, please let me know and I will relocate my question.
Thanks again!
-Jeff
03/19/2004 (2:17 pm)
@Glen: yeah, I even tried rebooting the computer. I will try using find in the start menu of my o.s.@Nic: Ooops! I figured it would be ok since I am not listing any code. I thought it might be a VC++ problem.
Anyway, assuming it's not a Torque related code problem, I would appreciate any help... If you think it is, please let me know and I will relocate my question.
Thanks again!
-Jeff
#4
Or alternatively, you can just use the Find in Files (under the Edit menu) in VC++. Just make sure you specify file types *.*
03/19/2004 (2:27 pm)
Note that if you have XP, the OS's Find might not be looking at all the files ... there's a resource somewhere about how to fix that.Or alternatively, you can just use the Find in Files (under the Edit menu) in VC++. Just make sure you specify file types *.*
#5
Edit : removed some unnecessary info
03/19/2004 (3:02 pm)
Jeff : true enough, I didn't read carefully : thought you were listing problems implementing the control itself :)Edit : removed some unnecessary info
#6
03/19/2004 (3:23 pm)
This could be caused by a million things, one of which could be your code. The code will need to be posted, and the exact error string pasted in so please make a post in the private SDK forums with a link to the code if thats doable.
#7
I will make a post of the code in another forum. Meanwhile, what makes me think this is not a code issue is that it is acting like "GuiBitmapArrayCtrl.cpp" exists. I am thinking that vc++'s project file info didn't get updated because I renamed the cpp file to a cc file, and I should have removed the file from the project first...
Hmmm...
-Jef
03/19/2004 (5:43 pm)
Thanks guys. I will make a post of the code in another forum. Meanwhile, what makes me think this is not a code issue is that it is acting like "GuiBitmapArrayCtrl.cpp" exists. I am thinking that vc++'s project file info didn't get updated because I renamed the cpp file to a cc file, and I should have removed the file from the project first...
Hmmm...
-Jef
#8
03/19/2004 (5:46 pm)
Can you post the exact error please?
#9
EDIT:
Ok, I figured it out. It was what I thought, a reference to the pre-renamed file still existed in the file view. I deleted the reference and it works now.
Thanks!
03/20/2004 (6:19 am)
The error is:Quote:
The source files "D:\Torque\engine\gui\GuiBitmapArrayCtrl.cpp" and "D:\Torque\engine\gui\guiBitmapArrayCtrl.cc" are both configured to produce the output file "D:\Torque\engine\out.VC6.DEBUG\guiBitmapArrayCtrl.obj".
The project can not be built.
EDIT:
Ok, I figured it out. It was what I thought, a reference to the pre-renamed file still existed in the file view. I deleted the reference and it works now.
Thanks!
Torque Owner Glen Farrell