CODESIGN_ALLOCATE(1) General Commands Manual CODESIGN_ALLOCATE(1)NAME
codesign_allocate - add code signing data to a Mach-O file
SYNOPSIS
codesign_allocate -i oldfile [ -a arch size ]... [ -A cputype cpusubtype size ]... -o newfile
DESCRIPTION
codesign_allocate sets up a Mach-O file used by the dynamic linker so space for code signing data of the specified size for the specified
architecture is embed in the Mach-O file. The program must be passed one -a argument or one -A argument for each architecture in a univer-
sal file, or exactly one -a or -A for a thin file.
-i oldfile
specifies the input file as oldfile.
-o newfile
specifies the output file as newfile.
-a arch size
specifies for the architecture arch that the size of the code signing data is to be size. The value of size must be a multiple of
16.
-a cputype cpusubtype size
specifies for the architecture as a pair of decimal integers for the cputype and cpusubtype that the size of the code signing data
is to be size. The value of size must be a multiple of 16.
Apple, Inc. January 11, 2008 CODESIGN_ALLOCATE(1)
Check Out this Related Man Page
REDO_PREBINDING(3) Library Functions Manual REDO_PREBINDING(3)NAME
redo_prebinding library functions
SYNOPSIS
#include <mach-o/redo_prebinding.h>
extern char ** dependent_libs(
const char *file_name,
const char *program_name,
char **error_message);
extern char * install_name(
const char *file_name,
const char *program_name,
char **error_message);
extern enum redo_prebinding_retval redo_prebinding(
const char *file_name,
const char *executable_path,
const char *root_dir,
const char *output_file,
const char *program_name,
char **error_message,
unsigned long slide_to_address,
int only_if_needed,
int zero_out_prebind_checksum,
cpu_type_t allow_missing_architectures,
unsigned long *throttle);
extern enum needs_redo_prebinding_retval needs_redo_prebinding(
const char *file_name,
const char *executable_path,
const char *root_dir,
const char *program_name,
char **error_message,
unsigned long expected_address,
cpu_type_t allow_missing_architectures);
extern enum object_file_type_retval object_file_type(
const char *file_name,
const char *program_name,
char **error_message);
extern int get_prebind_cksums(
const char *file_name,
struct prebind_cksum_arch **cksums,
unsigned long *ncksums,
const char *program_name,
char **error_message);
DESCRIPTION
These functions are intended for use by update_prebinding(1) and Mac OS X Build and Integration tools.
For all of these functions in the parameters program_name and error_message are used the same. For unrecoverable resource errors like
being unable to allocate memory each function prints a message to stderr precede with program_name then calls exit(2) with the value
EXIT_FAILURE. If a function is unsuccessful and if error_message pass to it is not NULL it is set to a malloc(3)'ed buffer with a NULL
terminated string with the error message. For all functions when they return they release all resources (memory, open file descriptors,
etc).
The file_name parameter for these functions may be of the form foo(bar) which is NOT interpreted as an archive name and a member name in
that archive. As these functions deal with prebinding and prebound binaries ready for execution can't be in archives.
If the executable_path parameter for these functions is not NULL it is used for any dependent library has a path that starts with @exe-
cutable_path. Then @executable_path is replaced with executable_path.
If the root_dir parameter is not NULL it is prepended to all the rooted dependent library paths.
dependent_libs() takes a file_name of a binary and returns a malloc(3)'ed array of pointers (NULL terminated) to names (also malloc(3)'ed
and '