added function sdk_init in libdevuansdk
This commit is contained in:
parent
fb9cb40d33
commit
d1a3995bff
20
libdevuansdk
20
libdevuansdk
|
|
@ -28,6 +28,15 @@ setopt pushdsilent
|
|||
|
||||
SDK_LIB=${SDK_LIB:-`pwd`}
|
||||
|
||||
sdk_init(){
|
||||
|
||||
fn sdk_init
|
||||
|
||||
req=(os release version mirror section)
|
||||
ckreq || { error "configuration is missing"; zshexit; return 1 }
|
||||
|
||||
# setting core, base, and other packages
|
||||
|
||||
[[ "$core_packages" = "" ]] && {
|
||||
# core packages for the system
|
||||
core_packages=(devuan-keyring debian-keyring)
|
||||
|
|
@ -42,8 +51,9 @@ SDK_LIB=${SDK_LIB:-`pwd`}
|
|||
# other system packages
|
||||
system_packages=(sysvinit ssh)
|
||||
}
|
||||
|
||||
# default size for an img
|
||||
imgsize=${imgsize:-1337}
|
||||
imgsize=${imgsize:-1337M}
|
||||
|
||||
|
||||
## libdevuansdk-specific settings
|
||||
|
|
@ -52,13 +62,12 @@ strapdir="${workdir}/${os}-${release}-${version}"
|
|||
outdir="$H/builds"
|
||||
|
||||
|
||||
|
||||
# KatolaZ says: wtf????
|
||||
[[ -r $SDK_LIB/libdevuansdk ]] || {
|
||||
print "Devuan SDK is not installed in: $SDK_LIB"
|
||||
print "export SDK_LIB if installed on a different path"
|
||||
}
|
||||
|
||||
|
||||
########################
|
||||
## Load Zuper extensions
|
||||
# conclude initialization
|
||||
|
|
@ -114,9 +123,6 @@ notice "Loading Devuan SDK library v$devuan_sdk_version"
|
|||
|
||||
# ...
|
||||
|
||||
req=(os release version mirror section)
|
||||
ckreq || { error "configuration is missing"; zshexit; return 1 }
|
||||
|
||||
act "library succesfully loaded"
|
||||
|
||||
# default operational paths
|
||||
|
|
@ -124,3 +130,5 @@ R=${R:-$SDK_PREFIX}
|
|||
H=${H:-$SDK_HOME}
|
||||
E=${E:-$SDK_CONF}
|
||||
|
||||
} # Closes sdk_init
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue