Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow to set --libpath #41

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,14 @@
"type": "boolean",
"description": "Skip unrecognized files instead of copying them to the pdx folder",
"default": false
},
"libPath": {
"type": "array",
"description": "List of paths to additional libraries to include in the build",
"items": {
"type": "string"
},
"default": []
}
}
},
Expand Down
2 changes: 2 additions & 0 deletions src/pdc/PDCExecutionFactory.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ export class PDCExecutionFactory implements TaskExecutionFactory {
verbose,
quiet,
skipUnknown,
libPath,
sdkPath: sdkPathDef,
sourcePath: sourcePathDef,
gamePath: gamePathDef,
Expand All @@ -65,6 +66,7 @@ export class PDCExecutionFactory implements TaskExecutionFactory {
verbose,
quiet,
skipUnknown,
libPath,
incrementBuildNumber,
sdkVersion,
});
Expand Down
3 changes: 3 additions & 0 deletions src/pdc/PDCTaskRunner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ export interface PDCTaskRunnerOptions {
skipUnknown?: boolean;
incrementBuildNumber?: boolean;
sdkVersion: string;
libPath?: string[];
}

/**
Expand Down Expand Up @@ -65,6 +66,7 @@ export class PDCTaskRunner implements TaskRunner {
verbose,
quiet,
skipUnknown,
libPath,
sdkVersion,
} = this.options;

Expand All @@ -77,6 +79,7 @@ export class PDCTaskRunner implements TaskRunner {
verbose,
quiet,
skipUnknown,
libPath,
sdkVersion,
};
}
Expand Down
7 changes: 7 additions & 0 deletions src/pdc/getPDCCommand.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export interface GetPDCCommandOptions {
verbose?: boolean;
quiet?: boolean;
skipUnknown?: boolean;
libPath?: string[];
sdkVersion: string;
}

Expand All @@ -25,6 +26,7 @@ export function getPDCCommand(options: GetPDCCommandOptions) {
verbose,
quiet,
skipUnknown,
libPath,
sdkVersion,
} = options;

Expand Down Expand Up @@ -55,6 +57,11 @@ export function getPDCCommand(options: GetPDCCommandOptions) {
if (skipUnknown) {
optionalArgs.push("--skip-unknown");
}
if (libPath) {
libPath.forEach((lib) => {
optionalArgs.push("--libpath", quote(lib));
});
}

const requiredArgs = [
"-sdkpath",
Expand Down