Opened 6 years ago

Closed 6 years ago

#2998 closed defect (fixed)

getenv missing prototype error src/bin/d2/d2_controller.cc on Solaris10 Sunstudio

Reported by: tmark Owned by: tmark
Priority: very high Milestone: Sprint-DHCP-20130606
Component: dhcp Version:
Keywords: Cc:
CVSS Scoring: Parent Tickets:
Sensitive: no Defect Severity: Very High
Sub-Project: DHCP Feature Depending on Ticket:
Estimated Difficulty: 0 Add Hours to Ticket: 0
Total Hours: 0 Internal?: no

Description

New code for D2 has the following build error only on Solaris10 Sunstudio:

source='d_controller.cc' object='d_controller.o' libtool=no \
DEPDIR=.deps depmode=none /bin/bash ../../../depcomp \
/usr/bin/CC -DHAVE_CONFIG_H -I. -I../../.. -I../../../src/lib -I../../../src/lib -I../../../src/bin -I../../../src/bin -I/udir/jreed/pkg/include -D_XPG4_2 -DEXTENSIONS -DOS_SUN -DBOOST_DISABLE_THREADS=1 -I../../../ext/asio -I../../../ext/coroutine -DASIO_DISABLE_THREADS=1 -g -library=stlport4 -features=tmplife -features=tmplrefstatic -c -o d_controller.o d_controller.cc
\
source='d2_controller.cc' object='d2_controller.o' libtool=no \
DEPDIR=.deps depmode=none /bin/bash ../../../depcomp \
/usr/bin/CC -DHAVE_CONFIG_H -I. -I../../.. -I../../../src/lib -I../../../src/lib -I../../../src/bin -I../../../src/bin -I/udir/jreed/pkg/include -D_XPG4_2 -DEXTENSIONS -DOS_SUN -DBOOST_DISABLE_THREADS=1 -I../../../ext/asio -I../../../ext/coroutine -DASIO_DISABLE_THREADS=1 -g -library=stlport4 -features=tmplife -features=tmplrefstatic -c -o d2_controller.o d2_controller.cc
"d2_controller.cc", line 46: Error: The function "getenv" must have a prototype.
"d2_controller.cc", line 47: Error: The function "getenv" must have a prototype.
"d2_controller.cc", line 47: Error: Cannot cast from int to std::string .
"d2_controller.cc", line 47: Error: Formal argument spec_file_name of type const std::string & in call to isc::d2::DControllerBase::setSpecFileName(const std::string &) is being passed int.
4 Error(s) detected.
* Error code 4

Need to include <stdlib.h>. Builds everywhere else.

Subtickets

Change History (4)

comment:1 Changed 6 years ago by tmark

  • Owner set to tmark
  • Status changed from new to assigned

comment:2 Changed 6 years ago by tmark

  • Status changed from assigned to accepted

comment:3 Changed 6 years ago by tmark

  • Summary changed from getenv missing prototype error src/bin/d2/d_controller.cc on Solaris10 Sunstudio to getenv missing prototype error src/bin/d2/d2_controller.cc on Solaris10 Sunstudio

comment:4 Changed 6 years ago by tmark

  • Resolution set to fixed
  • Status changed from accepted to closed

Change committed to master directly under git 25fec05f27988d1bf5dbdd87ab67ee61e6ff15f0.

Note: See TracTickets for help on using tickets.