Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
etercifs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
etersoft
etercifs
Commits
e575855a
Commit
e575855a
authored
Jan 20, 2012
by
Pavel Shilovsky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix build on CentOS
parent
55b96cb7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
24 deletions
+23
-24
functions.sh
etercifs/functions.sh
+23
-24
No files found.
etercifs/functions.sh
View file @
e575855a
...
...
@@ -123,54 +123,53 @@ check_for_centos()
detect_etercifs_sources
()
{
FIRSTNUM
=
`
echo
$KERNEL
|
cut
-d
"."
-f
1
`
if
[
"
$FIRSTNUM
"
-eq
2
]
;
then
[
-n
"
$ETERCIFS_SOURCES_LIST
"
]
||
ETERCIFS_SOURCES_LIST
=
$DATADIR
/sources/kernel-source-etercifs-2
*
KERNEL_STRING
=
$KERNEL
elif
[
"
$FIRSTNUM
"
-eq
3
]
;
then
[
-n
"
$ETERCIFS_SOURCES_LIST
"
]
||
ETERCIFS_SOURCES_LIST
=
$DATADIR
/sources/kernel-source-etercifs-3
*
kernel_release2
KERNEL_STRING
=
$KERNEL2
fi
[
-n
"
`
ls
$ETERCIFS_SOURCES_LIST
`
"
]
||
fatal
"Etercifs kernel module sources does not installed!"
KERNEL_SOURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
$KERNEL_STRING
|
sort
-r
|
head
-n
1
`
# CentOS-RHEL specific part
check_for_centos
if
[
-n
"
$SPECIFIC_CENTOS
"
]
;
then
[
-n
"
$ETERCIFS_SOURCES_LIST
"
]
||
ETERCIFS_SOURCES_LIST
=
$DATADIR
/sources/kernel-source-etercifs-
*
if
[
-n
"
$OVZ_KERNEL
"
]
;
then
echo
"Building from legacy sources with patch for OpenVZ kernels 2.6.18-274.x from CentOS 5.7."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos-ovz'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos-ovz'
elif
[
"
$CENTOS
"
-eq
60
]
;
then
echo
"Building from legacy sources with patch for kernels 2.6.32-x.y from CentOS 6.0."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos60'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos60'
elif
[
"
$CENTOS
"
-eq
57
]
;
then
# The same as CentOS 5.6
echo
"Building from legacy sources with patch for kernels 2.6.18-274.x from CentOS 5.7."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos56'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos56'
elif
[
"
$CENTOS
"
-eq
56
]
;
then
echo
"Building from legacy sources with patch for kernels 2.6.18-238.x from CentOS 5.6."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos56'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos56'
elif
[
"
$CENTOS
"
-eq
55
]
;
then
echo
"Building from legacy sources with patch for kernels 2.6.18-194.x from CentOS 5.5."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos55'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos55'
elif
[
"
$CENTOS
"
-eq
54
]
;
then
echo
"Building from legacy sources with patch for kernels 2.6.18-164.x from CentOS 5.4."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos54'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos54'
elif
[
"
$CENTOS
"
-eq
53
]
;
then
echo
"Building from legacy sources with patch for kernels 2.6.18-128.x from CentOS 5.3."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos53'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos53'
elif
[
"
$CENTOS
"
-eq
52
]
;
then
echo
"Building from legacy sources with patch for kernels 2.6.18-92.x from CentOS 5.2."
KERNEL_S
OURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'centos52'
|
sort
-r
|
head
-n
1
`
KERNEL_S
TRING
=
'centos52'
else
echo
"Building from legacy sources."
KERNEL_SOURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
'legacy'
|
sort
-r
|
head
-n
1
`
KERNEL_STRING
=
'legacy'
fi
# end of CentOS-RHEL specific part
else
FIRSTNUM
=
`
echo
$KERNEL
|
cut
-d
"."
-f
1
`
if
[
"
$FIRSTNUM
"
-eq
2
]
;
then
[
-n
"
$ETERCIFS_SOURCES_LIST
"
]
||
ETERCIFS_SOURCES_LIST
=
$DATADIR
/sources/kernel-source-etercifs-2
*
KERNEL_STRING
=
$KERNEL
elif
[
"
$FIRSTNUM
"
-eq
3
]
;
then
[
-n
"
$ETERCIFS_SOURCES_LIST
"
]
||
ETERCIFS_SOURCES_LIST
=
$DATADIR
/sources/kernel-source-etercifs-3
*
kernel_release2
KERNEL_STRING
=
$KERNEL2
fi
fi
# end of CentOS-RHEL specific part
[
-n
"
`
ls
$ETERCIFS_SOURCES_LIST
`
"
]
||
fatal
"Etercifs kernel module sources does not installed!"
KERNEL_SOURCE_ETERCIFS_LINK
=
`
ls
-1
$ETERCIFS_SOURCES_LIST
|
grep
$KERNEL_STRING
|
sort
-r
|
head
-n
1
`
if
[
-z
"
$KERNEL_SOURCE_ETERCIFS_LINK
"
]
;
then
ETERCIFS_SOURCES_LIST
=
$DATADIR
/sources/kernel-source-etercifs-[0-9]
*
...
...
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