 +  if (nacl_alignment > 0) {
 +    int align_base;
 +    int call_align;
-+    int instrsize = (int) frag_now_fix();
++    int instrsize = (int) frag_now_fix ();
 +
 +    /*
 +     * "library mode" enables compatible library builds for either 16 or

+  if (fragP->fr_offset != 0) {
+    // fragP->fr_fix is the start of the fixup code (i.e. nops).
+    int i;
+    unsigned char *tmp = alloca(fragP->fr_fix);
+    memcpy(tmp, fragP->fr_literal, fragP->fr_fix);
+    for (i = 0; i < fragP->fr_var; i++) {
+      fragP->fr_literal[i] = fragP->fr_literal[fragP->fr_fix+i];
+    }

+  insn_start_frag = frag_now;
+
+  if (nacl_alignment > 0) {
+    frag_align_code (0, 0);
+  }
+
   /* Tie dwarf2 debug info to the address at the start of the insn.
