Compare commits

..

24 Commits

Author SHA1 Message Date
clrbuilder 6a7fac08d9 Update packages file for version 22060
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-24 19:02:11 +00:00
Patrick McCarty 932c2236a7 generateupstream: fix upstream file handling
My previous change to handling of the 'upstream' file assumed that the
file exists already, but this need not be true.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-24 10:12:34 -07:00
Patrick McCarty 6c92ce3160 sources: download files directly if SOURCES_URL undefined
When SOURCES_URL is not defined, the current behavior of extracting
source files from SRPMs in the latest published Clear Linux release has
proven to not work so well: It is not optimal when users are adding new
packages, modifying existing packages, not building from latest master,
etc.

Instead, run 'generateupstream' automatically so that source files are
downloaded from the remote locations listed in the spec file. This
target creates the 'upstream' file too, which becomes useful if the user
later defines SOURCES_URL, when 'upstream' is actively consumed.

In the event that download errors occur, as a fallback mechanism, try to
find the corresponding SRPM from a published release of Clear Linux OS.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-23 16:07:33 -07:00
Patrick McCarty 3e2219c07e sources: move srpm fetch code to separate target
I will reusing this code (largely unmodified) in the next commit, so
move it into a separate target to easily inspect changes.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-23 16:07:33 -07:00
Patrick McCarty f0d2523151 sources/generateupstream: properly handle curl errors
If any of the curl commands fail, it's better for the entire target to
fail. In this way, developers will be properly notified.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-23 14:25:51 -07:00
Patrick McCarty de39e64e29 Fix some indentation issues
Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-23 14:15:58 -07:00
Patrick McCarty 877fee6375 sources: follow SOURCES_URL redirects; remove noproxy requirement
The curl --no-proxy hint is not needed anymore, since Clear Linux OS has
an autoproxy, and curl will honor proxy environment variables.

Also, pass -L to curl to follow redirects, similarly to other curl calls
in this makefile.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-23 13:47:24 -07:00
Patrick McCarty e921a2a883 generateupstream: make URL extraction more robust
Improve the detection of source URLs by matching only non-commented
Source* lines with "://" present.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-23 13:30:21 -07:00
clrbuilder e00c76846b Update packages file for version 22010
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-20 18:32:15 +00:00
clrbuilder af2c0bea72 Update packages file for version 21970
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-18 19:02:08 +00:00
clrbuilder b99b7e8c25 Update packages file for version 21960
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-18 12:47:49 +00:00
clrbuilder 359d2a8379 Update packages file for version 21860
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-16 02:52:02 +00:00
clrbuilder d828f3a3ce Update packages file for version 21850
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-14 20:29:27 +00:00
clrbuilder 330876d190 Update packages file for version 21830
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-13 13:01:54 +00:00
Patrick McCarty 3bf5f39687 Revert "autospecnew: master branch should track origin/master"
The 'git branch' command fails at this stage because the master branch
is not initialized locally, but because the remote is also not
initialized, additional special incantations are needed to make this
work. Revert it for now so that users do not see an error message from
the 'git branch' command. A proper fix will follow later.

This reverts commit 71d9699bdd.
2018-04-12 18:05:45 -07:00
Patrick McCarty 71d9699bdd autospecnew: master branch should track origin/master
Because 'make koji' expects that master should track origin/master,
initialize the tracking branch during the autospecnew.

