objcopy

OBJCOPY(1)                   GNU Development Tools                  OBJCOPY(1)



å称
       objcopy - ãªãã¸ã§ã¯ããã¡ã¤ã«ã®ã³ãã¼ã¨å¤æ

æ¸å¼
       objcopy [-F bfdname--target=bfdname]
               [-I bfdname--input-target=bfdname]
               [-O bfdname--output-target=bfdname]
               [-B bfdarch--binary-architecture=bfdarch]
               [-S--strip-all]
               [-g--strip-debug]
               [-K symbolname--keep-symbol=symbolname]
               [-N symbolname--strip-symbol=symbolname]
               [-G symbolname--keep-global-symbol=symbolname]
               [-L symbolname--localize-symbol=symbolname]
               [-W symbolname--weaken-symbol=symbolname]
               [-w--wildcard]
               [-x--discard-all]
               [-X--discard-locals]
               [-b byte--byte=byte]
               [-i interleave--interleave=interleave]
               [-j sectionname--only-section=sectionname]
               [-R sectionname--remove-section=sectionname]
               [-p--preserve-dates]
               [--debugging]
               [--gap-fill=val]
               [--pad-to=address]
               [--set-start=val]
               [--adjust-start=incr]
               [--change-addresses=incr]
               [--change-section-address section{=,+,-}val]
               [--change-section-lma section{=,+,-}val]
               [--change-section-vma section{=,+,-}val]
               [--change-warnings] [--no-change-warnings]
               [--set-section-flags section=flags]
               [--add-section sectionname=filename]
               [--rename-section oldname=newname[,flags]]
               [--change-leading-char] [--remove-leading-char]
               [--srec-len=ival] [--srec-forceS3]
               [--redefine-sym old=new]
               [--redefine-syms=filename]
               [--weaken]
               [--keep-symbols=filename]
               [--strip-symbols=filename]
               [--keep-global-symbols=filename]
               [--localize-symbols=filename]
               [--weaken-symbols=filename]
               [--alt-machine-code=index]
               [--prefix-symbols=string]
               [--prefix-sections=string]
               [--prefix-alloc-sections=string]
               [--add-gnu-debuglink=path-to-file]
               [--only-keep-debug]
               [--writable-text]
               [--readonly-text]
               [--pure]
               [--impure]
               [-v--verbose]
               [-V--version]
               [--help] [--info]
               infile [outfile]

解説
       GNU objcopy ã¦ã¼ãã£ãªãã£ã¯ãããªãã¸ã§ã¯ããã¡ã¤ã«ã®å容ãä»ã¸ã³ãã¼ãã¾ãã
       objcopy ã¯ãªãã¸ã§ã¯ããã¡ã¤ã«ã®èªã¿æ¸ãã« GNU BFD ã©ã¤ãã©ãªã使ãã¾ãã
       åã®ãªãã¸ã§ã¯ããã¡ã¤ã«ã¨ç°ãªããã©ã¼ãããã§ã³ãã¼åã®
       ãªãã¸ã§ã¯ããã¡ã¤ã«ã«æ¸ãè¾¼ãäºãå¯è½ã§ãã objcopy
       ã®å³å¯ãªæåã¯ã³ãã³ãã©ã¤ã³ã®å¼æ°ã§å¶å¾¡ãã¾ãã objcopy
       ã¯ãå®å¨ã«ãªã³ã¯ããããã¡ã¤ã«ãªãã ä»»æã® 2 å½¢å¼éã§ã³ãã¼å¯è½ã§ããã¯ãã§ããã
       åéç½®å¯è½ãªã¸ã§ã¯ããã¡ã¤ã«ã®ä»»æã® 2 å½¢å¼éã§ã®ã³ãã¼ã¯ã
       æå¾éãã«åä½ããªãããããã¾ããã

       objcopy ã¯å¤æã®ããã«ä¸æãã¡ã¤ã«ãä½æãã¦å¾ã§ããããåé¤ãã¾ãã objcopy
       ã¯ãã¹ã¦ã®å¤æä½æ¥ã§ BFD ã使ãã¾ã; ã¤ã¾ã BFD ãç¥ã£ã¦ãã
       ãã©ã¼ãããã¯ãã¹ã¦ç¥ã£ã¦ããäºã«ãªãã®ã§ãæ示çã«æå®ããªãã¦ã
       大é¨åã®ãã©ã¼ããããèªèããäºãåºæ¥ã¾ãã

       objcopy ã§åºååã« srec ãæå®ãã (ä¾ãã° -O srec ã使ã) ãã¨ã§ S
       ã¬ã³ã¼ããçæã§ãã¾ãã

       objcopy ã§åºååã« binary ãæå®ãã (ä¾ãã° -O binary ã使ã)
       ãã¨ã§çã®ãã¤ããªãã¡ã¤ã«ãçæã§ãã¾ãã objcopy
       ã§çã®ãã¤ããªãã¡ã¤ã«ãçæãããã¨ã¯ãæ¬è³ªçã«ã¯å¥åã®
       ãªãã¸ã§ã¯ããã¡ã¤ã«ã®å容ã®ã¡ã¢ãªãã³ããçæãããã¨ã« ãªãã§ãããã
       ã·ã³ãã«ã¨åéç½®æå ±ã¯ãã¹ã¦æ¨ã¦å»ããã¾ãã ã¡ã¢ãªãã³ãã¯åºåãã¡ã¤ã«ã«
       ã³ãã¼ãããä¸ã§æãä½ä½ã®ã»ã¯ã·ã§ã³ã®ä»®æ³ã¢ãã¬ã¹ããå§ã¾ãã¾ãã

       S ã¬ã³ã¼ããçã®ãã¤ããªãã¡ã¤ã«ãçæããå ´åã¯ã -S
       ã使ã£ã¦ãããã°æå ±ãå«ãã»ã¯ã·ã§ã³ãåé¤ããã®ãè¯ãããããã¾ããã å ´åã«ãã£ã¦ã¯ -R
       ãããã¤ããªãã¡ã¤ã«ã«å¿è¦ç¡ãæå ±ãå«ãã»ã¯ã·ã§ã³ãåé¤ããã®ã«æç¨ã§ãããã

       注 - objcopy ã¯å¥åãã¡ã¤ã«ã®ã¨ã³ãã£ã¢ã³ãå¤ãããã¾ããã
       å¥åãã¡ã¤ã«ã«ã¨ã³ãã£ã¢ã³æ§ãããå ´å (ãã©ã¼ãããã«ãã£ã¦ã¯
       ã¨ã³ãã£ã¢ã³æ§ããªããã®ãããã¾ã)ã åãã¨ã³ãã£ã¢ã³æ§ã®ãã¡ã¤ã«ãã©ã¼ãããã
       ã¨ã³ãã£ã¢ã³æ§ã®ç¡ããã¡ã¤ã«æ¸å¼ (ä¾: srec) ã¸ã®ã¿ã objcopy
       ã¯ã³ãã¼å¯è½ã¨ãªãã¾ãã

