OpenSolaris

You are not signed in. Sign in or register.

Flag day: 6683064: build and check_rtime() changes.

Date: Fri, 02 May 2008 15:07:15 -0700
From: Rod Evans <Rod.Evans at sun dot com>
To: onnv-gate at onnv dot eng dot sun dot com, on-all at sun dot com
Subject: Flag day: 6683064: build and check_rtime() changes.

The integration of 6683064 changes a number of OSNet build components,
and OSNET build practices for the future.  In a nutshell:

  i.	external interfaces that can not be resolved by defining dependencies
	are now defined as EXTERN symbols within mapfile files.  mapfile-extern
	is the conventional name I've used, for example:

		usr/src/cmd/mdb/common/modules/conf/mapfile-extern

	Unresolved references typically occur when a shared object expects
	to reference interfaces offered by a caller (perhaps the a.out).
	Thus,
	
	  a)	use mapfile-extern definitions to express EXTERN interfaces.

	  b)	there is no need to disable "-z defs" use within Makefiles
		once a mapfile-extern is employed.

	  c)	there is no need to add exceptions to check_rtime() to
		account for unresolved symbol references that would previously
		have been discovered by check_rtime()'s use of ldd(1).

  ii.	you should only specify the runpaths that are necessary for the
	object being built (ie. don't inherit a "common" runpath if you
	don't need it).

  iii.	you need snv_86 installed to build these new components if you
	enable check_rtime() processing with nightly -r.


More details:

The integration of 6683064 changes a number of OSNet build components
so that they use EXTERN declarations within mapfiles to express dependencies
on such things as external call back interfaces.  These mapfile declarations
record the EXTERN attribute in the associated ELF file.   In addition, a
number of exceptions in check_rtime() have been removed (or modified) to
no longer pattern match against objects that revealed unresolved external
symbol relocations.

With the integration of 6357282 in snv_86, ldd(1) was taught to detect these
EXTERN attributes and use this information to suppress any unresolved
relocation errors against the associated symbols.

Hence, if you built against these new 6683064 changes, and use the -r flag
of nightly to enable check_rtime() usage, and use the check_rtime() that
has been integrated with 6683064 (which would the default for nightly), you
need to be running at least build snv_86 so that you have the ldd(1)
associated with 6357282.

If you're build environment is earlier than snv_86 and you invoke the
6683064 version of check_rtime(), expect to see errors such as:

       foo.so.1: symbol not found mdb_warn (bar.so.1)   <no -zdefs>

Note also, that all runpaths used within the OSNet have been validated as
required by their associated components.  Validation of runpath use will
become an integral part of check_rtime when ldd(1) undergoes a further
update in a future integration (see 6686343).

I believe the use of a mapfile-extern will trigger an incremental build
of any associated component, but I can't claim to have tested every
possible permutation of builds.  If you do see an error as above, clobber
the associated component.  Or, just do a clobber build.

-- 

Rod.