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

add includedirs for swig #4484

Merged
merged 1 commit into from
Dec 12, 2023
Merged

add includedirs for swig #4484

merged 1 commit into from
Dec 12, 2023

Conversation

tokomine
Copy link
Contributor

When editing the *.i file for swig, sometimes you need to include the header files of third-party libraries.

swig --help
-I<dir>         - Look for SWIG files in directory <dir>

xmake.lua:

    add_files("*.i", {include_deps=true, include_pkgs=true, include_dirs=true})

@waruqi
Copy link
Member

waruqi commented Dec 11, 2023

We need add there options, you can add includedirs directly.

please refer

for _, pathmap in ipairs(pathmaps) do


target("example")
add_rules("swig.cpp", {moduletype = "python"})
add_files("src/example.i", {scriptdir = "share", auto_include=true})
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think it's necessary to add this option, if the user configured add_packages and add_deps, their includes should be added automatically.

@waruqi waruqi merged commit ba0ce32 into xmake-io:dev Dec 12, 2023
18 of 19 checks passed
@waruqi waruqi added this to the v2.8.6 milestone Dec 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants