3 $C{COMPILE} $DIR/imageorder1.m -o imageorder1.dylib -dynamiclib
4 $C{COMPILE} $DIR/imageorder2.m -x none imageorder1.dylib -o imageorder2.dylib -dynamiclib
5 $C{COMPILE} $DIR/imageorder3.m -x none imageorder2.dylib imageorder1.dylib -o imageorder3.dylib -dynamiclib
6 $C{COMPILE} $DIR/imageorder.m -x none imageorder3.dylib imageorder2.dylib imageorder1.dylib -o imageorder.out
11 #include "imageorder.h"
12 #include <objc/runtime.h>
17 // +load methods and C static initializers
18 testassert(state == 3);
19 testassert(cstate == 3);
21 Class cls = objc_getClass("Super");
24 // make sure all categories arrived
27 testassert(state == 0);
29 testassert(state == 1);
31 testassert(state == 2);
33 testassert(state == 3);
35 // make sure imageorder3.dylib is the last category to attach
38 testassert(state == 3);