mirror of
https://codeberg.org/scip/pcp.git
synced 2025-12-17 03:50:57 +01:00
added build env for compile farm
This commit is contained in:
72
tests/gcc-compilefarm/.bashrc
Normal file
72
tests/gcc-compilefarm/.bashrc
Normal file
@@ -0,0 +1,72 @@
|
||||
# .bashrc on gcc compile farm
|
||||
|
||||
if [ -f /etc/bashrc ]; then
|
||||
. /etc/bashrc
|
||||
fi
|
||||
|
||||
alias ll='ls -l'
|
||||
alias la='ls -la'
|
||||
alias l='ls -alF'
|
||||
alias ls-l='ls -l'
|
||||
alias o='less'
|
||||
alias ..='cd ..'
|
||||
alias ...='cd ../..'
|
||||
alias ....='cd ../../..'
|
||||
alias .....='cd ../../../..'
|
||||
alias rd=rmdir
|
||||
alias md='mkdir -p'
|
||||
alias which='type -p'
|
||||
alias .='pwd'
|
||||
alias less='less -i -P "?f%f:Standard input. %lb / %L ?e(END):>"'
|
||||
alias les='less'
|
||||
alias grip='egrep -i'
|
||||
|
||||
DATE () {
|
||||
echo -e "[`date +%d.%b" "%H:%M:%S`]"
|
||||
}
|
||||
|
||||
JOBS () {
|
||||
NUM=`jobs|wc -l| awk '{print $1}'`
|
||||
case $NUM in
|
||||
"0")
|
||||
;;
|
||||
*)
|
||||
echo -e " [&$NUM]"
|
||||
;;
|
||||
esac
|
||||
}
|
||||
|
||||
empty () {
|
||||
#
|
||||
# clean functions for subshell
|
||||
unset -f DATE JOBS
|
||||
}
|
||||
|
||||
case $UID in
|
||||
"0")
|
||||
CURSOR="#"
|
||||
;;
|
||||
*)
|
||||
CURSOR="\$"
|
||||
esac
|
||||
|
||||
case $TERM in
|
||||
*)
|
||||
PROMPT_COMMAND="PS1='\[\033]0;\u@\h:\w\007\]
|
||||
\$(DATE) --- [\w]\$(JOBS) ---
|
||||
\u@\h: $CURSOR '"
|
||||
;;
|
||||
esac
|
||||
|
||||
|
||||
PATH=/home/scip/bin:$PATH:/usr/local/bin:/usr/sbin
|
||||
EDITOR=vi
|
||||
LESSCHARSET=iso8859
|
||||
GREP_OPTIONS="--binary-files=without-match --directories=skip"
|
||||
|
||||
export EDITOR PROMPT_COMMAND PATH LESSCHARSET GREP_OPTIONS
|
||||
|
||||
|
||||
umask 022
|
||||
|
||||
shopt -s cdable_vars checkhash checkwinsize
|
||||
81
tests/gcc-compilefarm/Makefile
Normal file
81
tests/gcc-compilefarm/Makefile
Normal file
@@ -0,0 +1,81 @@
|
||||
PREFIX = $(HOME)/usr
|
||||
BUILD = $(HOME)/build
|
||||
|
||||
GITSODIUM = https://github.com/jedisct1/libsodium.git
|
||||
GITPCP = https://github.com/TLINDEN/pcp.git
|
||||
|
||||
DIRCFG = Config-General-2.52
|
||||
DIRTIE = Tie-IxHash-1.23
|
||||
DIRYAM = YAML-0.84
|
||||
|
||||
GZCFG = $(DIRCFG).tar.gz
|
||||
GZTIE = $(DIRTIE).tar.gz
|
||||
GZYAM = $(DIRYAM).tar.gz
|
||||
|
||||
CPANCFG = http://search.cpan.org/CPAN/authors/id/T/TL/TLINDEN/$(GZCFG)
|
||||
CPANTIE = http://search.cpan.org/CPAN/authors/id/C/CH/CHORNY/$(GZTIE)
|
||||
CPANYAM = http://search.cpan.org/CPAN/authors/id/M/MS/MSTROUT/$(GZYAM)
|
||||
|
||||
HAVEPERL = $(PREFIX)/share/perl/5.10.1/Config/General.pm
|
||||
|
||||
SRCSODIUM = $(BUILD)/libsodium
|
||||
SRCPCP = $(BUILD)/pcp
|
||||
|
||||
all: prepare fetch config-sodium compile-sodium install-sodium config-pcp compile-pcp install-pcp test-pcp
|
||||
@echo done
|
||||
|
||||
|
||||
prepare:
|
||||
if test ! -d $(PREFIX); then mkdir -p $(PREFIX); fi
|
||||
if test ! -d $(BUILD); then mkdir -p $(BUILD); fi
|
||||
|
||||
perl: prepare
|
||||
if test ! -f $(HAVEPERL); then \
|
||||
cd $(BUILD) && wget $(CPANCFG) && tar xvfz $(GZCFG); \
|
||||
cd $(BUILD)/$(DIRCFG) && perl Makefile.PL PREFIX=$(PREFIX) && make && make install; \
|
||||
cd $(BUILD) && wget $(CPANTIE) && tar xvfz $(GZTIE); \
|
||||
cd $(BUILD)/$(DIRTIE) && perl Makefile.PL PREFIX=$(PREFIX) && make && make install; \
|
||||
cd $(BUILD) && wget $(CPANYAM) && tar xvfz $(GZYAM); \
|
||||
cd $(BUILD)/$(DIRYAM) && perl Makefile.PL PREFIX=$(PREFIX) && make && make install; \
|
||||
fi
|
||||
|
||||
|
||||
fetch: prepare
|
||||
if test ! -d $(SRCSODIUM); then \
|
||||
cd $(BUILD) && git clone $(GITSODIUM); \
|
||||
else \
|
||||
cd $(SRCSODIUM) && git pull; \
|
||||
fi
|
||||
if test ! -d $(SRCPCP); then \
|
||||
cd $(BUILD) && git clone $(GITPCP); \
|
||||
else \
|
||||
cd $(SRCPCP) && git pull; \
|
||||
fi
|
||||
|
||||
config-sodium:
|
||||
cd $(SRCSODIUM) && ./autogen.sh
|
||||
cd $(SRCSODIUM) && ./configure --prefix=$(PREFIX)
|
||||
|
||||
config-pcp:
|
||||
cd $(SRCPCP) && ./configure --prefix=$(PREFIX) --with-libsodium=$(PREFIX)
|
||||
|
||||
compile-sodium:
|
||||
cd $(SRCSODIUM) && make
|
||||
|
||||
compile-pcp:
|
||||
cd $(SRCPCP) && make
|
||||
|
||||
install-sodium:
|
||||
cd $(SRCSODIUM) && make install
|
||||
|
||||
install-pcp:
|
||||
cd $(SRCPCP) && make install
|
||||
|
||||
clean:
|
||||
cd $(SRCSODIUM) && make clean
|
||||
cd $(SRCPCP) && make clean
|
||||
rm -rf $(PREFIX)
|
||||
|
||||
test-pcp: perl
|
||||
ln -sf $(PREFIX)/share/perl/5.10.1 $(SRCPCP)/tests/lib
|
||||
cd $(SRCPCP) && make test
|
||||
2
tests/gcc-compilefarm/README
Normal file
2
tests/gcc-compilefarm/README
Normal file
@@ -0,0 +1,2 @@
|
||||
Personal stuff for build/runtime testing on the
|
||||
GCC compile farm. Can be ignored.
|
||||
Reference in New Issue
Block a user