Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
I
inary
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
1
Konular (issue)
1
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
SulinOS
inary
Commits
7d9abcab
Kaydet (Commit)
7d9abcab
authored
Agu 12, 2020
tarafından
sulincix
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
configure script added
üst
247ee8f0
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
70 additions
and
4 deletions
+70
-4
configure
configure
+54
-0
setup.py
setup.py
+16
-4
No files found.
configure
0 → 100755
Dosyayı görüntüle @
7d9abcab
#!/bin/bash
setcfg
(){
echo
-ne
"
$1
[y/n]"
read
-sn
1 c
echo
-ne
"(
$c
)"
if
[
"
$c
"
==
"y"
]
||
[
"
$c
"
==
"Y"
]
;
then
echo
"
$2
=y"
>>
.config
else
echo
"
$2
=n"
>>
.config
fi
echo
}
ask_cfg
(){
echo
"Inary configure :"
echo
"#inary config file"
>
.config
setcfg
"Native Language Support"
"NLS_SUPPORT"
setcfg
"Additional scripts"
"ADDITIONAL_SCRIPTS"
echo
-e
"
\"
.config
\"
file changed."
}
yes
(){
while
true
;
do
echo
-ne
"
$1
"
done
}
usage
(){
cat
<<
EOF
./configure [OPTIONS]
Options list:
--yes-all : enable all
--no-all : disable all
--help : show this message
EOF
}
for
i
in
$@
;
do
if
[
"
$i
"
==
"--yes-all"
]
;
then
yes
y | ask_cfg
exit
0
elif
[
"
$i
"
==
"--no-all"
]
;
then
yes
n | ask_cfg
exit
0
elif
[
"
$i
"
==
"--help"
]
;
then
usage
exit
0
fi
done
ask_cfg
setup.py
Dosyayı görüntüle @
7d9abcab
...
...
@@ -35,6 +35,18 @@ CONFIG_DIR = "/etc/inary"
MIMEFILE_DIR
=
"/usr/share/mime/packages"
TMPFILES_DIR
=
"/usr/lib/tmpfiles.d"
#config file
if
not
os
.
path
.
isfile
(
".config"
):
print
(
"No config file found. You must run ./configure first."
)
exit
(
127
)
cfg
=
open
(
".config"
,
"r"
)
.
readlines
()
def
getConfig
(
name
=
""
):
for
line
in
cfg
:
if
name
in
line
:
return
"y"
in
line
.
split
(
"="
)[
1
]
return
False
class
Build
(
build
):
def
run
(
self
):
...
...
@@ -106,8 +118,8 @@ class BuildPo(build):
class
Install
(
install
):
def
run
(
self
):
install
.
run
(
self
)
#FIXME enable this
#
self.installi18n()
if
getConfig
(
"NLS_SUPPORT"
):
self
.
installi18n
()
self
.
generateConfigFile
()
def
finalize_options
(
self
):
...
...
@@ -204,7 +216,7 @@ setup(name="inary",
'test'
:
Test
},
data_files
=
[(
CONFIG_DIR
,
[
"config/inary.conf"
,
"config/mirrors.conf"
]),
(
MIMEFILE_DIR
,
[
"build/inary.xml"
])],
scripts
=
[
'inary-cli'
,
scripts
=
(
[
'inary-cli'
,
'scripts/pspec2po'
,
'scripts/revdep-rebuild'
,
'scripts/sulinstrapt'
,
...
...
@@ -219,7 +231,7 @@ setup(name="inary",
'scripts/detect-file-dep'
,
'scripts/uninary'
,
'scripts/update-inary-cache'
,
'scripts/version-bump'
],
'scripts/version-bump'
]
if
getConfig
(
"ADDITIONAL_SCRIPTS"
)
else
[
'inary-cli'
])
,
classifiers
=
[
'Development Status :: 5 - Production/Stable'
,
'Environment :: Console'
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment