/**********************************************************************
 * Copyright (c) 2020 Codethink Ltd., Sudip Mukherjee
 *
 * All rights reserved. This program and the accompanying materials are
 * made available under the terms of the Eclipse Public License 2.0 which
 * accompanies this distribution, and is available at
 * https://www.eclipse.org/legal/epl-2.0/
 *
 * SPDX-License-Identifier: EPL-2.0
 **********************************************************************/

import java.util.*;
import java.util.jar.*;
import java.io.*;
import java.lang.*;

public class create_info {
public static void main(String[] args)throws Exception{
	String [] traceclass = {
 "#encoding=UTF-8",
 "#version=1",
 "org.eclipse.tracecompass.analysis.counters.core,2.0.6.qualifier,plugins/org.eclipse.tracecompass.analysis.counters.core.jar,4,false",
 "org.eclipse.tracecompass.analysis.counters.ui,2.0.0.qualifier,plugins/org.eclipse.tracecompass.analysis.counters.ui.jar,4,false",
 "org.eclipse.tracecompass.analysis.graph.core,3.0.0.qualifier,plugins/org.eclipse.tracecompass.analysis.graph.core.jar,4,false",
 "org.eclipse.tracecompass.analysis.graph.ui,1.0.11.qualifier,plugins/org.eclipse.tracecompass.analysis.graph.ui.jar,4,false",
 "org.eclipse.tracecompass.analysis.lami.core,1.1.3.qualifier,plugins/org.eclipse.tracecompass.analysis.lami.core.jar,4,false",
 "org.eclipse.tracecompass.analysis.lami.ui,1.1.5.qualifier,plugins/org.eclipse.tracecompass.analysis.lami.ui.jar,4,false",
 "org.eclipse.tracecompass.analysis.os.linux.core,6.0.0.qualifier,plugins/org.eclipse.tracecompass.analysis.os.linux.core.jar,4,false",
 "org.eclipse.tracecompass.analysis.os.linux.ui,4.0.4.qualifier,plugins/org.eclipse.tracecompass.analysis.os.linux.ui.jar,4,false",
 "org.eclipse.tracecompass.analysis.profiling.core,2.0.1.qualifier,plugins/org.eclipse.tracecompass.analysis.profiling.core.jar,4,false",
 "org.eclipse.tracecompass.analysis.profiling.ui,2.1.3.qualifier,plugins/org.eclipse.tracecompass.analysis.profiling.ui.jar,4,false",
 "org.eclipse.tracecompass.analysis.timing.core,5.2.1.qualifier,plugins/org.eclipse.tracecompass.analysis.timing.core.jar,4,false",
 "org.eclipse.tracecompass.analysis.timing.ui,5.0.0.qualifier,plugins/org.eclipse.tracecompass.analysis.timing.ui.jar,4,false",
 "org.eclipse.tracecompass.common.core,4.3.0.qualifier,plugins/org.eclipse.tracecompass.common.core.jar,4,false",
 "org.eclipse.tracecompass.ctf.core,4.0.5.qualifier,plugins/org.eclipse.tracecompass.ctf.core.jar,4,false",
 "org.eclipse.tracecompass.ctf.parser,1.0.6.qualifier,plugins/org.eclipse.tracecompass.ctf.parser.jar,4,false",
 "org.eclipse.tracecompass.datastore.core,1.2.2.qualifier,plugins/org.eclipse.tracecompass.datastore.core.jar,4,false",
 "org.eclipse.tracecompass.lttng2.common.core,1.1.3.qualifier,plugins/org.eclipse.tracecompass.lttng2.common.core.jar,4,false",
 "org.eclipse.tracecompass.lttng2.control.core,1.2.5.qualifier,plugins/org.eclipse.tracecompass.lttng2.control.core.jar,4,false",
 "org.eclipse.tracecompass.lttng2.control.ui,1.2.12.qualifier,plugins/org.eclipse.tracecompass.lttng2.control.ui.jar,4,false",
 "org.eclipse.tracecompass.lttng2.kernel.core,3.0.5.qualifier,plugins/org.eclipse.tracecompass.lttng2.kernel.core.jar,4,false",
 "org.eclipse.tracecompass.lttng2.kernel.ui,2.0.2.qualifier,plugins/org.eclipse.tracecompass.lttng2.kernel.ui.jar,4,false",
 "org.eclipse.tracecompass.lttng2.ust.core,5.0.2.qualifier,plugins/org.eclipse.tracecompass.lttng2.ust.core.jar,4,false",
 "org.eclipse.tracecompass.lttng2.ust.ui,3.0.10.qualifier,plugins/org.eclipse.tracecompass.lttng2.ust.ui.jar,4,false",
 "org.eclipse.tracecompass.rcp.branding,7.0.0.qualifier,plugins/org.eclipse.tracecompass.rcp.branding/,4,false",
 "org.eclipse.tracecompass.rcp.ui,7.0.0.qualifier,plugins/org.eclipse.tracecompass.rcp.ui.jar,5,false",
 "org.eclipse.tracecompass.rcp.incubator.ui,1.0.2.qualifier,plugins/org.eclipse.tracecompass.rcp.incubator.ui.jar,4,false",
 "org.eclipse.tracecompass.segmentstore.core,3.0.1.qualifier,plugins/org.eclipse.tracecompass.segmentstore.core.jar,4,false",
 "org.eclipse.tracecompass.statesystem.core,5.0.3.qualifier,plugins/org.eclipse.tracecompass.statesystem.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.analysis.xml.core,4.0.2.qualifier,plugins/org.eclipse.tracecompass.tmf.analysis.xml.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.analysis.xml.ui,2.1.15.qualifier,plugins/org.eclipse.tracecompass.tmf.analysis.xml.ui.jar,4,false",
 "org.eclipse.tracecompass.tmf.chart.core,1.0.4.qualifier,plugins/org.eclipse.tracecompass.tmf.chart.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.chart.ui,1.0.11.qualifier,plugins/org.eclipse.tracecompass.tmf.chart.ui.jar,4,false",
 "org.eclipse.tracecompass.tmf.cli.core,1.0.2.qualifier,plugins/org.eclipse.tracecompass.tmf.cli.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.core,7.0.0.qualifier,plugins/org.eclipse.tracecompass.tmf.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.ctf.core,4.2.2.qualifier,plugins/org.eclipse.tracecompass.tmf.ctf.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.filter.parser,1.0.6.qualifier,plugins/org.eclipse.tracecompass.tmf.filter.parser.jar,4,false",
 "org.eclipse.tracecompass.tmf.remote.core,2.0.5.qualifier,plugins/org.eclipse.tracecompass.tmf.remote.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.remote.ui,1.0.9.qualifier,plugins/org.eclipse.tracecompass.tmf.remote.ui.jar,4,false",
 "org.eclipse.tracecompass.tmf.ui,7.0.0.qualifier,plugins/org.eclipse.tracecompass.tmf.ui.jar,4,false",
 "org.eclipse.tracecompass.pcap.core,1.1.3.qualifier,plugins/org.eclipse.tracecompass.pcap.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.pcap.core,1.0.5.qualifier,plugins/org.eclipse.tracecompass.tmf.pcap.core.jar,4,false",
 "org.eclipse.tracecompass.tmf.pcap.ui,1.1.4.qualifier,plugins/org.eclipse.tracecompass.tmf.pcap.ui.jar,4,false"};

		String[] jarclass = {
 "/usr/share/java/gson.jar,4,false",
 "/usr/share/java/guava.jar,4,false",
 "/usr/share/java/eclipse-core-runtime.jar,4,true",
 "/usr/share/java/equinox-common.jar,2,true",
 "/usr/share/java/eclipse-core-jobs.jar,4,false",
 "/usr/share/java/equinox-registry.jar,4,false",
 "/usr/share/java/equinox-preferences.jar,4,false",
 "/usr/share/java/eclipse-core-contenttype.jar,4,false",
 "/usr/share/java/equinox-app.jar,4,false",
 "/usr/share/java/eclipse-core-resources.jar,4,false",
 "/usr/share/java/eclipse-core-expressions.jar,4,false",
 "/usr/share/java/eclipse-core-filesystem.jar,4,false",
 "/usr/share/java/antlr3-runtime.jar,4,false",
 "/usr/share/java/commons-io.jar,4,false",
 "/usr/share/java/commons-lang3.jar,4,false",
 "/usr/share/java/org.eclipse.cdt.core.jar,4,false",
 "/usr/share/java/jaxb-api.jar,4,false",
 "/usr/share/java/javax.activation.jar,4,false",
 "/usr/share/java/org.eclipse.cdt.core.native.jar,4,false",
 "/usr/share/java/eclipse-core-filebuffers.jar,4,false",
 "/usr/share/java/eclipse-text.jar,4,false",
 "/usr/share/java/eclipse-core-commands.jar,4,false",
 "/usr/share/java/eclipse-core-variables.jar,4,false",
 "/usr/share/java/eclipse-ltk-core-refactoring.jar,4,false",
 "/usr/share/java/icu4j.jar,4,false",
 "/usr/share/java/swtchart.jar,4,false",
 "/usr/share/java/org.eclipse.swt.jar,4,false",
 "/usr/share/java/eclipse-ui.jar,4,false",
 "/usr/share/java/eclipse-jface.jar,4,false",
 "/usr/share/java/eclipse-ui-workbench.jar,4,false",
 "/usr/share/java/geronimo-annotation-1.3-spec.jar,4,false",
 "/usr/share/java/atinject-jsr330-api.jar,4,false",
 "/usr/share/java/eclipse-e4-core-commands.jar,4,false",
 "/usr/share/java/eclipse-e4-core-contexts.jar,4,false",
 "/usr/share/java/eclipse-osgi-services.jar,4,false",
 "/usr/share/java/eclipse-osgi-util.jar,4,false",
 "/usr/share/java/eclipse-e4-core-di.jar,4,false",
 "/usr/share/java/eclipse-e4-core-di-annotations.jar,4,false",
 "/usr/share/java/eclipse-e4-core-services.jar,4,false",
 "/usr/share/java/org.apache.felix.scr.jar,2,true",
 "/usr/share/java/eclipse-e4-ui-workbench.jar,4,false",
 "/usr/share/java/commons-jxpath.jar,4,false",
 "/usr/share/java/servlet-api.jar,4,false",
 "/usr/share/java/jsp-api.jar,4,false",
 "/usr/share/java/el-api.jar,4,false",
 "/usr/share/java/commons-beanutils.jar,4,false",
 "/usr/share/java/commons-collections3.jar,4,false",
 "/usr/share/java/commons-logging.jar,4,false",
 "/usr/share/java/jdom1.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-model-workbench.jar,4,false",
 "/usr/share/java/eclipse-emf-ecore.jar,4,false",
 "/usr/share/java/eclipse-emf-common.jar,4,false",
 "/usr/share/java/eclipse-e4-emf-xpath.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-services.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-di.jar,4,false",
 "/usr/share/java/eclipse-e4-core-di-extensions-supplier.jar,4,false",
 "/usr/share/java/eclipse-e4-core-di-extensions.jar,4,false",
 "/usr/share/java/eclipse-emf-ecore-change.jar,4,false",
 "/usr/share/java/eclipse-emf-ecore-xmi.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-workbench-renderers-swt.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-workbench-swt.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-dialogs.jar,4,false",
 "/usr/share/java/eclipse-core-databinding.jar,4,false",
 "/usr/share/java/eclipse-core-databinding-observable.jar,4,false",
 "/usr/share/java/eclipse-core-databinding-property.jar,4,false",
 "/usr/share/java/eclipse-jface-databinding.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-css-core.jar,4,false",
 "/usr/share/java/sac.jar,4,false",
 "/usr/share/java/batik-i18n.jar,4,false",
 "/usr/share/java/batik-css.jar,4,false",
 "/usr/share/java/batik-util.jar,4,false",
 "/usr/share/java/batik-gui-util.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-css-swt.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-bindings.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-workbench3.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-css-swt-theme.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-widgets.jar,4,false",
 "/usr/share/java/eclipse-urischeme.jar,4,false",
 "/usr/share/java/eclipse-help.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-workbench-addons-swt.jar,4,false",
 "/usr/share/java/eclipse-ui-editors.jar,4,false",
 "/usr/share/java/eclipse-ui-ide.jar,4,false",
 "/usr/share/java/eclipse-jface-text.jar,4,false",
 "/usr/share/java/eclipse-ui-views.jar,4,false",
 "/usr/share/java/eclipse-ui-forms.jar,4,false",
 "/usr/share/java/equinox-p2-engine.jar,4,false",
 "/usr/share/java/equinox-p2-core.jar,4,false",
 "/usr/share/java/equinox-p2-metadata.jar,4,false",
 "/usr/share/java/equinox-p2-metadata-repository.jar,4,false",
 "/usr/share/java/equinox-p2-repository.jar,4,false",
 "/usr/share/java/equinox-security.jar,4,false",
 "/usr/share/java/xz.jar,4,false",
 "/usr/share/java/equinox-bidi.jar,4,false",
 "/usr/share/java/eclipse-e4-ui-ide.jar,4,false",
 "/usr/share/java/eclipse-ui-navigator.jar,4,false",
 "/usr/share/java/eclipse-ui-workbench-texteditor.jar,4,false",
 "/usr/share/java/eclipse-compare-core.jar,4,false",
 "/usr/share/java/eclipse-ui-navigator-resources.jar,4,false",
 "/usr/share/java/eclipse-ui-views-properties-tabbed.jar,4,false",
 "/usr/share/java/eclipse-ltk-ui-refactoring.jar,4,false",
 "/usr/share/java/eclipse-compare.jar,4,false",
 "/usr/share/java/eclipse-team-core.jar,4,false",
 "/usr/share/java/eclipse-team-ui.jar,4,false",
 "/usr/share/java/org.eclipse.linuxtools.dataviewers.piechart.jar,4,false",
 "/usr/share/java/commons-compress.jar,4,false",
 "/usr/share/java/eclipse-wst-xml-ui.jar,4,false",
 "/usr/share/java/eclipse-wst-sse-ui.jar,4,false",
 "/usr/share/java/eclipse-debug-ui.jar,4,false",
 "/usr/share/java/eclipse-ui-console.jar,4,false",
 "/usr/share/java/eclipse-debug-core.jar,4,false",
 "/usr/share/java/eclipse-search.jar,4,false",
 "/usr/share/java/eclipse-wst-sse-core.jar,4,false",
 "/usr/share/java/eclipse-wst-common-uriresolver.jar,4,false",
 "/usr/share/java/eclipse-wst-validation.jar,4,false",
 "/usr/share/java/eclipse-wst-common-frameworks.jar,4,false",
 "/usr/share/java/eclipse-wst-common-environment.jar,4,false",
 "/usr/share/java/eclipse-wst-common-core.jar,4,false",
 "/usr/share/java/eclipse-wst-common-project-facet-core.jar,4,false",
 "/usr/share/java/eclipse-wst-xml-core.jar,4,false",
 "/usr/share/java/xercesImpl.jar,4,false",
 "/usr/share/java/xml-resolver.jar,4,false",
 "/usr/share/java/eclipse-wst-common-ui.jar,4,false",
 "/usr/share/java/eclipse-wst-validation-ui.jar,4,false",
 "/usr/share/java/eclipse-wst-common-frameworks-ui.jar,4,false",
 "/usr/share/java/eclipse-wst-xsd-core.jar,4,false",
 "/usr/share/java/eclipse-xsd.jar,4,false",
 "/usr/share/java/eclipse-ui-themes.jar,4,false",
 "/usr/share/java/openjson.jar,4,false",
 "/usr/share/java/eclipse-remote-core.jar,4,false",
 "/usr/share/java/eclipse-remote-ui.jar,4,false",
 "/usr/share/java/eclipse-jsch-core.jar,4,false",
 "/usr/share/java/eclipse-jsch-ui.jar,4,false",
 "/usr/share/java/jsch.jar,4,false",
 "/usr/share/java/eclipse-core-net.jar,4,false",
 "/usr/share/java/commons-cli.jar,4,false",
 "/usr/share/java/equinox-p2-ui-sdk.jar,4,false",
 "/usr/share/java/equinox-p2-operations.jar,4,false",
 "/usr/share/java/equinox-p2-director.jar,4,false",
 "/usr/share/java/org.ow2.sat4j.core.jar,4,false",
 "/usr/share/java/org.ow2.sat4j.pb.jar,4,false",
 "/usr/share/java/equinox-p2-ui.jar,4,false",
 "/usr/share/java/equinox-p2-artifact-repository.jar,4,false",
 "/usr/share/java/equinox-p2-jarprocessor.jar,4,false",
 "/usr/share/java/equinox-security-ui.jar,4,false",
 "/usr/share/java/eclipse-ui-workbench.jar,4,false",
 "/usr/share/java/eclipse-ui-ide-application.jar,4,false",
 "/usr/share/java/equinox-event.jar,2,true",
 "/usr/share/java/jna.jar,4,false",
 "/usr/share/java/jna-platform.jar,4,false",
 "/usr/share/java/eclipse-jface-notifications.jar,4,false",
 "/usr/share/java/org.eclipse.swtchart.jar,4,false",
 "/usr/share/java/org.eclipse.swtchart.extensions.jar,4,false"
 };

	for (int i = 0; i < traceclass.length; i++)
		System.out.println(traceclass[i]);
	for (int i = 0; i < jarclass.length; i++) {
		String[] arglist = jarclass[i].split(",");
		Manifest m = new JarFile(arglist[0]).getManifest();
		Attributes a = m.getMainAttributes();
		String[] symname = a.getValue("Bundle-SymbolicName").split(";");
		System.out.println(symname[0] + "," + a.getValue("Bundle-Version") + "," + arglist[0] + "," + arglist[1] + "," + arglist[2]);
	}
}
}
