Open yuki-shimoda-crypto opened 2 years ago
(cc: @usatie) このテスターはmacOSでしか動作しないため、Ubuntu (Linux) 環境でエラーが出てしまうのは仕方がない面があるかなと思います。
Linux対応を入れようとすると、libassert.c
については少なくとも
malloc_size
とmalloc_usable_size
の差異吸収が必要になりますし、
テスターの構造が「本物の関数を呼び出してその結果の差を確認する」形である都合上、glibcに含まれないstrlcpy
やstrlcat
のテストが不可能になる (コンパイルエラーを吐く) ことになりますし。
(glibcにない関数については「コンパイル + テストを行わない」ということも可能ですが、ユーザへの周知が大変そうで…)
確かにLinux需要は大きそうですし、個人的にも欲しい機能ではありますが…
make -C libft-tester-tokyo make[1]: Entering directory '/home/ubuntu/Desktop/42tokyo/42cursus/libft/ft/libft-tester-tokyo' make -C ../ make[2]: Entering directory '/home/ubuntu/Desktop/42tokyo/42cursus/libft/ft' make[2]: Nothing to be done for 'all'. make[2]: Leaving directory '/home/ubuntu/Desktop/42tokyo/42cursus/libft/ft' make -C ./libs/libassert make[2]: Entering directory '/home/ubuntu/Desktop/42tokyo/42cursus/libft/ft/libft-tester-tokyo/libs/libassert' cc -c libassert.c -o objs/libassert.o -Wall -Werror -Wextra libassert.c:17:10: fatal error: 'malloc/malloc.h' file not found
include <malloc/malloc.h>
1 error generated. make[2]: [Makefile:27: objs/libassert.o] Error 1 make[2]: Leaving directory '/home/ubuntu/Desktop/42tokyo/42cursus/libft/ft/libft-tester-tokyo/libs/libassert' make[1]: [Makefile:103: start_tests] Error 2 make[1]: Leaving directory '/home/ubuntu/Desktop/42tokyo/42cursus/libft/ft/libft-tester-tokyo' make: *** [Makefile:77: test] Error 2