]> git.saurik.com Git - apple/libinfo.git/commitdiff
Libinfo-459.tar.gz os-x-1010 os-x-10101 os-x-10102 v459
authorApple <opensource@apple.com>
Thu, 24 Jul 2014 21:25:26 +0000 (21:25 +0000)
committerApple <opensource@apple.com>
Thu, 24 Jul 2014 21:25:26 +0000 (21:25 +0000)
15 files changed:
Libinfo.xcodeproj/project.pbxproj
gen.subproj/ether_addr.c
lookup.subproj/file_module.c
lookup.subproj/getaddrinfo.3
lookup.subproj/getfsent.3
lookup.subproj/getgrent.3
lookup.subproj/getgrouplist.3
lookup.subproj/getpwent.3
lookup.subproj/initgroups.3
lookup.subproj/mdns_module.c
nis.subproj/yp.8
nis.subproj/ypclnt.3
rpc.subproj/rpc.h
xcodescripts/Libinfo.xcconfig [new file with mode: 0644]
xcodescripts/install_files.sh

index e085dc7f903d332c9605f86e7c28a269ffca8992..253ab6a2718cda0e5ff560aee986d2eacfafaded 100644 (file)
        objectVersion = 46;
        objects = {
 
+/* Begin PBXAggregateTarget section */
+               3F397F7E185BD71400987BCC /* Libinfo_Sim */ = {
+                       isa = PBXAggregateTarget;
+                       buildConfigurationList = 3F397F7F185BD71500987BCC /* Build configuration list for PBXAggregateTarget "Libinfo_Sim" */;
+                       buildPhases = (
+                               3F397F83185BD74800987BCC /* Comment on this Target */,
+                       );
+                       dependencies = (
+                               3F397F82185BD71900987BCC /* PBXTargetDependency */,
+                       );
+                       name = Libinfo_Sim;
+                       productName = Libinfo_Sim;
+               };
+/* End PBXAggregateTarget section */
+
 /* Begin PBXBuildFile section */
                2D31A0FC128074E700D5A84C /* getifmaddrs.c in Sources */ = {isa = PBXBuildFile; fileRef = 2D31A0FB128074E700D5A84C /* getifmaddrs.c */; };
-               2D31A0FD128074E700D5A84C /* getifmaddrs.c in Sources */ = {isa = PBXBuildFile; fileRef = 2D31A0FB128074E700D5A84C /* getifmaddrs.c */; };
                2D4070B1129354A700FE81ED /* getnameinfo_link.c in Sources */ = {isa = PBXBuildFile; fileRef = 2D4070B0129354A700FE81ED /* getnameinfo_link.c */; };
-               2D4070B2129354A700FE81ED /* getnameinfo_link.c in Sources */ = {isa = PBXBuildFile; fileRef = 2D4070B0129354A700FE81ED /* getnameinfo_link.c */; };
                2D5DD5D21608E6E80051891A /* configuration_profile.c in Sources */ = {isa = PBXBuildFile; fileRef = 2D5DD5D01608E6E80051891A /* configuration_profile.c */; };
-               2D5DD5D31608E6E80051891A /* configuration_profile.c in Sources */ = {isa = PBXBuildFile; fileRef = 2D5DD5D01608E6E80051891A /* configuration_profile.c */; };
-               3FCF60EC1257C272008D8BB1 /* herror.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5283EE11478C200058CCB0 /* herror.c */; };
-               3FCF60ED1257C272008D8BB1 /* res_comp.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5283F711478C200058CCB0 /* res_comp.c */; };
-               3FCF60F21257C272008D8BB1 /* res_query.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5283FC11478C200058CCB0 /* res_query.c */; };
-               3FCF60F41257C272008D8BB1 /* getifaddrs.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52840411478C200058CCB0 /* getifaddrs.c */; };
-               3FCF60F51257C272008D8BB1 /* if_indextoname.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52840A11478C200058CCB0 /* if_indextoname.c */; };
-               3FCF60F61257C272008D8BB1 /* if_nameindex.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52840B11478C200058CCB0 /* if_nameindex.c */; };
-               3FCF60F71257C272008D8BB1 /* if_nametoindex.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52840C11478C200058CCB0 /* if_nametoindex.c */; };
-               3FCF60FA1257C272008D8BB1 /* ip6opt.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52841211478C200058CCB0 /* ip6opt.c */; };
-               3FCF60FB1257C272008D8BB1 /* map_v4v6.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52841411478C200058CCB0 /* map_v4v6.c */; };
-               3FCF60FC1257C272008D8BB1 /* rthdr.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52841511478C200058CCB0 /* rthdr.c */; };
-               3FCF60FD1257C272008D8BB1 /* vars.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52841611478C200058CCB0 /* vars.c */; };
-               3FCF610A1257C272008D8BB1 /* membership.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52843E11478C200058CCB0 /* membership.c */; };
-               3FCF610C1257C272008D8BB1 /* getdomainname.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844611478C200058CCB0 /* getdomainname.c */; };
-               3FCF610D1257C272008D8BB1 /* getnetgrent.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844711478C200058CCB0 /* getnetgrent.c */; };
-               3FCF610E1257C272008D8BB1 /* innetgr.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844811478C200058CCB0 /* innetgr.c */; };
-               3FCF610F1257C272008D8BB1 /* setdomainname.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844A11478C200058CCB0 /* setdomainname.c */; };
-               3FCF61101257C272008D8BB1 /* xdr_domainname.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844B11478C200058CCB0 /* xdr_domainname.c */; };
-               3FCF61111257C272008D8BB1 /* xdr_keydat.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844C11478C200058CCB0 /* xdr_keydat.c */; };
-               3FCF61121257C272008D8BB1 /* xdr_mapname.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844D11478C200058CCB0 /* xdr_mapname.c */; };
-               3FCF61131257C272008D8BB1 /* xdr_peername.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844E11478C200058CCB0 /* xdr_peername.c */; };
-               3FCF61141257C272008D8BB1 /* xdr_valdat.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52844F11478C200058CCB0 /* xdr_valdat.c */; };
-               3FCF61151257C272008D8BB1 /* xdr_ypbind_binding.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845011478C200058CCB0 /* xdr_ypbind_binding.c */; };
-               3FCF61161257C272008D8BB1 /* xdr_ypbind_resp.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845111478C200058CCB0 /* xdr_ypbind_resp.c */; };
-               3FCF61171257C272008D8BB1 /* xdr_ypbind_resptype.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845211478C200058CCB0 /* xdr_ypbind_resptype.c */; };
-               3FCF61181257C272008D8BB1 /* xdr_ypbind_setdom.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845311478C200058CCB0 /* xdr_ypbind_setdom.c */; };
-               3FCF61191257C272008D8BB1 /* xdr_ypmaplist.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845411478C200058CCB0 /* xdr_ypmaplist.c */; };
-               3FCF611A1257C272008D8BB1 /* xdr_ypreq_key.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845511478C200058CCB0 /* xdr_ypreq_key.c */; };
-               3FCF611B1257C272008D8BB1 /* xdr_ypreq_nokey.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845611478C200058CCB0 /* xdr_ypreq_nokey.c */; };
-               3FCF611C1257C272008D8BB1 /* xdr_ypresp_all.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845711478C200058CCB0 /* xdr_ypresp_all.c */; };
-               3FCF611D1257C272008D8BB1 /* xdr_ypresp_key_val.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845811478C200058CCB0 /* xdr_ypresp_key_val.c */; };
-               3FCF611E1257C272008D8BB1 /* xdr_ypresp_maplist.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845911478C200058CCB0 /* xdr_ypresp_maplist.c */; };
-               3FCF611F1257C272008D8BB1 /* xdr_ypresp_master.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845A11478C200058CCB0 /* xdr_ypresp_master.c */; };
-               3FCF61201257C272008D8BB1 /* xdr_ypresp_order.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845B11478C200058CCB0 /* xdr_ypresp_order.c */; };
-               3FCF61211257C272008D8BB1 /* xdr_ypresp_val.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845C11478C200058CCB0 /* xdr_ypresp_val.c */; };
-               3FCF61221257C272008D8BB1 /* xdr_ypstat.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52845D11478C200058CCB0 /* xdr_ypstat.c */; };
-               3FCF61231257C272008D8BB1 /* yp_all.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52846011478C200058CCB0 /* yp_all.c */; };
-               3FCF61241257C272008D8BB1 /* yp_bind.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52846211478C200058CCB0 /* yp_bind.c */; };
-               3FCF61251257C272008D8BB1 /* yp_first.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52846411478C200058CCB0 /* yp_first.c */; };
-               3FCF61261257C272008D8BB1 /* yp_get_default_domain.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52846611478C200058CCB0 /* yp_get_default_domain.c */; };
-               3FCF61271257C272008D8BB1 /* yp_maplist.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52846711478C200058CCB0 /* yp_maplist.c */; };
-               3FCF61281257C272008D8BB1 /* yp_master.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52846911478C200058CCB0 /* yp_master.c */; };
-               3FCF61291257C272008D8BB1 /* yp_order.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52846D11478C200058CCB0 /* yp_order.c */; };
-               3FCF612A1257C272008D8BB1 /* yperr_string.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52847311478C200058CCB0 /* yperr_string.c */; };
-               3FCF612B1257C272008D8BB1 /* ypmatch_cache.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52847511478C200058CCB0 /* ypmatch_cache.c */; };
-               3FCF612C1257C272008D8BB1 /* yppasswdd_xdr.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52847611478C200058CCB0 /* yppasswdd_xdr.c */; };
-               3FCF612D1257C272008D8BB1 /* ypprot_err.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52847811478C200058CCB0 /* ypprot_err.c */; };
-               3FCF612E1257C272008D8BB1 /* auth_none.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52847B11478C200058CCB0 /* auth_none.c */; };
-               3FCF612F1257C272008D8BB1 /* auth_unix.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52847C11478C200058CCB0 /* auth_unix.c */; };
-               3FCF61301257C272008D8BB1 /* authunix_prot.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52847E11478C200058CCB0 /* authunix_prot.c */; };
-               3FCF61311257C272008D8BB1 /* bindresvport.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848011478C200058CCB0 /* bindresvport.c */; };
-               3FCF61321257C272008D8BB1 /* clnt_generic.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848211478C200058CCB0 /* clnt_generic.c */; };
-               3FCF61331257C272008D8BB1 /* clnt_perror.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848311478C200058CCB0 /* clnt_perror.c */; };
-               3FCF61341257C272008D8BB1 /* clnt_raw.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848411478C200058CCB0 /* clnt_raw.c */; };
-               3FCF61351257C272008D8BB1 /* clnt_simple.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848511478C200058CCB0 /* clnt_simple.c */; };
-               3FCF61361257C272008D8BB1 /* clnt_tcp.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848611478C200058CCB0 /* clnt_tcp.c */; };
-               3FCF61371257C272008D8BB1 /* clnt_udp.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848711478C200058CCB0 /* clnt_udp.c */; };
-               3FCF61381257C272008D8BB1 /* get_myaddress.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848911478C200058CCB0 /* get_myaddress.c */; };
-               3FCF61391257C272008D8BB1 /* getrpcent.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848B11478C200058CCB0 /* getrpcent.c */; };
-               3FCF613A1257C272008D8BB1 /* getrpcport.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52848D11478C200058CCB0 /* getrpcport.c */; };
-               3FCF613B1257C272008D8BB1 /* pmap_clnt.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849011478C200058CCB0 /* pmap_clnt.c */; };
-               3FCF613C1257C272008D8BB1 /* pmap_getmaps.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849211478C200058CCB0 /* pmap_getmaps.c */; };
-               3FCF613D1257C272008D8BB1 /* pmap_getport.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849311478C200058CCB0 /* pmap_getport.c */; };
-               3FCF613E1257C272008D8BB1 /* pmap_prot.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849411478C200058CCB0 /* pmap_prot.c */; };
-               3FCF613F1257C272008D8BB1 /* pmap_prot2.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849611478C200058CCB0 /* pmap_prot2.c */; };
-               3FCF61401257C272008D8BB1 /* pmap_rmt.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849711478C200058CCB0 /* pmap_rmt.c */; };
-               3FCF61411257C272008D8BB1 /* pmap_wakeup.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849911478C200058CCB0 /* pmap_wakeup.c */; };
-               3FCF61421257C272008D8BB1 /* rpc_callmsg.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849E11478C200058CCB0 /* rpc_callmsg.c */; };
-               3FCF61431257C272008D8BB1 /* rpc_commondata.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52849F11478C200058CCB0 /* rpc_commondata.c */; };
-               3FCF61441257C272008D8BB1 /* rpc_dtablesize.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284A011478C200058CCB0 /* rpc_dtablesize.c */; };
-               3FCF61451257C272008D8BB1 /* rpc_prot.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284A211478C200058CCB0 /* rpc_prot.c */; };
-               3FCF61461257C272008D8BB1 /* svc.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284A311478C200058CCB0 /* svc.c */; };
-               3FCF61471257C272008D8BB1 /* svc_auth.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284A511478C200058CCB0 /* svc_auth.c */; };
-               3FCF61481257C272008D8BB1 /* svc_auth_unix.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284A711478C200058CCB0 /* svc_auth_unix.c */; };
-               3FCF61491257C272008D8BB1 /* svc_raw.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284A811478C200058CCB0 /* svc_raw.c */; };
-               3FCF614A1257C272008D8BB1 /* svc_run.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284A911478C200058CCB0 /* svc_run.c */; };
-               3FCF614B1257C272008D8BB1 /* svc_simple.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284AA11478C200058CCB0 /* svc_simple.c */; };
-               3FCF614C1257C272008D8BB1 /* svc_tcp.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284AB11478C200058CCB0 /* svc_tcp.c */; };
-               3FCF614D1257C272008D8BB1 /* svc_udp.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284AC11478C200058CCB0 /* svc_udp.c */; };
-               3FCF614E1257C272008D8BB1 /* xdr.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284AF11478C200058CCB0 /* xdr.c */; };
-               3FCF614F1257C272008D8BB1 /* xdr_array.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284B111478C200058CCB0 /* xdr_array.c */; };
-               3FCF61501257C272008D8BB1 /* xdr_float.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284B211478C200058CCB0 /* xdr_float.c */; };
-               3FCF61511257C272008D8BB1 /* xdr_mem.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284B311478C200058CCB0 /* xdr_mem.c */; };
-               3FCF61521257C272008D8BB1 /* xdr_rec.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284B411478C200058CCB0 /* xdr_rec.c */; };
-               3FCF61531257C272008D8BB1 /* xdr_reference.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284B511478C200058CCB0 /* xdr_reference.c */; };
-               3FCF61541257C272008D8BB1 /* xdr_sizeof.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284B611478C200058CCB0 /* xdr_sizeof.c */; };
-               3FCF61551257C272008D8BB1 /* xdr_stdio.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284B711478C200058CCB0 /* xdr_stdio.c */; };
-               3FCF61561257C272008D8BB1 /* hton.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284BA11478C200058CCB0 /* hton.c */; };
-               3FCF61581257C272008D8BB1 /* rcmd.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5284BE11478C200058CCB0 /* rcmd.c */; };
-               3FCF615D1257C272008D8BB1 /* ether_addr.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5285F6114793400058CCB0 /* ether_addr.c */; };
-               3FFC065C167132160007509F /* cache_module.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52841B11478C200058CCB0 /* cache_module.c */; };
-               3FFC065D167132180007509F /* ds_module.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52841C11478C200058CCB0 /* ds_module.c */; };
-               3FFC065E1671321B0007509F /* file_module.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52841D11478C200058CCB0 /* file_module.c */; };
-               3FFC065F1671321E0007509F /* ils.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52842611478C200058CCB0 /* ils.c */; };
-               3FFC0660167132270007509F /* kvbuf.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52842911478C200058CCB0 /* kvbuf.c */; };
-               3FFC0661167132270007509F /* libinfo.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52842B11478C200058CCB0 /* libinfo.c */; };
-               3FFC0662167132270007509F /* mdns_module.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52842E11478C200058CCB0 /* mdns_module.c */; };
-               3FFC0663167132270007509F /* search_module.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52843211478C200058CCB0 /* search_module.c */; };
-               3FFC0664167132270007509F /* si_data.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52843311478C200058CCB0 /* si_data.c */; };
-               3FFC0665167132270007509F /* si_getaddrinfo.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52843511478C200058CCB0 /* si_getaddrinfo.c */; };
-               3FFC0666167132270007509F /* si_module.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52843611478C200058CCB0 /* si_module.c */; };
-               3FFC0667167132270007509F /* thread_data.c in Sources */ = {isa = PBXBuildFile; fileRef = FC52843811478C200058CCB0 /* thread_data.c */; };
                FC5284C011478C200058CCB0 /* herror.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5283EE11478C200058CCB0 /* herror.c */; };
                FC5284C811478C200058CCB0 /* res_comp.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5283F711478C200058CCB0 /* res_comp.c */; };
                FC5284CD11478C200058CCB0 /* res_query.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5283FC11478C200058CCB0 /* res_query.c */; };
                FC5285F7114793400058CCB0 /* ether_addr.c in Sources */ = {isa = PBXBuildFile; fileRef = FC5285F6114793400058CCB0 /* ether_addr.c */; };
 /* End PBXBuildFile section */
 
