njn | 747f8b0 | 2009-01-21 04:11:13 +0000 | [diff] [blame] | 1 | /*--------------------------------------------------------------------*/ |
| 2 | /*--- User-mode execve(). priv_ume.h ---*/ |
| 3 | /*--------------------------------------------------------------------*/ |
| 4 | |
| 5 | /* |
| 6 | This file is part of Valgrind, a dynamic binary instrumentation |
| 7 | framework. |
| 8 | |
sewardj | 0f157dd | 2013-10-18 14:27:36 +0000 | [diff] [blame] | 9 | Copyright (C) 2000-2013 Julian Seward |
njn | 747f8b0 | 2009-01-21 04:11:13 +0000 | [diff] [blame] | 10 | jseward@acm.org |
| 11 | |
| 12 | This program is free software; you can redistribute it and/or |
| 13 | modify it under the terms of the GNU General Public License as |
| 14 | published by the Free Software Foundation; either version 2 of the |
| 15 | License, or (at your option) any later version. |
| 16 | |
| 17 | This program is distributed in the hope that it will be useful, but |
| 18 | WITHOUT ANY WARRANTY; without even the implied warranty of |
| 19 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
| 20 | General Public License for more details. |
| 21 | |
| 22 | You should have received a copy of the GNU General Public License |
| 23 | along with this program; if not, write to the Free Software |
| 24 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA |
| 25 | 02111-1307, USA. |
| 26 | |
| 27 | The GNU General Public License is contained in the file COPYING. |
| 28 | */ |
| 29 | |
njn | 8b68b64 | 2009-06-24 00:37:09 +0000 | [diff] [blame] | 30 | #if defined(VGO_linux) || defined(VGO_darwin) |
| 31 | |
njn | 747f8b0 | 2009-01-21 04:11:13 +0000 | [diff] [blame] | 32 | #ifndef __PRIV_UME_H |
| 33 | #define __PRIV_UME_H |
| 34 | |
florian | 535fb1b | 2013-09-15 13:54:34 +0000 | [diff] [blame] | 35 | #include "pub_core_ume.h" // ExeInfo |
| 36 | |
florian | ff4a084 | 2015-04-08 19:01:15 +0000 | [diff] [blame] | 37 | extern Int VG_(do_exec_inner)(const HChar *exe, ExeInfo *info); |
njn | 747f8b0 | 2009-01-21 04:11:13 +0000 | [diff] [blame] | 38 | |
njn | 8b68b64 | 2009-06-24 00:37:09 +0000 | [diff] [blame] | 39 | #if defined(VGO_linux) |
florian | ff4a084 | 2015-04-08 19:01:15 +0000 | [diff] [blame] | 40 | extern Bool VG_(match_ELF) ( const void *hdr, SizeT len ); |
njn | 747f8b0 | 2009-01-21 04:11:13 +0000 | [diff] [blame] | 41 | extern Int VG_(load_ELF) ( Int fd, const HChar *name, ExeInfo *info ); |
njn | 8b68b64 | 2009-06-24 00:37:09 +0000 | [diff] [blame] | 42 | #elif defined(VGO_darwin) |
florian | ff4a084 | 2015-04-08 19:01:15 +0000 | [diff] [blame] | 43 | extern Bool VG_(match_macho) ( const void *hdr, SizeT len ); |
njn | f76d27a | 2009-05-28 01:53:07 +0000 | [diff] [blame] | 44 | extern Int VG_(load_macho) ( Int fd, const HChar *name, ExeInfo *info ); |
njn | 8b68b64 | 2009-06-24 00:37:09 +0000 | [diff] [blame] | 45 | #else |
| 46 | # error Unknown OS |
njn | f76d27a | 2009-05-28 01:53:07 +0000 | [diff] [blame] | 47 | #endif |
| 48 | |
florian | ff4a084 | 2015-04-08 19:01:15 +0000 | [diff] [blame] | 49 | extern Bool VG_(match_script) ( const void *hdr, SizeT len ); |
njn | 8b68b64 | 2009-06-24 00:37:09 +0000 | [diff] [blame] | 50 | extern Int VG_(load_script) ( Int fd, const HChar *name, ExeInfo *info ); |
| 51 | |
| 52 | |
| 53 | #endif // __PRIV_UME_H |
| 54 | |
| 55 | #endif // defined(VGO_linux) || defined(VGO_darwin) |
njn | 747f8b0 | 2009-01-21 04:11:13 +0000 | [diff] [blame] | 56 | |
| 57 | /*--------------------------------------------------------------------*/ |
| 58 | /*--- end ---*/ |
| 59 | /*--------------------------------------------------------------------*/ |
| 60 | |