catlib

package module
v0.0.0-...-d95e9f6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 9, 2016 License: MIT Imports: 19 Imported by: 0

README

catlib

A command line tool to concatenate static libraries into single file. This tool is intended to be used as a workaround in case you get LNK1189: the limit of 65535 objects or members in a library has been exceeded. when trying same job with lib command.

requirements

  • go
  • Visual Studio (Windows)
  • Xcode (macOS)

install

go get github.com/kbinani/catlib/cmd/catlib
go install github.com/kbinani/catlib/cmd/catlib

usage

Usage of catlib:
  --arch string
      x86_64 or i386 (macOS only) (default "x86_64")
  --base string
      file path of base static library
  --delete-default-lib
      delete '-defaultlib:"libfoo"' from '.drectve' section when libfoo.lib is in '--input' (Windows only) (default true)
  --extra-lib-flags string
      extra 'lib' command options for final concatenation stage
  --input string
      comma separated list of file path of import libs
  --output string
      file path of output library
Example:
  catlib --base=myproject.lib ^
         --input=zlibstat.lib,libprotobuf.lib ^
         --output=myproject-prelinked.lib ^
         --delete-default-lib ^
         --extra-lib-flags="/LTCG /WX"

license

MIT

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsFileExist

func IsFileExist(filePath string) bool

func Sha256sum

func Sha256sum(filePath string) string

func StderrPipe

func StderrPipe(cmd *exec.Cmd) (io.Reader, error)

func StdoutPipe

func StdoutPipe(cmd *exec.Cmd) (io.Reader, error)

func TempDir

func TempDir() string

Types

type ILibFile

type ILibFile interface {
	Open(filePath string, arch string) error
	Close()
	NumMembers() int
	Extract(memberIndex int, w io.Writer) error
	ImportSymbols(memberIndex int) []ISymbol
	ExportSymbols(memberIndex int) []ISymbol
}

type IObjectFile

type IObjectFile interface {
	Open(filePath string) error
	RemoveDefaultlibDrectve(inputLibNames []string) (keptDefaultLibNames []string, err error)
}

type ISymbol

type ISymbol interface {
	Name() string
	IsImportSymbol() bool
	IsExportSymbol() bool
}

type StringSet

type StringSet struct {
	// contains filtered or unexported fields
}

func NewStringSet

func NewStringSet() *StringSet

func (*StringSet) Del

func (this *StringSet) Del(s string)

func (*StringSet) Has

func (this *StringSet) Has(s string) bool

func (*StringSet) Merge

func (o *StringSet) Merge(other *StringSet)

func (*StringSet) Put

func (o *StringSet) Put(s string)

func (*StringSet) Size

func (o *StringSet) Size() int

func (*StringSet) SortedValues

func (o *StringSet) SortedValues() []string

func (*StringSet) Values

func (o *StringSet) Values() []string

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL