1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042
|
# -*- Makefile -*-
VPATH += tests
CFLAGS += -I $(CURDIR)/src/ctypes -I $(CURDIR)/tests
CC=$(shell ocamlc -config | sed -n '/native_c_compiler/{ s/[^:]*://; p;}')
# tests-common subproject
tests-common.dir = tests/tests-common
tests-common.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded
tests-common.install = no
tests-common.install_native_objects = yes
tests-common: PROJECT=tests-common
tests-common: $$(LIB_TARGETS)
test-raw.dir = tests/test-raw
test-raw.threads = yes
test-raw.deps = bigarray oUnit str bytes
test-raw.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-raw: PROJECT=test-raw
test-raw: $$(BEST_TARGET)
test-pointers-stubs.dir = tests/test-pointers/stubs
test-pointers-stubs.threads = yes
test-pointers-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-pointers-stubs: PROJECT=test-pointers-stubs
test-pointers-stubs: $$(LIB_TARGETS)
test-pointers-stub-generator.dir = tests/test-pointers/stub-generator
test-pointers-stub-generator.threads = yes
test-pointers-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-pointers-stubs tests-common
test-pointers-stub-generator.deps = str bigarray bytes
test-pointers-stub-generator: PROJECT=test-pointers-stub-generator
test-pointers-stub-generator: $$(BEST_TARGET)
test-pointers.dir = tests/test-pointers
test-pointers.threads = yes
test-pointers.deps = str bigarray oUnit bytes
test-pointers.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-pointers-stubs
test-pointers.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-pointers: PROJECT=test-pointers
test-pointers: $$(BEST_TARGET)
test-pointers-generated: \
tests/test-pointers/generated_bindings.ml \
tests/test-pointers/generated_stubs.c
tests/test-pointers/generated_stubs.c: $(BUILDDIR)/test-pointers-stub-generator.$(BEST)
$< --c-file $@
tests/test-pointers/generated_bindings.ml: $(BUILDDIR)/test-pointers-stub-generator.$(BEST)
$< --ml-file $@
test-variadic-stubs.dir = tests/test-variadic/stubs
test-variadic-stubs.threads = yes
test-variadic-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-variadic-stubs: PROJECT=test-variadic-stubs
test-variadic-stubs: $$(LIB_TARGETS)
test-variadic-stub-generator.dir = tests/test-variadic/stub-generator
test-variadic-stub-generator.threads = yes
test-variadic-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-variadic-stubs tests-common
test-variadic-stub-generator.deps = str bigarray bytes
test-variadic-stub-generator: PROJECT=test-variadic-stub-generator
test-variadic-stub-generator: $$(BEST_TARGET)
test-variadic.dir = tests/test-variadic
test-variadic.threads = yes
test-variadic.deps = str bigarray oUnit bytes
test-variadic.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-variadic-stubs
test-variadic.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-variadic: PROJECT=test-variadic
test-variadic: $$(BEST_TARGET)
test-variadic-generated: \
tests/test-variadic/generated_bindings.ml \
tests/test-variadic/generated_stubs.c
tests/test-variadic/generated_stubs.c: $(BUILDDIR)/test-variadic-stub-generator.$(BEST)
$< --c-file $@
tests/test-variadic/generated_bindings.ml: $(BUILDDIR)/test-variadic-stub-generator.$(BEST)
$< --ml-file $@
test-builtins-stubs.dir = tests/test-builtins/stubs
test-builtins-stubs.threads = yes
test-builtins-stubs.subproject_deps = ctypes cstubs tests-common
test-builtins-stubs: PROJECT=test-builtins-stubs
test-builtins-stubs: $$(LIB_TARGETS)
test-builtins-stub-generator.dir = tests/test-builtins/stub-generator
test-builtins-stub-generator.threads = yes
test-builtins-stub-generator.subproject_deps = ctypes cstubs \
test-builtins-stubs ctypes-foreign-base ctypes-foreign-threaded tests-common
test-builtins-stub-generator.deps = str bigarray bytes
test-builtins-stub-generator: PROJECT=test-builtins-stub-generator
test-builtins-stub-generator: $$(BEST_TARGET)
test-builtins.dir = tests/test-builtins
test-builtins.threads = yes
test-builtins.deps = str bigarray oUnit bytes
test-builtins.subproject_deps = ctypes cstubs test-builtins-stubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-builtins.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-builtins: PROJECT=test-builtins
test-builtins: $$(BEST_TARGET)
test-builtins-generated: \
tests/test-builtins/generated_bindings.ml \
tests/test-builtins/generated_stubs.c
tests/test-builtins/generated_stubs.c: $(BUILDDIR)/test-builtins-stub-generator.$(BEST)
$< --c-file $@
tests/test-builtins/generated_bindings.ml: $(BUILDDIR)/test-builtins-stub-generator.$(BEST)
$< --ml-file $@
test-macros-stubs.dir = tests/test-macros/stubs
test-macros-stubs.threads = yes
test-macros-stubs.subproject_deps = ctypes cstubs tests-common
test-macros-stubs: PROJECT=test-macros-stubs
test-macros-stubs: $$(LIB_TARGETS)
test-macros-stub-generator.dir = tests/test-macros/stub-generator
test-macros-stub-generator.threads = yes
test-macros-stub-generator.subproject_deps = ctypes cstubs \
test-macros-stubs ctypes-foreign-base ctypes-foreign-threaded tests-common
test-macros-stub-generator.deps = str bigarray bytes
test-macros-stub-generator: PROJECT=test-macros-stub-generator
test-macros-stub-generator: $$(BEST_TARGET)
test-macros.dir = tests/test-macros
test-macros.threads = yes
test-macros.deps = str bigarray oUnit bytes
test-macros.subproject_deps = ctypes cstubs test-macros-stubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-macros.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-macros: PROJECT=test-macros
test-macros: $$(BEST_TARGET)
test-macros-generated: \
tests/test-macros/generated_bindings.ml \
tests/test-macros/generated_stubs.c
tests/test-macros/generated_stubs.c: $(BUILDDIR)/test-macros-stub-generator.$(BEST)
$< --c-file $@
tests/test-macros/generated_bindings.ml: $(BUILDDIR)/test-macros-stub-generator.$(BEST)
$< --ml-file $@
test-higher_order-stubs.dir = tests/test-higher_order/stubs
test-higher_order-stubs.threads = yes
test-higher_order-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-higher_order-stubs: PROJECT=test-higher_order-stubs
test-higher_order-stubs: $$(LIB_TARGETS)
test-higher_order-stub-generator.dir = tests/test-higher_order/stub-generator
test-higher_order-stub-generator.threads = yes
test-higher_order-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-higher_order-stubs tests-common
test-higher_order-stub-generator.deps = str bigarray bytes
test-higher_order-stub-generator: PROJECT=test-higher_order-stub-generator
test-higher_order-stub-generator: $$(BEST_TARGET)
test-higher_order.dir = tests/test-higher_order
test-higher_order.threads = yes
test-higher_order.deps = str bigarray oUnit bytes
test-higher_order.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-higher_order-stubs tests-common
test-higher_order.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-higher_order: PROJECT=test-higher_order
test-higher_order: $$(BEST_TARGET)
test-higher_order-generated: \
tests/test-higher_order/generated_bindings.ml \
tests/test-higher_order/generated_stubs.c
tests/test-higher_order/generated_stubs.c: $(BUILDDIR)/test-higher_order-stub-generator.$(BEST)
$< --c-file $@
tests/test-higher_order/generated_bindings.ml: $(BUILDDIR)/test-higher_order-stub-generator.$(BEST)
$< --ml-file $@
test-enums-struct-stubs.dir = tests/test-enums/struct-stubs
test-enums-struct-stubs.threads = yes
test-enums-struct-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-enums-struct-stubs: PROJECT=test-enums-struct-stubs
test-enums-struct-stubs: $$(LIB_TARGETS)
test-enums-stubs.dir = tests/test-enums/stubs
test-enums-stubs.threads = yes
test-enums-stubs.extra_mls = generated_struct_bindings.ml
test-enums-stubs.subproject_deps = ctypes cstubs \
test-enums-struct-stubs \
test-enums-struct-stubs-generator \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-enums-stubs: PROJECT=test-enums-stubs
test-enums-stubs: $$(LIB_TARGETS)
test-enums-stub-generator.dir = tests/test-enums/stub-generator
test-enums-stub-generator.threads = yes
test-enums-stub-generator.subproject_deps = ctypes cstubs \
test-enums-struct-stubs \
ctypes-foreign-base ctypes-foreign-threaded test-enums-stubs tests-common
test-enums-stub-generator.deps = str bigarray bytes
test-enums-stub-generator: PROJECT=test-enums-stub-generator
test-enums-stub-generator: $$(BEST_TARGET)
test-enums-struct-stub-generator.dir = tests/test-enums/struct-stub-generator
test-enums-struct-stub-generator.threads = yes
test-enums-struct-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-enums-struct-stubs tests-common
test-enums-struct-stub-generator.deps = str bigarray bytes
test-enums-struct-stub-generator: PROJECT=test-enums-struct-stub-generator
test-enums-struct-stub-generator: $$(BEST_TARGET)
test-enums.dir = tests/test-enums
test-enums.threads = yes
test-enums.deps = str bigarray oUnit bytes
test-enums.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-enums-struct-stubs test-enums-stubs tests-common
test-enums.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-enums: PROJECT=test-enums
test-enums: $$(BEST_TARGET)
test-enums-structs-generated: \
tests/test-enums/stubs/generated_struct_bindings.ml \
$(BUILDDIR)/tests/test-enums/generated_struct_stubs.c
test-enums-generated: \
tests/test-enums/generated_bindings.ml \
tests/test-enums/generated_stubs.c \
tests/test-enums/generated_stubs.c: $(BUILDDIR)/test-enums-stub-generator.$(BEST)
$< --c-file $@
tests/test-enums/generated_bindings.ml: $(BUILDDIR)/test-enums-stub-generator.$(BEST)
$< --ml-file $@
tests/test-enums/stubs/generated_struct_bindings.ml: $(BUILDDIR)/test-enums-ml-struct-stub-generator.$(BEST)
$< > $@
$(BUILDDIR)/test-enums-ml-struct-stub-generator.$(BEST): $(BUILDDIR)/tests/test-enums/generated_struct_stubs.c
$(CC) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` $(CFLAGS) $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
$(BUILDDIR)/tests/test-enums/generated_struct_stubs.c: $(BUILDDIR)/test-enums-struct-stub-generator.$(BEST)
$< --c-struct-file $@
test-structs-stubs.dir = tests/test-structs/stubs
test-structs-stubs.threads = yes
test-structs-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-structs-stubs: PROJECT=test-structs-stubs
test-structs-stubs: $$(LIB_TARGETS)
test-structs-stub-generator.dir = tests/test-structs/stub-generator
test-structs-stub-generator.threads = yes
test-structs-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-structs-stubs tests-common
test-structs-stub-generator.deps = str bigarray bytes
test-structs-stub-generator: PROJECT=test-structs-stub-generator
test-structs-stub-generator: $$(BEST_TARGET)
test-structs.dir = tests/test-structs
test-structs.threads = yes
test-structs.deps = str bigarray oUnit bytes
test-structs.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-structs-stubs tests-common
test-structs.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-structs: PROJECT=test-structs
test-structs: $$(BEST_TARGET)
test-structs-generated: \
tests/test-structs/generated_bindings.ml \
tests/test-structs/generated_stubs.c \
tests/test-structs/generated_struct_bindings.ml \
$(BUILDDIR)/tests/test-structs/generated_struct_stubs.c
tests/test-structs/generated_stubs.c: $(BUILDDIR)/test-structs-stub-generator.$(BEST)
$< --c-file $@
tests/test-structs/generated_bindings.ml: $(BUILDDIR)/test-structs-stub-generator.$(BEST)
$< --ml-file $@
tests/test-structs/generated_struct_bindings.ml: $(BUILDDIR)/test-structs-ml-stub-generator.$(BEST)
$< > $@
$(BUILDDIR)/test-structs-ml-stub-generator.$(BEST): $(BUILDDIR)/tests/test-structs/generated_struct_stubs.c
$(CC) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` $(CFLAGS) $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
$(BUILDDIR)/tests/test-structs/generated_struct_stubs.c: $(BUILDDIR)/test-structs-stub-generator.$(BEST)
$< --c-struct-file $@
test-constants-stubs.dir = tests/test-constants/stubs
test-constants-stubs.threads = yes
test-constants-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-constants-stubs: PROJECT=test-constants-stubs
test-constants-stubs: $$(LIB_TARGETS)
test-constants-stub-generator.dir = tests/test-constants/stub-generator
test-constants-stub-generator.threads = yes
test-constants-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-constants-stubs tests-common
test-constants-stub-generator.deps = str bigarray bytes
test-constants-stub-generator: PROJECT=test-constants-stub-generator
test-constants-stub-generator: $$(BEST_TARGET)
test-constants.dir = tests/test-constants
test-constants.threads = yes
test-constants.deps = str bigarray oUnit bytes
test-constants.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-constants-stubs tests-common
test-constants.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-constants: PROJECT=test-constants
test-constants: $$(BEST_TARGET)
test-constants-generated: \
tests/test-constants/generated_bindings.ml \
tests/test-constants/generated_stubs.c \
tests/test-constants/generated_struct_bindings.ml \
$(BUILDDIR)/tests/test-constants/generated_struct_stubs.c
tests/test-constants/generated_stubs.c: $(BUILDDIR)/test-constants-stub-generator.$(BEST)
$< --c-file $@
tests/test-constants/generated_bindings.ml: $(BUILDDIR)/test-constants-stub-generator.$(BEST)
$< --ml-file $@
tests/test-constants/generated_struct_bindings.ml: $(BUILDDIR)/test-constants-ml-stub-generator.$(BEST)
$< > $@
$(BUILDDIR)/test-constants-ml-stub-generator.$(BEST): $(BUILDDIR)/tests/test-constants/generated_struct_stubs.c
$(CC) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` $(CFLAGS) $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
$(BUILDDIR)/tests/test-constants/generated_struct_stubs.c: $(BUILDDIR)/test-constants-stub-generator.$(BEST)
$< --c-struct-file $@
test-finalisers.dir = tests/test-finalisers
test-finalisers.threads = yes
test-finalisers.deps = str bigarray oUnit bytes
test-finalisers.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-finalisers: PROJECT=test-finalisers
test-finalisers: $$(BEST_TARGET)
test-cstdlib-stubs.dir = tests/test-cstdlib/stubs
test-cstdlib-stubs.threads = yes
test-cstdlib-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-cstdlib-stubs: PROJECT=test-cstdlib-stubs
test-cstdlib-stubs: $$(LIB_TARGETS)
test-cstdlib-stub-generator.dir = tests/test-cstdlib/stub-generator
test-cstdlib-stub-generator.threads = yes
test-cstdlib-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-cstdlib-stubs tests-common
test-cstdlib-stub-generator.deps = str bigarray bytes
test-cstdlib-stub-generator: PROJECT=test-cstdlib-stub-generator
test-cstdlib-stub-generator: $$(BEST_TARGET)
test-cstdlib.dir = tests/test-cstdlib
test-cstdlib.threads = yes
test-cstdlib.deps = str bigarray oUnit bytes
test-cstdlib.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-cstdlib-stubs tests-common
test-cstdlib.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-cstdlib: PROJECT=test-cstdlib
test-cstdlib: $$(BEST_TARGET)
test-cstdlib-generated: \
tests/test-cstdlib/generated_bindings.ml \
tests/test-cstdlib/generated_stubs.c
tests/test-cstdlib/generated_stubs.c: $(BUILDDIR)/test-cstdlib-stub-generator.$(BEST)
$< --c-file $@
tests/test-cstdlib/generated_bindings.ml: $(BUILDDIR)/test-cstdlib-stub-generator.$(BEST)
$< --ml-file $@
test-sizeof.dir = tests/test-sizeof
test-sizeof.threads = yes
test-sizeof.deps = str bigarray oUnit bytes
test-sizeof.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-sizeof: PROJECT=test-sizeof
test-sizeof: $$(BEST_TARGET)
test-foreign_values-stubs.dir = tests/test-foreign_values/stubs
test-foreign_values-stubs.threads = yes
test-foreign_values-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-foreign_values-stubs: PROJECT=test-foreign_values-stubs
test-foreign_values-stubs: $$(LIB_TARGETS)
test-foreign_values-stub-generator.dir = tests/test-foreign_values/stub-generator
test-foreign_values-stub-generator.threads = yes
test-foreign_values-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-foreign_values-stubs tests-common
test-foreign_values-stub-generator.deps = str bigarray bytes
test-foreign_values-stub-generator: PROJECT=test-foreign_values-stub-generator
test-foreign_values-stub-generator: $$(BEST_TARGET)
test-foreign_values.dir = tests/test-foreign_values
test-foreign_values.threads = yes
test-foreign_values.deps = str bigarray oUnit bytes
test-foreign_values.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-foreign_values-stubs
test-foreign_values.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-foreign_values: PROJECT=test-foreign_values
test-foreign_values: $$(BEST_TARGET)
test-foreign_values-generated: \
tests/test-foreign_values/generated_bindings.ml \
tests/test-foreign_values/generated_stubs.c
tests/test-foreign_values/generated_stubs.c: $(BUILDDIR)/test-foreign_values-stub-generator.$(BEST)
$< --c-file $@
tests/test-foreign_values/generated_bindings.ml: $(BUILDDIR)/test-foreign_values-stub-generator.$(BEST)
$< --ml-file $@
test-unions-stubs.dir = tests/test-unions/stubs
test-unions-stubs.threads = yes
test-unions-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-unions-stubs: PROJECT=test-unions-stubs
test-unions-stubs: $$(LIB_TARGETS)
test-unions-stub-generator.dir = tests/test-unions/stub-generator
test-unions-stub-generator.threads = yes
test-unions-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-unions-stubs tests-common
test-unions-stub-generator.deps = str bigarray bytes
test-unions-stub-generator: PROJECT=test-unions-stub-generator
test-unions-stub-generator: $$(BEST_TARGET)
test-unions.dir = tests/test-unions
test-unions.threads = yes
test-unions.deps = str bigarray oUnit bytes
test-unions.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-unions-stubs tests-common
test-unions.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-unions: PROJECT=test-unions
test-unions: $$(BEST_TARGET)
test-unions-generated: \
tests/test-unions/generated_bindings.ml \
tests/test-unions/generated_stubs.c \
tests/test-unions/generated_struct_bindings.ml \
$(BUILDDIR)/tests/test-unions/generated_struct_stubs.c
tests/test-unions/generated_stubs.c: $(BUILDDIR)/test-unions-stub-generator.$(BEST)
$< --c-file $@
tests/test-unions/generated_bindings.ml: $(BUILDDIR)/test-unions-stub-generator.$(BEST)
$< --ml-file $@
tests/test-unions/generated_struct_bindings.ml: $(BUILDDIR)/test-unions-ml-stub-generator.$(BEST)
$< > $@
$(BUILDDIR)/test-unions-ml-stub-generator.$(BEST): $(BUILDDIR)/tests/test-unions/generated_struct_stubs.c
$(CC) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` $(CFLAGS) $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
$(BUILDDIR)/tests/test-unions/generated_struct_stubs.c: $(BUILDDIR)/test-unions-stub-generator.$(BEST)
$< --c-struct-file $@
test-custom_ops.dir = tests/test-custom_ops
test-custom_ops.threads = yes
test-custom_ops.deps = str bigarray oUnit bytes
test-custom_ops.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-custom_ops: PROJECT=test-custom_ops
test-custom_ops: $$(BEST_TARGET)
test-arrays-stubs.dir = tests/test-arrays/stubs
test-arrays-stubs.threads = yes
test-arrays-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-arrays-stubs: PROJECT=test-arrays-stubs
test-arrays-stubs: $$(LIB_TARGETS)
test-arrays-stub-generator.dir = tests/test-arrays/stub-generator
test-arrays-stub-generator.threads = yes
test-arrays-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-arrays-stubs tests-common
test-arrays-stub-generator.deps = str bigarray bytes
test-arrays-stub-generator: PROJECT=test-arrays-stub-generator
test-arrays-stub-generator: $$(BEST_TARGET)
test-arrays.dir = tests/test-arrays
test-arrays.threads = yes
test-arrays.deps = str bigarray oUnit bytes
test-arrays.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-arrays-stubs tests-common
test-arrays.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-arrays: PROJECT=test-arrays
test-arrays: $$(BEST_TARGET)
test-arrays-generated: \
tests/test-arrays/generated_bindings.ml \
tests/test-arrays/generated_stubs.c
tests/test-arrays/generated_stubs.c: $(BUILDDIR)/test-arrays-stub-generator.$(BEST)
$< --c-file $@
tests/test-arrays/generated_bindings.ml: $(BUILDDIR)/test-arrays-stub-generator.$(BEST)
$< --ml-file $@
test-foreign-errno.dir = tests/test-foreign-errno
test-foreign-errno.threads = yes
test-foreign-errno.deps = str bigarray oUnit bytes
test-foreign-errno.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-foreign-errno: PROJECT=test-foreign-errno
test-foreign-errno: $$(BEST_TARGET)
test-passable.dir = tests/test-passable
test-passable.threads = yes
test-passable.deps = str bigarray oUnit bytes
test-passable.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-passable: PROJECT=test-passable
test-passable: $$(BEST_TARGET)
test-alignment.dir = tests/test-alignment
test-alignment.threads = yes
test-alignment.deps = str bigarray oUnit bytes
test-alignment.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-alignment: PROJECT=test-alignment
test-alignment: $$(BEST_TARGET)
test-views-stubs.dir = tests/test-views/stubs
test-views-stubs.threads = yes
test-views-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-views-stubs: PROJECT=test-views-stubs
test-views-stubs: $$(LIB_TARGETS)
test-views-stub-generator.dir = tests/test-views/stub-generator
test-views-stub-generator.threads = yes
test-views-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-views-stubs tests-common
test-views-stub-generator.deps = str bigarray bytes
test-views-stub-generator: PROJECT=test-views-stub-generator
test-views-stub-generator: $$(BEST_TARGET)
test-views.dir = tests/test-views
test-views.threads = yes
test-views.deps = str bigarray oUnit bytes
test-views.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded cstubs test-views-stubs tests-common
test-views.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-views: PROJECT=test-views
test-views: $$(BEST_TARGET)
test-views-generated: \
tests/test-views/generated_bindings.ml \
tests/test-views/generated_stubs.c
tests/test-views/generated_stubs.c: $(BUILDDIR)/test-views-stub-generator.$(BEST)
$< --c-file $@
tests/test-views/generated_bindings.ml: $(BUILDDIR)/test-views-stub-generator.$(BEST)
$< --ml-file $@
test-oo_style-stubs.dir = tests/test-oo_style/stubs
test-oo_style-stubs.threads = yes
test-oo_style-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-oo_style-stubs: PROJECT=test-oo_style-stubs
test-oo_style-stubs: $$(LIB_TARGETS)
test-oo_style-stub-generator.dir = tests/test-oo_style/stub-generator
test-oo_style-stub-generator.threads = yes
test-oo_style-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-oo_style-stubs tests-common
test-oo_style-stub-generator.deps = str bigarray bytes
test-oo_style-stub-generator: PROJECT=test-oo_style-stub-generator
test-oo_style-stub-generator: $$(BEST_TARGET)
test-oo_style.dir = tests/test-oo_style
test-oo_style.threads = yes
test-oo_style.deps = str bigarray oUnit bytes
test-oo_style.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-oo_style-stubs tests-common
test-oo_style.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-oo_style: PROJECT=test-oo_style
test-oo_style: $$(BEST_TARGET)
test-oo_style-generated: \
tests/test-oo_style/generated_bindings.ml \
tests/test-oo_style/generated_stubs.c
tests/test-oo_style/generated_stubs.c: $(BUILDDIR)/test-oo_style-stub-generator.$(BEST)
$< --c-file $@
tests/test-oo_style/generated_bindings.ml: $(BUILDDIR)/test-oo_style-stub-generator.$(BEST)
$< --ml-file $@
test-type_printing.dir = tests/test-type_printing
test-type_printing.threads = yes
test-type_printing.deps = str bigarray oUnit bytes
test-type_printing.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-type_printing: PROJECT=test-type_printing
test-type_printing: $$(BEST_TARGET)
test-value_printing-stubs.dir = tests/test-value_printing/stubs
test-value_printing-stubs.threads = yes
test-value_printing-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-value_printing-stubs: PROJECT=test-value_printing-stubs
test-value_printing-stubs: $$(LIB_TARGETS)
test-value_printing-stub-generator.dir = tests/test-value_printing/stub-generator
test-value_printing-stub-generator.threads = yes
test-value_printing-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-value_printing-stubs tests-common
test-value_printing-stub-generator.deps = str bigarray bytes
test-value_printing-stub-generator: PROJECT=test-value_printing-stub-generator
test-value_printing-stub-generator: $$(BEST_TARGET)
test-value_printing.dir = tests/test-value_printing
test-value_printing.threads = yes
test-value_printing.deps = str bigarray oUnit bytes
test-value_printing.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-value_printing-stubs
test-value_printing.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-value_printing: PROJECT=test-value_printing
test-value_printing: $$(BEST_TARGET)
test-value_printing-generated: \
tests/test-value_printing/generated_bindings.ml \
tests/test-value_printing/generated_stubs.c
tests/test-value_printing/generated_stubs.c: $(BUILDDIR)/test-value_printing-stub-generator.$(BEST)
$< --c-file $@
tests/test-value_printing/generated_bindings.ml: $(BUILDDIR)/test-value_printing-stub-generator.$(BEST)
$< --ml-file $@
test-complex-stubs.dir = tests/test-complex/stubs
test-complex-stubs.threads = yes
test-complex-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-complex-stubs: PROJECT=test-complex-stubs
test-complex-stubs: $$(LIB_TARGETS)
test-complex-stub-generator.dir = tests/test-complex/stub-generator
test-complex-stub-generator.threads = yes
test-complex-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-complex-stubs tests-common
test-complex-stub-generator.deps = str bigarray bytes
test-complex-stub-generator: PROJECT=test-complex-stub-generator
test-complex-stub-generator: $$(BEST_TARGET)
test-complex.dir = tests/test-complex
test-complex.threads = yes
test-complex.deps = str bigarray oUnit bytes
test-complex.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-complex-stubs
test-complex.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-complex: PROJECT=test-complex
test-complex: $$(BEST_TARGET)
test-complex-generated: \
tests/test-complex/generated_bindings.ml \
tests/test-complex/generated_stubs.c
tests/test-complex/generated_stubs.c: $(BUILDDIR)/test-complex-stub-generator.$(BEST)
$< --c-file $@
tests/test-complex/generated_bindings.ml: $(BUILDDIR)/test-complex-stub-generator.$(BEST)
$< --ml-file $@
test-bools-stubs.dir = tests/test-bools/stubs
test-bools-stubs.threads = yes
test-bools-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-bools-stubs: PROJECT=test-bools-stubs
test-bools-stubs: $$(LIB_TARGETS)
test-bools-stub-generator.dir = tests/test-bools/stub-generator
test-bools-stub-generator.threads = yes
test-bools-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-bools-stubs tests-common
test-bools-stub-generator.deps = str bigarray bytes
test-bools-stub-generator: PROJECT=test-bools-stub-generator
test-bools-stub-generator: $$(BEST_TARGET)
test-bools.dir = tests/test-bools
test-bools.threads = yes
test-bools.deps = str bigarray oUnit bytes
test-bools.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-bools-stubs
test-bools.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-bools: PROJECT=test-bools
test-bools: $$(BEST_TARGET)
test-bools-generated: \
tests/test-bools/generated_bindings.ml \
tests/test-bools/generated_stubs.c
tests/test-bools/generated_stubs.c: $(BUILDDIR)/test-bools-stub-generator.$(BEST)
$< --c-file $@
tests/test-bools/generated_bindings.ml: $(BUILDDIR)/test-bools-stub-generator.$(BEST)
$< --ml-file $@
test-callback_lifetime-stubs.dir = tests/test-callback_lifetime/stubs
test-callback_lifetime-stubs.threads = yes
test-callback_lifetime-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-callback_lifetime-stubs: PROJECT=test-callback_lifetime-stubs
test-callback_lifetime-stubs: $$(LIB_TARGETS)
test-callback_lifetime-stub-generator.dir = tests/test-callback_lifetime/stub-generator
test-callback_lifetime-stub-generator.threads = yes
test-callback_lifetime-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-callback_lifetime-stubs tests-common
test-callback_lifetime-stub-generator.deps = str bigarray bytes
test-callback_lifetime-stub-generator: PROJECT=test-callback_lifetime-stub-generator
test-callback_lifetime-stub-generator: $$(BEST_TARGET)
test-callback_lifetime.dir = tests/test-callback_lifetime
test-callback_lifetime.threads = yes
test-callback_lifetime.deps = str bigarray oUnit bytes
test-callback_lifetime.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs test-callback_lifetime-stubs tests-common
test-callback_lifetime.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-callback_lifetime: PROJECT=test-callback_lifetime
test-callback_lifetime: $$(BEST_TARGET)
test-callback_lifetime-generated: \
tests/test-callback_lifetime/generated_bindings.ml \
tests/test-callback_lifetime/generated_stubs.c
tests/test-callback_lifetime/generated_stubs.c: $(BUILDDIR)/test-callback_lifetime-stub-generator.$(BEST)
$< --c-file $@
tests/test-callback_lifetime/generated_bindings.ml: $(BUILDDIR)/test-callback_lifetime-stub-generator.$(BEST)
$< --ml-file $@
test-stubs.dir = tests/test-stubs
test-stubs.threads = yes
test-stubs.deps = str bigarray oUnit bytes
test-stubs.subproject_deps = ctypes ctypes-foreign-base ctypes-foreign-threaded
test-stubs: PROJECT=test-stubs
test-stubs: $$(BEST_TARGET)
test-bigarrays-stubs.dir = tests/test-bigarrays/stubs
test-bigarrays-stubs.threads = yes
test-bigarrays-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-bigarrays-stubs: PROJECT=test-bigarrays-stubs
test-bigarrays-stubs: $$(LIB_TARGETS)
test-bigarrays-stub-generator.dir = tests/test-bigarrays/stub-generator
test-bigarrays-stub-generator.threads = yes
test-bigarrays-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-bigarrays-stubs tests-common
test-bigarrays-stub-generator.deps = str bigarray bytes
test-bigarrays-stub-generator: PROJECT=test-bigarrays-stub-generator
test-bigarrays-stub-generator: $$(BEST_TARGET)
test-bigarrays.dir = tests/test-bigarrays
test-bigarrays.threads = yes
test-bigarrays.deps = str bigarray oUnit bytes
test-bigarrays.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-bigarrays-stubs
test-bigarrays.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-bigarrays: PROJECT=test-bigarrays
test-bigarrays: $$(BEST_TARGET)
test-bigarrays-generated: \
tests/test-bigarrays/generated_bindings.ml \
tests/test-bigarrays/generated_stubs.c
tests/test-bigarrays/generated_stubs.c: $(BUILDDIR)/test-bigarrays-stub-generator.$(BEST)
$< --c-file $@
tests/test-bigarrays/generated_bindings.ml: $(BUILDDIR)/test-bigarrays-stub-generator.$(BEST)
$< --ml-file $@
test-coercions-stubs.dir = tests/test-coercions/stubs
test-coercions-stubs.threads = yes
test-coercions-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-coercions-stubs: PROJECT=test-coercions-stubs
test-coercions-stubs: $$(LIB_TARGETS)
test-coercions-stub-generator.dir = tests/test-coercions/stub-generator
test-coercions-stub-generator.threads = yes
test-coercions-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-coercions-stubs tests-common
test-coercions-stub-generator.deps = str bigarray bytes
test-coercions-stub-generator: PROJECT=test-coercions-stub-generator
test-coercions-stub-generator: $$(BEST_TARGET)
test-coercions.dir = tests/test-coercions
test-coercions.threads = yes
test-coercions.deps = str bigarray oUnit bytes
test-coercions.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-coercions-stubs
test-coercions.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-coercions: PROJECT=test-coercions
test-coercions: $$(BEST_TARGET)
test-coercions-generated: \
tests/test-coercions/generated_bindings.ml \
tests/test-coercions/generated_stubs.c
tests/test-coercions/generated_stubs.c: $(BUILDDIR)/test-coercions-stub-generator.$(BEST)
$< --c-file $@
tests/test-coercions/generated_bindings.ml: $(BUILDDIR)/test-coercions-stub-generator.$(BEST)
$< --ml-file $@
test-roots.dir = tests/test-roots
test-roots.threads = yes
test-roots.deps = str bigarray oUnit bytes
test-roots.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common
test-roots.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-roots: PROJECT=test-roots
test-roots: $$(BEST_TARGET)
test-passing-ocaml-values-stubs.dir = tests/test-passing-ocaml-values/stubs
test-passing-ocaml-values-stubs.threads = yes
test-passing-ocaml-values-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-passing-ocaml-values-stubs: PROJECT=test-passing-ocaml-values-stubs
test-passing-ocaml-values-stubs: $$(LIB_TARGETS)
test-passing-ocaml-values-stub-generator.dir = tests/test-passing-ocaml-values/stub-generator
test-passing-ocaml-values-stub-generator.threads = yes
test-passing-ocaml-values-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-passing-ocaml-values-stubs tests-common
test-passing-ocaml-values-stub-generator.deps = str bigarray bytes
test-passing-ocaml-values-stub-generator: PROJECT=test-passing-ocaml-values-stub-generator
test-passing-ocaml-values-stub-generator: $$(BEST_TARGET)
test-passing-ocaml-values.dir = tests/test-passing-ocaml-values
test-passing-ocaml-values.threads = yes
test-passing-ocaml-values.deps = str bigarray oUnit bytes
test-passing-ocaml-values.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-passing-ocaml-values-stubs
test-passing-ocaml-values.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-passing-ocaml-values: PROJECT=test-passing-ocaml-values
test-passing-ocaml-values: $$(BEST_TARGET)
test-passing-ocaml-values-generated: \
tests/test-passing-ocaml-values/generated_bindings.ml \
tests/test-passing-ocaml-values/generated_stubs.c
tests/test-passing-ocaml-values/generated_stubs.c: $(BUILDDIR)/test-passing-ocaml-values-stub-generator.$(BEST)
$< --c-file $@
tests/test-passing-ocaml-values/generated_bindings.ml: $(BUILDDIR)/test-passing-ocaml-values-stub-generator.$(BEST)
$< --ml-file $@
test-lwt-jobs-stubs.dir = tests/test-lwt-jobs/stubs
test-lwt-jobs-stubs.threads = yes
test-lwt-jobs-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-lwt-jobs-stubs: PROJECT=test-lwt-jobs-stubs
test-lwt-jobs-stubs: $$(LIB_TARGETS)
test-lwt-jobs-stub-generator.dir = tests/test-lwt-jobs/stub-generator
test-lwt-jobs-stub-generator.threads = yes
test-lwt-jobs-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-lwt-jobs-stubs tests-common
test-lwt-jobs-stub-generator.deps = str bigarray bytes
test-lwt-jobs-stub-generator: PROJECT=test-lwt-jobs-stub-generator
test-lwt-jobs-stub-generator: $$(BEST_TARGET)
test-lwt-jobs.dir = tests/test-lwt-jobs
test-lwt-jobs.threads = yes
test-lwt-jobs.deps = str bigarray oUnit bytes lwt.unix
test-lwt-jobs.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-lwt-jobs-stubs
test-lwt-jobs.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-lwt-jobs: PROJECT=test-lwt-jobs
test-lwt-jobs: $$(BEST_TARGET)
test-lwt-jobs-generated: \
tests/test-lwt-jobs/generated_bindings.ml \
tests/test-lwt-jobs/generated_stubs.c \
tests/test-lwt-jobs/generated_struct_bindings.ml \
$(BUILDDIR)/tests/test-lwt-jobs/generated_struct_stubs.c
tests/test-lwt-jobs/generated_stubs.c: $(BUILDDIR)/test-lwt-jobs-stub-generator.$(BEST)
$< --c-file $@
tests/test-lwt-jobs/generated_bindings.ml: $(BUILDDIR)/test-lwt-jobs-stub-generator.$(BEST)
$< --ml-file $@
tests/test-lwt-jobs/generated_struct_bindings.ml: $(BUILDDIR)/test-lwt-jobs-ml-stub-generator.$(BEST)
$< > $@
$(BUILDDIR)/test-lwt-jobs-ml-stub-generator.$(BEST): $(BUILDDIR)/tests/test-lwt-jobs/generated_struct_stubs.c
$(CC) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` $(CFLAGS) $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
$(BUILDDIR)/tests/test-lwt-jobs/generated_struct_stubs.c: $(BUILDDIR)/test-lwt-jobs-stub-generator.$(BEST)
$< --c-struct-file $@
test-returning-errno-lwt-stubs.dir = tests/test-returning-errno-lwt/stubs
test-returning-errno-lwt-stubs.threads = yes
test-returning-errno-lwt-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-returning-errno-lwt-stubs: PROJECT=test-returning-errno-lwt-stubs
test-returning-errno-lwt-stubs: $$(LIB_TARGETS)
test-returning-errno-lwt-stub-generator.dir = tests/test-returning-errno-lwt/stub-generator
test-returning-errno-lwt-stub-generator.threads = yes
test-returning-errno-lwt-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-returning-errno-lwt-stubs tests-common
test-returning-errno-lwt-stub-generator.deps = str bigarray bytes
test-returning-errno-lwt-stub-generator: PROJECT=test-returning-errno-lwt-stub-generator
test-returning-errno-lwt-stub-generator: $$(BEST_TARGET)
test-returning-errno-lwt.dir = tests/test-returning-errno-lwt
test-returning-errno-lwt.threads = yes
test-returning-errno-lwt.deps = str bigarray oUnit bytes lwt.unix
test-returning-errno-lwt.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-returning-errno-lwt-stubs
test-returning-errno-lwt.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-returning-errno-lwt: PROJECT=test-returning-errno-lwt
test-returning-errno-lwt: $$(BEST_TARGET)
test-returning-errno-lwt-generated: \
tests/test-returning-errno-lwt/generated_bindings.ml \
tests/test-returning-errno-lwt/generated_struct_bindings.ml \
tests/test-returning-errno-lwt/generated_stubs.c
tests/test-returning-errno-lwt/generated_stubs.c: $(BUILDDIR)/test-returning-errno-lwt-stub-generator.$(BEST)
$< --c-file $@
tests/test-returning-errno-lwt/generated_bindings.ml: $(BUILDDIR)/test-returning-errno-lwt-stub-generator.$(BEST)
$< --ml-file $@
tests/test-returning-errno-lwt/generated_struct_bindings.ml: $(BUILDDIR)/test-returning-errno-lwt-ml-stub-generator.$(BEST)
$< > $@
$(BUILDDIR)/test-returning-errno-lwt-ml-stub-generator.$(BEST): $(BUILDDIR)/tests/test-returning-errno-lwt/generated_struct_stubs.c
$(CC) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` $(CFLAGS) $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
$(BUILDDIR)/tests/test-returning-errno-lwt/generated_struct_stubs.c: $(BUILDDIR)/test-returning-errno-lwt-stub-generator.$(BEST)
$< --c-struct-file $@
test-returning-errno-stubs.dir = tests/test-returning-errno/stubs
test-returning-errno-stubs.threads = yes
test-returning-errno-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-returning-errno-stubs: PROJECT=test-returning-errno-stubs
test-returning-errno-stubs: $$(LIB_TARGETS)
test-returning-errno-stub-generator.dir = tests/test-returning-errno/stub-generator
test-returning-errno-stub-generator.threads = yes
test-returning-errno-stub-generator.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded test-returning-errno-stubs tests-common
test-returning-errno-stub-generator.deps = str bigarray bytes
test-returning-errno-stub-generator: PROJECT=test-returning-errno-stub-generator
test-returning-errno-stub-generator: $$(BEST_TARGET)
test-returning-errno.dir = tests/test-returning-errno
test-returning-errno.threads = yes
test-returning-errno.deps = str bigarray oUnit bytes lwt.unix
test-returning-errno.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-returning-errno-stubs
test-returning-errno.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-returning-errno: PROJECT=test-returning-errno
test-returning-errno: $$(BEST_TARGET)
test-returning-errno-generated: \
tests/test-returning-errno/generated_bindings.ml \
tests/test-returning-errno/generated_struct_bindings.ml \
tests/test-returning-errno/generated_stubs.c
tests/test-returning-errno/generated_stubs.c: $(BUILDDIR)/test-returning-errno-stub-generator.$(BEST)
$< --c-file $@
tests/test-returning-errno/generated_bindings.ml: $(BUILDDIR)/test-returning-errno-stub-generator.$(BEST)
$< --ml-file $@
tests/test-returning-errno/generated_struct_bindings.ml: $(BUILDDIR)/test-returning-errno-ml-stub-generator.$(BEST)
$< > $@
$(BUILDDIR)/test-returning-errno-ml-stub-generator.$(BEST): $(BUILDDIR)/tests/test-returning-errno/generated_struct_stubs.c
$(CC) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` $(CFLAGS) $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
$(BUILDDIR)/tests/test-returning-errno/generated_struct_stubs.c: $(BUILDDIR)/test-returning-errno-stub-generator.$(BEST)
$< --c-struct-file $@
test-threads-stubs.dir = tests/test-threads/stubs
test-threads-stubs.threads = yes
test-threads-stubs.subproject_deps = ctypes cstubs \
ctypes-foreign-base ctypes-foreign-threaded tests-common
test-threads-stubs: PROJECT=test-threads-stubs
test-threads-stubs: $$(LIB_TARGETS)
test-threads.dir = tests/test-threads
test-threads.threads = yes
test-threads.deps = str bigarray oUnit bytes
test-threads.subproject_deps = ctypes ctypes-foreign-base \
ctypes-foreign-threaded cstubs tests-common test-threads-stubs
test-threads.link_flags = -L$(BUILDDIR)/clib -ltest_functions
test-threads: PROJECT=test-threads
test-threads: $$(BEST_TARGET)
TESTS =
TESTS += test-raw
TESTS += test-pointers-stubs test-pointers-stub-generator test-pointers-generated test-pointers
TESTS += test-variadic-stubs test-variadic-stub-generator test-variadic-generated test-variadic
TESTS += test-builtins-stubs test-builtins-stub-generator test-builtins-generated test-builtins
TESTS += test-macros-stubs test-macros-stub-generator test-macros-generated test-macros
TESTS += test-higher_order-stubs test-higher_order-stub-generator test-higher_order-generated test-higher_order
TESTS += test-enums-struct-stubs test-enums-struct-stub-generator test-enums-structs-generated test-enums-stubs test-enums-stub-generator test-enums-generated test-enums
TESTS += test-structs-stubs test-structs-stub-generator test-structs-generated test-structs
TESTS += test-constants-stubs test-constants-stub-generator test-constants-generated test-constants
TESTS += test-finalisers
TESTS += test-cstdlib-stubs test-cstdlib-stub-generator test-cstdlib-generated test-cstdlib
TESTS += test-sizeof
TESTS += test-foreign_values-stubs test-foreign_values-stub-generator test-foreign_values-generated test-foreign_values
TESTS += test-unions-stubs test-unions-stub-generator test-unions-generated test-unions
TESTS += test-custom_ops
TESTS += test-arrays-stubs test-arrays-stub-generator test-arrays-generated test-arrays
TESTS += test-foreign-errno
TESTS += test-passable
TESTS += test-alignment
TESTS += test-views-stubs test-views-stub-generator test-views-generated test-views
TESTS += test-oo_style-stubs test-oo_style-stub-generator test-oo_style-generated test-oo_style
TESTS += test-type_printing
TESTS += test-value_printing-stubs test-value_printing-stub-generator test-value_printing-generated test-value_printing
TESTS += test-complex-stubs test-complex-stub-generator test-complex-generated test-complex
TESTS += test-bools-stubs test-bools-stub-generator test-bools-generated test-bools
TESTS += test-callback_lifetime-stubs test-callback_lifetime-stub-generator test-callback_lifetime-generated test-callback_lifetime
TESTS += test-stubs
TESTS += test-bigarrays-stubs test-bigarrays-stub-generator test-bigarrays-generated test-bigarrays
TESTS += test-coercions-stubs test-coercions-stub-generator test-coercions-generated test-coercions
TESTS += test-roots
TESTS += test-passing-ocaml-values-stubs test-passing-ocaml-values-stub-generator test-passing-ocaml-values-generated test-passing-ocaml-values
TESTS += test-lwt-jobs-stubs test-lwt-jobs-stub-generator test-lwt-jobs-generated test-lwt-jobs
TESTS += test-returning-errno-lwt-stubs test-returning-errno-lwt-stub-generator test-returning-errno-lwt-generated test-returning-errno-lwt
TESTS += test-returning-errno-stubs test-returning-errno-stub-generator test-returning-errno-generated test-returning-errno
TESTS += test-threads-stubs test-threads
ifneq (,$(filter mingw%,$(OSYSTEM)))
WINLDFLAGS=-Wl,--out-implib,libtest_functions.dll.a
LDFLAGS+=-static-libgcc
endif
testlib: $(BUILDDIR)/clib/libtest_functions$(EXTDLL)
$(BUILDDIR)/clib/libtest_functions$(EXTDLL): $(BUILDDIR)/clib/test_functions.o
$(CC) -shared $(LDFLAGS) $(WINLDFLAGS) -o $@ $^
ifneq (,$(filter mingw%,$(OSYSTEM)))
cp $@ libtest_functions.dll.a $(BUILDDIR)
endif
$(BUILDDIR)/clib/test_functions.o: tests/clib/test_functions.c
@mkdir -p $(@D)
$(CC) -c $(CFLAGS) -I `$(OCAMLFIND) ocamlc -where | sed 's|\r$$||'` -o $@ $^
tests/clib/test_functions.c: tests/clib/test_functions.h
.PHONY: test testlib $(TESTS) tests-common
test: build testlib tests-common $(TESTS) \
$(filter-out %-stubs,\
$(filter-out %-stub-generator,\
$(filter-out %-generated,\
$(TESTS:%=run-%))))
run-%: $*
@echo running $*
@cd $(BUILDDIR) && CAML_LD_LIBRARY_PATH=. LD_LIBRARY_PATH=clib DYLD_LIBRARY_PATH=clib ./$*.$(BEST) -runner sequential
|