• Intro Headers Instructions Macros Commands
Fork me on GitHub
    • Introduction
    • How to install bnd
    • Guided Tour
    • Guided Tour Workspace & Projects
    • Concepts
    • Best practices
    • Build
    • Project Setup
    • Generating JARs
    • Versioning
    • Baselining
    • Service Components
    • Metatype
    • Contracts
    • Bundle Annotations
    • Accessor Properties
    • SPI Annotations
    • Resolving Dependencies
    • Launching
    • Startlevels
    • Testing
    • Testing with Launchpad
    • Packaging Applications
    • JPMS Libraries
    • Wrapping Libraries to OSGi Bundles
    • Generating Documentation
    • Commands
    • For Developers
    • Tips for Windows users
    • Tools bound to bnd
    • Reference
    • Headers
    • Instruction Reference
    • Instruction Index
    • Macro Reference
    • Macro Index
    • Plugins
    • External Plugins
    • Settings
    • Errors
    • Warnings
    • Frequently Asked Questions
  • -manifest FILE
    Builder

    	// Check if we override the calculation of the
    	// manifest. We still need to calculated it because
    	// we need to have analyzed the classpath.
    
    	Manifest manifest = calcManifest();
    
    	String mf = getProperty(MANIFEST);
    	if (mf != null) {
    		File mff = getFile(mf);
    		if (mff.isFile()) {
    			try {
    				InputStream in = new FileInputStream(mff);
    				manifest = new Manifest(in);
    				in.close();
    			}
    			catch (Exception e) {
    				error(MANIFEST + " while reading manifest file", e);
    			}
    		} else {
    			error(MANIFEST + ", no such file " + mf);
    		}
    	}
    
    • GitHub