Signed-off-by: Patrick McCarty <patrick.mccarty@intel.com>
2018-04-12 17:46:01 -07:00
clrbuilder ded920ccb3 Update packages file for version 21810
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-12 13:01:47 +00:00
clrbuilder cc16065a09 Update packages file for version 21790
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-11 13:01:37 +00:00
clrbuilder 45f2185a25 Update packages file for version 21780
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-10 19:05:07 +00:00
clrbuilder 9ffc0b9640 Update packages file for version 21770
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-10 13:03:01 +00:00
clrbuilder 98c5937801 Update packages file for version 21760
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-09 20:56:43 +00:00
clrbuilder a50450212c Update packages file for version 21720
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-08 13:28:18 +00:00
clrbuilder ab77a99a47 Update packages file for version 21710
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-07 17:41:19 +00:00
clrbuilder 090bb77f92 Update packages file for version 21690
Signed-off-by: clrbuilder <clrbuilder@intel.com>
2018-04-06 15:50:48 +00:00
3 changed files with 126 additions and 37 deletions
+63 -32
View File
@@ -205,30 +205,12 @@ bumpnogit:
$(__missingsources): sources
#help sources: If SOURCES_URL is defined, download required upstream source
#help files from that location. Otherwise, try to extract source files from the
#help SRPM in the latest Clear Linux release, as specified by the LATEST_SRPMS
#help variable. This will run automatically, as a dependency. NOTE: A Koji
#help server can make use of this "make sources" command, since it lives in a
#help repo named "common". If you use this makefile in Koji, ensure
#help "make sources" continues to work for both remote and local builds, since
#help it is a prerequisite of several commands for building packages.
sources: upstream
ifneq ($(strip $(SOURCES_URL)),)
while read u; do \
case "$$u" in \
"") continue ;; \
*://*) n="$$u" ;; \
*) n="$(SOURCES_URL)/$$u" ;; \
esac; \
curl --fail --noproxy "*" "$$n" -o `basename "$$n"`; \
done < upstream
else
@tmp=$$(mktemp -d -p "."); \
# First argument is a Clear Linux build number (e.g. 22000)
define fetch-from-srpm
tmp=$$(mktemp -d -p "."); \
srpm=$$(rpmspec --srpm -q --qf "%{NVR}.src.rpm\n" $(SPECFILE)); \
if cd "$$tmp" && ! curl -f -L -O $(LATEST_SRPMS)/$$srpm; then \
echo "Failed to download $$srpm from latest Clear Linux release." >&2; \
echo "Run \"git pull\" and try again." >&2; \
if cd "$$tmp" && ! curl -s -S -f -L -O $(DOWNLOAD_MIRROR)/releases/$(1)/clear/source/SRPMS/$$srpm; then \
echo "Failed to download $$srpm from Clear Linux release $(1)." >&2; \
cd .. && rm -rf "$$tmp"; \
exit 1; \
fi; \
@@ -236,14 +218,58 @@ else
cd ..; \
srclist=$$(rpmspec --srpm -q --qf "[%{SOURCE}\n]" $(SPECFILE)); \
for s in $$srclist; do \
if ! mv "$$tmp"/$$s .; then \
if ! mv --no-clobber "$$tmp"/$$s .; then \
echo "Missing source file \"$$s\" in $${srpm}." >&2; \
rm -rf "$$tmp"; \
exit 1; \
fi; \
echo "Retrieved source file $$s ..."; \
done; \
rm -rf "$$tmp";
rm -rf "$$tmp"
endef
#help sources: If SOURCES_URL is defined, download required upstream source files
#help from that location. Otherwise, try to download source files according to the
#help URLs listed in the spec file. If any of the source files fail to download,
#help check for the relevant SRPM from published releases of Clear Linux OS, and
#help extract the files if found. Note that SRPMs are taken from the DOWNLOAD_MIRROR
#help location. This will run automatically, as a dependency. NOTE: A Koji server can
#help make use of this "make sources" command, since it lives in a repo named
#help "common". If you use this makefile in Koji, ensure "make sources" continues to
#help work for both remote and local builds, since it is a prerequisite of several
#help commands for building packages.
ifneq ($(strip $(SOURCES_URL)),)
sources: upstream
while read u; do \
case "$$u" in \
"") continue ;; \
*://*) n="$$u" ;; \
*) n="$(SOURCES_URL)/$$u" ;; \
esac; \
if ! curl --fail -L "$$n" -o `basename "$$n"`; then \
echo "Failed to download $$n"; \
exit 1; \
fi; \
done < upstream
else
sources:
@$(MAKE) generateupstream; \
[ $$? -eq 0 ] && exit 0; \
nvr="$$(rpmspec --srpm -q --qf '%{NAME}\t%{VERSION}\t%{RELEASE}\n' $(SPECFILE))"; \
latest_builds=$$(git -C $(TOPLVL)/projects/common tag -l | sort -rn); \
for b in $$latest_builds; do \
url="$(DOWNLOAD_MIRROR)/releases/$$b/clear/source/package-sources"; \
echo "Checking for source files in build $$b ..."; \
if grep -q "$$nvr" <(curl -s -f -L $$url); then \
$(call fetch-from-srpm,$$b); \
if [ $$? -eq 0 ]; then \
echo "Source files retrieved from build $$b"; \
exit 0; \
fi; \
fi; \
done; \
echo "Source files not found for package"; \
exit 1
endif
prekoji-checks:
@@ -365,15 +391,20 @@ install:
#help calculating their hashes. Autospec performs this step automatically, so ignore
#help it for packages managed with autospec.
generateupstream:
@rm -f upstream
@urls=$$(rpmspec -D '_vendor clr' -P $(SPECFILE) | grep Source | cut -d: -f2- | grep '://'); \
@[ -e upstream ] && mv upstream upstream.bak; \
urls=$$(rpmspec -D '_vendor clr' -P $(SPECFILE) | sed -n "s|^Source[0-9]*[[:blank:]]*:[[:blank:]]*\(..*://..*\)$$|\1|p"); \
for url in $$urls; do \
filename=$$(basename $$url); \
if [ ! -e $$filename ]; then \
curl --fail -L -O $$url; \
fi; \
echo $$(sha1sum $$filename | cut -d\ -f1)/$$filename >> upstream; \
filename=$$(basename $$url); \
if [ ! -e $$filename ]; then \
if ! curl --fail -L -O $$url; then \
echo "Failed to download $$url"; \
[ -e upstream.bak ] && mv --no-clobber upstream.bak upstream; \
exit 1; \
fi; \
fi; \
echo $$(sha1sum $$filename | cut -d\ -f1)/$$filename >> upstream; \
done
@rm -f upstream.bak
@cat upstream
#help drop-abandoned: Remove all unused patches from the git tree
+2 -2
View File
@@ -14,9 +14,9 @@ define loopup
@sudo partprobe /dev/loop$(DEVICE)
@sleep 1
@if [ -e /dev/loop$(DEVICE)p3 ]; then \
sudo mount /dev/loop$(DEVICE)p3 $(TOPLVL)/image; \
sudo mount /dev/loop$(DEVICE)p3 $(TOPLVL)/image; \
else \
sudo mount /dev/loop$(DEVICE)p2 $(TOPLVL)/image; \
sudo mount /dev/loop$(DEVICE)p2 $(TOPLVL)/image; \
fi
@sudo mount /dev/loop$(DEVICE)p1 $(TOPLVL)/image/boot
endef
+61 -3
View File
@@ -39,6 +39,7 @@ R-Cairo
R-CircStats
R-ClustVarLV
R-Cubist
R-DAAG
R-DBI
R-DBItest
R-DEoptim
@@ -62,11 +63,14 @@ R-ICSNP
R-IRdisplay
R-IRkernel
R-ISwR
R-Iso
R-Lahman
R-LearnBayes
R-MCMCpack
R-Matching
R-MatrixModels
R-ModelMetrics
R-NADA
R-NLP
R-NMF
R-NMOF
@@ -127,6 +131,7 @@ R-bayesplot
R-bdsmatrix
R-betareg
R-bibtex
R-biglm
R-bindr
R-bindrcpp
R-bipartite
@@ -200,6 +205,7 @@ R-e1071
R-earth
R-ellipse
R-energy
R-estimability
R-evaluate
R-expint
R-expm
@@ -224,6 +230,7 @@ R-gamm4
R-gbm
R-gclus
R-gdata
R-geepack
R-geometry
R-getopt
R-ggjoy
@@ -251,8 +258,10 @@ R-htmltools
R-htmlwidgets
R-httpuv
R-httr
R-hunspell
R-ica
R-igraph
R-import
R-inline
R-inum
R-ipred
@@ -272,6 +281,7 @@ R-latticeExtra
R-lava
R-lazyeval
R-lda
R-leaflet
R-leaps
R-lfe
R-libcoin
@@ -281,10 +291,12 @@ R-lmtest
R-locfit
R-loo
R-lpSolve
R-lsmeans
R-lubridate
R-magic
R-magrittr
R-manipulate
R-manipulateWidget
R-mapproj
R-maps
R-maptools
@@ -293,6 +305,7 @@ R-matrixStats
R-matrixcalc
R-maxLik
R-mclust
R-mcmc
R-mda
R-memisc
R-memoise
@@ -311,6 +324,7 @@ R-modelr
R-modeltools
R-mondate
R-multcomp
R-multcompView
R-multiwayvcov
R-munsell
R-mvoutlier
@@ -356,6 +370,7 @@ R-pracma
R-praise
R-prettyunits
R-princurve
R-processx
R-prodlim
R-profileModel
R-progress
@@ -437,6 +452,8 @@ R-spatstat
R-spatstat.data
R-spatstat.utils
R-spdep
R-speedglm
R-spelling
R-spls
R-statmod
R-statnet.common
@@ -475,13 +492,16 @@ R-vegan
R-viridis
R-viridisLite
R-visNetwork
R-webshot
R-whisker
R-withr
R-xml2
R-xtable
R-xts
R-yaml
R-zCompositions
R-zoo
Remmina
SDL
SDL2
SDL2_gfx
@@ -593,6 +613,7 @@ bkcharts
bleach
blktrace
bluez
bmap-tools
bndl-lamp-basic
bokeh
boost
@@ -616,6 +637,7 @@ cached-property
cairo
cairomm
cantarell-fonts
capnproto
cargo
caribou
catch2
@@ -682,7 +704,9 @@ compat-efivar-soname0
compat-fuse-soname2
compat-gegl
compat-glew-soname1
compat-gtksourceview-soname3
compat-guile-soname20
compat-ipset-soname10
compat-libical-soname2
compat-libpng-soname12
compat-libwebp-soname6
@@ -743,6 +767,7 @@ defusedxml
dejagnu
desktop-file-utils
dfc
dfu-util
dhcp
dialog
diffoscope
@@ -759,6 +784,7 @@ docbook-utils
docbook-xml
docker
docker-py
dockerpy-creds
docutils
dogtail
dos2unix
@@ -770,6 +796,7 @@ dracut
dri2proto
dri3proto
dstat
dtc
e2fsprogs
ebtables
ecdsa
@@ -994,6 +1021,7 @@ httpd
httplib2
httpretty
hub
hugo
hunspell
hwloc
hyperscan
@@ -1069,6 +1097,7 @@ jupyterlab_launcher
kafka-dep
kbd
kbproto
kernel-install
kexec-tools
keyring
keyutils
@@ -1134,6 +1163,7 @@ libconfig
libcroco
libcryptui
libdatrie
libdazzle
libdmx
libdnf
libdrm
@@ -1256,9 +1286,11 @@ linux-hyperv-mini
linux-kvm
linux-libc-headers
linux-lts
linux-oracle
linux-pk414
linux-steam-integration
linux-tools
linuxptp
llvm
llvmlite
lmdb
@@ -1276,6 +1308,7 @@ lzip
lzo
m4
make
makedepend
man-db
man-pages
mariadb
@@ -1374,7 +1407,6 @@ numba
numpy
numpydoc
nvme-cli
nvml
oauth2client
ocl-icd
offlineimap
@@ -1402,6 +1434,7 @@ openvswitch
opus
opusfile
orc
orca
ordereddict
ostree
ovirt-guest-agent
@@ -1437,7 +1470,9 @@ perl-B-Hooks-EndOfScope
perl-CPAN-Meta-Check
perl-Capture-Tiny
perl-Class-Data-Inheritable
perl-Class-Inspector
perl-Class-Singleton
perl-Class-Tiny
perl-Crypt-SSLeay
perl-DBI
perl-DateTime
@@ -1453,7 +1488,14 @@ perl-Error
perl-Eval-Closure
perl-Exception-Class
perl-Exporter-Tiny
perl-ExtUtils-Config
perl-ExtUtils-Helpers
perl-ExtUtils-InstallPaths
perl-File-Copy-Recursive
perl-File-Listing
perl-File-MMagic
perl-File-ShareDir
perl-File-ShareDir-Install
perl-File-Slurp
perl-HTML-Parser
perl-HTML-Tagset
@@ -1478,6 +1520,7 @@ perl-MIME-Base64
perl-MRO-Compat
perl-Math-BigInt-GMP
perl-Module-Build
perl-Module-Build-Tiny
perl-Module-Implementation
perl-Module-Install
perl-Module-Pluggable
@@ -1490,6 +1533,7 @@ perl-Package-Stash
perl-Params-Validate
perl-Params-ValidationCompiler
perl-Path-Class
perl-Path-Tiny
perl-Role-Tiny
perl-Scope-Guard
perl-Specio
@@ -1497,10 +1541,14 @@ perl-Sub-Exporter-Progressive
perl-Sub-Identify
perl-Sub-Info
perl-Sub-Quote
perl-Sub-Uplevel
perl-TAP-Harness-Archive
perl-Term-Table
perl-Test-Deep
perl-Test-Exception
perl-Test-Fatal
perl-Test-File
perl-Test-File-ShareDir-Dist
perl-Test-Needs
perl-Test-NoWarnings
perl-Test-Output
@@ -1508,7 +1556,9 @@ perl-Test-Pod
perl-Test-Requires
perl-Test-Simple
perl-Test-Taint
perl-Test-Warn
perl-Test-Warnings
perl-Test-utf8
perl-Test2-Suite
perl-Text-Autoformat
perl-Text-CSV_XS
@@ -1543,6 +1593,7 @@ pkcs11-helper
pkg-config
pluggy
ply
pmdk
polkit
poppler
popt
@@ -1577,7 +1628,6 @@ pyatspi
pycairo
pycodestyle
pycparser
pycrypto
pycurl
pydot
pydot_ng
@@ -1603,7 +1653,6 @@ python-augeas
python-dateutil
python-future
python-gflags
python-keyczar
python-krbV
python-magic
python-memcached
@@ -1677,6 +1726,7 @@ rng-tools
rope
rpcbind
rpm
rr
rsa
rsync
ruby
@@ -1687,6 +1737,7 @@ rxvt-unicode
s2tc
s3transfer
samba
sane-backends
sassc
satyr
sbc
@@ -1714,6 +1765,7 @@ shared-mime-info
sharutils
shim
siege
simple-scan
simplegeneric
simplejson
sip
@@ -1748,6 +1800,7 @@ startup-notification
stow
strace
subunit
subversion
sudo
sure
suricata
@@ -1814,6 +1867,7 @@ tzdata
tzlocal
udisks2
uhttpmock
unbundle
unicode-xid
unifdef
unittest2
@@ -1831,6 +1885,7 @@ util-linux
util-macros
uwsgi
v4l-utils
vala
valgrind
vcversioner
videoproto
@@ -1843,6 +1898,7 @@ virt-viewer
virtualenv
vlc
volume_key
vorbis-tools
vsqlite
vte
vulkan-sdk
@@ -1861,6 +1917,7 @@ wget
wheel
which
widgetsnbextension
wireless-regdb-master
woff2
wol
wpa_supplicant
@@ -1880,6 +1937,7 @@ xclip
xcmiscproto
xcursor-themes
xcursorgen
xdg-desktop-portal
xdg-user-dirs
xdg-user-dirs-gtk
xdg-utils