4

cyanogenmod를 빌드하려고하는데 빌드가 다음과 같이 실패합니다./mnt에있는 드라이브에는 충분한 공간이 있지만,/tmp가있는 루트 파티션에는 공간이 적기 때문에 임시 파일을 쓰는 동안이 문제가 발생한다고 가정합니다.cyanogenmod를 빌드 할 때 임시 디렉토리를 설정하는 방법

그러므로 임시 디렉토리를/mnt 아래 어딘가에 리디렉션하고 싶습니다. 어떻게 cyanogenmod/Android 빌드 시스템에서이 작업을 수행 할 수 있습니까? TMPTEMP을 설정했지만 아무런 효과가없는 것으로 보입니다.

Package OTA: /mnt/android/system/out/target/product/oneplus3/cm_oneplus3-ota-178d4560f4.zip 
unzipping target target-files... 
    running: unzip -o -q /mnt/android/system/out/target/product/oneplus3/obj/PACKAGING/target_files_intermediates/cm_oneplus3-target_files-178d4560f4.zip -d /tmp/targetfiles-RM6VsH 
--- target info --- 
... 
cache_size    = (int) 268435456 
... 
recovery_size    = (int) 67108864 
... 
userdata_size    = (int) 57436708864 
(using device-specific extensions from target_files) 
loaded device-specific extensions from /tmp/targetfiles-RM6VsH/META/releasetools.py 
Warning: could not find RADIO/filesmap in <zipfile.ZipFile object at 0x2b4193f91fd0>. 
using prebuilt recovery.img from BOOTABLE_IMAGES... 
using system.img from target-files 
Total of 770048 4096-byte output blocks in 2698 input chunks. 
Generating digraph... 
Finding vertex sequence... 
Reversing backward edges... 
    0/0 dependencies (0.00%) were violated; 0 source blocks stashed. 
Improving vertex order... 
Revising stash size... 
    Total 0 blocks are packed as new blocks due to insufficient cache size. 
Reticulating splines... 
Traceback (most recent call last): 
    File "./build/tools/releasetools/ota_from_target_files", line 1772, in <module> 
    main(sys.argv[1:]) 
    File "./build/tools/releasetools/ota_from_target_files", line 1727, in main 
    WriteFullOTAPackage(input_zip, output_zip) 
    File "./build/tools/releasetools/ota_from_target_files", line 664, in WriteFullOTAPackage 
    system_diff = common.BlockDifference("system", system_tgt, src=None) 
    File "/mnt/android/system/build/tools/releasetools/common.py", line 1302, in __init__ 
    b.Compute(self.path) 
    File "/mnt/android/system/build/tools/releasetools/blockimgdiff.py", line 299, in Compute 
    self.ComputePatches(prefix) 
    File "/mnt/android/system/build/tools/releasetools/blockimgdiff.py", line 618, in ComputePatches 
    new_f.write(piece) 
IOError: [Errno 28] No space left on device 
make: *** [/mnt/android/system/out/target/product/oneplus3/cm_oneplus3-ota-178d4560f4.zip] Error 1 
make: Leaving directory `/mnt/android/system' 

업데이트 : mkdtempTMPTEMP를 사용해야 설명서에 따라, /mnt/android/system/build/tools/releasetools/common.py을 편집하고 라인 1299에서 tmpdir = tempfile.mkdtemp(dir='/mnt/tmp')과 같이 수동으로 임시-DIR을 설정하여 해결 방법을 찾을 그러나 보인다는 근무하지 않도록를 나를 위해 여기! 파이썬은 2.7.6 버전입니다.

답변

0

TMPDIR 환경 변수를 설정하려면 복제 또는 게시 프로그램을 실행하는 사용자 ID에 액세스 할 수있는 디렉토리를 지정하십시오. 다른 사용자 ID로 파일을 삭제할 수 없도록하십시오. 예를 들어 다음 명령은/home/repldba/tempfiles/디렉터리를 지정합니다. export TMPDIR =/home/repldba/tempfiles/

관련 문제