Skip to content

Commit

Permalink
Wrapper around test applications for cross compiler environment in me…
Browse files Browse the repository at this point in the history
…son.build (#804)

This enhances commit 7be56c5 to allow build
fuse to be built using a cross compiler

Fixes:
../meson.build:180:12: ERROR: Can not run test applications in this cross environment.
  • Loading branch information
heitbaum committed Jun 13, 2023
1 parent 6d08472 commit b58a001
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions meson.build
Expand Up @@ -177,10 +177,12 @@ int main()
}
'''

result = cc.run(detect_getmntent_needs_unescape)
if result.compiled() and result.returncode() == 0 and result.stdout().strip() == 'needs escaping'
message('getmntent does not unescape')
add_project_arguments('-DGETMNTENT_NEEDS_UNESCAPING', language: 'c')
if not meson.is_cross_build()
result = cc.run(detect_getmntent_needs_unescape)
if result.compiled() and result.returncode() == 0 and result.stdout().strip() == 'needs escaping'
message('getmntent does not unescape')
add_project_arguments('-DGETMNTENT_NEEDS_UNESCAPING', language: 'c')
endif
endif

# Write private test results into fuse_config.h (stored in build directory)
Expand Down

0 comments on commit b58a001

Please sign in to comment.