+/* Begin PBXContainerItemProxy section */
+               3F397F81185BD71900987BCC /* PBXContainerItemProxy */ = {
+                       isa = PBXContainerItemProxy;
+                       containerPortal = 08FB7793FE84155DC02AAC07 /* Project object */;
+                       proxyType = 1;
+                       remoteGlobalIDString = D2AAC0620554660B00DB518D;
+                       remoteInfo = Libinfo;
+               };
+/* End PBXContainerItemProxy section */
+
 /* Begin PBXFileReference section */
                2D31A0FA128074E700D5A84C /* getifmaddrs.3 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = getifmaddrs.3; sourceTree = "<group>"; };
                2D31A0FB128074E700D5A84C /* getifmaddrs.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = getifmaddrs.c; sourceTree = "<group>"; };
                2D5DD5D01608E6E80051891A /* configuration_profile.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = configuration_profile.c; sourceTree = "<group>"; };
                2D5DD5D11608E6E80051891A /* configuration_profile.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = configuration_profile.h; sourceTree = "<group>"; };
                2DBB147712DBD63300D710E3 /* inet6_opt_init.3 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = inet6_opt_init.3; sourceTree = "<group>"; };
-               3FCF61621257C272008D8BB1 /* libsystem_sim_info.dylib */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.dylib"; includeInIndex = 0; path = libsystem_sim_info.dylib; sourceTree = BUILT_PRODUCTS_DIR; };
+               3F397F7D185BD67F00987BCC /* Libinfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Libinfo.xcconfig; path = xcodescripts/Libinfo.xcconfig; sourceTree = "<group>"; };
                D2AAC0630554660B00DB518D /* libsystem_info.dylib */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.dylib"; includeInIndex = 0; path = libsystem_info.dylib; sourceTree = BUILT_PRODUCTS_DIR; };
                FC5283EE11478C200058CCB0 /* herror.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = herror.c; sourceTree = "<group>"; };
                FC5283F711478C200058CCB0 /* res_comp.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = res_comp.c; sourceTree = "<group>"; };
 /* End PBXFileReference section */
 
 /* Begin PBXFrameworksBuildPhase section */
