Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
package-helpers
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
trisquel
package-helpers
Commits
82e2e3ed
Commit
82e2e3ed
authored
10 years ago
by
Ruben Rodriguez
Browse files
Options
Downloads
Plain Diff
Merge branch 'belenos' of
ssh://devel.trisquel.info:10022/trisquel/package-helpers
into belenos
parents
b4cdaa2f
a6f445d7
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
helpers/config
+58
-65
58 additions, 65 deletions
helpers/config
helpers/make-cron
+31
-0
31 additions, 0 deletions
helpers/make-cron
helpers/make-ubuntu-release-upgrader
+8
-9
8 additions, 9 deletions
helpers/make-ubuntu-release-upgrader
with
97 additions
and
74 deletions
helpers/config
+
58
−
65
View file @
82e2e3ed
#!/bin/bash
#!/bin/bash
#
#
# Copyright (C) 2008-2010 Rubén Rodríguez <ruben@trisquel.info>
# Copyright (C) 2008-2010 Rubén Rodríguez <ruben@trisquel.info>
# Copyright (C) 2014 Santiago Rodriguez <santi@trisquel.info>
#
#
# This program is free software; you can redistribute it and/or modify
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# it under the terms of the GNU General Public License as published by
...
@@ -18,29 +19,20 @@
...
@@ -18,29 +19,20 @@
#
#
set
-e
set
-e
export
LANG
=
C
LC_TIME
=
C
PACKAGE
=
$(
echo
$0
|/bin/sed s/make-//g
)
PACKAGE
=
$(
echo
$0
|/bin/sed s/make-//g
)
export
DATE
=
$(
date
+
'%a, %d %b %Y %T %z'
)
export
DATA
=
$PWD
/DATA/
$PACKAGE
export
DATA
=
$PWD
/DATA/
$PACKAGE
if
!
[
1
$COMPONENT
=
"1main"
]
if
!
[
1
$COMPONENT
=
"1main"
]
then
then
COMPONENT
=
${
COMPONENT
:-
universe
}
COMPONENT
=
${
COMPONENT
:-
universe
}
/bin/sed
's/^enable.*/enable: false/g'
-i
/etc/pkgbinarymangler/
*
.conf
export
NO_PKG_MANGLE
=
1
fi
if
[
-f
/CurrentlyBuilding
]
then
echo
"Already running
$(
cat
/CurrentlyBuilding
)
"
echo
"If
$(
cat
/CurrentlyBuilding
)
broke and nothing is actually running"
echo
"remove /CurrentlyBuilding and run this script again"
exit
1
else
echo
"Package:
$PACKAGE
Component:
$COMPONENT
"
>
/CurrentlyBuilding
fi
fi
[
-d
PACKAGES
]
||
mkdir
PACKAGES
[
-d
PACKAGES
]
||
mkdir
PACKAGES
[
-d
/proc/sys
]
||
mount proc /proc
-t
proc
hostname
devel.trisquel.info
export
DEBIAN_FRONTEND
=
noninteractive
export
DEBIAN_FRONTEND
=
noninteractive
export
DEBEMAIL
=
trisquel-devel@listas.trisquel.info
export
DEBEMAIL
=
trisquel-devel@listas.trisquel.info
...
@@ -54,13 +46,7 @@ export UPSTREAMRELEASE=14.04
...
@@ -54,13 +46,7 @@ export UPSTREAMRELEASE=14.04
MIRROR
=
http://archive.ubuntu.com/ubuntu
MIRROR
=
http://archive.ubuntu.com/ubuntu
DEVELMIRROR
=
http://devel.trisquel.info/trisquel/
$CODENAME
DEVELMIRROR
=
http://devel.trisquel.info/trisquel/
$CODENAME
LOCALMIRROR
=
http://archive.trisquel.info/trisquel
LOCALMIRROR
=
http://archive.trisquel.info/trisquel
LOCAL_APT
=
`
mktemp
-d
`
cat
<<
EOF
> /etc/lsb-release
DISTRIB_ID=Trisquel
DISTRIB_RELEASE=
$REVISION
DISTRIB_CODENAME=
$CODENAME
DISTRIB_DESCRIPTION="Trisquel
$REVISION
"
EOF
replace
(){
replace
(){
find
$3
-type
f
-not
-iregex
'.*changelog.*'
-not
-iregex
'.*copyright.*'
-execdir
/bin/sed
--follow-symlinks
-i
s^
"
$1
"
^
"
$2
"
^g
{}
\;
find
$3
-type
f
-not
-iregex
'.*changelog.*'
-not
-iregex
'.*copyright.*'
-execdir
/bin/sed
--follow-symlinks
-i
s^
"
$1
"
^
"
$2
"
^g
{}
\;
...
@@ -72,42 +58,59 @@ echo | dch -D $CODENAME -v $(/bin/sed -n '1s/^.*(\(.*\)).*/\1'+${REVISION}trisqu
...
@@ -72,42 +58,59 @@ echo | dch -D $CODENAME -v $(/bin/sed -n '1s/^.*(\(.*\)).*/\1'+${REVISION}trisqu
/bin/sed
"/-- Trisquel/s/.*/ -- Trisquel GNU
\/
Linux developers <trisquel-devel@listas.trisquel.info>
$DATE
/"
-i
debian/changelog
/bin/sed
"/-- Trisquel/s/.*/ -- Trisquel GNU
\/
Linux developers <trisquel-devel@listas.trisquel.info>
$DATE
/"
-i
debian/changelog
}
}
rm
-rf
PACKAGES/
$PACKAGE
mkdir
PACKAGES/
$PACKAGE
cd
PACKAGES/
$PACKAGE
cat
<<
EOF
> /etc/apt/sources.list
#Setup local apt
deb
$MIRROR
$UPSTREAM
main universe
deb
$MIRROR
$UPSTREAM
-updates main universe
trap
"rm -rf
${
LOCAL_APT
}
"
0 HUP INT QUIT ILL ABRT FPE SEGV PIPE TERM
deb
$MIRROR
$UPSTREAM
-security main universe
mkdir
-p
${
LOCAL_APT
}
/var/lib/apt/partial
mkdir
-p
${
LOCAL_APT
}
/var/cache/apt/archives/partial
mkdir
-p
${
LOCAL_APT
}
/etc/
mkdir
-p
${
LOCAL_APT
}
/var/lib/dpkg
touch
${
LOCAL_APT
}
/var/lib/dpkg/status
touch
${
LOCAL_APT
}
/etc/trusted.gpg
cat
<<
EOF
>
${
LOCAL_APT
}
/etc/apt.conf
Dir::State "
${
LOCAL_APT
}
/var/lib/apt";
Dir::State::status "
${
LOCAL_APT
}
/var/lib/dpkg/status";
Dir::Etc::SourceList "
${
LOCAL_APT
}
/etc/apt.sources.list";
Dir::Cache "
${
LOCAL_APT
}
/var/cache/apt";
pkgCacheGen::Essential "none";
Dir::Etc::Trusted "
${
LOCAL_APT
}
/etc/trusted.gpg";
EOF
if
[
-f
trusted.local.gpg
]
then
cp
trusted.local.gpg
"
${
LOCAL_APT
}
/etc/trusted.gpg"
else
#Trisquel key
apt-key
--keyring
${
LOCAL_APT
}
/etc/trusted.gpg adv
--keyserver
keyserver.ubuntu.com
--recv-keys
B4EFB9F38D8AEBF1
#Ubuntu gpg keys
apt-key
--keyring
${
LOCAL_APT
}
/etc/trusted.gpg adv
--keyserver
keyserver.ubuntu.com
--recv-keys
40976EAF437D05B5
apt-key
--keyring
${
LOCAL_APT
}
/etc/trusted.gpg adv
--keyserver
keyserver.ubuntu.com
--recv-keys
3B4FE6ACC0B21F32
fi
cat
<<
EOF
>
${
LOCAL_APT
}
/etc/apt.sources.list
deb-src
$MIRROR
$UPSTREAM
main universe
deb-src
$MIRROR
$UPSTREAM
main universe
deb-src
$MIRROR
$UPSTREAM
-updates main universe
deb-src
$MIRROR
$UPSTREAM
-updates main universe
deb-src
$MIRROR
$UPSTREAM
-security main universe
deb-src
$MIRROR
$UPSTREAM
-security main universe
#deb
$LOCALMIRROR
$CODENAME
main
#deb
$LOCALMIRROR
$CODENAME
-updates main
#deb
$LOCALMIRROR
$CODENAME
-security main
deb
$DEVELMIRROR
$CODENAME
main
#deb-src
$DEVELMIRROR
$CODENAME
main
EOF
EOF
[
"1
$EXTERNAL
"
!=
"1"
]
&&
eval echo
"
$EXTERNAL
"
>>
/etc/apt/sources.list
[
"1
$EXTERNAL
"
!=
"1"
]
&&
eval echo
"
$EXTERNAL
"
>>
${
LOCAL_APT
}
/etc/apt.sources.list
[
"1
$SIGNKEY
"
!=
"1"
]
&&
apt-key adv
--recv-keys
--keyserver
keyserver.ubuntu.com
$SIGNKEY
apt-get update
[
"1
$SIGNKEY
"
!=
"1"
]
&&
apt-key
--keyring
${
LOCAL_APT
}
/etc/trusted.gpg adv
--recv-keys
--keyserver
keyserver.ubuntu.com
$SIGNKEY
apt-get
install
--force-yes
-y
devscripts
if
[
$PACKAGE
=
linux
]
#Cleanup
then
rm
-rf
PACKAGES/
$PACKAGE
apt-get
--force-yes
-y
build-dep linux-libc-dev
mkdir
PACKAGES/
$PACKAGE
apt-get
source
linux-libc-dev
--download-only
cd
PACKAGES/
$PACKAGE
dpkg-source
-x
--skip-patches
*
.dsc
source
else
#Get package and uncompress it
[
1
$LOCALDEPENDS
=
1true
]
||
apt-get
--force-yes
-y
build-dep
$PACKAGE
apt-get update
-c
$LOCAL_APT
/etc/apt.conf
apt-get
source
$PACKAGE
--download-only
apt-get
source
$PACKAGE
--download-only
-c
${
LOCAL_APT
}
/etc/apt.conf
dpkg-source
-x
--skip-patches
*
.dsc
source
dpkg-source
-x
--skip-patches
*
.dsc
source
fi
find
-maxdepth
1
-type
f | xargs
rm
find
-maxdepth
1
-type
f | xargs
rm
cd source
cd source
...
@@ -122,12 +125,7 @@ do
...
@@ -122,12 +125,7 @@ do
done
done
compile
(){
compile
(){
if
[
1
$LOCALDEPENDS
=
1true
]
then
DEPENDS
=
$(
/bin/sed
-n
'/Build-Dep/,/^[a-zA-W0-9]/ p'
debian/control |
head
-n
-1
| /bin/sed
's/.*://; s/(.*)//; s/\[.*\]//; s/,//g'
|xargs
echo
-n
)
echo
Installing Build-Depends:
$DEPENDS
apt-get
--force-yes
-y
install
$DEPENDS
fi
PROCESSORS
=
1
PROCESSORS
=
1
if
[
1
$PARALLEL
!=
"1false"
]
if
[
1
$PARALLEL
!=
"1false"
]
...
@@ -135,22 +133,17 @@ then
...
@@ -135,22 +133,17 @@ then
PROCESSORS
=
$(
grep
processor /proc/cpuinfo |
wc
-l
)
PROCESSORS
=
$(
grep
processor /proc/cpuinfo |
wc
-l
)
fi
fi
if
[
1
$QUILT
!=
1skip
]
;
then
if
[
1
$QUILT
!=
1skip
]
;
then
export
QUILT_PATCHES
=
debian/patches
export
QUILT_PATCHES
=
debian/patches
[
-s
debian/patches/series
]
&&
quilt push
-a
[
-s
debian/patches/series
]
&&
quilt push
-a
fi
fi
if
[
$FAKEROOT
]
cd
..
then
dpkg-source
-b
source
/bin/sed
'/nobody/ s_/usr/sbin/nologin_/bin/bash_'
-i
/etc/passwd
rm
-rf
${
LOCAL_APT
}
chown
nobody ../
-R
echo
"Trisquel source package built!"
su nobody
-c
'dpkg-buildpackage -us -uc -j$PROCESSORS -rfakeroot'
else
dpkg-buildpackage
-us
-uc
-j
$PROCESSORS
fi
rm
/CurrentlyBuilding
umount /proc
}
}
sedhelper2
(){
sedhelper2
(){
...
...
This diff is collapsed.
Click to expand it.
helpers/make-cron
0 → 100644
+
31
−
0
View file @
82e2e3ed
#!/bin/sh
#
# Copyright (C) 2014 Andrew M. Lindley <andrew@andrewlindley.co.uk>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#
VERSION
=
1
.
./config
rm
debian/examples/crontab2english.pl
sed
'/crontab2english.pl/,/License: Artistic/d;/License: Artistic/,/common-licenses/d'
-i
debian/copyright
changelog
"Removed non-free example #10868"
compile
This diff is collapsed.
Click to expand it.
helpers/make-ubuntu-release-upgrader
+
8
−
9
View file @
82e2e3ed
#!/bin/sh
#!/bin/sh
#
#
# Copyright (C) 2008-2010 Rubén Rodríguez <ruben@trisquel.info>
# Copyright (C) 2008-2010 Rubén Rodríguez <ruben@trisquel.info>
# Copyright (C) 2014 Santiago Rodriguez <santi@trisquel.info>
#
#
# This program is free software; you can redistribute it and/or modify
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# it under the terms of the GNU General Public License as published by
...
@@ -20,8 +21,9 @@
...
@@ -20,8 +21,9 @@
# Note that you would need to publish and sign the upgrade tarball
# Note that you would need to publish and sign the upgrade tarball
# gpg -ba release_name.tar.gz
# gpg -ba release_name.tar.gz
# Also, don't forget to update the meta-release files at archive and packages.t.i
# Also, don't forget to update the meta-release files at archive and packages.t.i
# The "obsoletes" list from ubuntu has been removed
VERSION
=
1
0
VERSION
=
1
1
.
./config
.
./config
...
@@ -35,10 +37,6 @@ sed s/self._test_and_warn_on_dropped_fglrx_support/#self._test_and_warn_on_dropp
...
@@ -35,10 +37,6 @@ sed s/self._test_and_warn_on_dropped_fglrx_support/#self._test_and_warn_on_dropp
sed
'/nvidia/d'
DistUpgrade/build-tarball.sh
-i
sed
'/nvidia/d'
DistUpgrade/build-tarball.sh
-i
rm
tests/test-data/xorg.conf.fglrx
rm
tests/test-data/xorg.conf.fglrx
#% Make sure nvidia-common and fglrx-modaliases are not installed
apt-get remove
--purge
-y
nvidia-common
||
true
apt-get remove
--purge
-y
fglrx-modaliases
||
true
#https://bugs.launchpad.net/ubuntu/+source/python-defaults/+bug/990740
#https://bugs.launchpad.net/ubuntu/+source/python-defaults/+bug/990740
cat
<<
EOF
>> DistUpgrade/DistUpgradeQuirks.py
cat
<<
EOF
>> DistUpgrade/DistUpgradeQuirks.py
...
@@ -195,7 +193,6 @@ EOF
...
@@ -195,7 +193,6 @@ EOF
rm
DistUpgrade/EOLReleaseAnnouncement.html DistUpgrade/ReleaseAnnouncement.html
rm
DistUpgrade/EOLReleaseAnnouncement.html DistUpgrade/ReleaseAnnouncement.html
apt-get
install
-q
-y
parsewiki
parsewiki DistUpgrade/EOLReleaseAnnouncement
>
DistUpgrade/EOLReleaseAnnouncement.html
parsewiki DistUpgrade/EOLReleaseAnnouncement
>
DistUpgrade/EOLReleaseAnnouncement.html
parsewiki DistUpgrade/ReleaseAnnouncement
>
DistUpgrade/ReleaseAnnouncement.html
parsewiki DistUpgrade/ReleaseAnnouncement
>
DistUpgrade/ReleaseAnnouncement.html
...
@@ -265,9 +262,8 @@ chmod 755 DistUpgrade/trisquel-postinstall.sh
...
@@ -265,9 +262,8 @@ chmod 755 DistUpgrade/trisquel-postinstall.sh
replace changelogs.ubuntu.com packages.trisquel.info
.
replace changelogs.ubuntu.com packages.trisquel.info
.
/bin/sed
-i
's/�~Lubuntu/�~Ltrisquel/g; s/被ubuntu/被trisquel/g; s#http://launchpad.net/ubuntu/+source/%s/%s/+changelog#http://trisquel.info/project/issues#g; s/<.*@ubuntu.com/<info@trisquel.info/g; s/ ubuntu\n/ trisquel\n/g; s/ubuntu\ /trisquel\ /g; s/\ ubuntu/\ trisquel/g; s/Ubuntu/Trisquel/g; s/ubuntu-desktop/trisquel-/g; s/www.ubuntu.com/trisquel.info/g; s/www.ubuntulinux.org/trisquel.info/g '
po/
*
.po
$(
find |
grep
py
$)
$(
find |
grep
'\.glade$'
)
/bin/sed
-i
's/�~Lubuntu/�~Ltrisquel/g; s/被ubuntu/被trisquel/g; s#http://launchpad.net/ubuntu/+source/%s/%s/+changelog#http://trisquel.info/project/issues#g; s/<.*@ubuntu.com/<info@trisquel.info/g; s/ ubuntu\n/ trisquel\n/g; s/ubuntu\ /trisquel\ /g; s/\ ubuntu/\ trisquel/g; s/Ubuntu/Trisquel/g; s/ubuntu-desktop/trisquel-/g; s/www.ubuntu.com/trisquel.info/g; s/www.ubuntulinux.org/trisquel.info/g '
po/
*
.po
$(
find
-type
f
|
grep
py
$)
$(
find
-type
f
|
grep
'\.glade$'
)
apt-get
install
--force-yes
-y
rpl
rpl 11
\.
04 5
\.
0 DistUpgrade/
*
.ui
rpl 11
\.
04 5
\.
0 DistUpgrade/
*
.ui
rpl 11
\.
04 5
\.
0 po/
*
-R
rpl 11
\.
04 5
\.
0 po/
*
-R
rpl 11
\.
10 5
\.
5 DistUpgrade/
*
.ui
rpl 11
\.
10 5
\.
5 DistUpgrade/
*
.ui
...
@@ -323,8 +319,11 @@ for i in core gtk qt; do
...
@@ -323,8 +319,11 @@ for i in core gtk qt; do
sed
"/Package: trisquel-release-upgrader-
$i
/ s/
$/
\n
Provides: ubuntu-release-upgrader-
$i
/"
-i
debian/control
sed
"/Package: trisquel-release-upgrader-
$i
/ s/
$/
\n
Provides: ubuntu-release-upgrader-
$i
/"
-i
debian/control
done
done
#ubuntu-drivers-common is not a build-dep, nor avaliable in trisquel.
sed
-i
's/cp \/usr\/share\/ubuntu-drivers-common\/obsolete/touch/g'
DistUpgrade/build-tarball.sh
changelog
"Compiled for Trisquel"
changelog
"Compiled for Trisquel"
PARALLEL
=
false
compile
PARALLEL
=
false
compile
cp
../dist-upgrader
*
/root
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment