www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - bud problems

reply Bill Baxter <dnewsgroup billbaxter.com> writes:
I seem to have to delete all my object files before running bud if I 
want to not get link errors and not have spurious crashes in the exe. 
This project has 11 files or so in two directories.  Linker errors seem 
to mostly be from template stuff.

Am I using bud incorrectly?

Here's my brf file:

-------------
# Damn, envvars like %DMDDIR% don't work
-g
-debug
-I..\..\baxissimo
-I..\..\ext
example1
---------------

and I run with
 bud  example1


Thanks, --bb
Nov 08 2006
next sibling parent reply Chris Nicholson-Sauls <ibisbasenji gmail.com> writes:
Bill Baxter wrote:
 I seem to have to delete all my object files before running bud if I 
 want to not get link errors and not have spurious crashes in the exe. 
 This project has 11 files or so in two directories.  Linker errors seem 
 to mostly be from template stuff.
 
 Am I using bud incorrectly?
 
 Here's my brf file:
 
 -------------
 # Damn, envvars like %DMDDIR% don't work
 -g
 -debug
 -I..\..\baxissimo
 -I..\..\ext
 example1
 ---------------
 
 and I run with
  >> bud  example1
 
 Thanks,
 --bb

You aren't using it incorrectly so far as I can immediately see, and I'm also not sure what's causing your problem. However, that said, if simply deleting the object files is enough to work around it, add the "-cleanup" switch to your BRF file to cause 'bud' to delete them automatically at the end of its run. This should at least get you working again until someone with more of a clue can figure out what's gone wrong. :) -- Chris Nicholson-Sauls
Nov 08 2006
parent Bill Baxter <dnewsgroup billbaxter.com> writes:
Chris Nicholson-Sauls wrote:
 Bill Baxter wrote:
 I seem to have to delete all my object files before running bud if I 
 want to not get link errors and not have spurious crashes in the exe. 
 This project has 11 files or so in two directories.  Linker errors 
 seem to mostly be from template stuff.

 Am I using bud incorrectly?


 
 You aren't using it incorrectly so far as I can immediately see, and I'm 
 also not sure what's causing your problem.  However, that said, if 
 simply deleting the object files is enough to work around it, add the 
 "-cleanup" switch to your BRF file to cause 'bud' to delete them 
 automatically at the end of its run.  This should at least get you 
 working again until someone with more of a clue can figure out what's 
 gone wrong.  :)
 
 -- Chris Nicholson-Sauls

Ah, ok. Thanks -cleanup is indeed better than "del *.obj *\*.obj && bud example1". It doesn't take that long to rebuild everything anyway. --bb
Nov 08 2006
prev sibling next sibling parent reply Derek Parnell <derek nomail.afraid.org> writes:
On Thu, 09 Nov 2006 10:32:30 +0900, Bill Baxter wrote:

 I seem to have to delete all my object files before running bud if I 
 want to not get link errors and not have spurious crashes in the exe. 
 This project has 11 files or so in two directories.  Linker errors seem 
 to mostly be from template stuff.
 
 Am I using bud incorrectly?
 
 Here's my brf file:
 
 -------------
 # Damn, envvars like %DMDDIR% don't work
 -g
 -debug
 -I..\..\baxissimo
 -I..\..\ext
 example1
 ---------------
 
 and I run with
  >> bud  example1
 

This looks fine. There seems to be an issue where somehow the object files get out of sync with source files but I haven't found out anything causing it yet. It maybe related to templates but I'm not sure. In the meantime, use either "-full" to force a compilation of all source files, and/or use "-clean" to have Bud delete work files (.obj etc ...) after successful compilation. -- Derek (skype: derek.j.parnell) Melbourne, Australia "Down with mediocrity!" 9/11/2006 1:28:09 PM
Nov 08 2006
parent reply Bill Baxter <dnewsgroup billbaxter.com> writes:
Derek Parnell wrote:
 On Thu, 09 Nov 2006 10:32:30 +0900, Bill Baxter wrote:
 
 I seem to have to delete all my object files before running bud if I 
 want to not get link errors and not have spurious crashes in the exe. 
 This project has 11 files or so in two directories.  Linker errors seem 
 to mostly be from template stuff.

 Am I using bud incorrectly?


 
 This looks fine. There seems to be an issue where somehow the object files
 get out of sync with source files but I haven't found out anything causing
 it yet. It maybe related to templates but I'm not sure.

