-
Notifications
You must be signed in to change notification settings - Fork 17
Modifications for Slackware support #30
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
Open
steven-7m
wants to merge
1
commit into
gnustep:master
Choose a base branch
from
steven-7m:slackware-support
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,65 @@ | ||
| #!/bin/bash | ||
|
|
||
|
|
||
| . /etc/os-release | ||
| version=${VERSION//[\.]/-} | ||
|
|
||
| echo | ||
| echo "The Slackware dependency relies on you (the user currently running gnustep-web-install) be part of the sudoers." | ||
| echo "Also, you need to have slackpkg setup and configured to allow the script to resolve any missing dependencies." | ||
| echo "If you are not currently a sudoer or do not have slackpkg setup, please exit here and configure these two items." | ||
| echo | ||
| read -p "Continue with the procedure? (Y/N): " confirm && [[ $confirm == [yY] || $confirm == [yY][eE][sS] ]] || exit 1 | ||
| echo | ||
|
|
||
| echo "GNUstep / Slackware ${VERSION} dependency installation" | ||
| echo "------------------------------------------------" | ||
| echo | ||
|
|
||
|
|
||
| if [[ "$version" != "15-0" ]]; then | ||
| echo "Only Slackware version 15.0 is supported at the moment" | ||
| exit | ||
| fi | ||
|
|
||
| # check if slackpkg is setup (a mirror has been chosen) | ||
|
|
||
| mirror=$(grep -v '^#' /etc/slackpkg/mirrors) | ||
|
|
||
| if [[ -z ${mirror} ]]; then | ||
| echo "slackpkg not setup" | ||
| exit 1 | ||
| else | ||
| echo "slackpkg mirror set to:" | ||
| echo | ||
| echo "${mirror}" | ||
| echo | ||
| echo "We'll use that to install missing packages (if any)" | ||
| echo | ||
| fi | ||
|
|
||
|
|
||
| # s l a c k w a r e 15 package dependencies | ||
| declare -A packages[15-0]="gcc gcc-objc llvm libjpeg-turbo libtiff libpng libxml2 libxslt " | ||
| packages[15-0]+="gdb gnutls libffi icu4c cairo make makedepend windowmaker cmake " | ||
| packages[15-0]+="libblockdev openssl openssl-solibs imagemagick " | ||
| packages[15-0]+="libxkbcommon wayland freetype-2 " | ||
|
|
||
|
|
||
|
|
||
| # because we want to cycle through the dependency list based on the slackware version, required a | ||
| # slighlty more complex for loop using the array index and indirection (the ! before packages below is indirection) | ||
| for pkg in ${packages["${version}"]}; do | ||
| if [[ -n $(find /var/log/packages/${pkg}*) ]]; then | ||
| printf 'Looking for package %-15s: %s\n' "$pkg" "found" | ||
| else | ||
| echo "Trying to install missing pkg ${pkg}" | ||
| sudo /usr/sbin/slackpkg install ${pkg} | ||
| fi | ||
| done | ||
|
|
||
| echo | ||
| echo "Slackware dependencies resolved, have fun!" | ||
|
|
||
|
|
||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,18 @@ | ||
| #!/bin/sh | ||
| # we have a new path | ||
| export PATH=$PATH:/usr/GNUstep/System/Tools | ||
|
|
||
| . /usr/GNUstep/System/Library/Makefiles/GNUstep.sh | ||
|
|
||
| pwd | ||
| cd apps-gorm || exit 1 | ||
| make debug=yes | ||
| sudo -E make GNUSTEP_INSTALLATION_DOMAIN=SYSTEM debug=yes install | ||
|
|
||
| echo | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This addresses #20, I like it |
||
| echo "GNUstep web install complete. You will need to source in this file into your shell using this command (the leading . is required):" | ||
| echo | ||
| echo ". /usr/GNUstep/System/Library/Makefiles/GNUstep.sh" | ||
| echo | ||
|
|
||
| echo "Please add this to your ~/.bash_profile (or your shell's equivalent) so the GNUstep environment is always set." | ||
| echo "Welcome to GNUstep!" | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -4,7 +4,11 @@ export USER=`whoami` | |
| COMMAND="apt" | ||
|
|
||
| # Add distro specific variables... | ||
| . /etc/lsb-release | ||
| if [[ -f /etc/lsb-release ]]; then | ||
| . /etc/lsb-release | ||
| elif [[ -f /etc/os-release ]]; then | ||
| . /etc/os-release | ||
| fi | ||
|
|
||
| # Install SUDO if needed... | ||
| if [ ! -e /usr/bin/sudo ]; then | ||
|
|
@@ -29,15 +33,18 @@ if [ "${DISTRIB_ID}" = "Ubuntu" ]; then | |
| fi | ||
| fi | ||
|
|
||
| # Add to sudoers | ||
| if [ "${DISTRIB_ID}" != "Ubuntu" ]; then | ||
| if [ ! -e /etc/sudoers.d/${USER} ]; then | ||
| echo "Adding ${USER} to sudoers..." | ||
| echo "Please enter the root user's password." | ||
| su -c 'echo "${USER} ALL=(ALL:ALL) ALL" > /etc/sudoers.d/${USER}' | ||
| else | ||
| echo "${USER} is already a member of sudo users." | ||
| fi | ||
| # Add to sudoers. slackware dependency install will prompt user to set it up | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I made this section optional, PTAL after rebasing |
||
| # prior to completing the gnustep-web-install | ||
| if [ "${ID}" != "slackware" ]; then | ||
| if [ "${DISTRIB_ID}" != "Ubuntu" ]; then | ||
| if [ ! -e /etc/sudoers.d/${USER} ]; then | ||
| echo "Adding ${USER} to sudoers..." | ||
| echo "Please enter the root user's password." | ||
| su -c 'echo "${USER} ALL=(ALL:ALL) ALL" > /etc/sudoers.d/${USER}' | ||
| else | ||
| echo "${USER} is already a member of sudo users." | ||
| fi | ||
| fi | ||
| fi | ||
|
|
||
| # Install git and curl if needed... | ||
|
|
@@ -49,4 +56,4 @@ fi | |
| if [ ! -e /usr/bin/git ]; then | ||
| echo "Installing git" | ||
| sudo ${COMMAND} install git | ||
| fi | ||
| fi | ||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is partially addressing #38