[mercury-users] mercury's messiness
Tyson Dowd
trd at cs.mu.OZ.AU
Wed Nov 22 14:26:28 AEDT 2000
Try
mkdir Mercury
mmake genetic_test.depend
mmake genetic_test
or
mmake --use-subdirs genetic_test.depend
mmake --use-subdirs genetic_test
or
mmc --use-subdirs genetic_test.m
The first one is easiest. Note that the second one will create a
`Mercury' subdirectory, so after the first time you no longer need to
give the `--use-subdirs' option to mmake.
If you are using mmc, it is a bit dumber, and you have to tell it yourself
every time -- it does not detect the `Mercury' subdirectory.
The other problem with the commands you are giving is that mmake is
*target* driven (you tell it what to make, and it makes it). Whereas
commands like `mmc' are source file driven -- you tell it what the input
source code is, and it turns it into output code.
Generally mmake needs to first make a .depend file so that it knows
which other modules it might need to compile to make your target.
That's why we had to do `mmake genetic_test.depend' first.
On 22-Nov-2000, Mattias Waldau <mattias.waldau at abc.se> wrote:
> tried creating a subdirectory called 'Mercury', didn't work
>
> /c$ cd data
> data$ cd mercury
> mercury$ nmake genetic_test.
> bash: nmake: command not found
> mercury$ nmake genetic_test.m
> bash: nmake: command not found
> mercury$ mmake genetic_test.m
> make: Nothing to be done for `genetic_test.m'.
> mercury$ rm genetic_test.exe
> mercury$ mmake genetic_test.m
> make: Nothing to be done for `genetic_test.m'.
> mercury$ mmc genetic_test.m
> mercury$ mmc --version
> mercury_compile: unrecognized option `--version'
> Mercury Compiler, version rotd-2000-09-01, configured for i386-pc-cygwin32
> Copyright (C) 1993-2000 The University of Melbourne
> Usage: mmc [<options>] <arguments>
> Use `mmc --help' for more information.
> mercury$ ls
> CVS genetic_test.m hello_world.m
> Mercury genetic_test.o tableplan1.exe
> genetic_test.c genetic_test_init.c tableplan1.m
> genetic_test.d genetic_test_init.o
> genetic_test.exe hello_world.exe
> mercury$
>
> -----Original Message-----
> From: owner-mercury-users at cs.mu.OZ.AU
> [mailto:owner-mercury-users at cs.mu.OZ.AU]On Behalf Of David Glen JEFFERY
> Sent: Wednesday, November 22, 2000 2:10 AM
> To: mercury-users at cs.mu.OZ.AU
> Subject: Re: [mercury-users] mercury's messiness
>
>
> On 22-Nov-2000, Tennessee <tjleeuw at students.cs.mu.oz.au> wrote:
> > This may strike you as a silly request, but nonetheless! I'd like to be
> > able to specify to mercury to put all the .o, .int etc files in a seperate
> > directory. It would be nice if mercury could put its' intermediate files
> in
> > subdirectories. I'm including code from many different modules, all of
> > which get a .o and a .int file, and basically it makes it hard to work out
> > which files are real, and which are just intermediates.
>
> Hi Tennessee,
>
> Try:
> mmake --use-subdirs <whatever>
>
> Alternatively, just make a directory called `Mercury' in the same directory
> as your source files. Either way, mmake will put all the intermediate files
> in the `Mercury' directory for you.
>
>
> dgj
> --
> David Jeffery (dgj at cs.mu.oz.au) | If your thesis is utterly vacuous
> PhD student, | Use first-order predicate calculus.
> Dept. of Comp. Sci. & Soft. Eng.| With sufficient formality
> The University of Melbourne | The sheerist banality
> Australia | Will be hailed by the critics:
> "Miraculous!"
> | -- Anon.
> --------------------------------------------------------------------------
> mercury-users mailing list
> post: mercury-users at cs.mu.oz.au
> administrative address: owner-mercury-users at cs.mu.oz.au
> unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
> subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
> --------------------------------------------------------------------------
>
> --------------------------------------------------------------------------
> mercury-users mailing list
> post: mercury-users at cs.mu.oz.au
> administrative address: owner-mercury-users at cs.mu.oz.au
> unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
> subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
> --------------------------------------------------------------------------
--
Tyson Dowd #
# Surreal humour isn't everyone's cup of fur.
trd at cs.mu.oz.au #
http://www.cs.mu.oz.au/~trd #
--------------------------------------------------------------------------
mercury-users mailing list
post: mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the users
mailing list