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

Always calculate libdir #588

Merged
merged 1 commit into from
Feb 24, 2024
Merged
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
4 changes: 4 additions & 0 deletions src/builder-module.c
Original file line number Diff line number Diff line change
Expand Up @@ -1787,6 +1787,8 @@ builder_module_build_helper (BuilderModule *self,
g_ptr_array_add (configure_args_arr, g_strdup_printf ("-DCMAKE_INSTALL_PREFIX:PATH='%s'", prefix));
if (libdir)
g_ptr_array_add (configure_args_arr, g_strdup_printf ("-DCMAKE_INSTALL_LIBDIR:PATH='%s'", libdir));
else
g_ptr_array_add (configure_args_arr, g_strdup_printf ("-DCMAKE_INSTALL_LIBDIR:PATH='%s/lib'", prefix));
g_ptr_array_add (configure_args_arr, g_strdup ("-G"));
g_ptr_array_add (configure_args_arr, g_strdup_printf ("%s", cmake_generator));
}
Expand All @@ -1800,6 +1802,8 @@ builder_module_build_helper (BuilderModule *self,
g_ptr_array_add (configure_args_arr, g_strdup_printf ("--prefix=%s", prefix));
if (libdir)
g_ptr_array_add (configure_args_arr, g_strdup_printf ("--libdir=%s", libdir));
else
g_ptr_array_add (configure_args_arr, g_strdup_printf ("--libdir=%s/lib", prefix));
}

g_ptr_array_add (configure_args_arr, configure_final_arg);
Expand Down
3 changes: 2 additions & 1 deletion tests/test-configure
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#!/bin/sh

if [ x$2 != 'x--some-arg' ] ; then
if [ x$3 != 'x--some-arg' ] ; then
echo $*
exit 2
fi

Expand Down
2 changes: 1 addition & 1 deletion tests/test-rename-appdata.json
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@
"type": "file",
"path": "test-configure",
"dest-filename": "configure",
"sha256": "675a1ac2feec4d4f54e581b4b01bc3cfd2c1cf31aa5963574d31228c8a11b7e7"
"sha256": "2c661bff6567f0e26e3a4bc5548f5a81ff86e052ccaa3791b847201be84f932f"
},
{
"type": "file",
Expand Down
2 changes: 1 addition & 1 deletion tests/test-rename.json
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
"type": "file",
"path": "test-configure",
"dest-filename": "configure",
"sha256": "675a1ac2feec4d4f54e581b4b01bc3cfd2c1cf31aa5963574d31228c8a11b7e7"
"sha256": "2c661bff6567f0e26e3a4bc5548f5a81ff86e052ccaa3791b847201be84f932f"
},
{
"type": "file",
Expand Down
2 changes: 1 addition & 1 deletion tests/test.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
"type": "file",
"path": "test-configure",
"dest-filename": "configure",
"sha256": "675a1ac2feec4d4f54e581b4b01bc3cfd2c1cf31aa5963574d31228c8a11b7e7"
"sha256": "2c661bff6567f0e26e3a4bc5548f5a81ff86e052ccaa3791b847201be84f932f"
},
{
"type": "file",
Expand Down
2 changes: 1 addition & 1 deletion tests/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ modules:
- type: file
path: test-configure
dest-filename: configure
sha256: 675a1ac2feec4d4f54e581b4b01bc3cfd2c1cf31aa5963574d31228c8a11b7e7
sha256: 2c661bff6567f0e26e3a4bc5548f5a81ff86e052ccaa3791b847201be84f932f
- type: file
path: app-data
- type: script
Expand Down