/build/blueprint/ |
D | ninja_writer_test.go | 30 input func(w *ninjaWriter) 34 input: func(w *ninjaWriter) { 35 ck(w.Comment("foo")) 40 input: func(w *ninjaWriter) { 41 ck(w.Pool("foo")) 46 input: func(w *ninjaWriter) { 47 ck(w.Rule("foo")) 52 input: func(w *ninjaWriter) { 53 ck(w.Build("foo comment", "foo", testNinjaStrings("o3", "o4"), 64 input: func(w *ninjaWriter) { [all …]
|
D | module_ctx_test.go | 146 if g, w := foo.forwardDeps, []*moduleInfo{barB}; !reflect.DeepEqual(g, w) { 147 t.Fatalf("expected foo deps to be %q, got %q", w, g) 166 if g, w := foo.forwardDeps, []*moduleInfo{barBB}; !reflect.DeepEqual(g, w) { 167 t.Fatalf("expected foo deps to be %q, got %q", w, g) 186 if g, w := foo.forwardDeps, []*moduleInfo{barAB}; !reflect.DeepEqual(g, w) { 187 t.Fatalf("expected foo deps to be %q, got %q", w, g) 273 if g, w := foo.forwardDeps, []*moduleInfo{barB}; !reflect.DeepEqual(g, w) { 274 t.Fatalf("expected foo deps to be %q, got %q", w, g) 293 if g, w := foo.forwardDeps, []*moduleInfo{barBB}; !reflect.DeepEqual(g, w) { 294 t.Fatalf("expected foo deps to be %q, got %q", w, g) [all …]
|
/build/soong/apex/ |
D | androidmk.go | 77 func (a *apexBundle) androidMkForFiles(w io.Writer, apexBundleName, moduleDir string, 112 fmt.Fprintln(w, "\ninclude $(CLEAR_VARS) # apex.apexBundle.files") 114 fmt.Fprintln(w, "LOCAL_PATH :=", fi.moduleDir) 116 fmt.Fprintln(w, "LOCAL_PATH :=", moduleDir) 118 fmt.Fprintln(w, "LOCAL_MODULE :=", moduleName) 121 fmt.Fprintln(w, "LOCAL_MODULE_OWNER :=", fi.module.Owner()) 126 fmt.Fprintln(w, "LOCAL_MODULE_PATH :=", modulePath) 129 extra(w, fi.builtFile) 135 fmt.Fprintln(w, "LOCAL_NO_NOTICE_FILE := true") 136 fmt.Fprintln(w, "LOCAL_SOONG_INSTALLED_MODULE :=", filepath.Join(modulePath, fi.stem())) [all …]
|
/build/soong/third_party/zip/ |
D | writer.go | 33 func NewWriter(w io.Writer) *Writer { 34 return &Writer{cw: &countWriter{w: bufio.NewWriter(w)}} 41 func (w *Writer) SetOffset(n int64) { 42 if w.cw.count != 0 { 45 w.cw.count = n 50 func (w *Writer) Flush() error { 51 return w.cw.w.(*bufio.Writer).Flush() 56 func (w *Writer) Close() error { 57 if w.last != nil && !w.last.closed { 58 if err := w.last.close(); err != nil { [all …]
|
D | android.go | 25 func (w *Writer) CopyFrom(orig *File, newName string) error { 26 if w.last != nil && !w.last.closed { 27 if err := w.last.close(); err != nil { 30 w.last = nil 43 offset: uint64(w.cw.count), 45 w.dir = append(w.dir, h) 56 if err := writeHeader(w.cw, fh); err != nil { 68 io.Copy(w.cw, io.NewSectionReader(orig.zipr, dataOffset, int64(orig.CompressedSize64))) 88 _, err = w.cw.Write(buf) 136 func (w *Writer) CreateCompressedHeader(fh *FileHeader) (io.WriteCloser, error) { [all …]
|
D | register.go | 20 type Compressor func(w io.Writer) (io.WriteCloser, error) 31 func newFlateWriter(w io.Writer) io.WriteCloser { 34 fw.Reset(w) 36 fw, _ = flate.NewWriter(w, 5) 46 func (w *pooledFlateWriter) Write(p []byte) (n int, err error) { 47 w.mu.Lock() 48 defer w.mu.Unlock() 49 if w.fw == nil { 52 return w.fw.Write(p) 55 func (w *pooledFlateWriter) Close() error { [all …]
|
D | android_test.go | 86 w, err := fromZip.CreateHeaderAndroid(&FileHeader{ 95 _, err = w.Write(make([]byte, size)) 135 if g, w := toZipReader.File[0].CompressedSize64, uint64(size); g != w { 136 t.Errorf("Expected CompressedSize64 %d, got %d", w, g) 139 if g, w := toZipReader.File[0].UncompressedSize64, uint64(size); g != w { 140 t.Errorf("Expected UnompressedSize64 %d, got %d", w, g) 189 if g, w := d.directoryRecords, uint64(1); g != w { 190 t.Errorf("wanted directoryRecords %d, got %d", w, g) 195 if g, w := d.directorySize, uint64(expectedDirSize); g != w { 196 t.Errorf("wanted directorySize %d, got %d", w, g) [all …]
|
D | writer_test.go | 70 w := NewWriter(buf) 73 testCreate(t, w, &wt) 76 if err := w.Close(); err != nil { 104 w := NewWriter(buf) 105 w.SetOffset(int64(n)) 108 testCreate(t, w, &wt) 111 if err := w.Close(); err != nil { 127 w := NewWriter(struct{ io.Writer }{&buf}) 128 _, err := w.Create("foo") 135 if err := w.Flush(); err != nil { [all …]
|
D | example_test.go | 22 w := zip.NewWriter(buf) 33 f, err := w.Create(file.Name) 44 err := w.Close() 85 w := zip.NewWriter(buf) 88 w.RegisterCompressor(zip.Deflate, func(out io.Writer) (io.WriteCloser, error) {
|
/build/soong/android/ |
D | deptag_test.go | 98 if g, w := hostFoo.Implicits.Strings(), hostInstallDep.Output.String(); !InList(w, g) { 99 t.Errorf("expected host dependency %q, got %q", w, g) 102 if g, w := hostFoo.Implicits.Strings(), hostTransitive.Output.String(); !InList(w, g) { 103 t.Errorf("expected host dependency %q, got %q", w, g) 106 if g, w := hostInstallDep.Implicits.Strings(), hostTransitive.Output.String(); !InList(w, g) { 107 t.Errorf("expected host dependency %q, got %q", w, g) 110 if g, w := hostFoo.Implicits.Strings(), hostDep.Output.String(); InList(w, g) { 111 t.Errorf("expected no host dependency %q, got %q", w, g) 119 if g, w := deviceFoo.OrderOnly.Strings(), deviceInstallDep.Output.String(); !InList(w, g) { 120 t.Errorf("expected device dependency %q, got %q", w, g) [all …]
|
D | arch_test.go | 456 if g, w := enabledVariants(ctx, "foo"), tt.fooVariants; !reflect.DeepEqual(w, g) { 457 t.Errorf("want foo variants:\n%q\ngot:\n%q\n", w, g) 460 if g, w := enabledVariants(ctx, "bar"), tt.barVariants; !reflect.DeepEqual(w, g) { 461 t.Errorf("want bar variants:\n%q\ngot:\n%q\n", w, g) 464 if g, w := enabledVariants(ctx, "baz"), tt.bazVariants; !reflect.DeepEqual(w, g) { 465 t.Errorf("want baz variants:\n%q\ngot:\n%q\n", w, g) 468 if g, w := enabledVariants(ctx, "qux"), tt.quxVariants; !reflect.DeepEqual(w, g) { 469 t.Errorf("want qux variants:\n%q\ngot:\n%q\n", w, g) 471 if g, w := enabledVariants(ctx, "first"), tt.firstVariants; !reflect.DeepEqual(w, g) { 472 t.Errorf("want first variants:\n%q\ngot:\n%q\n", w, g) [all …]
|
D | ninja_deps_test.go | 40 if g, w := result.NinjaDeps, "foo"; !InList(w, g) { 41 t.Errorf("expected %q in %q", w, g)
|
/build/soong/rust/ |
D | protobuf_test.go | 52 if w := "protoc-gen-rust"; !strings.Contains(cmd, w) { 53 t.Errorf("expected %q in %q", w, cmd) 57 if w := "-Ishared_include"; !strings.Contains(cmd, w) { 58 t.Errorf("expected %q in %q", w, cmd) 60 if w := "-Istatic_include"; !strings.Contains(cmd, w) { 61 t.Errorf("expected %q in %q", w, cmd) 116 if w := "-Iproto"; !strings.Contains(cmd, w) { 117 t.Errorf("expected %q in %q", w, cmd) 149 if w := "protoc-gen-grpc"; !strings.Contains(cmd, w) { 150 t.Errorf("expected %q in %q", w, cmd) [all …]
|
/build/soong/phony/ |
D | phony.go | 59 Custom: func(w io.Writer, name, prefix, moduleDir string, data android.AndroidMkData) { 60 fmt.Fprintln(w, "\ninclude $(CLEAR_VARS)", " # phony.phony") 61 fmt.Fprintln(w, "LOCAL_PATH :=", moduleDir) 62 fmt.Fprintln(w, "LOCAL_MODULE :=", name) 64 fmt.Fprintln(w, "LOCAL_IS_HOST_MODULE := true") 67 fmt.Fprintln(w, "LOCAL_REQUIRED_MODULES :=", 71 fmt.Fprintln(w, "LOCAL_HOST_REQUIRED_MODULES :=", 75 fmt.Fprintln(w, "LOCAL_TARGET_REQUIRED_MODULES :=", 80 extra(w, nil) 82 fmt.Fprintln(w, "include $(BUILD_PHONY_PACKAGE)") [all …]
|
/build/soong/ui/terminal/ |
D | status.go | 29 func NewStatusOutput(w io.Writer, statusFormat string, forceSimpleOutput, quietBuild, forceKeepANSI… 32 if !forceSimpleOutput && isSmartTerminal(w) { 33 return NewSmartStatusOutput(w, formatter) 35 return NewSimpleStatusOutput(w, formatter, forceKeepANSI)
|
D | util.go | 25 func isSmartTerminal(w io.Writer) bool { 26 if f, ok := w.(*os.File); ok { 35 } else if _, ok := w.(*fakeSmartTerminal); ok { 41 func termSize(w io.Writer) (width int, height int, ok bool) { 42 if f, ok := w.(*os.File); ok { 51 } else if f, ok := w.(*fakeSmartTerminal); ok {
|
D | status_test.go | 101 if g, w := smart.String(), tt.smart; g != w { 102 t.Errorf("want:\n%q\ngot:\n%q", w, g) 112 if g, w := simple.String(), tt.simple; g != w { 113 t.Errorf("want:\n%q\ngot:\n%q", w, g) 123 if g, w := smart.String(), tt.simple; g != w { 124 t.Errorf("want:\n%q\ngot:\n%q", w, g) 292 …w := "\r\x1b[1m[ 0% 0/2] action with very long descrip\x1b[0m\x1b[K\r\x1b[1m[ 50% 1/2] action wit… 294 if g := smart.String(); g != w { 295 t.Errorf("want:\n%q\ngot:\n%q", w, g) 328 …w := "\r\x1b[1m[ 0% 0/2] action1\x1b[0m\x1b[K\r\x1b[1m[ 0% 0/2] action2\x1b[0m\x1b[K\r\x1b[1m[ 5… [all …]
|
/build/soong/ui/status/ |
D | log.go | 34 w io.WriteCloser member 48 w := gzip.NewWriter(f) 51 w: w, 63 fmt.Fprintf(v.w, "[%d/%d] %s\n", counts.FinishedActions, counts.TotalActions, cmd) 66 fmt.Fprintf(v.w, "FAILED: %s\n", strings.Join(result.Outputs, " ")) 70 fmt.Fprintln(v.w, result.Output) 75 v.w.Close() 79 fmt.Fprintf(v.w, "%s%s\n", level.Prefix(), message) 83 fmt.Fprint(v.w, string(p)) 88 w io.WriteCloser member [all …]
|
/build/soong/java/ |
D | droiddoc_test.go | 84 …if g, w := android.PathsRelativeToTop(javaDoc.Implicits), android.PathRelativeToTop(barStubsOutput… 85 t.Errorf("implicits of bar-doc must contain %q, but was %q.", w, g) 94 …if g, w := android.PathsRelativeToTop(javaDoc.Implicits), android.PathRelativeToTop(aidl.Output); … 95 t.Errorf("implicits of bar-doc must contain %q, but was %q.", w, g) 98 …if g, w := aidl.Implicits.Strings(), []string{"bar-doc/IBar.aidl", "bar-doc/IFoo.aidl"}; !reflect.… 99 t.Errorf("aidl inputs must be %q, but was %q", w, g)
|
D | androidmk.go | 302 func(w io.Writer, name, prefix, moduleDir string) { 303 fmt.Fprintln(w, "jar_installed_module := $(LOCAL_INSTALLED_MODULE)") 319 func(w io.Writer, name, prefix, moduleDir string) { 321 fmt.Fprintln(w, "$(LOCAL_INSTALLED_MODULE): $(jar_installed_module)") 322 fmt.Fprintln(w, "jar_installed_module :=") 443 func(w io.Writer, name, prefix, moduleDir string) { 445 fmt.Fprintf(w, "$(call dist-for-goals,%s,%s:%s/$(notdir %s))\n", 593 func(w io.Writer, name, prefix, moduleDir string) { 595 fmt.Fprintf(w, ".PHONY: %s %s.txt\n", dstubs.Name(), dstubs.Name()) 596 fmt.Fprintf(w, "%s %s.txt: %s\n", dstubs.Name(), dstubs.Name(), dstubs.apiFile) [all …]
|
/build/soong/cc/ |
D | proto_test.go | 60 if w := "--foobar_out="; !strings.Contains(cmd, w) { 61 t.Errorf("expected %q in %q", w, cmd) 66 if w := "--plugin=protoc-gen-foobar=" + foobarPath; !strings.Contains(cmd, w) { 67 t.Errorf("expected %q in %q", w, cmd)
|
/build/soong/bpf/ |
D | bpf.go | 220 Custom: func(w io.Writer, name, prefix, moduleDir string, data android.AndroidMkData) { 222 fmt.Fprintln(w) 223 fmt.Fprintln(w, "LOCAL_PATH :=", moduleDir) 224 fmt.Fprintln(w) 237 fmt.Fprintln(w, "include $(CLEAR_VARS)", " # bpf.bpf.obj") 238 fmt.Fprintln(w, "LOCAL_MODULE := ", objName) 239 fmt.Fprintln(w, "LOCAL_PREBUILT_MODULE_FILE :=", obj.String()) 240 fmt.Fprintln(w, "LOCAL_MODULE_STEM :=", obj.Base()) 241 fmt.Fprintln(w, "LOCAL_MODULE_CLASS := ETC") 242 fmt.Fprintln(w, localModulePath) [all …]
|
/build/soong/cmd/diff_target_files/ |
D | allow_list.go | 56 for _, w := range newAllowlists { 57 add(w.path, w.ignoreMatchingLines) 92 for _, w := range jsonAllowLists { 93 for _, p := range w.Paths { 96 ignoreMatchingLines: w.IgnoreMatchingLines, 107 for _, w := range allowLists { 108 if match, err := Match(w.path, l[i][0].Name); err != nil { 111 … if match, err := diffIgnoringMatchingLines(l[i][0], l[i][1], w.ignoreMatchingLines); err != nil { 113 } else if match || len(w.ignoreMatchingLines) == 0 { 132 for _, w := range allowLists { [all …]
|
/build/soong/finder/fs/ |
D | fs_test.go | 39 if g, w := stat.Name(), wantName; g != w { 40 t.Errorf("want name %q, got %q", w, g) 42 if g, w := stat.Mode(), wantMode; g != w { 43 t.Errorf("%s: want mode %q, got %q", wantName, w, g)
|
/build/soong/symbol_inject/ |
D | symbol_inject.go | 54 func InjectStringSymbol(file *File, w io.Writer, symbol, value, from string) error { 82 return copyAndInject(file.r, w, offset, buf) 85 func InjectUint64Symbol(file *File, w io.Writer, symbol string, value uint64) error { 98 return copyAndInject(file.r, w, offset, buf) 101 func copyAndInject(r io.ReaderAt, w io.Writer, offset uint64, buf []byte) (err error) { 103 _, err = io.Copy(w, io.NewSectionReader(r, 0, int64(offset))) 107 _, err = w.Write(buf) 113 _, err = io.Copy(w, io.NewSectionReader(r, pos, 1<<63-1-pos))
|