diff --git a/js/src/wasm/WasmSignalHandlers.cpp b/js/src/wasm/WasmSignalHandlers.cpp
index 4a45905..d8445b8 100644
--- a/js/src/wasm/WasmSignalHandlers.cpp
+++ b/js/src/wasm/WasmSignalHandlers.cpp
@@ -112,6 +112,7 @@ using mozilla::DebugOnly;
 #      define R32_sig(p) ((p)->sc_frame.srr0)
 #    endif
 #  elif defined(__linux__) || defined(__sun)
+#    include <sys/regset.h>
 #    if defined(__linux__)
 #      define EIP_sig(p) ((p)->uc_mcontext.gregs[REG_EIP])
 #      define EBP_sig(p) ((p)->uc_mcontext.gregs[REG_EBP])