swarm-support
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Swarm-Support] Compiling Swarm-2.2 on Solaris 2.8


From: Gary Polhill
Subject: Re: [Swarm-Support] Compiling Swarm-2.2 on Solaris 2.8
Date: Fri, 16 Jun 2006 16:48:13 +0100

See code below. As it stands I get beyond the message saying
"Initialised verbosity". If I comment out the first initSwarmArguments,
and uncomment the second, I only get the message saying "Hi there!" with
the error message in an earlier email. Verbosity and MiscFunc are my own
(singleton) classes that subclass from SwarmObject. So, to answer your
question directly, I didn't do anything else.

int
main (int argc, const char **argv)
{
  id theTopLevelSwarm;
  unsigned seed;
  char *verbyfile;
  BOOL free_verbyfile = NO;

  initSwarmArguments (argc, argv, [FearlusArguments class]);
  printf("Hi there!\n");
  verbyfile = getenv("FEARLUS_VERBOSITY_FILE");
  if(verbyfile == NULL || ![MiscFunc fileExists: verbyfile]) {
    verbyfile = DEFAULT_VERBOSITY_FILE;
    if(![MiscFunc fileExists: verbyfile]) {
      char *p;

      verbyfile = (char *)malloc(strlen(verbyfile) + strlen(argv[0]));
      if(verbyfile == NULL) {
        perror("malloc");
        abort();
      }
      free_verbyfile = YES;

      strcpy(verbyfile, argv[0]);
      p = strrchr(verbyfile, (int)'/');
      if(p == NULL) {
        strcpy(verbyfile, DEFAULT_VERBOSITY_FILE);
      }
      else {
        strcpy(p + 1, DEFAULT_VERBOSITY_FILE);
      }
    }
  }
  printf("Dealt with Verbosity file location\n");
  [Verbosity initialiseFromFile: verbyfile];
  printf("Initialised Verbosity\n");
  if(free_verbyfile) free(verbyfile);
 
//  initSwarmArguments (argc, argv, [FearlusArguments class]);

/* ... etc. */

>>> address@hidden 2006-06-16 15:43:27 >>>
Gary Polhill wrote:
> When I move the call
> to initSwarmArguments() to the beginning of main(), however (before I
do
> anything else) I don't get this error.
>   
What else did you do?

_______________________________________________
Support mailing list
address@hidden 
http://www.swarm.org/mailman/listinfo/support

-- 
Please note that the views expressed in this e-mail are those of the
sender and do not necessarily represent the views of the Macaulay
Institute. This email and any attachments are confidential and are
intended solely for the use of the recipient(s) to whom they are
addressed. If you are not the intended recipient, you should not read,
copy, disclose or rely on any information contained in this e-mail, and
we would ask you to contact the sender immediately and delete the email
from your system. Thank you.
Macaulay Institute and Associated Companies, Macaulay Drive,
Craigiebuckler, Aberdeen, AB15 8QH.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]