-               3FCF615E1257C272008D8BB1 /* Frameworks */ = {
-                       isa = PBXFrameworksBuildPhase;
-                       buildActionMask = 2147483647;
-                       files = (
-                       );
-                       runOnlyForDeploymentPostprocessing = 0;
-               };
                D289988505E68E00004EDB86 /* Frameworks */ = {
                        isa = PBXFrameworksBuildPhase;
                        buildActionMask = 2147483647;
                08FB7794FE84155DC02AAC07 /* Libinfo */ = {
                        isa = PBXGroup;
                        children = (
+                               3F397F7D185BD67F00987BCC /* Libinfo.xcconfig */,
                                FC5283ED11478C200058CCB0 /* dns.subproj */,
                                FC52840011478C200058CCB0 /* gen.subproj */,
                                FC52841711478C200058CCB0 /* lookup.subproj */,
                                FC52843A11478C200058CCB0 /* membership.subproj */,
-                               FC52844211478C200058CCB0 /* netinfo.subproj */,
                                FC52844511478C200058CCB0 /* nis.subproj */,
                                FC52847911478C200058CCB0 /* rpc.subproj */,
                                FC5284B811478C200058CCB0 /* util.subproj */,
                        isa = PBXGroup;
                        children = (
                                D2AAC0630554660B00DB518D /* libsystem_info.dylib */,
-                               3FCF61621257C272008D8BB1 /* libsystem_sim_info.dylib */,
                        );
                        name = Products;
                        sourceTree = "<group>";
 /* End PBXGroup section */
 
 /* Begin PBXNativeTarget section */
-               3FCF60EA1257C272008D8BB1 /* Libinfo_Sim */ = {
-                       isa = PBXNativeTarget;
-                       buildConfigurationList = 3FCF61601257C272008D8BB1 /* Build configuration list for PBXNativeTarget "Libinfo_Sim" */;
-                       buildPhases = (
-                               3FCF60EB1257C272008D8BB1 /* Sources */,
-                               3FCF615E1257C272008D8BB1 /* Frameworks */,
-                               3FCF615F1257C272008D8BB1 /* Install Files */,
-                       );
-                       buildRules = (
-                       );
-                       dependencies = (
-                       );
-                       name = Libinfo_Sim;
-                       productName = Libinfo;
-                       productReference = 3FCF61621257C272008D8BB1 /* libsystem_sim_info.dylib */;
-                       productType = "com.apple.product-type.library.dynamic";
-               };
                D2AAC0620554660B00DB518D /* Libinfo */ = {
                        isa = PBXNativeTarget;
                        buildConfigurationList = 1DEB914A08733D8E0010E9CD /* Build configuration list for PBXNativeTarget "Libinfo" */;
                        projectRoot = "";
                        targets = (
                                D2AAC0620554660B00DB518D /* Libinfo */,
-                               3FCF60EA1257C272008D8BB1 /* Libinfo_Sim */,
+                               3F397F7E185BD71400987BCC /* Libinfo_Sim */,
                        );
                };
 /* End PBXProject section */
 
 /* Begin PBXShellScriptBuildPhase section */
-               3FCF615F1257C272008D8BB1 /* Install Files */ = {
+               3F397F83185BD74800987BCC /* Comment on this Target */ = {
                        isa = PBXShellScriptBuildPhase;
-                       buildActionMask = 8;
+                       buildActionMask = 2147483647;
                        files = (
                        );
                        inputPaths = (
                        );
-                       name = "Install Files";
+                       name = "Comment on this Target";
                        outputPaths = (
                        );
-                       runOnlyForDeploymentPostprocessing = 1;
+                       runOnlyForDeploymentPostprocessing = 0;
                        shellPath = /bin/sh;
-                       shellScript = "\"$PROJECT_DIR\"/xcodescripts/install_files.sh";
+                       shellScript = "# This target is here for compatibility reasons.  It can be removed once B&I has updated Libinfo_Sim is\n# building with the default -target (https://buildcentral.apple.com/XBSProjectInfo)\n\ntrue";
                };
                FC52866A114795BD0058CCB0 /* Install Files */ = {
                        isa = PBXShellScriptBuildPhase;
 /* End PBXShellScriptBuildPhase section */
 
 /* Begin PBXSourcesBuildPhase section */
-               3FCF60EB1257C272008D8BB1 /* Sources */ = {
-                       isa = PBXSourcesBuildPhase;
-                       buildActionMask = 2147483647;
-                       files = (
-                               3FCF60EC1257C272008D8BB1 /* herror.c in Sources */,
-                               3FCF60ED1257C272008D8BB1 /* res_comp.c in Sources */,
-                               3FCF60F21257C272008D8BB1 /* res_query.c in Sources */,
-                               3FCF60F41257C272008D8BB1 /* getifaddrs.c in Sources */,
-                               3FCF60F51257C272008D8BB1 /* if_indextoname.c in Sources */,
-                               3FCF60F61257C272008D8BB1 /* if_nameindex.c in Sources */,
-                               3FCF60F71257C272008D8BB1 /* if_nametoindex.c in Sources */,
-                               3FCF60FA1257C272008D8BB1 /* ip6opt.c in Sources */,
-                               3FCF60FB1257C272008D8BB1 /* map_v4v6.c in Sources */,
-                               3FCF60FC1257C272008D8BB1 /* rthdr.c in Sources */,
-                               3FCF60FD1257C272008D8BB1 /* vars.c in Sources */,
-                               3FCF610A1257C272008D8BB1 /* membership.c in Sources */,
-                               3FCF610C1257C272008D8BB1 /* getdomainname.c in Sources */,
-                               3FCF610D1257C272008D8BB1 /* getnetgrent.c in Sources */,
-                               3FCF610E1257C272008D8BB1 /* innetgr.c in Sources */,
-                               3FCF610F1257C272008D8BB1 /* setdomainname.c in Sources */,
-                               3FCF61101257C272008D8BB1 /* xdr_domainname.c in Sources */,
-                               3FCF61111257C272008D8BB1 /* xdr_keydat.c in Sources */,
-                               3FCF61121257C272008D8BB1 /* xdr_mapname.c in Sources */,
-                               3FCF61131257C272008D8BB1 /* xdr_peername.c in Sources */,
-                               3FCF61141257C272008D8BB1 /* xdr_valdat.c in Sources */,
-                               3FCF61151257C272008D8BB1 /* xdr_ypbind_binding.c in Sources */,
-                               3FCF61161257C272008D8BB1 /* xdr_ypbind_resp.c in Sources */,
-                               3FCF61171257C272008D8BB1 /* xdr_ypbind_resptype.c in Sources */,
-                               3FCF61181257C272008D8BB1 /* xdr_ypbind_setdom.c in Sources */,
-                               3FCF61191257C272008D8BB1 /* xdr_ypmaplist.c in Sources */,
-                               3FCF611A1257C272008D8BB1 /* xdr_ypreq_key.c in Sources */,
-                               3FCF611B1257C272008D8BB1 /* xdr_ypreq_nokey.c in Sources */,
-                               3FCF611C1257C272008D8BB1 /* xdr_ypresp_all.c in Sources */,
-                               3FCF611D1257C272008D8BB1 /* xdr_ypresp_key_val.c in Sources */,
-                               3FCF611E1257C272008D8BB1 /* xdr_ypresp_maplist.c in Sources */,
-                               3FCF611F1257C272008D8BB1 /* xdr_ypresp_master.c in Sources */,
-                               3FCF61201257C272008D8BB1 /* xdr_ypresp_order.c in Sources */,
-                               3FCF61211257C272008D8BB1 /* xdr_ypresp_val.c in Sources */,
-                               3FCF61221257C272008D8BB1 /* xdr_ypstat.c in Sources */,
-                               3FCF61231257C272008D8BB1 /* yp_all.c in Sources */,
-                               3FCF61241257C272008D8BB1 /* yp_bind.c in Sources */,
-                               3FCF61251257C272008D8BB1 /* yp_first.c in Sources */,
-                               3FCF61261257C272008D8BB1 /* yp_get_default_domain.c in Sources */,
-                               3FCF61271257C272008D8BB1 /* yp_maplist.c in Sources */,
-                               3FCF61281257C272008D8BB1 /* yp_master.c in Sources */,
-                               3FCF61291257C272008D8BB1 /* yp_order.c in Sources */,
-                               3FCF612A1257C272008D8BB1 /* yperr_string.c in Sources */,
-                               3FCF612B1257C272008D8BB1 /* ypmatch_cache.c in Sources */,
-                               3FCF612C1257C272008D8BB1 /* yppasswdd_xdr.c in Sources */,
-                               3FCF612D1257C272008D8BB1 /* ypprot_err.c in Sources */,
-                               3FCF612E1257C272008D8BB1 /* auth_none.c in Sources */,
-                               3FCF612F1257C272008D8BB1 /* auth_unix.c in Sources */,
-                               3FCF61301257C272008D8BB1 /* authunix_prot.c in Sources */,
-                               3FCF61311257C272008D8BB1 /* bindresvport.c in Sources */,
-                               3FCF61321257C272008D8BB1 /* clnt_generic.c in Sources */,
-                               3FCF61331257C272008D8BB1 /* clnt_perror.c in Sources */,
-                               3FCF61341257C272008D8BB1 /* clnt_raw.c in Sources */,
-                               3FCF61351257C272008D8BB1 /* clnt_simple.c in Sources */,
-                               3FCF61361257C272008D8BB1 /* clnt_tcp.c in Sources */,
-                               3FCF61371257C272008D8BB1 /* clnt_udp.c in Sources */,
-                               3FCF61381257C272008D8BB1 /* get_myaddress.c in Sources */,
-                               3FCF61391257C272008D8BB1 /* getrpcent.c in Sources */,
-                               3FCF613A1257C272008D8BB1 /* getrpcport.c in Sources */,
-                               3FCF613B1257C272008D8BB1 /* pmap_clnt.c in Sources */,
-                               3FCF613C1257C272008D8BB1 /* pmap_getmaps.c in Sources */,
-                               3FCF613D1257C272008D8BB1 /* pmap_getport.c in Sources */,
-                               3FCF613E1257C272008D8BB1 /* pmap_prot.c in Sources */,
-                               3FCF613F1257C272008D8BB1 /* pmap_prot2.c in Sources */,
-                               3FCF61401257C272008D8BB1 /* pmap_rmt.c in Sources */,
-                               3FCF61411257C272008D8BB1 /* pmap_wakeup.c in Sources */,
-                               3FCF61421257C272008D8BB1 /* rpc_callmsg.c in Sources */,
-                               3FCF61431257C272008D8BB1 /* rpc_commondata.c in Sources */,
-                               3FCF61441257C272008D8BB1 /* rpc_dtablesize.c in Sources */,
-                               3FCF61451257C272008D8BB1 /* rpc_prot.c in Sources */,
-                               3FCF61461257C272008D8BB1 /* svc.c in Sources */,
-                               3FCF61471257C272008D8BB1 /* svc_auth.c in Sources */,
-                               3FCF61481257C272008D8BB1 /* svc_auth_unix.c in Sources */,
-                               3FCF61491257C272008D8BB1 /* svc_raw.c in Sources */,
-                               3FCF614A1257C272008D8BB1 /* svc_run.c in Sources */,
-                               3FCF614B1257C272008D8BB1 /* svc_simple.c in Sources */,
-                               3FCF614C1257C272008D8BB1 /* svc_tcp.c in Sources */,
-                               3FCF614D1257C272008D8BB1 /* svc_udp.c in Sources */,
-                               3FCF614E1257C272008D8BB1 /* xdr.c in Sources */,
-                               3FCF614F1257C272008D8BB1 /* xdr_array.c in Sources */,
-                               3FCF61501257C272008D8BB1 /* xdr_float.c in Sources */,
-                               3FCF61511257C272008D8BB1 /* xdr_mem.c in Sources */,
-                               3FCF61521257C272008D8BB1 /* xdr_rec.c in Sources */,
-                               3FCF61531257C272008D8BB1 /* xdr_reference.c in Sources */,
-                               3FCF61541257C272008D8BB1 /* xdr_sizeof.c in Sources */,
-                               3FCF61551257C272008D8BB1 /* xdr_stdio.c in Sources */,
-                               3FCF61561257C272008D8BB1 /* hton.c in Sources */,
-                               3FCF61581257C272008D8BB1 /* rcmd.c in Sources */,
-                               3FCF615D1257C272008D8BB1 /* ether_addr.c in Sources */,
-                               2D31A0FD128074E700D5A84C /* getifmaddrs.c in Sources */,
-                               2D4070B2129354A700FE81ED /* getnameinfo_link.c in Sources */,
-                               2D5DD5D31608E6E80051891A /* configuration_profile.c in Sources */,
-                               3FFC065C167132160007509F /* cache_module.c in Sources */,
-                               3FFC065D167132180007509F /* ds_module.c in Sources */,
-                               3FFC065E1671321B0007509F /* file_module.c in Sources */,
-                               3FFC065F1671321E0007509F /* ils.c in Sources */,
-                               3FFC0660167132270007509F /* kvbuf.c in Sources */,
-                               3FFC0661167132270007509F /* libinfo.c in Sources */,
-                               3FFC0662167132270007509F /* mdns_module.c in Sources */,
-                               3FFC0663167132270007509F /* search_module.c in Sources */,
-                               3FFC0664167132270007509F /* si_data.c in Sources */,
-                               3FFC0665167132270007509F /* si_getaddrinfo.c in Sources */,
-                               3FFC0666167132270007509F /* si_module.c in Sources */,
-                               3FFC0667167132270007509F /* thread_data.c in Sources */,
-                       );
-                       runOnlyForDeploymentPostprocessing = 0;
-               };
                D2AAC0610554660B00DB518D /* Sources */ = {
                        isa = PBXSourcesBuildPhase;
                        buildActionMask = 2147483647;
                };
 /* End PBXSourcesBuildPhase section */
 
+/* Begin PBXTargetDependency section */
+               3F397F82185BD71900987BCC /* PBXTargetDependency */ = {
+                       isa = PBXTargetDependency;
+                       target = D2AAC0620554660B00DB518D /* Libinfo */;
+                       targetProxy = 3F397F81185BD71900987BCC /* PBXContainerItemProxy */;
+               };
+/* End PBXTargetDependency section */
+
 /* Begin XCBuildConfiguration section */
                1DEB914C08733D8E0010E9CD /* Release */ = {
                        isa = XCBuildConfiguration;
+                       baseConfigurationReference = 3F397F7D185BD67F00987BCC /* Libinfo.xcconfig */;
                        buildSettings = {
-                               EXECUTABLE_PREFIX = libsystem_;
-                               GCC_PREPROCESSOR_DEFINITIONS = (
-                                       "__DARWIN_NON_CANCELABLE=1",
-                                       "__MigTypeCheck=1",
-                                       "INET6=1",
-                               );
-                               "GCC_PREPROCESSOR_DEFINITIONS[sdk=iphone*][arch=*]" = (
-                                       CONFIG_IPHONE,
-                                       "$(GCC_PREPROCESSOR_DEFINITIONS)",
-                               );
-                               "GCC_PREPROCESSOR_DEFINITIONS[sdk=macosx*][arch=*]" = (
-                                       CONFIG_MAC,
-                                       DS_AVAILABLE,
-                                       SYNTH_ROOTFS,
-                                       "$(GCC_PREPROCESSOR_DEFINITIONS)",
-                               );
-                               INSTALLHDRS_SCRIPT_PHASE = YES;
-                               INSTALL_PATH = /usr/lib/system;
-                               LINK_WITH_STANDARD_LIBRARIES = NO;
-                               ORDER_FILE = "$(SDKROOT)/$(APPLE_INTERNAL_DIR)/OrderFiles/libsystem_info.order";
-                               OTHER_LDFLAGS = (
-                                       "-Wl,-umbrella,System",
-                                       "-L/usr/lib/system",
-                                       "-lcompiler_rt",
-                                       "-ldispatch",
-                                       "-ldyld",
-                                       "-llaunch",
-                                       "-lsystem_asl",
-                                       "-lsystem_blocks",
-                                       "-lsystem_dnssd",
-                                       "-lsystem_kernel",
-                                       "-lsystem_notify",
-                                       "-lsystem_malloc",
-                                       "-lsystem_platform",
-                                       "-lsystem_pthread",
-                                       "-lsystem_c",
-                                       "-lxpc",
-                                       "-Wl,-upward-lsystem_network",
-                               );
                                PRODUCT_NAME = info;
                                VERSION_INFO_EXPORT_DECL = static;
                                VERSION_INFO_PREFIX = __;
                        };
                        name = Release;
                };
-               3FCF61611257C272008D8BB1 /* Release */ = {
+               3F397F80185BD71500987BCC /* Release */ = {
                        isa = XCBuildConfiguration;
                        buildSettings = {
-                               EXECUTABLE_PREFIX = libsystem_sim_;
-                               GCC_PREPROCESSOR_DEFINITIONS = (
-                                       "__DARWIN_NON_CANCELABLE=1",
-                                       "__MigTypeCheck=1",
-                                       "INET6=1",
-                               );
-                               "GCC_PREPROCESSOR_DEFINITIONS[sdk=iphone*][arch=*]" = (
-                                       CONFIG_IPHONE,
-                                       "$(GCC_PREPROCESSOR_DEFINITIONS)",
-                               );
-                               "GCC_PREPROCESSOR_DEFINITIONS[sdk=macosx*][arch=*]" = (
-                                       CONFIG_MAC,
-                                       DS_AVAILABLE,
-                                       SYNTH_ROOTFS,
-                                       "$(GCC_PREPROCESSOR_DEFINITIONS)",
-                               );
-                               INSTALLHDRS_SCRIPT_PHASE = YES;
-                               INSTALL_PATH = "$(SDKROOT)/usr/lib/system";
-                               LINK_WITH_STANDARD_LIBRARIES = NO;
-                               OTHER_LDFLAGS = (
-                                       "-Wl,-umbrella,System",
-                                       "-Wl,-upward-lSystem",
-                               );
-                               PRODUCT_NAME = info;
-                               VERSION_INFO_EXPORT_DECL = static;
-                               VERSION_INFO_PREFIX = __;
+                               PRODUCT_NAME = "$(TARGET_NAME)";
                        };
                        name = Release;
                };
                        defaultConfigurationIsVisible = 0;
                        defaultConfigurationName = Release;
                };
-               3FCF61601257C272008D8BB1 /* Build configuration list for PBXNativeTarget "Libinfo_Sim" */ = {
+               3F397F7F185BD71500987BCC /* Build configuration list for PBXAggregateTarget "Libinfo_Sim" */ = {
                        isa = XCConfigurationList;
                        buildConfigurations = (
-                               3FCF61611257C272008D8BB1 /* Release */,
+                               3F397F80185BD71500987BCC /* Release */,
                        );
                        defaultConfigurationIsVisible = 0;
-                       defaultConfigurationName = Release;
                };
 /* End XCConfigurationList section */
        };
index f49e25804e559992121c580688d87c44bec69842..92bc1a1093a12a1e3e47c07057443903743620fa 100644 (file)
@@ -44,8 +44,6 @@ static  char sccsid[] = "@(#)ether_addr.c     1.2 88/05/10 4.0NFSSRC; from 1.9 88/02
 #include <netinet/in.h>
 #include <netinet/if_ether.h>
 
-static const char ethers[] = "/etc/ethers";
-
 /*
  * Parses a line from /etc/ethers into its components.  The line has the form
  * 8:0:20:1:17:c8      krypton
index 1f62e84254c78d373c165a0a53a95b7ecd7cb7d8..95c9adb9bc0ad097aeab5be3272c2a4bd43a695b 100644 (file)
@@ -37,6 +37,7 @@
 #include <sys/stat.h>
 #include <ils.h>
 #include <dispatch/dispatch.h>
+#include <TargetConditionals.h>
 
 /* notify SPI */
 uint32_t notify_peek(int token, uint32_t *val);
@@ -348,6 +349,11 @@ _fsi_validate(si_mod_t *si, int cat, uint64_t va, uint64_t vb)
 
        if (si == NULL) return 0;
 
+#if TARGET_OS_EMBEDDED
+       /* /etc is on a read-only filesystem, so no validation is required */
+       return 1;
+#endif
+
        pp = (file_si_private_t *)si->private;
        if (pp == NULL) return 0;
 
@@ -2354,7 +2360,7 @@ si_module_static_file(void)
                        for (i = 0; i < VALIDATION_COUNT; i++) pp->notify_token[i] = -1;
 
                        /* hardwired for now, but we may want to make this configurable someday */
-                       pp->validation_notify_mask = VALIDATION_MASK_HOSTS | VALIDATION_MASK_SERVICES;
+                       pp->validation_notify_mask = VALIDATION_MASK_HOSTS | VALIDATION_MASK_SERVICES | VALIDATION_MASK_PROTOCOLS;
                }
 
                si.private = pp;
index f0683425e5537f041b0dc15f98f4bd2a563aaf57..abdbc09b8d5063ca57014048dc6066bbb9ef9af9 100644 (file)
@@ -335,7 +335,7 @@ is released by the
 function.
 The
 .Fa ai
-pointer should be a
+pointer should be an
 .Li addrinfo
 structure created by a call to
 .Fn getaddrinfo .
index 299267b3eb68110fe759eb96101f45c2aebca32c..f8741b4e884d2637c8cf89cccc58294aed5f56c4 100644 (file)
 .\"     @(#)getfsent.3 8.1 (Berkeley) 6/4/93
 .\" $FreeBSD: src/lib/libc/gen/getfsent.3,v 1.17 2007/01/09 00:27:53 imp Exp $
 .\"
+.\" @APPLE_LICENSE_HEADER_START@
+.\"
+.\" Portions Copyright (c) 2003-2013 Apple Inc.  All Rights Reserved.
+.\"
+.\" This file contains Original Code and/or Modifications of Original Code
+.\" as defined in and that are subject to the Apple Public Source License
+.\" Version 2.0 (the 'License'). You may not use this file except in
+.\" compliance with the License. Please obtain a copy of the License at
+.\" http://www.opensource.apple.com/apsl/ and read it before using this
+.\" file.
+.\"
+.\" The Original Code and all software distributed under the License are
+.\" distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+.\" EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+.\" INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+.\" FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+.\" Please see the License for the specific language governing rights and
+.\" limitations under the License.
+.\"
+.\" @APPLE_LICENSE_HEADER_END@
+.\"
 .Dd April 7, 2003
 .Dt GETFSENT 3
 .Os
@@ -39,7 +60,7 @@
 .Nm endfsent
 .Nd get file system descriptor file entry
 .Sh LIBRARY
-.Lb libc
+Standard system libraries.
 .Sh SYNOPSIS
 .In fstab.h
 .Ft "struct fstab *"
@@ -64,9 +85,11 @@ and
 .Fn getfsfile
 functions
 each return a pointer to an object with the following structure
-containing the broken-out fields of a line in the file system
-description file,
-.In fstab.h .
+containing file system descriptions from the directory systems
+consulted by the
+.Nm opendirectoryd
+daemon.
+This will include records from the local /etc/fstab file.
 .Bd -literal -offset indent
 struct fstab {
        char    *fs_spec;       /* block special device name */
@@ -83,41 +106,28 @@ The fields have meanings described in
 .Xr fstab 5 .
 .Pp
 The
-.Fn setfsent
-function
-opens the file (closing any previously opened file) or rewinds it
-if it is already open.
-.Pp
-The
-.Fn endfsent
-function
-closes the file.
-.\".Pp
-.\"The
-.\".Fn setfstab
-.\"function sets the file to be used by subsequent operations.
-.\"The value set by
-.\".Fn setfstab
-.\"does not persist across calls to
-.\".Fn endfsent .
-.\".Pp
-.\"The
-.\".Fn getfstab
-.\"function returns the name of the file that will be used.
-.Pp
-The
 .Fn getfsspec
 and
 .Fn getfsfile
 functions
-search the entire file (opening it if necessary) for a matching special
+search in available directory services for a matching special
 file name or file system file name.
 .Pp
 For programs wishing to read the entire database,
 .Fn getfsent
-reads the next entry (opening the file if necessary).
+searches all available directory services on it's first invocation.
+It caches the returned entries in a list
+and returns fstab entries one at a time.
 .Pp
-All entries in the file with a type field equivalent to
+The
+.Fn setfsent
+and
+.Fn endfsent
+functions clear the cached results from a previous
+.Fn getfsent 
+call.
+.Pp
+Entries in the /etc/fstab file with a type field equivalent to
 .Dv FSTAB_XX
 are ignored.
 .Sh RETURN VALUES
@@ -140,26 +150,13 @@ The
 .Fn endfsent
 function
 returns nothing.
-.\".Sh ENVIRONMENT
-.\".Bl -tag -width ".Ev PATH_FSTAB"
-.\".It Ev PATH_FSTAB
-.\"If the environment variable
-.\".Ev PATH_FSTAB
-.\"is set, all operations are performed against the specified file.
-.\".Ev PATH_FSTAB
-.\"will not be honored if the process environment or memory address space is
-.\"considered
-.\".Dq tainted .
-.\"(See
-.\".Xr issetugid 2
-.\"for more information.)
-.\".El
 .Sh FILES
 .Bl -tag -width /etc/fstab -compact
 .It Pa /etc/fstab
 .El
 .Sh SEE ALSO
-.Xr fstab 5
+.Xr opendirectoryd 8 ,
+.Xr fstab 5 .
 .Sh HISTORY
 The
 .Fn getfsent
@@ -173,17 +170,7 @@ and
 .Fn setfsent
 functions appeared in
 .Bx 4.3 .
-.\".Bx 4.3 ;
-.\"the
-.\".Fn setfstab
-.\"and
-.\".Fn getfstab
-.\"functions appeared in
-.\".Fx 5.1 .
 .Sh BUGS
 The data space used by
 these functions is thread-specific; if future use requires the data, it should be
 copied before any subsequent calls to these functions overwrite it.
-.\"These functions use static data storage;
-.\"if the data is needed for future use, it should be
-.\"copied before any subsequent calls overwrite it.
index adad337cd965522b023e60a77a0ae8a143b4d3aa..14b13931f67827c9126bb173d70b185f4eab278d 100644 (file)
 .\"     From: @(#)getgrent.3   8.2 (Berkeley) 4/19/94
 .\" $FreeBSD: src/lib/libc/gen/getgrent.3,v 1.28 2007/01/09 00:27:53 imp Exp $
 .\"
+.\" @APPLE_LICENSE_HEADER_START@
+.\"
+.\" Portions Copyright (c) 2003-2013 Apple Inc.  All Rights Reserved.
+.\"
+.\" This file contains Original Code and/or Modifications of Original Code
+.\" as defined in and that are subject to the Apple Public Source License
+.\" Version 2.0 (the 'License'). You may not use this file except in
+.\" compliance with the License. Please obtain a copy of the License at
+.\" http://www.opensource.apple.com/apsl/ and read it before using this
+.\" file.
+.\"
+.\" The Original Code and all software distributed under the License are
+.\" distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+.\" EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+.\" INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+.\" FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+.\" Please see the License for the specific language governing rights and
+.\" limitations under the License.
+.\"
+.\" @APPLE_LICENSE_HEADER_END@
+.\"
 .Dd October 26, 2011
 .Dt GETGRENT 3
 .Os
@@ -45,7 +66,7 @@
 .Nm endgrent
 .Nd group database operations
 .Sh LIBRARY
-.Lb libc
+Standard system libraries.
 .Sh SYNOPSIS
 .In grp.h
 .In uuid/uuid.h
@@ -115,7 +136,7 @@ does not contain group UUIDs.
 The UUID for a group may be found using
 .Fn mbr_gid_to_uuid .
 .Pp
-On Mac OS X, these routines are thread-safe and return a pointer to a
+On OS X, these routines are thread-safe and return a pointer to a
 thread-specific data structure.  The contents of this data
 structure are automatically released by subsequent calls to
 any of these routines on the same thread, or when the thread exits.
@@ -128,8 +149,18 @@ variants detailed below.
 The
 .Fn getgrent
 function
-sequentially reads the group database and is intended for programs
-that wish to step through the complete list of groups.
+searches all available directory services on it's first invocation.
+It caches the returned entries in a list
+and returns group entries one at a time.
+.Pp
+.Em NOTE
+that 
+.Fn getgrent
+may cause a very lengthy search for group records by
+.Nm opendirectoryd
+and may result in a large number of group records being cached
+by the calling process.
+Use of this function is not advised.
 .Pp
 The functions
 .Fn getgrnam_r , 
@@ -164,30 +195,23 @@ These functions will open the group file for reading, if necessary.
 .Pp
 The
 .Fn setgroupent
-function
-opens the file, or rewinds it if it is already open.
-If
-.Fa stayopen
-is non-zero, file descriptors are left open, significantly speeding
-functions subsequent calls.
-This functionality is unnecessary for
+function causes
 .Fn getgrent
-as it does not close its file descriptors by default.
-It should also
-be noted that it is dangerous for long-running programs to use this
-functionality as the group file may be updated.
-.Pp
+to ``rewind'' to the beginning of the list of entries cached by a previous
+.Fn getgrent
+call.
+The cache is not cleared.
 The
-.Fn setgrent
-function
-is identical to
-.Fn setgroupent
-with an argument of zero.
+.Fa stayopen
+parameter value is unused on OS X.
 .Pp
 The
+.Fn setgrent
+and
 .Fn endgrent
-function
-closes any open files.
+functions clear the cached results from a previous
+.Fn getgrent
+call.
 .Sh RETURN VALUES
 The functions
 .Fn getgrent ,
index fa62c540537e013b60193579f1c9e302d7df29a3..5f48ab3340123adbf8c253d117260685f33cfa6b 100644 (file)
 .\"     @(#)getgrouplist.3     8.1 (Berkeley) 6/9/93
 .\" $FreeBSD: src/lib/libc/gen/getgrouplist.3,v 1.9 2007/01/09 00:27:53 imp Exp $
 .\"
+.\" @APPLE_LICENSE_HEADER_START@
+.\"
+.\" Portions Copyright (c) 2003-2013 Apple Inc.  All Rights Reserved.
+.\"
+.\" This file contains Original Code and/or Modifications of Original Code
+.\" as defined in and that are subject to the Apple Public Source License
+.\" Version 2.0 (the 'License'). You may not use this file except in
+.\" compliance with the License. Please obtain a copy of the License at
+.\" http://www.opensource.apple.com/apsl/ and read it before using this
+.\" file.
+.\"
+.\" The Original Code and all software distributed under the License are
+.\" distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+.\" EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+.\" INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+.\" FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+.\" Please see the License for the specific language governing rights and
+.\" limitations under the License.
+.\"
+.\" @APPLE_LICENSE_HEADER_END@
+.\"
 .Dd June 9, 1993
 .Dt GETGROUPLIST 3
 .Os
 .Sh NAME
 .Nm getgrouplist
-.Nd calculate group access list
+.Nd calculate partial group access list
 .Sh LIBRARY
-.Lb libc
+Standard system libraries.
 .Sh SYNOPSIS
 .In unistd.h
 .Ft int
 .Sh DESCRIPTION
 The
 .Fn getgrouplist
-function reads through the group file and calculates
-the group access list for the user specified in
+function obtains information from
+.Xr opendirectoryd 8
+to construct the group access list for the user specified in
 .Fa name .
 The
 .Fa basegid
 is automatically included in the groups list.
 Typically this value is given as
-the group number from the password file.
+the default group number from the user's account record.
 .Pp
 The resulting group list is returned in the array pointed to by
 .Fa groups .
@@ -65,9 +87,12 @@ the actual number of groups found is returned in
 The
 .Fn getgrouplist
 function
-returns \-1 if the size of the group list is too small to
-hold all the user's groups.
-Here, the group array will be filled with as many groups as will fit.
+returns 0 on success.
+If the size of the group list is too small to
+hold all the user's groups,
+.Fn getgrouplist
+returns \-1 to indicate failure.
+In this case, the group array will be filled with as many groups as will fit.
 .Sh FILES
 .Bl -tag -width /etc/group -compact
 .It Pa /etc/group
@@ -75,19 +100,10 @@ group membership list
 .El
 .Sh SEE ALSO
 .Xr setgroups 2 ,
-.Xr initgroups 3
+.Xr initgroups 3 ,
+.Xr opendirectoryd 8 .
 .Sh HISTORY
 The
 .Fn getgrouplist
 function first appeared in
 .Bx 4.4 .
-.Sh BUGS
-The
-.Fn getgrouplist
-function
-uses the routines based on
-.Xr getgrent 3 .
-If the invoking program uses any of these routines,
-the group structure will
-be overwritten in the call to
-.Fn getgrouplist .
index 792b1ae36dd22c41edd2ee180c6ca7612e295cdb..bf8566eeb1efcd597086978e947ce8f068ba0b11 100644 (file)
 .\"     From: @(#)getpwent.3   8.2 (Berkeley) 12/11/93
 .\" $FreeBSD: src/lib/libc/gen/getpwent.3,v 1.30 2007/01/09 00:27:54 imp Exp $
 .\"
+.\" @APPLE_LICENSE_HEADER_START@
+.\"
+.\" Portions Copyright (c) 2003-2013 Apple Inc.  All Rights Reserved.
+.\"
+.\" This file contains Original Code and/or Modifications of Original Code
+.\" as defined in and that are subject to the Apple Public Source License
+.\" Version 2.0 (the 'License'). You may not use this file except in
+.\" compliance with the License. Please obtain a copy of the License at
+.\" http://www.opensource.apple.com/apsl/ and read it before using this
+.\" file.
+.\"
+.\" The Original Code and all software distributed under the License are
+.\" distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+.\" EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+.\" INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+.\" FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+.\" Please see the License for the specific language governing rights and
+.\" limitations under the License.
+.\"
+.\" @APPLE_LICENSE_HEADER_END@
+.\"
 .Dd October 26, 2011
 .Dt GETPWENT 3
 .Os
@@ -117,7 +138,7 @@ does not contain user UUIDs.
 The UUID for a user may be found using
 .Fn mbr_uid_to_uuid .
 .Pp
-On Mac OS X, these routines are thread-safe and return a pointer to a
+On OS X, these routines are thread-safe and return a pointer to a
 thread-specific data structure.  The contents of this data
 structure are automatically released by subsequent calls to
 any of these routines on the same thread, or when the thread exits.
@@ -130,8 +151,18 @@ variants detailed below.
 The
 .Fn getpwent
 function
-sequentially reads the password database and is intended for programs
-that wish to process the complete list of users.
+searches all available directory services on it's first invocation.
+It caches the returned entries in a list
+and returns user account entries one at a time.
+.Pp
+.Em NOTE
+that 
+.Fn getpwent
+may cause a very lengthy search for user account records by
+.Nm opendirectoryd
+and may result in a large number of user account records being cached
+by the calling process.
+Use of this function is not advised.
 .Pp
 The functions
 .Fn getpwnam_r ,
@@ -167,34 +198,23 @@ will be set to
 .Pp
 The
 .Fn setpassent
-function
-accomplishes two purposes.
-First, it causes
+function causes
 .Fn getpwent
-to ``rewind'' to the beginning of the database.
-Additionally, if
-.Fa stayopen
-is non-zero, file descriptors are left open, significantly speeding
-up subsequent accesses for all of the routines.
-(This latter functionality is unnecessary for
+to ``rewind'' to the beginning of the list of entries cached by a previous
 .Fn getpwent
-as it does not close its file descriptors by default.)
-.Pp
-It is dangerous for long-running programs to keep the file descriptors
-open as the database will become out of date if it is updated while the
-program is running.
-.Pp
+call.
+The cache is not cleared.
 The
-.Fn setpwent
-function
-is identical to
-.Fn setpassent
-with an argument of zero.
+.Fa stayopen
+parameter value is unused on OS X.
 .Pp
 The
+.Fn setpwent
+and
 .Fn endpwent
-function
-closes any open files.
+functions clear the cached results from a previous
+.Fn getpwent
+call.
 .Pp
 .\"These routines have been written to ``shadow'' the password file, e.g.\&
 .\"allow only certain programs to have access to the encrypted password.
index 039b87fd4303220aa6ebe0a8bc2cd543e0362166..492ba65eee6fc061ef09538bba24ea92f467838b 100644 (file)
 .\"     @(#)initgroups.3       8.1 (Berkeley) 6/4/93
 .\" $FreeBSD: src/lib/libc/gen/initgroups.3,v 1.10 2001/10/01 16:08:51 ru Exp $
 .\"
+.\" @APPLE_LICENSE_HEADER_START@
+.\"
+.\" Portions Copyright (c) 2003-2013 Apple Inc.  All Rights Reserved.
+.\"
+.\" This file contains Original Code and/or Modifications of Original Code
+.\" as defined in and that are subject to the Apple Public Source License
+.\" Version 2.0 (the 'License'). You may not use this file except in
+.\" compliance with the License. Please obtain a copy of the License at
+.\" http://www.opensource.apple.com/apsl/ and read it before using this
+.\" file.
+.\"
+.\" The Original Code and all software distributed under the License are
+.\" distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+.\" EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+.\" INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+.\" FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+.\" Please see the License for the specific language governing rights and
+.\" limitations under the License.
+.\"
+.\" @APPLE_LICENSE_HEADER_END@
+.\"
 .Dd June 4, 1993
 .Dt INITGROUPS 3
 .Os
@@ -39,7 +60,7 @@
 .Nm initgroups
 .Nd initialize group access list
 .Sh LIBRARY
-.Lb libc
+Standard system libraries.
 .Sh SYNOPSIS
 .In unistd.h
 .Ft int
 .Sh DESCRIPTION
 The
 .Fn initgroups
-function
-uses the
-.Xr getgrouplist 3
-function to calculate the group access list for the user
+function calculates a group access list for the user
 specified in
 .Fa name .
-This group list is then setup for the current process using
-.Xr setgroups 2 .
+This group list is then saved in the kernel credentials for the current process.
 The
 .Fa basegid
-is automatically included in the groups list.
+is included in the groups list.
 Typically this value is given as
-the group number from the password file.
+the default group associated with the user's account record.
+.Pp
+This function sets at most 16 group IDs in the process credentials.
+This list can be retrieved using the
+.Xr getgroups 2
+function.
+Note that OS X supports group membership in an unlimited number of groups.
+The OS X kernel uses the group list stored in the process credentials only
+as an initial cache.
+Additional group memberships are determined by communication between the operating system and the
+.Nm opendirectoryd
+daemon.
+.Pp
+Processes should not use the group ID numbers from
+.Xr getgroups 2
+to determine a user's group membership.
+The list obtained from
+.Fn getgroups
+may only be a partial list of a user's group membership.
+Membership checks should use the
+.Xr mbr_gid_to_uuid 3 ,
+.Xr mbr_uid_to_uuid 3 ,
+and
+.Xr mbr_check_membership 3
+functions.
 .Sh RETURN VALUES
 The
 .Fn initgroups
 function
-returns \-1 if it was not invoked by the super-user.
+returns 0 on success.
+On failure, this function will return -1 and set
+.Va errno 
+to one of the following values:
+.Bl -tag -width ".Bq Er EFAULT"
+.It Bq Er EPERM
+The caller's effictive UID is not zero.
+.It Bq Er EINVAL
+Internal error, an invalid array size was supplied to the kernel.
+.It Bq Er EFAULT
+Internal error, invalid data was supplied to the kernel.
+.El
 .Sh SEE ALSO
-.Xr setgroups 2 ,
-.Xr getgrouplist 3
+.Xr getgroups 2 ,
+.Xr getgrouplist 3 ,
+.Xr mbr_gid_to_uuid 3 ,
+.Xr mbr_uid_to_uuid 3 ,
+.Xr mbr_check_membership 3 .
 .Sh HISTORY
 The
 .Fn initgroups
 function appeared in
 .Bx 4.2 .
-.Sh BUGS
-The
-.Fn getgrouplist
-function called by
-.Fn initgroups
-uses the routines based on
-.Xr getgrent 3 .
-If the invoking program uses any of these routines,
-the group structure will
-be overwritten in the call to
-.Fn initgroups .
index c9f9dac5eb1115439c876548b251ec542e05ee1b..63890e87b8debf810ef211f59afb65161d5daf5e 100644 (file)
 #define MEDIUM_AAAA_EXTRA 5
 #define LONG_AAAA_EXTRA 10
 
+#define MDNS_DEBUG_FILE "/etc/.mdns_debug"
+#define MDNS_DEBUG_STDOUT 0x00000001
+#define MDNS_DEBUG_STDERR 0x00000002
+#define MDNS_DEBUG_ASL    0x00000004
+#define MDNS_DEBUG_OUT    0x00000007
+#define MDNS_DEBUG_MORE   0x00000010
+
 static int _mdns_debug = 0;
 
 // mutex protects DNSServiceProcessResult and DNSServiceRefDeallocate
@@ -197,6 +204,25 @@ const static uint8_t hexval[128] = {
        0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0,  0           /* 112 - 127 */
 };
 
+static void
+_mdns_debug_message(const char *str, ...)
+{
+       va_list v;
+       char *out = NULL;
+       if ((_mdns_debug & MDNS_DEBUG_OUT) == 0) return;
+
+       va_start(v, str);
+       vasprintf(&out, str, v);
+       if (out == NULL) return;
+
+       if (_mdns_debug & MDNS_DEBUG_STDOUT) fprintf(stdout, "%s", out);
+       if (_mdns_debug & MDNS_DEBUG_STDERR) fprintf(stderr, "%s", out);
+       if (_mdns_debug & MDNS_DEBUG_ASL) asl_log_message(ASL_LEVEL_NOTICE, "%s", out);
+       free(out);
+
+       va_end(v);
+}
+
 static char *
 _mdns_reverse_ipv4(const char *addr)
 {
@@ -717,7 +743,24 @@ _mdns_init(void)
 {
        pthread_atfork(_mdns_atfork_prepare, _mdns_atfork_parent, _mdns_atfork_child);
 
-       _mdns_debug = getenv("RES_DEBUG") != NULL;
+       if (getenv("RES_DEBUG") != NULL) _mdns_debug |= MDNS_DEBUG_STDOUT;
+       int fd = open(MDNS_DEBUG_FILE, O_RDONLY, 0);
+       errno = 0;
+       if (fd >= 0)
+       {
+               int i, n;
+               char c[5];
+               memset(c, 0, sizeof(c));
+               n = read(fd, c, 4);
+
+               for (i = 0; i < n; i++)
+               {
+                       if ((c[i] == 'o') || (c[i] == 'O')) _mdns_debug |= MDNS_DEBUG_STDOUT;
+                       if ((c[i] == 'e') || (c[i] == 'E')) _mdns_debug |= MDNS_DEBUG_STDERR;
+                       if ((c[i] == 'a') || (c[i] == 'A')) _mdns_debug |= MDNS_DEBUG_ASL;
+                       if ((c[i] == 'm') || (c[i] == 'M')) _mdns_debug |= MDNS_DEBUG_MORE;
+               }
+       }
 }
 
 si_mod_t *
@@ -745,7 +788,7 @@ si_module_static_mdns(void)
        };
 
        static dispatch_once_t once;
-       
+
        dispatch_once(&once, ^{
                si.name = strdup("mdns");
                _mdns_init();
@@ -766,7 +809,7 @@ _mdns_parse_domain_name(const uint8_t *data, uint32_t datalen)
        uint32_t len;
        uint32_t domainlen = 0;
        char *domain = NULL;
-       
+
        if ((data == NULL) || (datalen == 0)) return NULL;
 
        // i: index into input data
@@ -1021,7 +1064,8 @@ _mdns_query_start(mdns_query_context_t *ctx, mdns_reply_t *reply, uint8_t *answe
                if (iface2 != 0) iface = iface2;
        }
 
-       if (_mdns_debug) printf(";; mdns query %s %d %d\n", qname, type, class);
+       _mdns_debug_message(";; mdns query %s %d %d [ctx %p]\n", qname, type, class, ctx);
+
        status = DNSServiceQueryRecord(&ctx->sd, flags, iface, qname, type, class, _mdns_query_callback, ctx);
        if (qname != name) free(qname);
        return status;
@@ -1034,30 +1078,45 @@ _mdns_query_start(mdns_query_context_t *ctx, mdns_reply_t *reply, uint8_t *answe
 static int
 _mdns_query_is_complete(mdns_query_context_t *ctx)
 {
+       int complete = 0;
+
+       /* NULL context is an error, but we call it complete */
        if (ctx == NULL) return 1;
-       //if (ctx->flags & kDNSServiceFlagsMoreComing) return 0;
-       if (ctx->last_type != ctx->type) return 0;
+
+       /*
+        * The default is to ignore kDNSServiceFlagsMoreComing, since it has either
+        * never been supported or worked correctly.  MDNS_DEBUG_MORE makes us honor it.
+        */
+       if (ctx->flags & kDNSServiceFlagsMoreComing) {
+               if (_mdns_debug & MDNS_DEBUG_MORE) {
+                       _mdns_debug_message(";; mdns is_complete type %d ctx %p more coming - incomplete\n", ctx->type, ctx);
+                       return 0;
+               }
+       }
+
+       if (ctx->last_type != ctx->type) {
+               _mdns_debug_message(";; mdns is_complete ctx %p type mismatch (%d != %d) - incomplete\n", ctx, ctx->last_type, ctx->type);
+               return 0;
+       }
+
        switch (ctx->type) {
                case ns_t_a:
                case ns_t_aaaa:
-                       if (ctx->host != NULL && ctx->host->addr_count > 0) {
-                               return 1;
-                       }
+                       if (ctx->host != NULL && ctx->host->addr_count > 0) complete = 1;
                        break;
                case ns_t_ptr:
-                       if (ctx->host != NULL && ctx->host->host.h_name != NULL) {
-                               return 1;
-                       }
+                       if (ctx->host != NULL && ctx->host->host.h_name != NULL) complete = 1;
                        break;
                case ns_t_srv:
-                       if (ctx->reply != NULL && ctx->reply->srv != NULL) {
-                               return 1;
-                       }
+                       if (ctx->reply != NULL && ctx->reply->srv != NULL) complete = 1;
                        break;
                default:
-                       return 0;
+                       _mdns_debug_message(";; mdns is_complete unexpected type %d ctx %p\n", ctx->type, ctx);
        }
-       return 0;
+
+       _mdns_debug_message(";; mdns is_complete type %d ctx %p %s%scomplete\n", ctx->type, ctx, (ctx->flags & kDNSServiceFlagsMoreComing) ? "(more coming flag ignored)" : "", (complete == 0) ? " - in" : " - ");
+
+       return complete;
 }
 
 /* _mdns_query_clear
@@ -1076,16 +1135,17 @@ _mdns_query_clear(mdns_query_context_t *ctx)
                        DNSServiceRefDeallocate(ctx->sd);
                }
        }
-       
+
        ctx->sd = NULL;
        ctx->sd_gen = 0;
        ctx->flags = 0;
        ctx->kq = -1;
 
-       if (!complete) {
+       if (complete == 0) {
                _mdns_hostent_clear(ctx->host);
                ctx->anslen = -1;
        }
+
        return complete;
 }
 
@@ -1102,7 +1162,7 @@ _mdns_query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t ifInde
        context->last_type = rrtype;
 
        if (errorCode != kDNSServiceErr_NoError) {
-               if (_mdns_debug) printf(";; [%s %hu %hu]: error %d\n", fullname, rrtype, rrclass, errorCode);
+               _mdns_debug_message(";; [%s %hu %hu]: error %d [ctx %p]\n", fullname, rrtype, rrclass, errorCode, context);
                goto wakeup_kevent;
        }
 
@@ -1160,6 +1220,7 @@ _mdns_query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t ifInde
                                name = _mdns_parse_domain_name(rdata, rdlen);
                                if (!name) malformed = 1;
                                _mdns_hostent_append_alias(context->host, name);
+                               _mdns_debug_message(";; [%s %hu %hu] cname %s [ctx %p]\n", fullname, rrtype, rrclass, name, context);
                                free(name);
                                break;
                        case ns_t_ptr:
@@ -1201,8 +1262,8 @@ _mdns_query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t ifInde
                                malformed = _mdns_debug;
                                break;
                }
-               if (malformed && _mdns_debug) {
-                       printf(";; [%s %hu %hu]: malformed reply\n", fullname, rrtype, rrclass);
+               if (malformed != 0) {
+                       _mdns_debug_message(";; [%s %hu %hu]: malformed reply [ctx %p]\n", fullname, rrtype, rrclass, context);
                        goto wakeup_kevent;
                }
        }
@@ -1212,9 +1273,8 @@ _mdns_query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t ifInde
                uint8_t *cp;
                HEADER *ans;
                size_t buflen = context->ansmaxlen - context->anslen;
-               if (buflen < NS_HFIXEDSZ)
-               {
-                       if (_mdns_debug) printf(";; [%s %hu %hu]: malformed reply\n", fullname, rrtype, rrclass);
+               if (buflen < NS_HFIXEDSZ) {
+                       _mdns_debug_message(";; [%s %hu %hu]: malformed reply (too small) [ctx %p]\n", fullname, rrtype, rrclass, context);
                        goto wakeup_kevent;
                }
 
@@ -1222,7 +1282,7 @@ _mdns_query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t ifInde
 
                n = _mdns_pack_domain_name(fullname, cp, buflen);
                if (n < 0) {
-                       if (_mdns_debug) printf(";; [%s %hu %hu]: name mismatch\n", fullname, rrtype, rrclass);
+                       _mdns_debug_message(";; [%s %hu %hu]: name mismatch [ctx %p]\n", fullname, rrtype, rrclass, context);
                        goto wakeup_kevent;
                }
 
@@ -1230,7 +1290,7 @@ _mdns_query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t ifInde
                // resource name (n), the resource record data (rdlen) and
                // the resource record header (10).
                if (buflen < n + rdlen + 10) {
-                       if (_mdns_debug) printf(";; [%s %hu %hu]: insufficient buffer space for reply\n", fullname, rrtype, rrclass);
+                       _mdns_debug_message(";; [%s %hu %hu]: insufficient buffer space for reply [ctx %p]\n", fullname, rrtype, rrclass, context);
                        goto wakeup_kevent;
                }
 
@@ -1265,7 +1325,7 @@ _mdns_query_callback(DNSServiceRef sdRef, DNSServiceFlags flags, uint32_t ifInde
                context->anslen = (size_t)(cp - context->answer);
        }
 
-       if (_mdns_debug) printf(";; [%s %hu %hu]\n", fullname, rrtype, rrclass);
+       _mdns_debug_message(";; [%s %hu %hu] reply [ctx %p]\n", fullname, rrtype, rrclass, context);
 
 wakeup_kevent:
        // Ping the waiting thread in case this callback was invoked on another
@@ -1273,7 +1333,7 @@ wakeup_kevent:
                struct kevent ev;
                EV_SET(&ev, 1, EVFILT_USER, 0, NOTE_TRIGGER, 0, 0);
                int res = kevent(context->kq, &ev, 1, NULL, 0, NULL);
-               if (res && _mdns_debug) printf(";; kevent EV_TRIGGER: %s\n", strerror(errno));
+               if (res != 0) _mdns_debug_message(";; kevent EV_TRIGGER: %s [ctx %p]\n", strerror(errno), context);
        }
 }
 
@@ -1424,12 +1484,17 @@ _mdns_search(const char *name, int class, int type, const char *interface, DNSSe
                                                                                name, class,
                                                                                (type == 0) ? ns_t_a : type, interface, flags, kq);
                        }
+
                        if (err == 0 && type == 0) {
                                err = _mdns_query_start(&ctx[n_ctx++], reply,
                                                                                answer, anslen,
                                                                                name, class, ns_t_aaaa, interface, flags, kq);
                        }
-                       if (err && _mdns_debug) printf(";; initialization error %d\n", err);
+
+                       if (err != 0) {
+                               _mdns_debug_message(";; initialization error %d\n", err);
+                       }
+
                        // try to reinitialize
                        if (err == kDNSServiceErr_Unknown ||
                                err == kDNSServiceErr_ServiceNotRunning ||
@@ -1456,7 +1521,8 @@ _mdns_search(const char *name, int class, int type, const char *interface, DNSSe
                        if (err != 0 || n != 0) break;
                }
 
-               if (_mdns_debug) printf(";; kevent timeout %ld.%ld\n", timeout.tv_sec, timeout.tv_nsec);
+               _mdns_debug_message(";; set kevent timeout %ld.%ld [ctx %p %p]\n", timeout.tv_sec, timeout.tv_nsec, (n_ctx > 0) ? &(ctx[0]) : NULL, (n_ctx > 1) ? &(ctx[1]) : NULL);
+
                n = kevent(kq, NULL, 0, &ev, 1, &timeout);
                if (n < 0 && errno != EINTR) {
                        res = -1;
@@ -1474,7 +1540,7 @@ _mdns_search(const char *name, int class, int type, const char *interface, DNSSe
                        err = DNSServiceProcessResult(_mdns_sdref);
                        if (err == kDNSServiceErr_ServiceNotRunning ||
                            err == kDNSServiceErr_BadReference) {
-                               if (_mdns_debug) printf(";; DNSServiceProcessResult status %d\n", err);
+                               _mdns_debug_message(";; DNSServiceProcessResult status %d [ctx %p %p]\n", err, (n_ctx > 0) ? &(ctx[0]) : NULL, (n_ctx > 1) ? &(ctx[1]) : NULL);
                                err = 0;
                                // re-initialize the shared connection
                                _mdns_generation++;
@@ -1487,22 +1553,25 @@ _mdns_search(const char *name, int class, int type, const char *interface, DNSSe
                // Check if all queries are complete (including errors)
                complete = 1;
                for (i = 0; i < n_ctx; ++i) {
-                       if (_mdns_query_is_complete(&ctx[i]) || ctx[i].error != 0) {
+                       if ((ctx[i].error != 0) || _mdns_query_is_complete(&ctx[i])) {
                                if (ctx[i].type == ns_t_a) {
                                        got_a_response = GOT_DATA;
                                        if (ctx[i].error != 0) got_a_response = GOT_ERROR;
                                }
+                               _mdns_debug_message(";; [%s %d %d] finished processing ctx %p\n", name, class, type, &(ctx[i]));
+
                        } else {
+                               _mdns_debug_message(";; [%s %d %d] continuing ctx %p\n", name, class, type, &(ctx[i]));
                                complete = 0;
                        }
                }
                pthread_mutex_unlock(&_mdns_mutex);
 
                if (err != 0) {
-                       if (_mdns_debug) printf(";; DNSServiceProcessResult status %d\n", err);
+                       _mdns_debug_message(";; DNSServiceProcessResult error status %d [ctx %p %p]\n", err, (n_ctx > 0) ? &(ctx[0]) : NULL, (n_ctx > 1) ? &(ctx[1]) : NULL);
                        break;
                } else if (complete == 1) {
-                       if (_mdns_debug) printf(";; done\n");
+                       _mdns_debug_message(";; [%s %d %d] done [ctx %p %p]\n", name, class, type, (n_ctx > 0) ? &(ctx[0]) : NULL, (n_ctx > 1) ? &(ctx[1]) : NULL);
                        break;
                } else if (got_a_response != 0) {
                        // got A, adjust deadline for AAAA
@@ -1534,7 +1603,7 @@ _mdns_search(const char *name, int class, int type, const char *interface, DNSSe
                        // check that delta doesn't exceed our total timeout
                        _mdns_sub_time(&tn, &timeout, &delta);
                        if (tn.tv_sec >= 0) {
-                               if (_mdns_debug) printf(";; new timeout (waiting for AAAA) %ld.%ld\n", delta.tv_sec, delta.tv_nsec);
+                               _mdns_debug_message(";; new timeout [%s %d %d] (waiting for AAAA) %ld.%ld [ctx %p %p]\n", name, class, type, delta.tv_sec, delta.tv_nsec, (n_ctx > 0) ? &(ctx[0]) : NULL, (n_ctx > 1) ? &(ctx[1]) : NULL);
                                _mdns_deadline(&finish, &delta);
                        }
                }
@@ -1544,7 +1613,7 @@ _mdns_search(const char *name, int class, int type, const char *interface, DNSSe
 
                // check for time remaining
                if (timeout.tv_sec < 0) {
-                       if (_mdns_debug) printf(";; timeout\n");
+                       _mdns_debug_message(";; [%s %d %d] timeout [ctx %p %p]\n", name, class, type, (n_ctx > 0) ? &(ctx[0]) : NULL, (n_ctx > 1) ? &(ctx[1]) : NULL);
                        break;
                }
        }
index cec58345cd5b0530efbfa2c5575d12c610931137..5dbc940abb2a7b1d2487fc5213d893419128c2d5 100644 (file)
 .\"     from: @(#)yp.8 1.0 (deraadt) 4/26/93
 .\" $FreeBSD: src/share/man/man8/yp.8,v 1.36 2005/01/21 08:36:40 ru Exp $
 .\"
+.\" @APPLE_LICENSE_HEADER_START@
+.\"
+.\" Portions Copyright (c) 2003-2013 Apple Inc.  All Rights Reserved.
+.\"
+.\" This file contains Original Code and/or Modifications of Original Code
+.\" as defined in and that are subject to the Apple Public Source License
+.\" Version 2.0 (the 'License'). You may not use this file except in
+.\" compliance with the License. Please obtain a copy of the License at
+.\" http://www.opensource.apple.com/apsl/ and read it before using this
+.\" file.
+.\"
+.\" The Original Code and all software distributed under the License are
+.\" distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+.\" EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
+.\" INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
+.\" FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+.\" Please see the License for the specific language governing rights and
+.\" limitations under the License.
+.\"
+.\" @APPLE_LICENSE_HEADER_END@
+.\"
 .Dd April 5, 1993
 .Dt YP 8
 .Os
 .Sh DESCRIPTION
 The
 .Nm YP
-subsystem allows network management of passwd, group, netgroup, hosts,
-services, rpc, bootparams and ethers file
-entries through the functions
+subsystem allows network access to directory information hosted by
+.Tn NIS
+servers.
+OS X support is provided through the functions
 .Xr getpwent 3 ,
 .Xr getgrent 3 ,
+.Xr getfsent 3 ,
 .Xr getnetgrent 3 ,
 .Xr gethostent 3 ,
 .Xr getnetent 3 ,
 .Xr getrpcent 3 ,
-and
-.Xr ethers 3 .
-The
-.Xr bootparamd 8
-daemon makes direct
-.Tn NIS
-library calls since there are no
-functions in the standard C library for reading bootparams.
+.Xr getprotoent 3 ,
+.Xr getservent 3 ,
+.Xr ethers 3
+and other related functions.
+Queries to 
+.Tn NIS
+servers are sent by the
+.Nm opendirectoryd
+daemon.
+The configuration of
 .Tn NIS
-support is enabled in
-.Xr nsswitch.conf 5 .
+clients is further described in the
+.Xr opendirectoryd 8
+manual page.
 .Pp
 The
 .Nm YP
@@ -95,15 +121,6 @@ called the
 The databases used to store the information are called
 .Tn NIS
 .Em maps .
-In
-.Fx ,
-these maps are stored in
-.Pa /var/yp/ Ns Aq Ar domainname
-where
-.Aq Ar domainname
-is the name of the
-.Tn NIS
-domain being served.
 A single
 .Tn NIS
 server can
@@ -112,53 +129,6 @@ such directories, one for each supported domain.
 Each domain will have
 its own independent set of maps.
 .Pp
-In
-.Fx ,
-the
-.Tn NIS
-maps are Berkeley DB hashed database files (the
-same format used for the
-.Xr passwd 5
-database files).
-Other operating systems that support
-.Tn NIS
-use old-style
-.Nm ndbm
-databases instead (largely because Sun Microsystems originally based
-their
-.Tn NIS
-implementation on
-.Nm ndbm ,
-and other vendors have simply licensed
-Sun's code rather than design their own implementation with a different
-database format).
-On these systems, the databases are generally split
-into
-.Pa .dir
-and
-.Pa .pag
-files which the
-.Nm ndbm
-code uses to hold separate parts of the hash
-database.
-The Berkeley DB hash method instead uses a single file for
-both pieces of information.
-This means that while you may have
-.Pa passwd.byname.dir
-and
-.Pa passwd.byname.pag
-files on other operating systems (both of which are really parts of the
-same map),
-.Fx
-will have only one file called
-.Pa passwd.byname .
-The difference in format is not significant: only the
-.Tn NIS
-server,
-.Xr ypserv 8 ,
-and related tools need to know the database format of the
-.Tn NIS
-maps.
 Client
 .Tn NIS
 systems receive all
@@ -192,6 +162,10 @@ maps that are periodically
 updated by the master.
 .El
 .Pp
+OS X systems may be configured as
+.Tn NIS
+clients, but not as master or slave servers.
+.Pp
 A
 .Tn NIS
 client establishes what is called a
@@ -253,7 +227,7 @@ back to the client.
 There is a specific set of requests that
 .Xr ypserv 8
 is designed to handle, most of which are implemented as functions
-within the standard C library:
+within the standard system libraries:
 .Bl -tag -width ".Fn yp_master"
 .It Fn yp_order
 check the creation date of a particular map
@@ -293,220 +267,6 @@ but
 these requests are usually generated only by
 .Xr ypbind 8
 and are not meant to be used by standard utilities.
-.Pp
-On networks with a large number of hosts, it is often a good idea to
-use a master server and several slaves rather than just a single master
-server.
-A slave server provides the exact same information as a master
-server: whenever the maps on the master server are updated, the new
-data should be propagated to the slave systems using the
-.Xr yppush 8
-command.
-The
-.Tn NIS
-.Pa Makefile
-.Pq Pa /var/yp/Makefile
-will do this automatically if the administrator comments out the
-line which says
-.Dq Li NOPUSH=true
-.Va ( NOPUSH
-is set to true by default because the default configuration is
-for a small network with only one
-.Tn NIS
-server).
-The
-.Xr yppush 8
-command will initiate a transaction between the master and slave
-during which the slave will transfer the specified maps from the
-master server using
-.Xr ypxfr 8 .
-(The slave server calls
-.Xr ypxfr 8
-automatically from within
-.Xr ypserv 8 ;
-therefore it is not usually necessary for the administrator
-to use it directly.
-It can be run manually if
-desired, however.)
-Maintaining
-slave servers helps improve
-.Tn NIS
-performance on large
-networks by:
-.Bl -bullet
-.It
-Providing backup services in the event that the
-.Tn NIS
-master crashes
-or becomes unreachable
-.It
-Spreading the client load out over several machines instead of
-causing the master to become overloaded
-.It
-Allowing a single
-.Tn NIS
-domain to extend beyond
-a local network (the
-.Xr ypbind 8
-daemon might not be able to locate a server automatically if it resides on
-a network outside the reach of its broadcasts.
-It is possible to force
-.Xr ypbind 8
-to bind to a particular server with
-.Xr ypset 8
-but this is sometimes inconvenient.
-This problem can be avoided simply by
-placing a slave server on the local network.)
-.El
-.Pp
-The
-.Fx
-.Xr ypserv 8
-is specially designed to provide enhanced security (compared to
-other
-.Tn NIS
-implementations) when used exclusively with
-.Fx
-client
-systems.
-The
-.Fx
-password database system (which is derived directly
-from
-.Bx 4.4 )
-includes support for
-.Em "shadow passwords" .
-The standard password database does not contain users' encrypted
-passwords: these are instead stored (along with other information)
-in a separate database which is accessible only by the super-user.
-If the encrypted password database were made available as an
-.Tn NIS
-map, this security feature would be totally disabled, since any user
-is allowed to retrieve
-.Tn NIS
-data.
-.Pp
-To help prevent this,
-.Fx Ns 's
-.Tn NIS
-server handles the shadow password maps
-.Pa ( master.passwd.byname
-and
-.Pa master.passwd.byuid )
-in a special way: the server will only provide access to these
-maps in response to requests that originate on privileged ports.
-Since only the super-user is allowed to bind to a privileged port,
-the server assumes that all such requests come from privileged
-users.
-All other requests are denied: requests from non-privileged
-ports will receive only an error code from the server.
-Additionally,
-.Fx Ns 's
-.Xr ypserv 8
-includes support for
-.An Wietse Venema Ns 's
-tcp wrapper package; with tcp
-wrapper support enabled, the administrator can configure
-.Xr ypserv 8
-to respond only to selected client machines.
-.Pp
-While these enhancements provide better security than stock
-.Tn NIS ,
-they are by no means 100% effective.
-It is still possible for
-someone with access to your network to spoof the server into disclosing
-the shadow password maps.
-.Pp
-On the client side,
-.Fx Ns 's
-.Xr getpwent 3
-functions will automatically search for the
-.Pa master.passwd
-maps and use them if they exist.
-If they do, they will be used, and
-all fields in these special maps (class, password age and account
-expiration) will be decoded.
-If they are not found, the standard
-.Pa passwd
-maps will be used instead.
-.Sh COMPATIBILITY
-When using a
-.No non- Ns Fx
-.Tn NIS
-server for
-.Xr passwd 5
-files, it is unlikely that the default MD5-based format that
-.Fx
-uses for passwords will be accepted by it.
-If this is the case, the value of the
-.Va passwd_format
-setting in
-.Xr login.conf 5
-should be changed to
-.Qq Li des
-for compatibility.
-.Pp
-Some systems, such as
-.Tn SunOS
-4.x, need
-.Tn NIS
-to be running in order
-for their hostname resolution functions
-.Fn ( gethostbyname ,
-.Fn gethostbyaddr ,
-etc.) to work properly.
-On these systems,
-.Xr ypserv 8
-performs
-.Tn DNS
-lookups when asked to return information about
-a host that does not exist in its
-.Pa hosts.byname
-or
-.Pa hosts.byaddr
-maps.
-.Fx Ns 's
-resolver uses
-.Tn DNS
-by default (it can be made to use
-.Tn NIS ,
-if desired), therefore its
-.Tn NIS
-server does not do
-.Tn DNS
-lookups
-by default.
-However,
-.Xr ypserv 8
-can be made to perform
-.Tn DNS
-lookups if it is started with a special
-flag.
-It can also be made to register itself as an
-.Tn NIS
-v1 server
-in order to placate certain systems that insist on the presence of
-a v1 server
-.No ( Fx
-uses only
-.Tn NIS
-v2, but many other systems,
-including
-.Tn SunOS
-4.x, search for both a v1 and v2 server when binding).
-.Fx Ns 's
-.Xr ypserv 8
-does not actually handle
-.Tn NIS
-v1 requests, but this
-.Dq "kludge mode"
-is useful for silencing stubborn systems that search for both
-a v1 and v2 server.
-.Pp
-(Please see the
-.Xr ypserv 8
-manual page for a detailed description of these special features
-and flags.)
 .Sh HISTORY
 The
 .Nm YP
@@ -525,38 +285,7 @@ and
 and is subject to the GNU Public License.
 No Sun code was
 referenced.
-.Sh BUGS
-While
-.Fx
-now has both
-.Tn NIS
-client and server capabilities, it does not yet have support for
-.Xr ypupdated 8
-or the
-.Fn yp_update
-function.
-Both of these require secure
-.Tn RPC ,
-which
-.Fx
-does not
-support yet either.
 .Pp
-The
-.Xr getservent 3
-and
-.Xr getprotoent 3
-functions do not yet have
+OS X
 .Tn NIS
-support.
-Fortunately, these files
-do not need to be updated that often.
-.Pp
-Many more manual pages should be written, especially
-.Xr ypclnt 3 .
-For the time being, seek out a local Sun machine and read the
-manuals for there.
-.Pp
-Neither Sun nor this author have found a clean way to handle
-the problems that occur when ypbind cannot find its server
-upon bootup.
+client software is derived from FreeBSD.
index 36e0744ca34dc1d5c4fa4c17a194be26031985b7..0b86f2bae8cc9e4093e5fbd91858e27999a7b5ac 100644 (file)
@@ -230,12 +230,12 @@ returns a value of 0, and is called with the following arguments:
 .Pp
 .Bd -literal -offset indent
 int foreach (
-       int instatus,
+       unsigned long instatus,
        char *inkey,
        int inkeylen,
        char *inval,
        int invallen,
-       char *indata
+       void *indata
 );
 .Ed
 .Pp
index da89dff56311e331fe228773308cb7dc55fb1814..847e21dd71145a819d34f9026b16c07a325f8dcd 100644 (file)
@@ -90,4 +90,9 @@
 
 #include <netdb.h>
 
+__BEGIN_DECLS
+extern int bindresvport(int, struct sockaddr_in *);
+extern int bindresvport_sa(int, struct sockaddr *);
+__END_DECLS
+
 #endif /* !_RPC_RPC_H */
diff --git a/xcodescripts/Libinfo.xcconfig b/xcodescripts/Libinfo.xcconfig
new file mode 100644 (file)
index 0000000..ad31df8
--- /dev/null
@@ -0,0 +1,50 @@
+#include "<DEVELOPER_DIR>/AppleInternal/XcodeConfig/SimulatorSupport.xcconfig"
+
+INSTALLHDRS_SCRIPT_PHASE = YES
+
+GCC_PREPROCESSOR_DEFINITIONS = __DARWIN_NON_CANCELABLE=1 __MigTypeCheck=1 INET6=1
+GCC_PREPROCESSOR_DEFINITIONS[sdk=iphone*] = CONFIG_IPHONE $(GCC_PREPROCESSOR_DEFINITIONS)
+GCC_PREPROCESSOR_DEFINITIONS[sdk=macosx*] = CONFIG_MAC DS_AVAILABLE SYNTH_ROOTFS $(GCC_PREPROCESSOR_DEFINITIONS)
+
+INSTALL_PATH_ACTUAL = /usr/lib/system
+INSTALL_PATH[sdk=macosx*] = $(INSTALL_PATH_ACTUAL)
+
+EXECUTABLE_PREFIX = libsystem_
+EXECUTABLE_PREFIX[sdk=iphonesimulator*] = libsystem_sim_
+
+ORDER_FILE[sdk=macosx*] = $(SDKROOT)/$(APPLE_INTERNAL_DIR)/OrderFiles/libsystem_info.order
+ORDER_FILE[sdk=iphoneos*] = $(SDKROOT)/$(APPLE_INTERNAL_DIR)/OrderFiles/libsystem_info.order
+
+LINK_WITH_STANDARD_LIBRARIES = NO
+
+LIBCOMPILER_RT_LDFLAGS = -lcompiler_rt
+LIBCOMPILER_RT_LDFLAGS[sdk=iphonesimulator*] = -lcompiler_rt_sim
+LIBMALLOC_LDFLAGS = -lsystem_malloc
+LIBMALLOC_LDFLAGS[sdk=iphonesimulator*] = -Wl,-upward-lSystem
+LIBPLATFORM_LDFLAGS = -lsystem_platform
+LIBPLATFORM_LDFLAGS[sdk=iphonesimulator*] = -Wl,-upward-lSystem
+LIBPTHREAD_LDFLAGS = -lsystem_pthread
+LIBPTHREAD_LDFLAGS[sdk=iphonesimulator*] = -Wl,-upward-lSystem
+LIBSYSCALL_LDFLAGS = -lsystem_kernel
+LIBSYSCALL_LDFLAGS[sdk=iphonesimulator*] = -Wl,-upward-lSystem
+LIBM_LDFLAGS = -lsystem_m
+LIBM_LDFLAGS[sdk=iphonesimulator*] = -lsystem_sim_m
+LIBDYLD_LDFLAGS = -ldyld
+LIBDYLD_LDFLAGS[sdk=iphonesimulator*] = -ldyld_sim
+LIBC_LDFLAGS = -lsystem_c
+LIBC_LDFLAGS[sdk=iphonesimulator*] = -lsystem_sim_c
+LIBDISPATCH_LDFLAGS = -ldispatch
+LIBLAUNCH_LDFLAGS = -llaunch
+LIBLAUNCH_LDFLAGS[sdk=iphonesimulator*] =
+LIBASL_LDFLAGS = -lsystem_asl
+LIBASL_LDFLAGS[sdk=iphonesimulator*] = -lsystem_sim_asl
+LIBBLOCKS_LDFLAGS = -lsystem_blocks
+LIBBLOCKS_LDFLAGS[sdk=iphonesimulator*] = -lsystem_sim_blocks
+LIBDNSD_LDFLAGS = -lsystem_dnssd
+LIBDNSD_LDFLAGS[sdk=iphonesimulator*] = -lsystem_sim_dnssd
+LIBNOTIFY_LDFLAGS = -lsystem_notify
+LIBNOTIFY_LDFLAGS[sdk=iphonesimulator*] = -lnotify_sim
+LIBXPC_LDFLAGS = -lxpc
+LIBNETWORK_LDFLAGS = -Wl,-upward-lsystem_network
+
+OTHER_LDFLAGS = -all_load -umbrella System -L/usr/lib/system $(LIBCOMPILER_RT_LDFLAGS) $(LIBDYLD_LDFLAGS) $(LIBSYSCALL_LDFLAGS) $(LIBMALLOC_LDFLAGS) $(LIBPLATFORM_LDFLAGS) $(LIBPTHREAD_LDFLAGS) $(LIBC_LDFLAGS) $(LIBDISPATCH_LDFLAGS) $(LIBLAUNCH_LDFLAGS) $(LIBASL_LDFLAGS) $(LIBBLOCKS_LDFLAGS) $(LIBDNSD_LDFLAGS) $(LIBNOTIFY_LDFLAGS) $(LIBXPC_LDFLAGS) $(LIBNETWORK_LDFLAGS)
index 8ed2fc196b57fca6820a25c840ef376c150ab9f4..85d1a7dfe405e11e0cce5fa9be35c50accc1c502 100755 (executable)
@@ -1,19 +1,8 @@
 # exit immediately on failure
 set -e -x
 
-# check if we're building for the simulator
-if [ "${RC_ProjectName%_Sim}" != "${RC_ProjectName}" ] ; then
-       if [ -d ${DSTROOT}${SDKROOT}/usr/lib/system ] ; then
-               for lib in ${DSTROOT}${SDKROOT}/usr/lib/system/*.dylib ; do
-                       install_name_tool -id "${lib#${DSTROOT}${SDKROOT}}" "${lib}"
-               done
-       fi
-
-       DSTROOT="${DSTROOT}${SDKROOT}"
-fi
-
 function InstallHeaders() {
-       DESTDIR="$DSTROOT/$1"
+       DESTDIR="$DSTROOT/$INSTALL_PATH_PREFIX/$1"
        shift
        install -d -o "$INSTALL_OWNER" -g "$INSTALL_GROUP" -m 0755 "$DESTDIR"
        install -o "$INSTALL_OWNER" -g "$INSTALL_GROUP" -m 0444 "$@" "$DESTDIR"