ext/-test-/RUBY_ALIGNOF: skip C++ when no compiler
C++ compilers are optional. Skip C++ tests when they are absent.
This commit is contained in:
parent
e75aed7abb
commit
4cc501bcfd
Notes:
git
2020-09-25 11:39:04 +09:00
@ -7,3 +7,9 @@ struct T {
|
|||||||
};
|
};
|
||||||
|
|
||||||
RBIMPL_STATIC_ASSERT(RUBY_ALIGNOF, RUBY_ALIGNOF(double) == offsetof(struct T, t));
|
RBIMPL_STATIC_ASSERT(RUBY_ALIGNOF, RUBY_ALIGNOF(double) == offsetof(struct T, t));
|
||||||
|
|
||||||
|
void
|
||||||
|
Init_RUBY_ALIGNOF()
|
||||||
|
{
|
||||||
|
// Windows linker mandates this symbol to exist.
|
||||||
|
}
|
||||||
|
@ -7,9 +7,3 @@ struct T {
|
|||||||
};
|
};
|
||||||
|
|
||||||
RBIMPL_STATIC_ASSERT(RUBY_ALIGNOF, RUBY_ALIGNOF(double) == offsetof(T, t));
|
RBIMPL_STATIC_ASSERT(RUBY_ALIGNOF, RUBY_ALIGNOF(double) == offsetof(T, t));
|
||||||
|
|
||||||
extern "C" void
|
|
||||||
Init_RUBY_ALIGNOF()
|
|
||||||
{
|
|
||||||
// Windows linker mandates this symbol to exist.
|
|
||||||
}
|
|
||||||
|
@ -1,2 +1,6 @@
|
|||||||
# frozen_string_literal: false
|
# frozen_string_literal: false
|
||||||
|
$objs = %W"c.#$OBJEXT"
|
||||||
|
|
||||||
|
$objs << "cpp.#$OBJEXT" if MakeMakefile['C++'].have_devel?
|
||||||
|
|
||||||
create_makefile("-test-/RUBY_ALIGNOF")
|
create_makefile("-test-/RUBY_ALIGNOF")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user