Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sudo install fix #14

Open
wants to merge 3 commits into
base: unstable
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@ Prerequisites

$ sudo apt-get build-dep qt4-qmake

$ sudo apt-get gdb "^libxcb.*" libx11-xcb-dev libglu1-mesa-dev libxrender-dev hunspell

* The components listed above are valid for both Ubuntu 11.04 and 12.04, except for libxcb-icccm1-dev which is libxcb-icccm4-dev on 12.04

* CMake version 2.8.7 will be fetched and used for the build; there is no need to install it.
Expand Down
25 changes: 10 additions & 15 deletions build-webos-desktop.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1734,20 +1734,15 @@ if [ -d $BASE/luna-sysmgr ] ; then
rm -f $BASE/luna-sysmgr/luna-desktop-build*.stamp
fi

## TODO: Remove this temporary fix once pbnjson incremented past 7
if [ -d "$BASE/pbnjson" ] && [ -e "$BASE/pbnjson/luna-desktop-build-7.stamp" ] ; then
rm -f $BASE/pbnjson/luna-desktop-build-7.stamp
fi

# Build a local version of cmake 2.8.7 so that cmake-modules-webos doesn't have to write to the OS-supplied CMake modules directory
build cmake
build cmake-modules-webos 12

build cjson 35
build pbnjson 7
build pmloglib 21
build pbnjson 14
build pmloglib 22
build nyx-lib 58
build luna-service2 149
build luna-service2 150
#build qt4 4
build_qt5
build npapi-headers 0.4
Expand All @@ -1756,12 +1751,12 @@ build luna-webkit-api 3

build luna-sysmgr-ipc 2
build luna-sysmgr-ipc-messages 3
build luna-sysmgr-common 8
build luna-sysmgr-common 11
build luna-sysmgr $LSM_TAG
build keyboard-efigs 5
build keyboard-efigs 12

build webappmanager 5
build luna-init 1.03
build luna-init 1.04
build luna-prefs 1.01
build luna-sysservice 3
build librolegen 16
Expand All @@ -1776,10 +1771,10 @@ build core-apps 2
#build isis-browser 0.21
build isis-fonts v0.1

build foundation-frameworks 1.0
build foundation-frameworks 1.0.1
build mojoservice-frameworks 1.0
build loadable-frameworks 1.0.1
build app-services 1.02
build app-services 1.03
build mojolocation-stub 2
build pmnetconfigmanager-stub 3

Expand All @@ -1800,10 +1795,10 @@ build node-addon pmlog 10
build node-addon dynaload 11

build leveldb 1.9 0
build db8 63
build db8 72 #74
build configurator 49
build hunspell 1.3 2
build smartkey-hun 2
build smartkey-hun 6

build activitymanager 110
build pmstatemachineengine 13
Expand Down
12 changes: 12 additions & 0 deletions install-webos-desktop.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,18 @@ export SCRIPT_DIR=$PWD

source ./webos-desktop-common.sh

if [ -z "$BASE" ]; then
echo "You have a problem with your local.sh script which is"
echo "preventing install-luna-sysmgr.sh from locating your"
echo "binaries. Please correct the problem and try again."
exit
fi

if [ $EUID -ne 0 ]; then
echo "This script must be run as root."
exit
fi

if [ "$1" = "--help" ] ; then
echo "Usage: sudo ./install-luna-sysmgr.sh [OPTION]"
echo "Installs the luna-sysmgr component and its dependencies."
Expand Down
6 changes: 5 additions & 1 deletion local.sh.default
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,11 @@
## This has been the default target location for build-desktop since its initial creation
##

export BASE="${HOME}/luna-desktop-binaries"
if [ -z "${SUDO_USER}" ]; then
export BASE="${HOME}/luna-desktop-binaries"
else
export BASE="$(getent passwd ${SUDO_USER} | grep -o [^:]*:[^:]*$ | grep -o ^[^:]*)/luna-desktop-binaries"
fi


#########################################
Expand Down