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

debug make target compiles hid.c without debug flags #43

Open
goretkin opened this issue Mar 17, 2022 · 1 comment
Open

debug make target compiles hid.c without debug flags #43

goretkin opened this issue Mar 17, 2022 · 1 comment

Comments

@goretkin
Copy link

https://github.com/c4ev3/ev3duder/blob/5ceca3/Makefile#L107-L109

passing CLFAGS works, but produces several warnings, such as

hidapi/mac/hid.c:48:90: warning: unused parameter 'attr' [-Wunused-parameter]
static int pthread_barrier_init(pthread_barrier_t *barrier, const pthread_barrierattr_t *attr, unsigned int count)
                                                                                         ^
hidapi/mac/hid.c:255:20: warning: comparison of integers of different signs: 'CFIndex' (aka 'long') and 'size_t' (aka 'unsigned long') [-Wsign-compare]
                if (chars_copied == len)
                    ~~~~~~~~~~~~ ^  ~~~
hidapi/mac/hid.c:295:20: warning: comparison of integers of different signs: 'CFIndex' (aka 'long') and 'size_t' (aka 'unsigned long') [-Wsign-compare]
                if (used_buf_len == len)
                    ~~~~~~~~~~~~ ^  ~~~
hidapi/mac/hid.c:551:65: warning: unused parameter 'result' [-Wunused-parameter]
static void hid_device_removal_callback(void *context, IOReturn result,
@a3f
Copy link
Member

a3f commented Mar 17, 2022

I think I vendored HIDAPI to make Windows builds easier, but I don't think it's a good idea anymore. We could fix the warning, but I think the best thing to do here is to use pkg-config to see if there's a host HIDAPI and use that instead.

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

No branches or pull requests

2 participants