* Makefile.am (spu_ovl.o_c): Add missing line continuations.
[binutils-gdb.git] / gold / output.cc
index 145fca159df5f00e0fb4bc7c3e6af3c592b9d5ac..f6a6f1da6e11f3613e6eb90323f84337a29723c9 100644 (file)
@@ -838,11 +838,11 @@ Output_reloc<elfcpp::SHT_REL, dynamic, size, big_endian>::
   Output_section* os = this->u1_.relobj->output_section(lsi);
   gold_assert(os != NULL);
   Address offset = this->u1_.relobj->get_output_section_offset(lsi);
-  if (offset != -1U)
+  if (offset != invalid_address)
     return offset + addend;
   // This is a merge section.
   offset = os->output_address(this->u1_.relobj, lsi, addend);
-  gold_assert(offset != -1U);
+  gold_assert(offset != invalid_address);
   return offset;
 }
 
@@ -858,13 +858,13 @@ Output_reloc<elfcpp::SHT_REL, dynamic, size, big_endian>::get_address() const
       Output_section* os = this->u2_.relobj->output_section(this->shndx_);
       gold_assert(os != NULL);
       Address off = this->u2_.relobj->get_output_section_offset(this->shndx_);
-      if (off != -1U)
+      if (off != invalid_address)
        address += os->address() + off;
       else
        {
          address = os->output_address(this->u2_.relobj, this->shndx_,
                                       address);
-         gold_assert(address != -1U);
+         gold_assert(address != invalid_address);
        }
     }
   else if (this->u2_.od != NULL)
@@ -2043,7 +2043,7 @@ Output_section::output_address(const Relobj* object, unsigned int shndx,
       if (p->output_offset(object, shndx, offset, &output_offset))
        {
          if (output_offset == -1)
-           return -1U;
+           return -1ULL;
          return addr + output_offset;
        }
       addr += p->data_size();
@@ -2651,8 +2651,7 @@ Output_segment::add_output_section(Output_section* os,
   // and the PT_TLS segment -- we do this grouping only for the
   // PT_LOAD segment.
   if (this->type_ != elfcpp::PT_TLS
-      && (os->flags() & elfcpp::SHF_TLS) != 0
-      && !this->output_data_.empty())
+      && (os->flags() & elfcpp::SHF_TLS) != 0)
     {
       pdl = &this->output_data_;
       bool nobits = os->type() == elfcpp::SHT_NOBITS;
@@ -2777,7 +2776,9 @@ Output_segment::maximum_alignment()
       // segment is a relro section, then the segment must be aligned
       // to at least the common page size.  This ensures that the
       // PT_GNU_RELRO segment will start at a page boundary.
-      if (parameters->options().relro() && this->is_first_section_relro())
+      if (this->type_ == elfcpp::PT_LOAD
+         && parameters->options().relro()
+         && this->is_first_section_relro())
        {
          addralign = parameters->target().common_pagesize();
          if (addralign > this->max_align_)