Print this page
10366 ld(1) should support GNU-style linker sets
10581 ld(1) should know kernel modules are a thing


1257                  * .SUNW_capinfo section.
1258                  */
1259                 if (ofl->ofl_oscapinfo)
1260                         cnt++;                  /* DT_SUNW_CAPINFO */
1261 
1262                 /*
1263                  * Capabilities chain information requires a .SUNW_capchain
1264                  * entry (DT_SUNW_CAPCHAIN), entry size (DT_SUNW_CAPCHAINENT),
1265                  * and total size (DT_SUNW_CAPCHAINSZ).
1266                  */
1267                 if (ofl->ofl_oscapchain)
1268                         cnt += 3;
1269 
1270                 if (flags & FLG_OF_SYMBOLIC)
1271                         cnt++;                  /* DT_SYMBOLIC */
1272 
1273                 if (ofl->ofl_aslr != 0)              /* DT_SUNW_ASLR */
1274                         cnt++;
1275         }
1276 




1277         /*
1278          * Account for Architecture dependent .dynamic entries, and defaults.
1279          */
1280         (*ld_targ.t_mr.mr_mach_make_dynamic)(ofl, &cnt);
1281 
1282         /*
1283          * DT_FLAGS, DT_FLAGS_1, DT_SUNW_STRPAD, and DT_NULL. Also,
1284          * allow room for the unused extra DT_NULLs. These are included
1285          * to allow an ELF editor room to add items later.
1286          */
1287         cnt += 4 + DYNAMIC_EXTRA_ELTS;
1288 
1289         /*
1290          * DT_SUNW_LDMACH. Used to hold the ELF machine code of the
1291          * linker that produced the output object. This information
1292          * allows us to determine whether a given object was linked
1293          * natively, or by a linker running on a different type of
1294          * system. This information can be valuable if one suspects
1295          * that a problem might be due to alignment or byte order issues.
1296          */




1257                  * .SUNW_capinfo section.
1258                  */
1259                 if (ofl->ofl_oscapinfo)
1260                         cnt++;                  /* DT_SUNW_CAPINFO */
1261 
1262                 /*
1263                  * Capabilities chain information requires a .SUNW_capchain
1264                  * entry (DT_SUNW_CAPCHAIN), entry size (DT_SUNW_CAPCHAINENT),
1265                  * and total size (DT_SUNW_CAPCHAINSZ).
1266                  */
1267                 if (ofl->ofl_oscapchain)
1268                         cnt += 3;
1269 
1270                 if (flags & FLG_OF_SYMBOLIC)
1271                         cnt++;                  /* DT_SYMBOLIC */
1272 
1273                 if (ofl->ofl_aslr != 0)              /* DT_SUNW_ASLR */
1274                         cnt++;
1275         }
1276 
1277         /* DT_SUNW_KMOD */
1278         if (ofl->ofl_flags & FLG_OF_KMOD)
1279                 cnt++;
1280 
1281         /*
1282          * Account for Architecture dependent .dynamic entries, and defaults.
1283          */
1284         (*ld_targ.t_mr.mr_mach_make_dynamic)(ofl, &cnt);
1285 
1286         /*
1287          * DT_FLAGS, DT_FLAGS_1, DT_SUNW_STRPAD, and DT_NULL. Also,
1288          * allow room for the unused extra DT_NULLs. These are included
1289          * to allow an ELF editor room to add items later.
1290          */
1291         cnt += 4 + DYNAMIC_EXTRA_ELTS;
1292 
1293         /*
1294          * DT_SUNW_LDMACH. Used to hold the ELF machine code of the
1295          * linker that produced the output object. This information
1296          * allows us to determine whether a given object was linked
1297          * natively, or by a linker running on a different type of
1298          * system. This information can be valuable if one suspects
1299          * that a problem might be due to alignment or byte order issues.
1300          */