home *** CD-ROM | disk | FTP | other *** search
/ H4CK3R 4 / hacker04 / 04_HACK04.ISO / darwin / darwinx86.iso / usr / local / include / mach-o / rld.h < prev    next >
Encoding:
C/C++ Source or Header  |  2001-09-14  |  2.1 KB  |  75 lines

  1. /*
  2.  * Copyright (c) 1999 Apple Computer, Inc. All rights reserved.
  3.  *
  4.  * @APPLE_LICENSE_HEADER_START@
  5.  * 
  6.  * Portions Copyright (c) 1999 Apple Computer, Inc.  All Rights
  7.  * Reserved.  This file contains Original Code and/or Modifications of
  8.  * Original Code as defined in and that are subject to the Apple Public
  9.  * Source License Version 1.1 (the "License").  You may not use this file
  10.  * except in compliance with the License.  Please obtain a copy of the
  11.  * License at http://www.apple.com/publicsource and read it before using
  12.  * this file.
  13.  * 
  14.  * The Original Code and all software distributed under the License are
  15.  * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  16.  * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  17.  * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
  18.  * FITNESS FOR A PARTICULAR PURPOSE OR NON- INFRINGEMENT.  Please see the
  19.  * License for the specific language governing rights and limitations
  20.  * under the License.
  21.  * 
  22.  * @APPLE_LICENSE_HEADER_END@
  23.  */
  24. /*
  25.  * This is the interface to the rld package as described in rld(3).
  26.  */
  27.  
  28. #ifndef _MACHO_RLD_H_
  29. #define _MACHO_RLD_H_
  30.  
  31. #import <streams/streams.h>
  32. #import <mach-o/loader.h>
  33.  
  34. extern long rld_load(
  35.     NXStream *stream,
  36.     struct mach_header **header_addr,
  37.     const char * const *object_filenames,
  38.     const char *output_filename);
  39.  
  40. extern long rld_load_from_memory(
  41.     NXStream *stream,
  42.     struct mach_header **header_addr,
  43.     const char *object_name,
  44.     char *object_addr,
  45.     long object_size,
  46.     const char *output_filename);
  47.  
  48. extern long rld_unload(
  49.     NXStream *stream);
  50.  
  51. extern long rld_lookup(
  52.     NXStream *stream,
  53.     const char *symbol_name,
  54.     unsigned long *value);
  55.  
  56. extern long rld_forget_symbol(
  57.     NXStream *stream,
  58.     const char *symbol_name);
  59.  
  60. extern long rld_unload_all(
  61.     NXStream *stream,
  62.     long deallocate_sets);
  63.  
  64. extern long rld_load_basefile(
  65.     NXStream *stream,
  66.     const char *base_filename);
  67.  
  68. extern void rld_address_func(
  69.     unsigned long (*func)(unsigned long size, unsigned long headers_size));
  70.  
  71. extern long rld_write_symfile(
  72.     NXStream *stream,
  73.     const char *output_filename);
  74. #endif /* _MACHO_RLD_H_ */
  75.