← Back to team overview

touch-packages team mailing list archive

[Bug 1518106] Re: Using "$ source export_modules_dir.sh" causes the error "bash: /bin/build_paths.inc: No such file or directory"

 

Sourcing in the "export_modules_dir.sh" script causes $0 to be "bash" in
gnome-terminal and "/bin/bash" in terminator. When executing the script
$0 is ./export_modules_dir.sh as one would expect.

Since the script is being sourced in I don't think it dirname should be
used.

http://unix.stackexchange.com/questions/4650/determining-path-to-
sourced-shell-script

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to ubuntu-ui-toolkit in
Ubuntu.
https://bugs.launchpad.net/bugs/1518106

Title:
  Using "$ source export_modules_dir.sh" causes the error "bash:
  /bin/build_paths.inc: No such file or directory"

Status in ubuntu-ui-toolkit package in Ubuntu:
  Confirmed

Bug description:
  When branching lp:ubuntu-ui-toolkit and using the script
  export_modules_dir.sh it causes the error "bash: /bin/build_paths.inc:
  No such file or directory".

  What happened:
  1) Branch lp:ubuntu-ui-toolkit and cd into the directory
  2) Run the command $ source export_modules_dir.sh
  3) Observe the error "bash: /bin/build_paths.inc: No such file or directory"

  What I expected to happen:
  At step 3) for the modules to be correctly exported.

  
  Note that the workaround I currently perform is running the following set of commands (the only difference from the script is ". `dirname $0`/build_paths.inc" is now ". build_paths.inc")

  $ . build_paths.inc 
  $ export QML_IMPORT_PATH=$BUILD_DIR/qml
  $ export QML2_IMPORT_PATH=$BUILD_DIR/qml
  $ export UBUNTU_UI_TOOLKIT_THEMES_PATH=$BUILD_DIR/qml
  $ /sbin/initctl set-env --global QML_IMPORT_PATH=$BUILD_DIR/qml
  $ /sbin/initctl set-env --global QML2_IMPORT_PATH=$BUILD_DIR/qml
  $ /sbin/initctl set-env --global UBUNTU_UI_TOOLKIT_THEMES_PATH=$BUILD_DIR/qml

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ubuntu-ui-toolkit/+bug/1518106/+subscriptions


References