ãªãã·ã§ã³
       infile
       outfile
           ããããå¥åã¨åºåãã¡ã¤ã«ã§ãã outfile ãæå®ããªãã¨ã objcopy
           ã¯ä¸æãã¡ã¤ã«ãä½æãã¦ãã ãã®ãã¡ã¤ã«åã infile ã«ä»ããã㦠ãã¾ãã¾ãã

       -I bfdname
       --input-target=bfdname
           å¥åãã¡ã¤ã«ã®ãªãã¸ã§ã¯ãå½¢å¼ãæ¨æ¸¬ãããã¨ãããããã« bfdname
           ã§ããã¨ãã¦æ±ãã¾ãã

       -O bfdname
       --output-target=bfdname
           ãªãã¸ã§ã¯ãå½¢å¼ã¨ã㦠bfdname ã使ã£ã¦åºåãã¡ã¤ã«ã«æ¸ãè¾¼ã¿ã¾ãã

       -F bfdname
       --target=bfdname
           å¥åºå両æ¹ã®ãªãã¸ã§ã¯ãå½¢å¼ã bfdname ã§ããã¨ãã¾ã;
           ã¤ã¾ããå¥åããåºåã¸ç¡å¤æã§ãã¼ã¿ã åç´ã«è»¢éããã¨ãããã¨ã§ãã

       -B bfdarch
       --binary-architecture=bfdarch
           çã®ãã¤ããªå¥åãã¡ã¤ã«ããªãã¸ã§ã¯ããã¡ã¤ã«ã¸å¤æããå ´åã«æç¨ã§ãã
           ãã®å ´åãåºåã¢ã¼ããã¯ãã£ã bfdarch ã«è¨å®å¯è½ã§ãã å¥åãã¡ã¤ã«ãæ¢ç¥ã®
           bfdarch ãæã¤å ´åããã®ãªãã·ã§ã³ã¯ç¡è¦ããã¾ãã
           ãã®ãã¤ããªãã¼ã¿ã¯ãå¤æå¦çã«ãã£ã¦ä½æãããç¹æ®ã·ã³ãã«ãä»ãã ãã‐
           ã°ã©ã ããã¢ã¯ã»ã¹å¯è½ã¨ãªãã¾ãã ãããã®ã·ã³ãã«ã¯ã
           _binary_objfile_start, _binary_objfile_end, _binary_objfile_size
           ã¨ããååã§ãã ä¾ãã°ãç»åãã¡ã¤ã«ããªãã¸ã§ã¯ããã¡ã¤ã«ã«å¤æãã
           ã³ã¼ããããããã®ã·ã³ãã«ã使ç¨ãããã¨ã§ã¢ã¯ã»ã¹å¯è½ã¨ãªãã¾ãã

       -j sectionname
       --only-section=sectionname
           æå®ããã»ã¯ã·ã§ã³ã®ã¿å¥åãã¡ã¤ã«ããåºåãã¡ã¤ã«ã¸ã³ãã¼ãã
           ä»ã®ãã¹ã¦ã®ã»ã¯ã·ã§ã³ãæ¨ã¦ã¾ãã ãã®ãªãã·ã§ã³ã¯ 2 å以ä¸æå®ã§ãã¾ãã
           ãã®ãªãã·ã§ã³ãä¸é©åã«ä½¿ãã¨åºåãã¡ã¤ã«ã
           å©ç¨ã§ããªãç©ã«ãªãã®ã§æ³¨æãã¦ä¸ããã

       -R sectionname
       --remove-section=sectionname
           sectionname 㧠æå®ãããã»ã¯ã·ã§ã³ããã¡ã¤ã«ããåãé¤ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã ãã®ãªãã·ã§ã³ãä¸é©åã«ä½¿ãã¨åºåãã¡ã¤ã«ã
           å©ç¨ã§ããªãç©ã«ãªãã®ã§æ³¨æãã¦ä¸ããã

       -S
       --strip-all
           åéç½®ã¨ã·ã³ãã«ã®æå ±ãå¥åãã¡ã¤ã«ããã³ãã¼ãã¾ããã

       -g
       --strip-debug
           ãããã°ã·ã³ãã«ããããã°ã»ã¯ã·ã§ã³ãå¥åãã¡ã¤ã«ããã³ãã¼ãã¾ããã

       --strip-unneeded
           åéç½®å¦çã«ä¸è¦ãªã·ã³ãã«ããã¹ã¦åãé¤ãã¾ãã

       -K symbolname
       --keep-symbol=symbolname
           å¥åãã¡ã¤ã«ããã·ã³ãã« symbolname ã ããã³ãã¼ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã

       -N symbolname
       --strip-symbol=symbolname
           å¥åãã¡ã¤ã«ããã·ã³ãã« symbolname ãã³ãã¼ãã¾ããã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã

       -G symbolname
       --keep-global-symbol=symbolname
           ã·ã³ãã« symbolname ã®ã¿ãã°ãã¼ãã«ã«ãã¾ãã
           ä»ã®ã·ã³ãã«ã¯ãã¹ã¦ãå¤é¨ããåç§ã§ããªãããã«ãã¡ã¤ã«åãã¼ã«ã«ã«ãã¾ãã
           ãã®ãªãã·ã§ã³ã¯ 2 å以ä¸æå®ã§ãã¾ãã

       -L symbolname
       --localize-symbol=symbolname
           ã·ã³ãã« symbolname ããå¤é¨ããåç§ã§ããªãããã«ãã¡ã¤ã«å ã‐
           ã¼ã«ã«ã«ãã¾ãããã®ãªãã·ã§ã³ã¯ 2 å以ä¸æå®ã§ãã¾ãã

       -W symbolname
       --weaken-symbol=symbolname
           ã·ã³ãã« symbolname ã weak ã«ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2 å以ä¸æå®ã§ãã¾ãã

       -w
       --wildcard
           ä»ã®ã³ãã³ãè¡ãªãã·ã§ã³ã®ä¸ã§ä½¿ç¨ããã symbolname ã§ã æ‐
           £è¦è¡¨ç¾ã®ä½¿ç¨ã許å¯ãã¾ãã çå符 (?)ãã¢ã¹ã¿ãªã¹ã¯ (*)ãããã¯ã¹ã©ãã·ã¥
           (\)ãè§æ¬å¼§ ([]) æ¼ç®åãã·ã³ãã«åã®ä¸ã®ã©ãã§ã§ã使ç¨å¯è½ã«ãã¾ãã
           ã·ã³ãã«åã®æåã®æåãæå符 (!) ã§ããå ´åããã®ã¹ã¤ããã®æå³ã
           ãã®ã·ã³ãã«ã«å¯¾ãã¦ã¯éã«ãªãã¾ãã ä¾ãã°ã

                     -w -W !foo -W fo*

           ã«ãããobjcopy 㯠``foo'' ãé¤ãã``fo'' ã§å§ã¾ããã¹ã¦ã®ã·ã³ãã«ã weak
           ã«ãã¾ãã

       -x
       --discard-all
           å¥åãã¡ã¤ã«ããã°ãã¼ãã«ã§ãªãã·ã³ãã«ãã³ãã¼ãã¾ããã

       -X
       --discard-locals
           ã³ã³ãã¤ã©ãçæãããã¼ã«ã«ã·ã³ãã«ãã³ãã¼ãã¾ãã (ãããã¯é常 L ã .
           ã§å§ã¾ãã¾ã)ã

       -b byte
       --byte=byte
           å¥åãã¡ã¤ã«ã®å byte çªãã®ãã¤ãã®ã¿ãåãåºãã¾ã (ããããã¼ã¿ã«ã¯å½±é¿ãã¾ãã)ã
           byte ã«ã¯ 0 ãã interleave-1 ã®ç¯å²ã®å¤ãæå®ã§ãã¾ãã interleave ã¯ã-i
           ã¾ã㯠--interleave ã®ãªãã·ã§ã³ã§ æå®ããããããã©ã«ãã® 4 ã§ãã
           ãã®ãªãã·ã§ã³ã¯ ROM ã«æ¸ãè¾¼ãããã®ãã¡ã¤ã«ãä½æããããã«æç¨ã§ãã å¸åçã«ã¯
           "srec" ã®åºåæå®ã¨å±ã«ä½¿ãã¾ãã

       -i interleave
       --interleave=interleave
           å interleave ãã¤ããã¨ã« 1 ãã¤ãã ããã³ãã¼ãã¾ãã ã©ããã³ãã¼ããã㯠-b ã
           --byte ãªãã·ã§ã³ã§ é¸ã³ã¾ããããã©ã«ã㯠4ã§ãã -b ã --byte
           ã®ã©ã¡ããæå®ããã¦ããªãå ´åã objcopy ã¯æ¬ãªãã·ã§ã³ãç¡è¦ãã¾ãã

       -p
       --preserve-dates
           åºåãã¡ã¤ã«ã®ã¢ã¯ã»ã¹æå»ã¨æ´æ°æå»ãå¥åãã¡ã¤ã«ã«åããã¾ãã

       --debugging
           å¯è½ã§ããã°ãããã°æå ±ãå¤æãã¾ãã
           ç¹å®ã®ãããã°æå ±ãããµãã¼ããã¦ããããå¤æå¦çã¯æéã
           è¦ããå¯è½æ§ãããã®ã§ãããã¯ããã©ã«ãã§ã¯ããã¾ããã

       --gap-fill val
           ã»ã¯ã·ã§ã³éã®ããã¾ã val ã§åãã¾ãã ãã®æä½ã¯ã»ã¯ã·ã§ã³ã® load address
           (LMA) ã«é©ç¨ããã¾ãã
           ä½ä½ã¢ãã¬ã¹ã®ã»ã¯ã·ã§ã³ã®ãµã¤ãºãå¢ãããã§ããä½åã®ç©ºéã val ã§
           åããäºã§å®ç¾ãã¦ãã¾ãã

       --pad-to address
           ãã¼ãã¢ãã¬ã¹ address ã¾ã§åºåãã¡ã¤ã«ã«è©°ãç©ããã¾ãã
           ããã¯æå¾ã®ã»ã¯ã·ã§ã³ã®ãµã¤ãºãå¢ããäºã§è¡ããã¾ãã ã§ããä½åã®ç©ºéã¯
           --gap-fill 㧠æå®ãããå¤ (ããã©ã«ã㯠0) ã§åãããã¾ãã

       --set-start val
           æ°ãããã¡ã¤ã«ã®éå§ã¢ãã¬ã¹ã val ã«è¨å®ãã¾ãã
           ãã¹ã¦ã®ãªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ãéå§ã¢ãã¬ã¹ã®è¨å®ããµãã¼ããã¦ãã
           ããã§ã¯ããã¾ããã

       --change-start incr
       --adjust-start incr
           éå§ã¢ãã¬ã¹ããincr ãå ç®ããäºã§å¤æ´ãã¾ãã
           ãã¹ã¦ã®ãªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ãéå§ã¢ãã¬ã¹ã®è¨å®ããµãã¼ããã¦ãã
           ããã§ã¯ããã¾ããã

       --change-addresses incr
       --adjust-vma incr
           éå§ã¢ãã¬ã¹ããã³ãã¹ã¦ã®ã»ã¯ã·ã§ã³ã® VMA ããã³ LMA ã®ã¢ãã¬ã¹ããincr ã
           å ç®ããäºã§å¤æ´ãã¾ãã ããã¤ãã®ãªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ã§ã¯
           ã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ãä»»æã®å¤ã«å¤æ´ããäºã¯è¨±ããã¦ãã¾ããã
           ããã¯ã»ã¯ã·ã§ã³ãåéç½®ããã®ã§ã¯ãªãäºã«æ³¨æãã¦ä¸ãã; ãããã‐
           ã°ã©ã ãã»ã¯ã·ã§ã³ãç¹å®ã®ã¢ãã¬ã¹ã«ãã¼ããããäºã
           æå¾ãã¦ãããããã¦ãã®ãªãã·ã§ã³ãã»ã¯ã·ã§ã³ãç°ãªãã¢ãã¬ã¹ã« ã‐
           ã¼ãããããã«ä½¿ãããå ´åã¯ãããã°ã©ã ã¯æ£å¸¸ã« åä½ããªãããããã¾ããã

       --change-section-address section{=,+,-}val
       --adjust-section-vma section{=,+,-}val
           æå®ããã section ã® VMA ããã³ LMA ã¢ãã¬ã¹ãã è¨å®ã¾ãã¯å¤æ´ãã¾ãã = ã
           æå®ãããå ´åã¯ãã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã¯ val ã«è¨å®ããã¾ãã ããã§ãªããã° val
           ãã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã«å ç®ã¾ãã¯æ¸ç®ããã¾ãã ä¸ã® --change-addresses
           ã«æ¸ããã¦ããã³ã¡ã³ããåç§ãã¦ä¸ããã å¥åãã¡ã¤ã«ã« section ãåå¨ããªãå ´åã¯ã
           --no-change-warnings ãæå®ããã¦ããªããã°è¦åãåºåããã¾ãã

       --change-section-lma section{=,+,-}val
           æå®ããã section ã® LMA ã¢ãã¬ã¹ãã è¨å®ã¾ãã¯å¤æ´ãã¾ãã LMA ã¢ãã¬ã¹ã¯ã
           ããã°ã©ã ãã¼ãæã«ã»ã¯ã·ã§ã³ããã¼ããããã¡ã¢ãªã®ã¢ãã¬ã¹ã§ãã ããã¯é常ããã‐
           ã°ã©ã å®è¡æã®ã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã§ãã VMA
           ã¢ãã¬ã¹ã¨åãã§ãããã·ã¹ãã ã«ãã£ã¦ã¯ã ç¹ã« ROM ã«ãã‐
           ã°ã©ã ãä¿æããããã®ã«ããã¦ã¯ã両èã¯ç°ãªãã¾ãã = ã
           æå®ãããå ´åã¯ãã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã¯ val ã«è¨å®ããã¾ãã ããã§ãªããã° val
           ãã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã«å ç®ã¾ãã¯æ¸ç®ããã¾ãã ä¸ã® --change-addresses
           ã«æ¸ããã¦ããã³ã¡ã³ããåç§ãã¦ä¸ããã å¥åãã¡ã¤ã«ã« section ãåå¨ããªãå ´åã¯ã
           --no-change-warnings ãæå®ããã¦ããªããã°è¦åãåºåããã¾ãã

       --change-section-vma section{=,+,-}val
           æå®ããã section ã® VMA ã¢ãã¬ã¹ãã è¨å®ã¾ãã¯å¤æ´ãã¾ãã VMA ã¢ãã¬ã¹ã¯ã
           ããã°ã©ã ãå®è¡éå§ããå¾ã«ã»ã¯ã·ã§ã³ãç½®ãããã¢ãã¬ã¹ã§ãã
           ããã¯é常ãã¡ã¢ãªã«ãã¼ããããã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã§ãã LMA
           ã¢ãã¬ã¹ã¨åãã§ãããã·ã¹ãã ã«ãã£ã¦ã¯ã ç¹ã« ROM ã«ãã‐
           ã°ã©ã ãä¿æããããã®ã«ããã¦ã¯ã両èã¯ç°ãªãã¾ãã = ã
           æå®ãããå ´åã¯ãã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã¯ val ã«è¨å®ããã¾ãã ããã§ãªããã° val
           ãã»ã¯ã·ã§ã³ã®ã¢ãã¬ã¹ã«å ç®ã¾ãã¯æ¸ç®ããã¾ãã ä¸ã® --change-addresses
           ã«æ¸ããã¦ããã³ã¡ã³ããåç§ãã¦ä¸ããã å¥åãã¡ã¤ã«ã« section ãåå¨ããªãå ´åã¯ã
           --no-change-warnings ãæå®ããã¦ããªããã°è¦åãåºåããã¾ãã

       --change-warnings
       --adjust-warnings
           --change-section-address, --change-section-lma,
           --change-section-vma ã®ãããããæå®ãããå ´åã æå®ãããã»ã¯ã·ã§ã³ãå‐
           å¨ããªãã¨è¦åãåºåããã¾ãã ããã¯ããã©ã«ãã§ãã

       --no-change-warnings
       --no-adjust-warnings
           --change-section-address, --adjust-section-lma,
           --adjust-section-vma ã®ãããããæå®ãããå ´åã æå®ããã ã»ã¯ã·ã§ã³ãå‐
           å¨ããªãã¦ãè¦åãåºåãã¾ããã

       --set-section-flags section=flags
           æå®ãããã»ã¯ã·ã§ã³ã®ãã©ã°ãè¨å®ãã¾ãã å¼æ° flags
           ã¯ãã©ã°åãã³ã³ãã§åºåã£ãæååã§ãã èªèãããã©ã°å㯠alloc, contents, load,
           noload, readonly, code, data, rom, share, debug ã§ãã
           å容ãæããªãã»ã¯ã·ã§ã³ã«å¯¾ã㦠contents ãã©ã°ãè¨å®å¯è½ã§ããã
           å容ãæããªãã»ã¯ã·ã§ã³ã«å¯¾ã㦠contents ãã©ã°ãã¯ãªã¢ãã ãã¨ã¯ç¡æå³ã§ãã
           åã«ãã®ã»ã¯ã·ã§ã³ãåé¤ãã¦ãã ããã
           ãã¹ã¦ã®ãã©ã°ããã¹ã¦ã®ãªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ã§ æå³ãæã¤ã¨ã¯éãã¾ããã

       --add-section sectionname=filename
           sectionname ã§æå®ãããååã®æ°ããã»ã¯ã·ã§ã³ããã¡ã¤ã«ã® ã³ãã¼ä¸‐
           ã«ä»ãå ãã¾ãã æ°ããã»ã¯ã·ã§ã³ã®å容ã¯ãã¡ã¤ã« filename ããåãè¾¼ã¾ãã¾ãã
           ã»ã¯ã·ã§ã³ã®ãµã¤ãºã¯ãã¡ã¤ã«ã®ãµã¤ãºã«ãªãã¾ãã
           ãã®ãªãã·ã§ã³ã¯ä»»æã®ååãæã¤ã»ã¯ã·ã§ã³ã
           ãµãã¼ãã§ãããã¡ã¤ã«å½¢å¼ã§ã®ã¿æ©è½ãã¾ãã

       --rename-section oldname=newname[,flags]
           ã»ã¯ã·ã§ã³ã®ååã oldname ãã newname ã¸å¤ãã¾ãã
           ãã®å¦çã«ããã¦ãã»ã¯ã·ã§ã³ãã©ã°ã flags ã«å¤ãããã¨ãã§ãã¾ãã
           ãªã³ã«ã¹ã¯ãªããã使ã£ã¦ãªãã¼ã ãããã¨ã«å¯¾ããå©ç¹ã¯ã
           åºåããªãã¸ã§ã¯ããã¡ã¤ã«ã®ã¾ã¾ã§ããã ãªã³ã¯æ¸å®è¡å½¢å¼ã¨ã¯ãªããªããã¨ã§ãã

           ãã®ãªãã·ã§ã³ãç¹ã«æç¨ãªã®ã¯ãå¥åãã©ã¼ãããããã¤ããªã®æã§ãã
           ãªããªããæ¬ãªãã·ã§ã³ã¯ .data ã»ã¯ã·ã§ã³ã常ã«ä½æããããã§ãã
           ä¾ãã°ããã¤ããªãã¼ã¿ãå«ã .rodata ã»ã¯ã·ã§ã³ã代ãã«ä½æãããå ´åã
           次ã®ã³ãã³ãã©ã¤ã³ã§å®ç¾å¯è½ã§ã:

                     objcopy -I binary -O <output_format> -B <architecture> \
                      --rename-section .data=.rodata,alloc,load,readonly,data,contents \
                      <input_binary_file> <output_object_file>

       --change-leading-char
           ããã¤ãã®ãªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ã§ã·ã³ãã«ã®æåã«ç¹æ®æåã 使ããã¦ãã¾ãã
           ãã£ã¨ãä¸è¬çãªã®ã¯ã¢ã³ãã¹ã³ã¢ã§ããã°ãã°
           ã³ã³ãã¤ã©ãåã·ã³ãã«ã®åã«ä»ãå ãã¾ãã ãã®ãªãã·ã§ã³ã¯ objcopy
           ã«ããªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ãå¤æããæã«åã·ã³ãã«ã®å§ã¾ãã® æå‐
           ãå¤æ´ããããæ示ãã¾ãã
           å¤æåå¾ã®ãªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ãã·ã³ãã«ã®å§ã¾ãã«åãæåã
           使ã£ã¦ããå ´åã¯ããã®ãªãã·ã§ã³ã¯ä½ããã¾ããã ããã§ãªããã°ã
           ãã®ãªãã·ã§ã³ã§æåãä»ãå ãããã¾ãã¯æåãåé¤ãããã¾ã㯠æå‐
           ãå¤æ´ããäºããé©åã«è¡ããã¾ãã

       --remove-leading-char
           ã°ãã¼ãã«ã·ã³ãã«ã®æåã®æåãããªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ã§ä½¿ããã
           ã·ã³ãã«ã®æåã«ä»å ãããç¹æ®æåã ã£ãå ´åã¯ããã®æåãåãé¤ãã¾ãã
           ã·ã³ãã«ã«åç½®ãããæãä¸è¬çãªæåã¯ã¢ã³ãã¹ã³ã¢ã§ãã
           ãã®ãªãã·ã§ã³ã¯åç½®ããã¦ããã¢ã³ãã¹ã³ã¢ããã¹ã¦ã® ã°ã‐
           ã¼ãã«ã·ã³ãã«ããåãé¤ãã¾ãã ããã¯ã·ã³ãã«åã®åã決ãã
           ç°ãªããã¡ã¤ã«å½¢å¼ã®ãã¡ã¤ã«ãä¸ç·ã«ãªã³ã¯ãããå ´åã«æç¨ã§ãã ããã¯
           --change-leading-char ã¨ã¯ç°ãªãã¾ãã
           ãªããªããã®ãªãã·ã§ã³ã§ã¯é©åã§ããã°ã
           åºåã®ãªãã¸ã§ã¯ããã¡ã¤ã«å½¢å¼ã¨ã¯é¢ä¿ãªã
           常ã«ã·ã³ãã«åãå¤æ´ãã¦ãã¾ãããã§ãã

       --srec-len=ival
           srec åºåã§ã®ã¿æå³ãããã¾ãã S ã¬ã³ã¼ãã®é·ãã val ã«è¨å®ãã¾ãã
           ãã®é·ãã«ã¯ãã¢ãã¬ã¹ããã¼ã¿ãCRC ãã£ã¼ã«ããå«ã¾ãã¾ãã

       --srec-forceS3
           srec åºåã§ã®ã¿æå³ãããã¾ãã S1/S2 ã¬ã³ã¼ãã®çæãé²ããS3
           ã¬ã³ã¼ãã®ã¿ã®ãã©ã¼ãããã«ãã¾ãã

       --redefine-sym old=new
           ã·ã³ãã«ã®ååã old ãã new ã¸å¤æ´ãã¾ãã ã½ã¼ã¹ãç¡ã 2
           ã¤ã®ãã®ãªã³ã¯ãããã¨ãã¦ãã¦ã ååã®è¡çªãããã¨ãã«æç¨ã§ãããã

       --redefine-syms=filename
           ãã¡ã¤ã« filename ã«ãªã¹ããããã·ã³ãã«ã®çµ "old new"
           ã®ããããã«å¯¾ãã--redefine-sym ãé©ç¨ãã¾ãã filename
           ã¯åãªããã©ãããã¡ã¤ã«ã§ãããã·ã³ãã«ã®çµ 1 ã¤ã«ã¤ã 1 è¡ãå ãã¾ãã ããã·ã¥æå‐
           ã«ããã³ã¡ã³ãè¡ãç½®ããã¨ãã§ãã¾ãã ãã®ãªãã·ã§ã³ã¯è¤æ°åæå®ãããã¨ãã§ãã¾ãã

       --weaken
           ãã¡ã¤ã«ã®ãã¹ã¦ã®ã°ãã¼ãã«ã·ã³ãã«ã weak ã«å¤æ´ãã¾ãã ããã¯ã-R
           ãªãã·ã§ã³ããªã³ã«ã«ä½¿ç¨ãã¦ã
           ä»ã®ãªãã¸ã§ã¯ãã¨ãªã³ã¯ãããªãã¸ã§ã¯ããä½æããã¨ãã«æç¨ã§ãã
           ãã®ãªãã·ã§ã³ã¯ããªãã¸ã§ã¯ããã¡ã¤ã«ãã©ã¼ãããã weak
           ã·ã³ãã«ããµãã¼ãããã¨ãã®ã¿å¹æãããã¾ãã

       --keep-symbols=filename
           ãã¡ã¤ã« filename ã§åæããã¦ããåã·ã³ãã«ã«å¯¾ãã --keep-symbol
           ãªãã·ã§ã³ãé©ç¨ãã¾ãã filename ã¯åã«å¹³å¦ãªãã¡ã¤ã«ã§ããã1 è¡ã« 1
           ã·ã³ãã«ãè¨è¿°ããã¾ãã è¡ã³ã¡ã³ãã¯ãããã·ã¥æåã§éå§ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã

       --strip-symbols=filename
           ãã¡ã¤ã« filename ã§åæããã¦ããåã·ã³ãã«ã«å¯¾ãã --strip-symbol
           ãªãã·ã§ã³ãé©ç¨ãã¾ãã filename ã¯åã«å¹³å¦ãªãã¡ã¤ã«ã§ããã1 è¡ã« 1
           ã·ã³ãã«ãè¨è¿°ããã¾ãã è¡ã³ã¡ã³ãã¯ãããã·ã¥æåã§éå§ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã

       --keep-global-symbols=filename
           ãã¡ã¤ã« filename ã§åæããã¦ããåã·ã³ãã«ã«å¯¾ãã --keep-global-symbol
           ãªãã·ã§ã³ãé©ç¨ãã¾ãã filename ã¯åã«å¹³å¦ãªãã¡ã¤ã«ã§ããã1 è¡ã« 1
           ã·ã³ãã«ãè¨è¿°ããã¾ãã è¡ã³ã¡ã³ãã¯ãããã·ã¥æåã§éå§ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã

       --localize-symbols=filename
           ãã¡ã¤ã« filename ã§åæããã¦ããåã·ã³ãã«ã«å¯¾ãã --localize-symbol
           ãªãã·ã§ã³ãé©ç¨ãã¾ãã filename ã¯åã«å¹³å¦ãªãã¡ã¤ã«ã§ããã1 è¡ã« 1
           ã·ã³ãã«ãè¨è¿°ããã¾ãã è¡ã³ã¡ã³ãã¯ãããã·ã¥æåã§éå§ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã

       --weaken-symbols=filename
           ãã¡ã¤ã« filename ã§åæããã¦ããåã·ã³ãã«ã«å¯¾ãã --weaken-symbol
           ãªãã·ã§ã³ãé©ç¨ãã¾ãã filename ã¯åã«å¹³å¦ãªãã¡ã¤ã«ã§ããã1 è¡ã« 1
           ã·ã³ãã«ãè¨è¿°ããã¾ãã è¡ã³ã¡ã³ãã¯ãããã·ã¥æåã§éå§ãã¾ãã ãã®ãªãã·ã§ã³ã¯ 2
           å以ä¸æå®ã§ãã¾ãã

       --alt-machine-code=index
           åºåã¢ã¼ããã¯ãã£ãå¥ã®ãã·ã³ã³ã¼ããæã¤å ´åã ããã©ã«ãã®ã³ã¼ãã®ä»£ãã« index
           çªç®ã®ã³ã¼ãã使ç¨ãã¾ãã ãããã·ã³ã«å¬å¼ãªã³ã¼ããå²ãå½ã¦ããã¦ããã
           ãã¼ã«ãã§ã¼ã³ãæ°è¦ã³ã¼ããæ¡ç¨ãããã
           ä»ã®ã¢ããªã±ã¼ã·ã§ã³ã¯åã®ã³ã¼ãã使ããããã¨ã«ä¾åãã¦ããå ´åã æç¨ã¨ãªãã¾ãã

       --writable-text
           åºåãã¡ã¤ã«ã«æ¸ãè¾¼ã¿å¯è½ã®å°ãä»ãã¾ãã
           ãã®ãªãã·ã§ã³ã¯ãã¹ã¦ã®ãã¡ã¤ã«å½¢å¼ã«å¯¾ãã¦æå³ãããããã§ã¯ ããã¾ããã

       --readonly-text
           åºåãã¡ã¤ã«ã«æ¸ãè¾¼ã¿ç¦æ¢ã®å°ãä»ãã¾ãã
           ãã®ãªãã·ã§ã³ã¯ãã¹ã¦ã®ãã¡ã¤ã«å½¢å¼ã«å¯¾ãã¦æå³ãããããã§ã¯ ããã¾ããã

       --pure
           åºåãã¡ã¤ã«ã«ããã³ããã¼ã¸ã®å°ãä»ãã¾ãã
           ãã®ãªãã·ã§ã³ã¯ãã¹ã¦ã®ãã¡ã¤ã«å½¢å¼ã«å¯¾ãã¦æå³ãããããã§ã¯ ããã¾ããã

       --impure
           åºåãã¡ã¤ã«ã« impure ã®å°ãä»ãã¾ãã
           ãã®ãªãã·ã§ã³ã¯ãã¹ã¦ã®ãã¡ã¤ã«å½¢å¼ã«å¯¾ãã¦æå³ãããããã§ã¯ ããã¾ããã

       --prefix-symbols=string
           åºåãã¡ã¤ã«ã®ã·ã³ãã«ãã¹ã¦ã« string ãåç½®ãã¾ãã

       --prefix-sections=string
           åºåãã¡ã¤ã«ã®ã»ã¯ã·ã§ã³ãã¹ã¦ã« string ãåç½®ãã¾ãã

       --prefix-alloc-sections=string
           åºåãã¡ã¤ã«ä¸ã®å²ãå½ã¦ãããã»ã¯ã·ã§ã³ãã¹ã¦ã®ååãã¹ã¦ã« string
           ãåç½®ãã¾ãã

       --add-gnu-debuglink=path-to-file
           path-to-file ã¸ã®åç§ãå«ã .gnu_debuglink ã»ã¯ã·ã§ã³ã
           çæããåºåãã¡ã¤ã«ã«è¿½å ãã¾ãã

       --only-keep-debug
           ãã¡ã¤ã«ãã¹ããªãããã¾ãã ããªãã¡ã--strip-debug
           ã«ããé¤å»ãããä»»æã®ã»ã¯ã·ã§ã³ãåé¤ãããããã°ç¨ ã»ã¯ã·ã§ã³ãæ®ãã¾ãã

           ãã®æå³ã¯ããã®ãªãã·ã§ã³ã¨ --add-gnu-debuglink ã¨ã çµã¿åããã¦ä½¿ç¨ãã2
           ãã¼ãã®å®è¡å¯è½ãã¡ã¤ã«ãçæãããã¨ã« ããã¾ãã 1
           çªç®ã¯ã¹ããªããããããã¤ããªã§ãRAM ã¨
           éå¸ãã¡ã¤ã«ã«ããã¦ããå°ãªã空éãå ããããã«ãªãã 2
           çªç®ã¯ãããã°æå ±ãã¡ã¤ã«ã§ããããã°æ©è½ãè¦æ±ãããå ´åã«ã®ã¿
           å¿è¦ã¨ãªããã®ã§ãã ãããã®ãã¡ã¤ã«ã®çæã®ããã®æ¨å¥¨æé ã¯æ¬¡ã®ããã«ãªãã¾ãã

           1.<å®è¡å¯è½å½¢å¼ãæ®éã©ããã«ãªã³ã¯ãããããã§ã¯ããã®ååã>
               "foo" ã¨ãã...

           1.<"objcopy --only-keep-debug foo foo.dbg" ãå®è¡ã>
               ãããã°æå ±ãå«ããã¡ã¤ã«ãçæããã

           1.<"objcopy --strip-debug foo" ãå®è¡ã>
               ã¹ããªãããããå®è¡å¯è½å½¢å¼ãçæããã

           1.<"objcopy --add-gnu-debuglink=foo.dbg foo"ãå®è¡ã>
               ãããã°æå ±ã¸ã®ãªã³ã¯ãã¹ããªããæ¸ã®å®è¡å¯è½å½¢å¼ã«ä»å ããã

           注æ:  ãããã°æå ±ãã¡ã¤ã«ã®ããã®æ¡å¼µåã® ".dbg"
           ã¯ãä»»æã®ãã®ãé¸æã§ãã¾ãã ã¾ãã"--only-keep-debug" ã®ã¹ããããããã
           ãããªãããé¸æ次第ã§ãã代ããã«æ¬¡ã®ããã«è¡ãªããã¨ãã§ãã¾ãã

           1.<å®è¡å¯è½å½¢å¼ãæ®éã©ãããªã³ã¯ãã>
           1.<"foo" ã "foo.full" ã«ã³ãã¼ãã>
           1.<"objcopy --strip-debug foo"ãå®è¡ãã>
           1.<"objcopy --add-gnu-debuglink=foo.full foo" ãå®è¡ãã>

           ããªãã¡ã --add-gnu-debuglink ãæããã¡ã¤ã«ã¯
           å®å¨ãªæå ±ãæã¤å®è¡å¯è½å½¢å¼ã§ãæ§ãã¾ããã --only-keep-debug
           ã¹ã¤ããã使ãçæãããã¡ã¤ã«ã§ãªãã¦ãæ§ãã¾ããã

       -V
       --version
           objcopy ã®ãã¼ã¸ã§ã³çªå·ã表示ãã¦çµäºãã¾ãã

       -v
       --verbose
           åºåãåé·ã«ãã¾ã: å¤æ´ããããã¹ã¦ã®ãªãã¸ã§ã¯ããã¡ã¤ã«ããªã¹ããã¾ãã
           ã¢ã¼ã«ã¤ãã®å ´å㯠"objcopy -V" ã§ã¢ã¼ã«ã¤ãã®ã¡ã³ãããã¹ã¦ ãªã¹ãããã¾ãã

       --help
           objcopy ã®ãªãã·ã§ã³ã®ãµããªã表示ãã¦çµäºãã¾ãã

       --info
           å©ç¨å¯è½ãªã¢ã¼ããã¯ãã£ã¨ãªãã¸ã§ã¯ãå½¢å¼ãã¹ã¦ã®ãªã¹ãã表示ãã¾ãã

é¢é£é ç®
       ld(1), objdump(1), Info ã® binutils ã®é ã

COPYRIGHT
       Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002
       Free Software Foundation, Inc.

       Permission is granted to copy, distribute and/or modify this document
       under the terms of the GNU Free Documentation License, Version 1.1 or
       any later version published by the Free Software Foundation; with no
       Invariant Sections, with no Front-Cover Texts, and with no Back-Cover
       Texts.  A copy of the license is included in the section entitled "GNU
       Free Documentation License".

æ¥æ¬èªè¨³
       éé¦ å¯é«(hnokubi@yyy.or.jp): FreeBSD ç¨ã«ç¿»è¨³



binutils-2.14.91                  2004-04-09                        OBJCOPY(1)