private static void generateModuleSourceInstructions(@NotNull List<JpsModuleSourceRoot> roots,
                                                       @NotNull ArtifactCompilerInstructionCreator creator,
                                                       @NotNull JpsPackagingElement contextElement) {
    for (JpsModuleSourceRoot root : roots) {
      File source = root.getFile();
      ArtifactCompilerInstructionCreator target;
      JavaSourceRootProperties javaProperties = root.getProperties(JavaModuleSourceRootTypes.SOURCES);
      if (javaProperties != null) {
        String prefix = javaProperties.getPackagePrefix().replace('.', '/');
        target = creator.subFolderByRelativePath(prefix);
      } else {
        target = creator;
      }

      target.addDirectoryCopyInstructions(source, null, target.getInstructionsBuilder().createCopyingHandler(source, contextElement, target));
    }
  }
private static void generateModuleSourceInstructions(@NotNull List<JpsModuleSourceRoot> roots,
                                                       @NotNull ArtifactCompilerInstructionCreator creator,
                                                       @NotNull JpsPackagingElement contextElement)