New issue
Advanced search Search tips

Issue 643037 link

Starred by 0 users

Issue metadata

Status: Fixed
Owner: ----
Closed: Mar 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux
Pri: 3
Type: Bug



Sign in to add a comment

installer/linux/debian/build.sh doesn't work for chromium

Reported by pdk...@gmail.com, Sep 1 2016

Issue description

https://cs.chromium.org/chromium/src/chrome/installer/linux/debian/build.sh

# TODO(mmoss) This currently only works with official builds, since non-official
# builds don't add the "${BUILDDIR}/installer/" files needed for packaging.

The first problem is a minor bug in the script. (I guess the variable is set on build-bots.)

$ ./build.sh -h
usage: build.sh [-c channel] [-a target_arch] [-o 'dir'] 
                      [-b 'dir'] -d branding
-c channel the package channel (trunk, asan, unstable, beta, stable)
-a arch    package architecture (ia32 or x64)
-o dir     package output directory [/home/user/chromium/src/chrome/installer/linux/debian]
./build.sh: line 129: BUILDDIR: unbound variable
Cleaning...

$ export BUILDDIR=~/chromium/src/out/linux-release/

$ ./build.sh -h
usage: build.sh [-c channel] [-a target_arch] [-o 'dir'] 
                      [-b 'dir'] -d branding
-c channel the package channel (trunk, asan, unstable, beta, stable)
-a arch    package architecture (ia32 or x64)
-o dir     package output directory [/home/user/chromium/src/chrome/installer/linux/debian]
-b dir     build input directory    [/home/user/chromium/src/out/linux-release/]
-d brand   either chromium or google_chrome
-h         this help message
Cleaning...

Ok, now to build.

$ ./build.sh -c stable -d chromium
./build.sh: line 226: /home/user/chromium/src/out/linux-release//installer/common/installer.include: No such file or directory
Cleaning...

And indeed, the directory is missing.

$ ls chromium/src/out/linux-release/
args.gn                         gen                             libmus_library.so              protoc
bro                             genmacro                        libmus_library.so.TOC          pyproto
build.ninja                     genmodule                       libtracing_library.so          re2c
build.ninja.d                   genperf                         libtracing_library.so.TOC      resources
character_data_generator        genstring                       locales                        resources.pak
chrome                          genversion                      mksnapshot                     snapshot_blob.bin
chrome.1                        icudtl.dat                      Mojo Applications              toolchain.ninja
chrome_100_percent.pak          keyboard_resources.pak          mojo_runner                    views_mus_resources.pak
chrome_200_percent.pak          libEGL.so                       mus_app_resources_100.pak      xdg-mime
chrome-wrapper                  libEGL.so.TOC                   mus_app_resources_200.pak      xdg-settings
content_browser_manifest.json   libfont_service_library.so      mus_app_resources_strings.pak  yasm
content_gpu_manifest.json       libfont_service_library.so.TOC  natives_blob.bin
content_renderer_manifest.json  libGLESv2.so                    obj
content_utility_manifest.json   libGLESv2.so.TOC                product_logo_48.png

Maybe it's somewhere else.

$ find chromium/ -name installer -type d
chromium/src/chrome/installer
chromium/src/chrome/test/data/installer
chromium/src/remoting/host/installer
chromium/src/out/linux-release/obj/chrome/installer

Appears unrelated. 

$ ls chromium/src/out/linux-release/obj/chrome/installer
installer.ninja  util

It has the file, but doesn't copy it.

$ find chromium/ -name installer.include -type f
chromium/src/chrome/installer/linux/common/installer.include

 
Cc: thomasanderson@chromium.org mmoss@chromium.org
Components: Internals>Installer
Is last forward slash at

$ export BUILDDIR=~/chromium/src/out/linux-release/

issue; where result includes extra forward slash at 

./build.sh: line 226: /home/user/chromium/src/out/linux-release//installer/common/installer.include

?

Comment 3 by pdk...@gmail.com, Nov 3 2016

That's not the problem, as multiple / get folded.
Still a problem? Looking at chrome/installer/linux/BUILD.gn, I don't see any special treatment of installer.include for Chromium vs Chrome, and the Chrome branded builds work AFAIK.

Comment 5 by pdk...@gmail.com, Mar 29 2017

I can't try right now, but I think this might've fixed it.

https://chromium.googlesource.com/chromium/src/+/fa8f43b2fd4d831b1422b1ad3d10c54da941752a

Comment 6 by pdk...@gmail.com, Mar 29 2017

That didn't fix it. Still same error message.
Project Member

Comment 7 by sheriffbot@chromium.org, Mar 29 2018

Status: Archived (was: Unconfirmed)
Issue has not been modified or commented on in the last 365 days, please re-open or file a new bug if this is still an issue.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Status: Fixed (was: Archived)
There was some work a while back that made the Chromium Linux packages buildable

Comment 9 by pdk...@gmail.com, Mar 29 2018

I can't confirm this. It's still the same problem it has always been, plus perhaps a few additional.

~/chromium$ ./src/chrome/installer/linux/debian/build.sh
./src/chrome/installer/linux/debian/build.sh: line 241: CHANNEL: unbound variable
./src/chrome/installer/linux/debian/build.sh: line 132: log_cmd: command not found

The first problem is easy, but it only gets worse from there.

~/chromium$ ./src/chrome/installer/linux/debian/build.sh
./src/chrome/installer/linux/debian/build.sh: line 249: /home/user/chromium/src/out/Release/installer/common/installer.include: No such file or directory
./src/chrome/installer/linux/debian/build.sh: line 132: log_cmd: command not found

Adjusting the out directory doesn't work.

~/chromium$ ./src/chrome/installer/linux/debian/build.sh
./src/chrome/installer/linux/debian/build.sh: line 249: /home/user/chromium/src/out/linux-release/installer/common/installer.include: No such file or directory
./src/chrome/installer/linux/debian/build.sh: line 132: log_cmd: command not found

The file isn't copied, nor the directory made.

~/chromium$ find -name installer.include
./src/chrome/installer/linux/common/installer.include
./src/extensions/shell/installer/linux/common/installer.include

~/chromium$ ls /home/user/chromium/src/out/linux-release/installer/
ls: cannot access /home/user/chromium/src/out/linux-release/installer/: No such file or directory

Don't run the script directly.  Build the chrome/installer/linux target.  If you want just the stable deb, then build chrome/installer/linux:stable_deb

Comment 11 by pdk...@gmail.com, Mar 29 2018

Ah thanks, I'll try that next time I build.

Comment 12 by pdk...@gmail.com, Apr 8 2018

Works!

Sign in to add a comment