Actual source code: arch.c

  1: /*$Id: arch.c,v 1.44 2001/03/23 23:20:45 balay Exp $*/
 2:  #include petsc.h
 3:  #include petscsys.h

  5: #undef __FUNCT__  
  7: /*@C
  8:      PetscGetArchType - Returns a standardized architecture type for the machine
  9:      that is executing this routine. 

 11:      Not Collective

 13:      Input Parameter:
 14: .    slen - length of string buffer

 16:      Output Parameter:
 17: .    str - string area to contain architecture name, should be at least 
 18:            10 characters long. Name is truncated if string is not long enough.

 20:      Level: developer

 22:      Concepts: machine type
 23:      Concepts: architecture

 25: @*/
 26: int PetscGetArchType(char str[],int slen)
 27: {

 31: #if defined(PETSC_ARCH_NAME)
 32:   PetscStrncpy(str,PETSC_ARCH_NAME,slen);
 33: #else
 34: #error "bmake/$PETSC_ARCH/petscconf.h is missing PETSC_ARCH_NAME"
 35: #endif
 36:   return(0);
 37: }