jdk/make/java/nio/Makefile
changeset 2057 3acf8e5e2ca0
parent 1713 f8b8bfa64fc1
child 2913 39a9cc073b84
equal deleted inserted replaced
2056:115e09b7a004 2057:3acf8e5e2ca0
     1 #
     1 #
     2 # Copyright 2000-2008 Sun Microsystems, Inc.  All Rights Reserved.
     2 # Copyright 2000-2009 Sun Microsystems, Inc.  All Rights Reserved.
     3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4 #
     4 #
     5 # This code is free software; you can redistribute it and/or modify it
     5 # This code is free software; you can redistribute it and/or modify it
     6 # under the terms of the GNU General Public License version 2 only, as
     6 # under the terms of the GNU General Public License version 2 only, as
     7 # published by the Free Software Foundation.  Sun designates this
     7 # published by the Free Software Foundation.  Sun designates this
    54 	sun/nio/ch/DevPollArrayWrapper.java \
    54 	sun/nio/ch/DevPollArrayWrapper.java \
    55 	sun/nio/ch/DevPollSelectorImpl.java \
    55 	sun/nio/ch/DevPollSelectorImpl.java \
    56         sun/nio/ch/DevPollSelectorProvider.java \
    56         sun/nio/ch/DevPollSelectorProvider.java \
    57 	sun/nio/ch/InheritedChannel.java \
    57 	sun/nio/ch/InheritedChannel.java \
    58         sun/nio/ch/PollSelectorProvider.java \
    58         sun/nio/ch/PollSelectorProvider.java \
    59         sun/nio/ch/PollSelectorImpl.java
    59         sun/nio/ch/PollSelectorImpl.java \
       
    60 	sun/nio/ch/Port.java \
       
    61 	sun/nio/ch/SimpleAsynchronousFileChannelImpl.java \
       
    62 	sun/nio/ch/SolarisAsynchronousChannelProvider.java \
       
    63 	sun/nio/ch/SolarisEventPort.java \
       
    64 	sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java \
       
    65 	sun/nio/ch/UnixAsynchronousSocketChannelImpl.java \
       
    66 	\
       
    67 	sun/nio/fs/GnomeFileTypeDetector.java \
       
    68 	sun/nio/fs/PollingWatchService.java \
       
    69 	sun/nio/fs/SolarisAclFileAttributeView.java \
       
    70 	sun/nio/fs/SolarisFileStore.java \
       
    71 	sun/nio/fs/SolarisFileSystem.java \
       
    72 	sun/nio/fs/SolarisFileSystemProvider.java \
       
    73 	sun/nio/fs/SolarisUserDefinedFileAttributeView.java \
       
    74 	sun/nio/fs/SolarisNativeDispatcher.java \
       
    75 	sun/nio/fs/SolarisWatchService.java \
       
    76 	sun/nio/fs/UnixChannelFactory.java \
       
    77 	sun/nio/fs/UnixCopyFile.java \
       
    78 	sun/nio/fs/UnixDirectoryStream.java \
       
    79 	sun/nio/fs/UnixException.java \
       
    80 	sun/nio/fs/UnixFileAttributeViews.java \
       
    81 	sun/nio/fs/UnixFileAttributes.java \
       
    82 	sun/nio/fs/UnixFileKey.java \
       
    83 	sun/nio/fs/UnixFileModeAttribute.java \
       
    84 	sun/nio/fs/UnixFileStore.java \
       
    85 	sun/nio/fs/UnixFileStoreAttributes.java \
       
    86 	sun/nio/fs/UnixFileSystem.java \
       
    87 	sun/nio/fs/UnixFileSystemProvider.java \
       
    88 	sun/nio/fs/UnixMountEntry.java \
       
    89 	sun/nio/fs/UnixNativeDispatcher.java \
       
    90 	sun/nio/fs/UnixPath.java \
       
    91 	sun/nio/fs/UnixSecureDirectoryStream.java \
       
    92 	sun/nio/fs/UnixUriUtils.java \
       
    93 	sun/nio/fs/UnixUserPrincipals.java
    60 
    94 
    61 FILES_c += \
    95 FILES_c += \
    62         DevPollArrayWrapper.c \
    96         DevPollArrayWrapper.c \
    63 	InheritedChannel.c \
    97 	InheritedChannel.c \
    64 	NativeThread.c \
    98 	NativeThread.c \
    65         PollArrayWrapper.c
    99         PollArrayWrapper.c \
       
   100 	SolarisEventPort.c \
       
   101 	UnixAsynchronousServerSocketChannelImpl.c \
       
   102 	UnixAsynchronousSocketChannelImpl.c \
       
   103 	\
       
   104 	GnomeFileTypeDetector.c \
       
   105 	SolarisNativeDispatcher.c \
       
   106 	SolarisWatchService.c \
       
   107 	UnixCopyFile.c \
       
   108 	UnixNativeDispatcher.c
    66 
   109 
    67 FILES_export += \
   110 FILES_export += \
    68 	sun/nio/ch/DevPollArrayWrapper.java \
   111 	sun/nio/ch/DevPollArrayWrapper.java \
    69 	sun/nio/ch/InheritedChannel.java \
   112 	sun/nio/ch/InheritedChannel.java \
    70 	sun/nio/ch/NativeThread.java
   113 	sun/nio/ch/NativeThread.java \
       
   114 	sun/nio/ch/SolarisEventPort.java \
       
   115 	sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java \
       
   116 	sun/nio/ch/UnixAsynchronousSocketChannelImpl.java \
       
   117 	\
       
   118 	sun/nio/fs/GnomeFileTypeDetector.java \
       
   119 	sun/nio/fs/SolarisNativeDispatcher.java \
       
   120 	sun/nio/fs/SolarisWatchService.java \
       
   121 	sun/nio/fs/UnixCopyFile.java \
       
   122 	sun/nio/fs/UnixNativeDispatcher.java
       
   123 
       
   124 FILES_gen += \
       
   125 	sun/nio/fs/SolarisConstants.java \
       
   126 	sun/nio/fs/UnixConstants.java
    71 endif # PLATFORM = solaris
   127 endif # PLATFORM = solaris
    72 
   128 
    73 ifeq ($(PLATFORM), windows)
   129 ifeq ($(PLATFORM), windows)
    74 FILES_java += \
   130 FILES_java += \
       
   131 	sun/nio/ch/Iocp.java \
       
   132 	sun/nio/ch/PendingIoCache.java \
       
   133 	sun/nio/ch/WindowsAsynchronousChannelProvider.java \
       
   134 	sun/nio/ch/WindowsAsynchronousFileChannelImpl.java \
       
   135 	sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.java \
       
   136 	sun/nio/ch/WindowsAsynchronousSocketChannelImpl.java \
    75         sun/nio/ch/WindowsSelectorImpl.java \
   137         sun/nio/ch/WindowsSelectorImpl.java \
    76         sun/nio/ch/WindowsSelectorProvider.java
   138         sun/nio/ch/WindowsSelectorProvider.java \
       
   139 	\
       
   140 	sun/nio/fs/RegistryFileTypeDetector.java \
       
   141 	sun/nio/fs/WindowsAclFileAttributeView.java \
       
   142 	sun/nio/fs/WindowsChannelFactory.java \
       
   143 	sun/nio/fs/WindowsConstants.java \
       
   144 	sun/nio/fs/WindowsDirectoryStream.java \
       
   145 	sun/nio/fs/WindowsException.java \
       
   146 	sun/nio/fs/WindowsFileAttributeViews.java \
       
   147 	sun/nio/fs/WindowsFileAttributes.java \
       
   148 	sun/nio/fs/WindowsFileCopy.java \
       
   149 	sun/nio/fs/WindowsFileStore.java \
       
   150 	sun/nio/fs/WindowsFileSystem.java \
       
   151 	sun/nio/fs/WindowsFileSystemProvider.java \
       
   152 	sun/nio/fs/WindowsLinkSupport.java \
       
   153 	sun/nio/fs/WindowsUserDefinedFileAttributeView.java \
       
   154 	sun/nio/fs/WindowsNativeDispatcher.java \
       
   155 	sun/nio/fs/WindowsPath.java \
       
   156 	sun/nio/fs/WindowsPathParser.java \
       
   157 	sun/nio/fs/WindowsPathType.java \
       
   158 	sun/nio/fs/WindowsSecurity.java \
       
   159 	sun/nio/fs/WindowsSecurityDescriptor.java \
       
   160 	sun/nio/fs/WindowsUriSupport.java \
       
   161 	sun/nio/fs/WindowsUserPrincipals.java \
       
   162 	sun/nio/fs/WindowsWatchService.java
    77 
   163 
    78 FILES_c += \
   164 FILES_c += \
       
   165 	Iocp.c \
       
   166 	RegistryFileTypeDetector.c \
       
   167 	WindowsAsynchronousFileChannelImpl.c \
       
   168 	WindowsAsynchronousServerSocketChannelImpl.c \
       
   169 	WindowsAsynchronousSocketChannelImpl.c \
       
   170 	WindowsNativeDispatcher.c \
    79         WindowsSelectorImpl.c
   171         WindowsSelectorImpl.c
    80 
   172 
    81 FILES_export += \
   173 FILES_export += \
    82 	sun/nio/ch/WindowsSelectorImpl.java
   174 	sun/nio/ch/Iocp.java \
       
   175 	sun/nio/ch/WindowsAsynchronousFileChannelImpl.java \
       
   176 	sun/nio/ch/WindowsAsynchronousServerSocketChannelImpl.java \
       
   177 	sun/nio/ch/WindowsAsynchronousSocketChannelImpl.java \
       
   178 	sun/nio/ch/WindowsSelectorImpl.java \
       
   179 	sun/nio/fs/WindowsNativeDispatcher.java \
       
   180 	sun/nio/fs/RegistryFileTypeDetector.java
    83 endif # PLATFORM = windows
   181 endif # PLATFORM = windows
    84 
   182 
    85 ifeq ($(PLATFORM), linux)
   183 ifeq ($(PLATFORM), linux)
    86 FILES_java += \
   184 FILES_java += \
    87         sun/nio/ch/AbstractPollSelectorImpl.java \
   185         sun/nio/ch/AbstractPollSelectorImpl.java \
       
   186 	sun/nio/ch/EPoll.java \
    88 	sun/nio/ch/EPollArrayWrapper.java \
   187 	sun/nio/ch/EPollArrayWrapper.java \
       
   188 	sun/nio/ch/EPollPort.java \
    89 	sun/nio/ch/EPollSelectorProvider.java \
   189 	sun/nio/ch/EPollSelectorProvider.java \
    90 	sun/nio/ch/EPollSelectorImpl.java \
   190 	sun/nio/ch/EPollSelectorImpl.java \
    91 	sun/nio/ch/InheritedChannel.java \
   191 	sun/nio/ch/InheritedChannel.java \
       
   192 	sun/nio/ch/LinuxAsynchronousChannelProvider.java \
    92         sun/nio/ch/PollSelectorProvider.java \
   193         sun/nio/ch/PollSelectorProvider.java \
    93         sun/nio/ch/PollSelectorImpl.java
   194         sun/nio/ch/PollSelectorImpl.java \
       
   195 	sun/nio/ch/Port.java \
       
   196 	sun/nio/ch/SimpleAsynchronousFileChannelImpl.java \
       
   197 	sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java \
       
   198 	sun/nio/ch/UnixAsynchronousSocketChannelImpl.java \
       
   199 	\
       
   200 	sun/nio/fs/GnomeFileTypeDetector.java \
       
   201 	sun/nio/fs/LinuxDosFileAttributeView.java \
       
   202 	sun/nio/fs/LinuxFileStore.java \
       
   203 	sun/nio/fs/LinuxFileSystem.java \
       
   204 	sun/nio/fs/LinuxFileSystemProvider.java \
       
   205 	sun/nio/fs/LinuxUserDefinedFileAttributeView.java \
       
   206 	sun/nio/fs/LinuxNativeDispatcher.java \
       
   207 	sun/nio/fs/LinuxWatchService.java \
       
   208 	sun/nio/fs/PollingWatchService.java \
       
   209 	sun/nio/fs/UnixChannelFactory.java \
       
   210 	sun/nio/fs/UnixCopyFile.java \
       
   211 	sun/nio/fs/UnixDirectoryStream.java \
       
   212 	sun/nio/fs/UnixException.java \
       
   213 	sun/nio/fs/UnixFileAttributeViews.java \
       
   214 	sun/nio/fs/UnixFileAttributes.java \
       
   215 	sun/nio/fs/UnixFileKey.java \
       
   216 	sun/nio/fs/UnixFileModeAttribute.java \
       
   217 	sun/nio/fs/UnixFileStore.java \
       
   218 	sun/nio/fs/UnixFileStoreAttributes.java \
       
   219 	sun/nio/fs/UnixFileSystem.java \
       
   220 	sun/nio/fs/UnixFileSystemProvider.java \
       
   221 	sun/nio/fs/UnixMountEntry.java \
       
   222 	sun/nio/fs/UnixNativeDispatcher.java \
       
   223 	sun/nio/fs/UnixPath.java \
       
   224 	sun/nio/fs/UnixSecureDirectoryStream.java \
       
   225 	sun/nio/fs/UnixUriUtils.java \
       
   226 	sun/nio/fs/UnixUserPrincipals.java
    94 
   227 
    95 FILES_c += \
   228 FILES_c += \
       
   229 	EPoll.c \
    96 	EPollArrayWrapper.c \
   230 	EPollArrayWrapper.c \
       
   231 	EPollPort.c \
    97 	InheritedChannel.c \
   232 	InheritedChannel.c \
    98 	NativeThread.c \
   233 	NativeThread.c \
    99         PollArrayWrapper.c
   234         PollArrayWrapper.c \
       
   235 	UnixAsynchronousServerSocketChannelImpl.c \
       
   236 	UnixAsynchronousSocketChannelImpl.c \
       
   237 	\
       
   238 	GnomeFileTypeDetector.c \
       
   239 	LinuxNativeDispatcher.c \
       
   240 	LinuxWatchService.c \
       
   241 	UnixCopyFile.c \
       
   242 	UnixNativeDispatcher.c
   100 
   243 
   101 FILES_export += \
   244 FILES_export += \
       
   245 	sun/nio/ch/EPoll.java \
   102         sun/nio/ch/EPollArrayWrapper.java \
   246         sun/nio/ch/EPollArrayWrapper.java \
       
   247 	sun/nio/ch/EPollPort.java \
   103 	sun/nio/ch/InheritedChannel.java \
   248 	sun/nio/ch/InheritedChannel.java \
   104 	sun/nio/ch/NativeThread.java
   249 	sun/nio/ch/NativeThread.java \
       
   250 	sun/nio/ch/UnixAsynchronousServerSocketChannelImpl.java \
       
   251 	sun/nio/ch/UnixAsynchronousSocketChannelImpl.java \
       
   252 	\
       
   253 	sun/nio/fs/GnomeFileTypeDetector.java \
       
   254 	sun/nio/fs/LinuxNativeDispatcher.java \
       
   255 	sun/nio/fs/LinuxWatchService.java \
       
   256 	sun/nio/fs/UnixCopyFile.java \
       
   257 	sun/nio/fs/UnixNativeDispatcher.java
       
   258 	
       
   259 FILES_gen += \
       
   260 	sun/nio/fs/UnixConstants.java
   105 endif # PLATFORM = linux
   261 endif # PLATFORM = linux
   106 
   262 
       
   263 #
   107 # Find platform-specific C source files
   264 # Find platform-specific C source files
   108 #
   265 #
       
   266 vpath %.c $(PLATFORM_SRC)/native/sun/nio/fs
   109 vpath %.c $(PLATFORM_SRC)/native/sun/nio/ch
   267 vpath %.c $(PLATFORM_SRC)/native/sun/nio/ch
   110 vpath %.c $(SHARE_SRC)/native/sun/nio/ch
   268 vpath %.c $(SHARE_SRC)/native/sun/nio/ch
   111 
   269 
   112 #
   270 #
   113 # Various variables
   271 # Various variables
   173 BUF_SRC=$(NIO_SRC)
   331 BUF_SRC=$(NIO_SRC)
   174 CH_SRC=$(NIO_SRC)/channels
   332 CH_SRC=$(NIO_SRC)/channels
   175 CS_SRC=$(NIO_SRC)/charset
   333 CS_SRC=$(NIO_SRC)/charset
   176 SCH_SRC=$(SNIO_SRC)/ch
   334 SCH_SRC=$(SNIO_SRC)/ch
   177 SCS_SRC=$(SNIO_SRC)/cs
   335 SCS_SRC=$(SNIO_SRC)/cs
       
   336 SFS_SRC=$(SNIO_SRC)/fs
   178 
   337 
   179 BUF_GEN=$(NIO_GEN)
   338 BUF_GEN=$(NIO_GEN)
   180 CH_GEN=$(NIO_GEN)/channels
   339 CH_GEN=$(NIO_GEN)/channels
   181 CS_GEN=$(NIO_GEN)/charset
   340 CS_GEN=$(NIO_GEN)/charset
   182 SCH_GEN=$(SNIO_GEN)/ch
   341 SCH_GEN=$(SNIO_GEN)/ch
   183 SCS_GEN=$(SNIO_GEN)/cs
   342 SCS_GEN=$(SNIO_GEN)/cs
       
   343 SFS_GEN=$(SNIO_GEN)/fs
   184 
   344 
   185 FILES_gensbcs_out = $(FILES_gen_sbcs:%.java=$(GENSRCDIR)/%.java)
   345 FILES_gensbcs_out = $(FILES_gen_sbcs:%.java=$(GENSRCDIR)/%.java)
   186 
   346 
   187 sources: $(SPP_JARFILE) $(FILES_genout) $(FILES_gensbcs_out)
   347 sources: $(SPP_JARFILE) $(FILES_genout) $(FILES_gensbcs_out)
   188 
   348 
   668 $(FILES_gensbcs_out): $(GENCSSRC)/SingleByte-X.java $(GENCSSRC)/sbcs
   828 $(FILES_gensbcs_out): $(GENCSSRC)/SingleByte-X.java $(GENCSSRC)/sbcs
   669 	@$(prep-target)
   829 	@$(prep-target)
   670 	$(BOOT_JAVA_CMD) -cp $(CHARSETMAPPING_JARFILE) build.tools.charsetmapping.GenerateSBCS \
   830 	$(BOOT_JAVA_CMD) -cp $(CHARSETMAPPING_JARFILE) build.tools.charsetmapping.GenerateSBCS \
   671 		$(GENCSSRC) $(SCS_GEN) sbcs
   831 		$(GENCSSRC) $(SCS_GEN) sbcs
   672 
   832 
       
   833 # 
       
   834 # Generated file system implementation classes (Unix only)
       
   835 #
       
   836 
       
   837 GENUC_SRC = $(PLATFORM_SRC)/native/sun/nio/fs/genUnixConstants.c
       
   838 
       
   839 GENUC_EXE = $(TEMPDIR)/genUnixConstants
       
   840 
       
   841 GENUC_COPYRIGHT_YEARS = $(shell $(CAT) $(GENUC_SRC) | \
       
   842 	$(NAWK) '/^.*Copyright.*Sun/ { print $$3 }')
       
   843 
       
   844 $(GENUC_EXE) : $(GENUC_SRC)
       
   845 	$(prep-target)
       
   846 	$(CC) $(CPPFLAGS) -o $@ $(GENUC_SRC)
       
   847 
       
   848 $(SFS_GEN)/UnixConstants.java: $(GENUC_EXE)
       
   849 	$(prep-target)
       
   850 	NAWK="$(NAWK)" SH="$(SH)" $(SH) -e addNotices.sh $(GENUC_COPYRIGHT_YEARS) > $@
       
   851 	$(GENUC_EXE) >> $@
       
   852 
       
   853 GENSC_SRC = $(PLATFORM_SRC)/native/sun/nio/fs/genSolarisConstants.c
       
   854 
       
   855 GENSC_EXE = $(TEMPDIR)/genSolarisConstants
       
   856 
       
   857 GENSC_COPYRIGHT_YEARS = $(shell $(CAT) $(GENSC_SRC) | \
       
   858 	$(NAWK) '/^.*Copyright.*Sun/ { print $$3 }')
       
   859 
       
   860 $(GENSC_EXE) : $(GENSC_SRC)
       
   861 	$(prep-target)
       
   862 	$(CC) $(CPPFLAGS) -o $@ $(GENSC_SRC)
       
   863 
       
   864 $(SFS_GEN)/SolarisConstants.java: $(GENSC_EXE)
       
   865 	$(prep-target)
       
   866 	NAWK="$(NAWK)" SH="$(SH)" $(SH) -e addNotices.sh $(GENSC_COPYRIGHT_YEARS) > $@
       
   867 	$(GENSC_EXE) >> $@
       
   868 
   673 .PHONY: sources 
   869 .PHONY: sources