hxxps://pwnedlist.com/
use a hashed SHA-512 insead of the email address...seems to work
This is where I post snippets of information about Information Technology. It is mostly for my own reference but I hope that others will find it useful and comments are welcome.
Log on to mysystem and execute screen
On mysystem execute :
redcricket@mysystem:~$ ssh -L 2022:host-behind-firewall:22 host-not-blockedStep 3) Use the tunnel
Password:
...
redcricket@host-not-blocked:~$
Now detach ^A^D (if you are using screen. If not you will need to start up a terminal.)
Why port 2022? Well if I had used port 22 I would have gotten an error message about how that port number is reserved for the 'root' user, so I pick 2000 + 22 = 2022.
On mysystem execute:
redcricket@mysystem:~$ ssh -p 2022 localhost
...
redcricket@host-behind-firewall:~$
# useradd lame # passwd lame # usermod -s /usr/libexec/openssh/sftp-server lame
$ tar -zxvf scponly-20110526.tgz $ cd scponly-20110526 $ ./configure --enable-scp-compat $ make $ make install $ sudo make installAdd /usr/local/bin/scponly to the /etc/shells file
$ vim /etc/shells ... $ cat /etc/shells ... /usr/local/bin/scponlyAdd a user and give set its shell to /usr/local/bin/scponly
# useradd lame # passwd lame # usermod -s /usr/local/bin/scponly lamehttp://sublimation.org/scponly/wiki/index.php/FAQ#What_does_.22lost_connection.22_mean.3F
$ perl Makefile.PL... but I have libgd installed ...
Notice: Type perl Makefile.PL -h for command-line option summary.
**UNRECOVERABLE ERROR**
Could not find gdlib-config in the search path. Please install libgd 2.0.28 or higher.
If you want to try to compile anyway, please rerun this script with the option --ignore_missing_gd.
$ rpm -q gd... so when I do as the error message suggest ...
gd-2.0.35-10.el6.x86_64
$ perl Makefile.PL --ignore_missing_gd... I answered 'n' to all questions to give Makeperl.PL a good chance to execute without error. So now I can run make right ...
Where is libgd installed? [/usr/lib]
Please choose the features that match how libgd was built:
Build JPEG support? [y] n
Build PNG support? [y] n
Build FreeType support? [y] n
Build GIF support? [y] n
Build XPM support? [y] n
If you experience compile problems, please check the @INC, @LIBPATH and @LIBS
arrays defined in Makefile.PL and manually adjust, if necessary.
Writing Makefile for GD
Writing MYMETA.yml
.... perl-5.14.1/bin/perl GD/Image.pm.PLS GD/Image.pm... I guess I need to gd-devel but I haven't got that in my yum repo :(
Extracting Image.pm (with variable substitutions)
Skip blib/lib/GD/Polyline.pm (unchanged)
Skip blib/lib/qd.pl (unchanged)
Skip blib/lib/GD/Image.pm (unchanged)
Skip blib/lib/GD.pm (unchanged)
Skip blib/lib/GD/Simple.pm (unchanged)
Skip blib/lib/GD/Polygon.pm (unchanged)
Skip blib/lib/GD/Group.pm (unchanged)
gcc -c -I/usr/include -I/usr/include/gd -Wformat=0 -O2 -DVERSION=\"2.46\" -DXS_VERSION=\"2.46\" -fPIC "-I/apps/RED/red-perl-5.14.1/lib/5.14.1/x86_64-linux-thread-multi/CORE" GD.c
GD.xs:7:16: error: gd.h: No such file or directory
GD.xs:8:21: error: gdfontg.h: No such file or directory
GD.xs:9:21: error: gdfontl.h: No such file or directory
GD.xs:10:22: error: gdfontmb.h: No such file or directory
GD.xs:11:21: error: gdfonts.h: No such file or directory
GD.xs:12:21: error: gdfontt.h: No such file or directory
GD.xs:342: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âGD__Imageâ
GD.xs:343: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âGD__Fontâ
GD.xs:385: error: expected specifier-qualifier-list before âgdIOCtxâ
GD.xs:393: error: expected â)â before âctxâ
GD.xs:400: error: expected â)â before âctxâ
GD.xs:416: error: expected â)â before âctxâ
GD.xs:424: error: expected â)â before âctxâ
GD.xs:429: error: expected â)â before âctxâ
GD.xs:433: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before â*â token
GD.xs:454: error: expected â=â, â,â, â;â, âasmâ or â__attribute__â before âgd_cloneDimâ
GD.xs:478: error: expected â)â before âsrcâ
GD.xs:507: error: expected â)â before âimageâ
GD.c: In function âXS_GD__Image__newâ:
GD.c:682: error: âGD__Imageâ undeclared (first use in this function)
GD.c:682: error: (Each undeclared identifier is reported only once
GD.c:682: error: for each function it appears in.)
I bet I just need to counteract that 'sign' argument. Let's check the rpmbuild man page .. hmm, refers us to rpm, OK, check that man page .. bingo!
So let's try it with the no-sign argument instead ..
[alex@box FC8]$ cpan2rpm --no-sign http://search.cpan.org/CPAN/authors +/id/D/DC/DCLINTON/Cache-Cache-1.05.tar.gz -- cpan2rpm - Ver: 2.028 -- Upgrade check Fetch: HTTP [...] + rm -rf Cache-Cache-1.05 + exit 0 RPM: /home/box/alex/RPMS/RPMS/noarch/perl-Cache-Cache-1.05-1.noarch.rp +m SRPM: /home/box/alex/RPMS/SRPMS/perl-Cache-Cache-1.05-1.src.rpm -- Done --
$ dig +dnssec isc.org NSEC
; <<>> DiG 9.3.4 <<>> +dnssec isc.org NSEC
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 47304
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags: do; udp: 4000
;; QUESTION SECTION:
;isc.org. IN NSEC
;; ANSWER SECTION:
isc.org. 3600 IN NSEC _kerberos.isc.org. A NS SOA MX TXT AAAA NAPTR RRSIG NSEC DNSKEY TYPE99
;; Query time: 23 msec
;; SERVER: 68.87.76.182#53(68.87.76.182)
;; WHEN: Sat Sep 10 19:38:38 2011
;; MSG SIZE rcvd: 82
red@cel6-test:~/platform/red-vendor_perl/perl-Test-Tester$ rpm -q rpm-build
rpm-build-4.8.0-16.el6.x86_64
# Makefile for perl-Test-Tester... and given the SPEC file perl-Test-Tester.spec ...
VER=0.107
RELEASE=1
RPM_NAME=perl-Test-Tester
ARCH=x86_64
TAR_NAME=Test-Tester
TOPDIR := $(shell pwd)
FILES = \
${TOPDIR}/BUILD \
${TOPDIR}/BUILDROOT \
${TOPDIR}/SOURCES \
${TOPDIR}/RPMS \
${RPM_NAME}-${VER}.tar.gz \
${TOPDIR}/SOURCES/${RPM_NAME}-${VER}.tar.gz \
${RPM_NAME}-${VER}-${RELEASE}.${ARCH}.rpm
all : ${FILES}
${TOPDIR}/BUILD :
mkdir -p ${TOPDIR}/BUILD
${TOPDIR}/BUILDROOT :
mkdir -p $@/${RPM_NAME}-${VER}-${RELEASE}.${ARCH}
${TOPDIR}/RPMS :
mkdir -p ${TOPDIR}/RPMS
${TOPDIR}/SOURCES :
mkdir -p ${TOPDIR}/SOURCES
${TAR_NAME}-${VER}.tar.gz :
#wget http://search.cpan.org/CPAN/authors/id/K/KR/KRUSCOE/${TAR_NAME}-${VER}.tar.gz this line is incorrect
cvs update $@
${RPM_NAME}-${VER}.tar.gz : ${TAR_NAME}-${VER}.tar.gz
tar -zxf $<
mv ${TAR_NAME}-${VER}/ ${RPM_NAME}-${VER}
tar -czvf $@ ${RPM_NAME}-${VER}
rm -rf ${RPM_NAME}-${VER}
${TOPDIR}/SOURCES/${RPM_NAME}-${VER}.tar.gz : ${RPM_NAME}-${VER}.tar.gz
cp $< $@
${RPM_NAME}-${VER}-${RELEASE}.${ARCH}.rpm : ${TOPDIR}/SOURCES/${RPM_NAME}-${VER}.tar.gz ${RPM_NAME}.spec
rpmbuild --define "_topdir ${TOPDIR}" -vv -bb ${RPM_NAME}.spec
cp ${TOPDIR}/RPMS/${ARCH}/$@ .
- rpm -i --force -v $@
test -e $@
test: ${RPM_NAME}-${VER}-${RELEASE}.${ARCH}.rpm
rpm -q --filesbypkg -p $<
clean:
rm -rf ${FILES}
Summary: Install pre-complied Perl module Test::Tester... when I execute make the output shows the error ...
#
# Spec file
#
Name: perl-Test-Tester
Version: 0.107
Release: 1
License: Copyright Red Cricket Systems Inc. 2008
Group: None
Source: perl-Test-Tester-0.107.tar.gz
Requires: red-perl
BuildRequires: red-perl
Provides: perl(Test::Tester)
%description
Install pre-complied Perl module Test::Tester for RED
%prep
%global
%setup
%build
/usr/RED/perl/bin/perl Makefile.PL INSTALLDIRS=vendor
make
make test
%install
make install
%post
%clean
%files
%defattr(-,red,cricket)
/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester.pm
/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/CaptureRunner.pm
/apps/REDD/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Capture.pm
/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Delegate.pm
/apps/REDD/red-perl-5.14.1/man/man3/Test::Tester::Capture.3
/apps/REDD/red-perl-5.14.1/man/man3/Test::Tester.3
/apps/RED/red-perl-5.14.1/man/man3/Test::Tester::CaptureRunner.3
%changelog
redcricket@cel6-test:~/platform/red-vendor_perl/perl-Test-Tester$ makeThe problem is that for one reason or another rpmbuild does not want to place the installed files into the BUILDROOT/perl-Test-tester-0.107.x86_64 directory. So to correct this I wrote the shell script ...
rpmbuild --define "_topdir /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester" -vv -bb perl-Test-Tester.spec
error: Macro % has illegal name (%define)
D: opening db environment /var/lib/rpm cdb:mpool:joinenv
D: opening db index /var/lib/rpm/Packages rdonly mode=0x0
D: locked db index /var/lib/rpm/Packages
D: ========== +++ perl-Test-Tester-0.107-1 x86_64/linux 0x0
D: loading keyring from pubkeys in /var/lib/rpm/pubkeys/*.key
D: couldn't find any keys in /var/lib/rpm/pubkeys/*.key
D: loading keyring from rpmdb
D: opening db index /var/lib/rpm/Name rdonly mode=0x0
D: read h# 622 Header sanity check: OK
D: added key gpg-pubkey-fd431d51-4ae0493b to keyring
D: read h# 623 Header sanity check: OK
D: added key gpg-pubkey-2fa658e0-45700c69 to keyring
D: read h# 624 Header sanity check: OK
D: added key gpg-pubkey-665b9872-3fd4f7c5 to keyring
D: Using legacy gpg-pubkey(s) from rpmdb
D: opening db index /var/lib/rpm/Providename rdonly mode=0x0
D: read h# 656 Header SHA1 digest: OK (cac9c305ade60953baec0168c93953daa3dee1f7)
D: Requires: red-perl YES (db provides)
D: closed db index /var/lib/rpm/Providename
D: closed db index /var/lib/rpm/Name
D: closed db index /var/lib/rpm/Packages
D: closed db environment /var/lib/rpm
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.C93SZy
+ umask 022
+ cd /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD
+ cd /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD
+ rm -rf perl-Test-Tester-0.107
+ /usr/bin/gzip -dc /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/SOURCES/perl-Test-Tester-0.107.tar.gz
+ /bin/tar -xvvf -
drwxr-xr-x 1000/1000 0 2008-03-01 16:17 perl-Test-Tester-0.107/
-rw-r--r-- 1000/1000 12462 2008-03-01 16:17 perl-Test-Tester-0.107/README
drwxr-xr-x 1000/1000 0 2008-03-01 16:17 perl-Test-Tester-0.107/t/
-rw-r--r-- 1000/1000 488 2005-07-04 18:09 perl-Test-Tester-0.107/t/capture.t
-rw-r--r-- 1000/1000 1775 2005-10-08 05:53 perl-Test-Tester-0.107/t/check_tests.t
-rw-r--r-- 1000/1000 379 2007-08-25 10:21 perl-Test-Tester-0.107/t/depth.t
-rw-r--r-- 1000/1000 4231 2007-08-25 10:11 perl-Test-Tester-0.107/t/run_test.t
-rw-r--r-- 1000/1000 336 2005-07-04 17:43 perl-Test-Tester-0.107/t/SmallTest.pm
drwxr-xr-x 1000/1000 0 2008-03-01 16:17 perl-Test-Tester-0.107/t/fail/
-rw-r--r-- 1000/1000 187 2005-02-12 02:53 perl-Test-Tester-0.107/t/fail/fail.t
-rw-r--r-- 1000/1000 464 2008-03-01 16:17 perl-Test-Tester-0.107/t/auto.t
-rw-r--r-- 1000/1000 127 2004-07-05 18:07 perl-Test-Tester-0.107/t/MyTest.pm
-rw-r--r-- 1000/1000 19 2003-03-04 20:27 perl-Test-Tester-0.107/TODO
-rw-r--r-- 1000/1000 6451 2004-07-11 04:35 perl-Test-Tester-0.107/ARTISTIC
-rw-r--r-- 1000/1000 603 2004-07-05 17:22 perl-Test-Tester-0.107/Makefile.PL
drwxr-xr-x 1000/1000 0 2008-03-01 16:17 perl-Test-Tester-0.107/lib/
drwxr-xr-x 1000/1000 0 2008-03-01 16:17 perl-Test-Tester-0.107/lib/Test/
drwxr-xr-x 1000/1000 0 2008-03-01 16:17 perl-Test-Tester-0.107/lib/Test/Tester/
-rw-r--r-- 1000/1000 372 2005-07-04 17:31 perl-Test-Tester-0.107/lib/Test/Tester/Delegate.pm
-rw-r--r-- 1000/1000 1273 2004-07-11 11:16 perl-Test-Tester-0.107/lib/Test/Tester/CaptureRunner.pm
-rw-r--r-- 1000/1000 4251 2008-03-01 16:13 perl-Test-Tester-0.107/lib/Test/Tester/Capture.pm
-rw-r--r-- 1000/1000 17068 2008-03-01 16:14 perl-Test-Tester-0.107/lib/Test/Tester.pm
-rw-r--r-- 1000/1000 3143 2008-03-01 16:12 perl-Test-Tester-0.107/CHANGES
-rw-r--r-- 1000/1000 349 2008-03-01 16:17 perl-Test-Tester-0.107/META.yml
-rw-r--r-- 1000/1000 307 2005-07-04 18:22 perl-Test-Tester-0.107/MANIFEST
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd perl-Test-Tester-0.107
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.JIXFCg
+ umask 022
+ cd /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD
+ cd perl-Test-Tester-0.107
+ /usr/RED/perl/bin/perl Makefile.PL INSTALLDIRS=vendor
Checking if your kit is complete...
Looks good
Writing Makefile for Test::Tester
Writing MYMETA.yml
+ make
make[1]: Entering directory `/apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD/perl-Test-Tester-0.107'
cp lib/Test/Tester.pm blib/lib/Test/Tester.pm
cp lib/Test/Tester/Capture.pm blib/lib/Test/Tester/Capture.pm
cp lib/Test/Tester/CaptureRunner.pm blib/lib/Test/Tester/CaptureRunner.pm
cp lib/Test/Tester/Delegate.pm blib/lib/Test/Tester/Delegate.pm
Manifying blib/man3/Test::Tester::Capture.3
Manifying blib/man3/Test::Tester.3
Manifying blib/man3/Test::Tester::CaptureRunner.3
make[1]: Leaving directory `/apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD/perl-Test-Tester-0.107'
+ make test
make[1]: Entering directory `/apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD/perl-Test-Tester-0.107'
PERL_DL_NONLAZY=1 /apps/RED/red-perl-5.14.1/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/auto.t ......... ok
t/capture.t ...... ok
t/check_tests.t .. ok
t/depth.t ........ ok
t/run_test.t ..... ok
All tests successful.
Files=5, Tests=169, 0 wallclock secs ( 0.04 usr 0.00 sys + 0.10 cusr 0.01 csys = 0.15 CPU)
Result: PASS
make[1]: Leaving directory `/apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD/perl-Test-Tester-0.107'
+ exit 0
Executing(%install): /bin/sh -e /var/tmp/rpm-tmp.RidKYZ
+ umask 022
+ cd /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD
+ cd perl-Test-Tester-0.107
+ make install
make[1]: Entering directory `/apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD/perl-Test-Tester-0.107'
Manifying blib/man3/Test::Tester::Capture.3
Manifying blib/man3/Test::Tester.3
Manifying blib/man3/Test::Tester::CaptureRunner.3
Installing /apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester.pm
Installing /apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Delegate.pm
Installing /apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/CaptureRunner.pm
Installing /apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Capture.pm
Installing /apps/RED/red-perl-5.14.1/man/man3/Test::Tester.3
Installing /apps/RED/red-perl-5.14.1/man/man3/Test::Tester::Capture.3
Installing /apps/RED/red-perl-5.14.1/man/man3/Test::Tester::CaptureRunner.3
Appending installation info to /apps/RED/red-perl-5.14.1/lib/5.14.1/x86_64-linux-thread-multi/perllocal.pod
make[1]: Leaving directory `/apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILD/perl-Test-Tester-0.107'
+ /usr/lib/rpm/brp-compress
+ /usr/lib/rpm/brp-strip
+ /usr/lib/rpm/brp-strip-static-archive
+ /usr/lib/rpm/brp-strip-comment-note
Processing files: perl-Test-Tester-0.107-1.x86_64
error: File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester.pm
error: File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/CaptureRunner.pm
error: File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Capture.pm
error: File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Delegate.pm
error: File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/man/man3/Test::Tester::Capture.3
error: File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/man/man3/Test::Tester.3
error: File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/man/man3/Test::Tester::CaptureRunner.3
RPM build errors:
Macro % has illegal name (%define)
File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester.pm
File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/CaptureRunner.pm
File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Capture.pm
File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/lib/vendor_perl/5.14.1/Test/Tester/Delegate.pm
File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/man/man3/Test::Tester::Capture.3
File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/man/man3/Test::Tester.3
File not found: /apps/users/redcricket/platform/red-vendor_perl/perl-Test-Tester/BUILDROOT/perl-Test-Tester-0.107-1.x86_64/apps/RED/red-perl-5.14.1/man/man3/Test::Tester::CaptureRunner.3
make: *** [perl-Test-Tester-0.107-1.x86_64.rpm] Error 1
redcricket@cel6-test:~/platform/red-vendor_perl/perl-Test-Tester$ cat /etc/redhat-release
Red Hat Enterprise Linux Server release 6.1 (Santiago)
redcricket@cel6-test:~/platform/red-vendor_perl/perl-Test-Tester$ cat ../process_install_output.shThen I call this script in the %install section of my SPEC file like so ...
#!/bin/sh
#
# $Id: process_install_output.sh,v 1.1.2.1 2011/09/09 19:24:34 redcricket Exp $
#
# This script is used in perl-<Module>.spec files
#
INSTALL_OUTPUT=$1
BUILDROOT=$2
if [ -z "$INSTALL_OUTPUT" ]
then
echo "Usage : $0 <install output file> <rpm build root directory>"
exit 1
fi
if [ -z "$BUILDROOT" ]
then
echo "Usage : $0 <install output file> <rpm build root directory>"
exit 1
fi
cat $INSTALL_OUTPUT
echo "grep "Installing" $INSTALL_OUTPUT"
for installed_file in `grep "Installing" $INSTALL_OUTPUT | cut -d' ' -f2`
do
installed_dir=`dirname $installed_file`
echo "Executing [mkdir -p $BUILDROOT/$installed_dir]"
mkdir -p $BUILDROOT/$installed_dir
echo "Execute [cp -p $installed_file $BUILDROOT/$installed_dir]"
cp -p $installed_file $BUILDROOT/$installed_dir
done
RPM build errors:... when running rpmbuild to make a RPM, double check your %files section of your spec file:
File must begin with "/": ./perl
File must begin with "/": installman
File must begin with "/": --destdir=
./perl installman --destdir=
red@cricket:~$ ./fib.sh
0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144
red@cricket:~$ cat fib.sh
#!/bin/sh
first=0
second=1
echo -n "$first, $second, "
thrid=`expr $first + $second`
echo -n $thrid
while [ $thrid -lt 100 ]
do
first=$second
second=$thrid
thrid=`expr $first + $second`
echo -n ", $thrid"
done
echo ""
here's an explanation of how it works | 12:51 PM |
http://blogs.technet.com/b/askds/archive/2009/02/15/test2.aspx |
sub upd_server_type_filter {
- Setting cookies & redirection
- Getting the cookie
sub get_server_type_filter {
my @filter;
# fetch cookies
my %cookies = CGI::Cookie->fetch;
my $server_type_filter = $cookies{'server_type_filter'}->value if $cookies{'server_type_filter'};
$server_type_filter =~ s/\s//g;
@filter = split /,/, $server_type_filter;
return @filter;
}