Is bud a-ok with = and :'s in imports? import submodule = mypackage.submodule.detail; import std.stdio : writefln; And also note that I'm renaming submodule.detail to just submodule. Could that be confusing bud?
 
 In the meantime, use either "-full" to force a compilation of all source
 files, and/or use "-clean" to have Bud delete work files (.obj etc ...)
 after successful compilation.
 

--bb
Nov 08 2006
parent reply Derek Parnell <derek nomail.afraid.org> writes:
On Thu, 09 Nov 2006 12:15:01 +0900, Bill Baxter wrote:

 Is bud a-ok with = and :'s in imports?
 
     import submodule = mypackage.submodule.detail;
     import std.stdio : writefln;
 
 And also note that I'm renaming submodule.detail to just submodule. 
 Could that be confusing bud?

Yes, these forms are okay to use. In the first form, the module's real name is the stuff after the '=', and in the second is the stuff before the ':'. Bud doesn't need to know how you use the module name in your code, just that you are importing it. -- Derek (skype: derek.j.parnell) Melbourne, Australia "Down with mediocrity!" 9/11/2006 2:40:25 PM
Nov 08 2006
parent Bill Baxter <wbaxter gmail.com> writes:
Derek Parnell wrote:
 On Thu, 09 Nov 2006 12:15:01 +0900, Bill Baxter wrote:
 
 
Is bud a-ok with = and :'s in imports?

    import submodule = mypackage.submodule.detail;
    import std.stdio : writefln;

And also note that I'm renaming submodule.detail to just submodule. 
Could that be confusing bud?

Yes, these forms are okay to use. In the first form, the module's real name is the stuff after the '=', and in the second is the stuff before the ':'. Bud doesn't need to know how you use the module name in your code, just that you are importing it.

One more thing: I've got two files called "base.d". One at the root level, one in a subdirectory. Could that cause problems? --bb
Nov 09 2006
prev sibling parent mike <vertex gmx.at> writes:
I'm getting that too ... around 20 files now, one directory. Randomly  =

occuring access violations which disappear after inserting a  =

debug-writefln and saving again (thus updating the timestamp), linker  =

errors with templates which disappear after saving a certain file again,=
  =

etc.

Anyway, it's no big deal, since I've figured it out I do a make clean  =

(yeah, ... I've got a batch file called "make" to call build :) ) every =
 =

once in a while. Compared to C++ and "oh, sigh, I need to change a heade=
r  =

file - so make clean it is, I'll get a smoke while the compiler takes it=
s  =

4 minutes and chokes on a typo after 3 minutes" that's not even annoying=
.  =

4 minutes compiling compared to an access violation, 10 seconds of "WTF?=
"  =

and 3 seconds of building the complete project is great. Nothing to  =

complain about.

In my last job I had to wait 30-45 minutes when changing a header file .=
..  =

that was even nicer.

-Mike

Am 09.11.2006, 02:32 Uhr, schrieb Bill Baxter <dnewsgroup billbaxter.com=
:

 I seem to have to delete all my object files before running bud if I  =

 want to not get link errors and not have spurious crashes in the exe. =

 This project has 11 files or so in two directories.  Linker errors see=

 to mostly be from template stuff.

 Am I using bud incorrectly?

 Here's my brf file:

 -------------
 # Damn, envvars like %DMDDIR% don't work
 -g
 -debug
 -I..\..\baxissimo
 -I..\..\ext
 example1
 ---------------

 and I run with
  >> bud  example1

 Thanks,
 --bb

-- = Erstellt mit Operas revolution=E4rem E-Mail-Modul: http://www.opera.com/= mail/
Nov 09 2006