Android教程網
  1. 首頁
  2. Android 技術
  3. Android 手機
  4. Android 系統教程
  5. Android 游戲
 Android教程網 >> Android技術 >> Android開發 >> 關於android開發 >> 建立自己的ubuntu發行服務器for mips

建立自己的ubuntu發行服務器for mips

編輯:關於android開發

建立自己的ubuntu發行服務器for mips


1.dupload *.changes
能將我們的軟件上傳到服務器上
但不是按照 pool/main/a/aalib/
而是將所有的放在信息放在 服務器的 / 目錄下

研究結果使用 dupload + Reprepro創建成功
Code:

#!/bin/bash
echo "********** REPO CONTROL SCRIPT **********"
echo "******* CLOSE GEDIT TEXT EDITORS! *******"
echo "* *"

cd /home/user/Documents
mkdir -p Original_debs
mkdir -p Output_debs
mkdir -p tmp/DEBIAN
echo -n "Name of File with extension (Example: program.deb) > "
read FILE
cp $FILE /home/user/Documents/Original_debs/
dpkg-deb -x $FILE tmp/
dpkg-deb --control $FILE tmp/DEBIAN
echo "DEPACKAGING DONE. OPENING CONTROL FILE FOR EDIT..."
cd /home/user/Documents/tmp/DEBIAN
gedit control
cd /home/user/Documents/
echo "EDITING DONE."

echo "REPACKAGING..."
dpkg-deb -b tmp $FILE
cp $FILE /home/user/Desktop/repository/deb/
rm -r tmp/
echo "REPACKAGING COMPLETE. TEMP FILES REMOVED."


echo "REBUILDING REPOSITORY INFORMATION..."

cd /home/user/Desktop/repository/
dpkg-scanpackages -m . /dev/null | bzip2 -9c >Packages.bz2
dpkg-scanpackages -m . /dev/null | gzip -9c >Packages.gz

echo "REBUILDING REPOSITORY INFORMATION COMPLETE."


echo "FTP PROCESS IN PROGRESS...UPDATING REPOSITORY..."
ftp -nmy.webhost.com<quote USER username
quote PASS password
cd public_html
cd deb
lcd /home/user/Desktop/repository/deb/
put $FILE
cd ..
lcd /home/user/Desktop/repository/
put Packages.bz2
put Packages.gz
put Release
by
END_SCRIPT
echo -n "FTP PROCESS DONE. "

cd /home/user/Documents/
mv $FILE /home/user/Documents/Output_debs/
cd /
echo "REPOSITORY UPDATED!"

echo "* *"
echo "********** REPO CONTROL SCRIPT **********"

dpkg-scanpackages -m . /dev/null | bzip2 -9c >Packages.bz2

使用Reprepro創建成功
Origin: Your Name
Label: Your own label
Suite: stable
Codename: sarge
Version: 3.1
Architectures: i386 all source
Components: main non-free contrib
Description: Your description

Origin: Your Name
Label: Your own label
Suite: unstable
Codename: sid
Architectures: i386 all source
Components: main non-free contrib
Description: Your description


skx@lappy:~/apt$ reprepro -Vb . include sarge \
/home/skx/debian/sarge/reprepro/reprepro_0.6-1sarge0_i386.changes
Created directory "./db"
Created directory "./pool"
Created directory "./pool/main"
Created directory "./pool/main/r"
Created directory "./pool/main/r/reprepro"
db: 'reprepro' added to 'sarge|main|i386'.
db: 'reprepro' added to 'sarge|main|source'.
Created directory "./dists"
Created directory "./dists/sarge"
Created directory "./dists/sarge/main"
Created directory "./dists/sarge/main/binary-i386"
writing to './dists/sarge/main/binary-i386/Packages.new'...
writing to './dists/sarge/main/binary-i386/Packages.gz.new'...
Created directory "./dists/sarge/main/binary-all"
writing to './dists/sarge/main/binary-all/Packages.new'...
writing to './dists/sarge/main/binary-all/Packages.gz.new'...
Created directory "./dists/sarge/main/source"
writing to './dists/sarge/main/source/Sources.gz.new'...
Created directory "./dists/sarge/non-free"
Created directory "./dists/sarge/non-free/binary-i386"
writing to './dists/sarge/non-free/binary-i386/Packages.new'...
writing to './dists/sarge/non-free/binary-i386/Packages.gz.new'...
Created directory "./dists/sarge/non-free/binary-all"
writing to './dists/sarge/non-free/binary-all/Packages.new'...
writing to './dists/sarge/non-free/binary-all/Packages.gz.new'...
Created directory "./dists/sarge/non-free/source"
writing to './dists/sarge/non-free/source/Sources.gz.new'...
Created directory "./dists/sarge/contrib"
Created directory "./dists/sarge/contrib/binary-i386"
writing to './dists/sarge/contrib/binary-i386/Packages.new'...
writing to './dists/sarge/contrib/binary-i386/Packages.gz.new'...
Created directory "./dists/sarge/contrib/binary-all"
writing to './dists/sarge/contrib/binary-all/Packages.new'...
writing to './dists/sarge/contrib/binary-all/Packages.gz.new'...
Created directory "./dists/sarge/contrib/source"
writing to './dists/sarge/contrib/source/Sources.gz.new'...

sudo reprepro -Vb . includedeb lucid ../ubuntu10.04/pool/main/libpa*.deb

more conf/distributions
Origin: sns.akaedu.org
Label: Ubuntu
Suite: stable
Codename: lucid
Version: 10.04
Architectures: mipsel binary
Components: main free non-free
Description: Ubuntu 10.04package repositories for mipsel(loongson)
Log: /var/log/repos/lucid.log

  1. 上一頁:
  2. 下一頁:
熱門文章
閱讀排行版
Copyright © Android教程網 All Rights Reserved