diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /app-emulation/lxc |
reinit the tree, so we can have metadata
Diffstat (limited to 'app-emulation/lxc')
23 files changed, 2065 insertions, 0 deletions
diff --git a/app-emulation/lxc/Manifest b/app-emulation/lxc/Manifest new file mode 100644 index 000000000000..be660440866f --- /dev/null +++ b/app-emulation/lxc/Manifest @@ -0,0 +1,31 @@ +AUX lxc-1.0.8-bash-completion.patch 1324 SHA256 efadb125a43665ad60bb80a773fec517d2440cfc848fb9072be9db705378b45e SHA512 0d6293efa1080b568f8f2d64f41406ae6f07109eeb80e3d2a509246fa145c70c4128c4b8c38347b5b7e9bb0a69e2cc11f0c4e8e3ac2b6f74b57836216e5290db WHIRLPOOL 9f7fd01e8befa4e41079030ab55daefd95f7d3023d9aff1630da7d13aed1fca1bb1b6969332e3dcc052d02ece146bd3fdd249f9541d70cbee0668eb6eaaf3261 +AUX lxc-2.0.3-bash-completion.patch 1221 SHA256 ada52a06cb9ef871d6c92fbcfbd28b5484b597812c4429e03d61db0cc66206d8 SHA512 8380c1fecef8e158cc076bf9dc7556e855c202a246ae062168055b45b1ecd893ef7f188e7a784605dfe7963817a8e33fe7fc7d836b72757c913215aa06c750d0 WHIRLPOOL b9b1249bab9c51400cd3ff74d77423fe25f0b61d0f3c59c425e36e3079c5337ddacb7e062cb85536f8c46d584c029be6cdaf68c44edf34b60fa80baa0bf08511 +AUX lxc-2.0.3-omit-sysconfig.patch 285 SHA256 3046a6e31406e614c76feb7b72d19f66d0bb8874f05b39f6a48fdf1878e9f972 SHA512 3fac46c73a8c3c542d5f94b4d2e39d4c240f598090927a042d1dfbeac887444a905c7bba8fd03d58dd5436a4ef4d109c45c33e1a8917e9ec1d24f1ca7240549f WHIRLPOOL 45fd9e7be9f976ed3774f4d90ddf4496d59425de5ff55d5bfc2322dae01bf6df90e3b139c1ef437e202bb3b6cabc8b4edb90a93f22efd981fac82e06e8081b4e +AUX lxc-2.0.4-bash-completion.patch 1169 SHA256 b5f219e0fd7eaff5e574222f87309c2826d23049c73b392bf4369d33773db52c SHA512 02f875c1f04e973f79b0b963999526e4a689e6e0e2eae5d652445b130a943b6f181ee5f4389f7fc91f0109da236419b661437e9f2e8e5144a1ae23216f09b820 WHIRLPOOL c0984cb8dac366399d97664509efb685349639f635eeae00602277974110ac1dafd1cc6b4c46f8abf4e16abe8bd20ec337324716521fa159b597ed945c8947b5 +AUX lxc-2.0.4-omit-sysconfig.patch 259 SHA256 2dc717dfa8afd2823a38aeb4de72d1594b59d51ce182e71dd41b00109901fdff SHA512 0aed9aca687accc6df79e97f48ab333043256e8ae68c8643f2b2452cc8013191238867d64ec71f7d399c59a43d3ba698b35d965090c5cb149b4f41302432e6e7 WHIRLPOOL 5dbad4a04955c818e010f5229c3d061c841d1d12ad2cd7f585343fb1f5d42362aa37842149399570a0abe45cae0f4be60f3fe8e4281a473e1657edf9da039fe5 +AUX lxc-2.0.5-bash-completion.patch 1169 SHA256 b5f219e0fd7eaff5e574222f87309c2826d23049c73b392bf4369d33773db52c SHA512 02f875c1f04e973f79b0b963999526e4a689e6e0e2eae5d652445b130a943b6f181ee5f4389f7fc91f0109da236419b661437e9f2e8e5144a1ae23216f09b820 WHIRLPOOL c0984cb8dac366399d97664509efb685349639f635eeae00602277974110ac1dafd1cc6b4c46f8abf4e16abe8bd20ec337324716521fa159b597ed945c8947b5 +AUX lxc-2.0.5-omit-sysconfig.patch 259 SHA256 2dc717dfa8afd2823a38aeb4de72d1594b59d51ce182e71dd41b00109901fdff SHA512 0aed9aca687accc6df79e97f48ab333043256e8ae68c8643f2b2452cc8013191238867d64ec71f7d399c59a43d3ba698b35d965090c5cb149b4f41302432e6e7 WHIRLPOOL 5dbad4a04955c818e010f5229c3d061c841d1d12ad2cd7f585343fb1f5d42362aa37842149399570a0abe45cae0f4be60f3fe8e4281a473e1657edf9da039fe5 +AUX lxc-2.0.6-bash-completion.patch 919 SHA256 44c354c90d85371654d77337c8daeca34c0b22a76a424d67b76e38daa960a1fd SHA512 caa90c8bad2a79b4e42b781f00d6f2a7be37fc5c5301592b026c88db2652c90871be940c86a9156f03bc186f76cf2068a2d3084e9abc7a5896ea081885085d41 WHIRLPOOL caf8b079f994db0a3139b6bc77b50f3510ec7fee91ba902d9f4f562a06e40110eea01c02c4427a85daae480dcce1e4cc352e6e00cf4b200cad3dd758fd573133 +AUX lxc-2.0.6-major.patch 1834 SHA256 c0095581ab6f92e6cdbfc8298af08f1fbcbff98cf6d107b925489fd7253e418d SHA512 274e2d138e32645aca2ab954e24db02c4d7c5750a781ebf3d81c69c7eeade06b33a3c8ac36a16548a58f6d7f518977fb2df09e22de96d966de542f470720b398 WHIRLPOOL 386ac9236f5b6ff7ed721f1d0aeace99598a62f42c06423b268f1b75bc96aa446a7dcedf41c3fe131ec21dbdf670b3308d957ae508ca125623656eb06fdd2638 +AUX lxc.initd.3 3273 SHA256 f704614cfb1b07aeceda15f4edfa392f5866743b0e582753d6afcf8a942a0155 SHA512 38b4b4d4cc8473d5836ac5c4a0824099ea9037e11c6624db53d977f0dcd2dfec3731db5d71a47dc5ebd4fa723cca50dfa9bf39f317e8d146f2a278ef3c9c83a8 WHIRLPOOL 7c68c9c7a68c995294f67186c27d726838605693611a21bdc548b497d1fa23a2a30762da136ca2d474504f25680ca83b8ce41545ae4ae8d4172420fd5d6321ea +AUX lxc.initd.5 3282 SHA256 bc57cbf32f3b226b938a5871e97323849050e3c2f68a3e1db78b927c16f7f930 SHA512 6f72701fa42d41b39647a95ec45ca4d669a08a300f54b39715bbb554001bf662b9173cdacc2cb49b8e1093f5fcef971a1fd8270164c73a8e49d1b66dcbe7408d WHIRLPOOL fc4f8c066fd8c8b4290d01b8b12161630437738bdc656e50ba8183f7d1e7775d40c211ab94f6dbd9a640c568168d98c94c26d24eb9969049fa1cc45145a40977 +AUX lxc.initd.6 3280 SHA256 1bc1ee13105e6e0e060952d9c00d8e21c2ca14f8a345196251399cf5d1114a5f SHA512 914075985f11c84f41c10a1b48906e7ac10c7e486389df2a18bfde87af105bf0d302f6db19ffd6f794cbaf06c691bb8ca914c15e651d4f7b442f7eaaa80b658e WHIRLPOOL e8c19d151e1072e067fd57c148f8d7bd1a6f6f43043a0cc060b450bf56233b28647afd8e22c21e29f3ae56c29c835f6b5f79c36ed66a51128ee5b1a5f835e026 +AUX lxc_at.service 232 SHA256 0aaf2f362b3ac6aa2b427d47ac4436d46387624b0d8bc4850c5d5b6a7d228711 SHA512 4c3bab4f2cc9aea8b0753dcaf2fd7ed5f1cd7d97d286d6204b2fc17505b6edaac2f536bbda5c1466856311d0e93d75de91dec51e9b0f665d67afedbf40c19170 WHIRLPOOL f6928b4b85e63c38295cabc651b7bd61d2b0bc69ff1850de7cfa8a4f40e4894d94264c262fec7d345488cace49c4283f932739313b975f6862c1aa0ef51e0652 +AUX lxc_at.service.4 265 SHA256 194ce2917e99a5050dd793bc31c7d4393f61a9244aaa2f59109eaf8bebfe44fd SHA512 d61e7103e90e6ffb3202533e7d7555d8c02b943f06ec6c0d673713c1c0ede58641312c65d6dd6a15907c1171522e6148c2313d7b11acbd85d59fe65758cd52b3 WHIRLPOOL 55892d9cc5ff8cd8ca95ccae65abbb9735904cf1aba6ea33008349bbe4ea2ac01f83307998e90265b7dd2127761c05199be4f7133f21af1490bda40bf18a2873 +DIST lxc-1.0.8.tar.gz 575127 SHA256 399ac3eb4e0a89d657fb2e2a57f686ed061d3f1ea4733e7521b1539e9906c7ee SHA512 f552a4f48bb47d26c6b9ddaf8221a439c0848e3f54ec41b77d54717c21bddd56193941046cc96c699790e8265e762a926469c25ee687adcf7795f2906b1c260a WHIRLPOOL 72cd0b8b0345692dd9a3ed8785ee27f5e575794a96c515db1f1d073c29be4c06ae8c1ee24fa375a5ede2bba2494704916710b2e8814ed991d43330a40dff3d56 +DIST lxc-2.0.3.tar.gz 772448 SHA256 635afa330088fea57883018da326fc72f85460b5a6c7802ad68044381aff14f3 SHA512 df714f189ec7aa681710fbd58405b8958740102032c0130d8a0eaaae0341a9bc91a215136203c404ad79773800f620bf6f71f811b3effe559aed66efa4f34fef WHIRLPOOL 89ce2f6762c7279e24658c1154b5c2960d3db32e0ec3724b338f5d30da77cc0b33a2376e5eebe6d9c356bdd34c2aa9da1e2434aecd7e428fa4b729389e35b862 +DIST lxc-2.0.4.tar.gz 775634 SHA256 57d40234aeecf5b60fb29d563e5a09d6a04c89e1267eb22a6704388ac8573e7b SHA512 3f985bba5aaa8a70f0329316ea4f42ab135d58c47611154c62e103718212a4b2c5e4f25fd45c372424db1fbf40afdc8269ae98655fb3bc8e31085a5d948f702b WHIRLPOOL b001c75d67d676e75b203d789cf2c0643ba9a47aa31965441340b66f28e18371415b9d44ce752e35102bc8677688eec6e586d800a33a2a965c8a046c091ebc06 +DIST lxc-2.0.5.tar.gz 778842 SHA256 1f1c491b2ad5e74a85b8eb791ccac8128e6eaf5ddcc1323e9360997c030f7072 SHA512 8e14036597fa3407c87fb92d13b40bbca9a646d27d817e0a9d20fe626625d6cf04a1df65b1a723391d41a311b9f4f3432b3213004892d64355fe0edc7858cb9f WHIRLPOOL fa6ac86d67fe563f92411cbd09a0d66d729a0a15fe48076b42f4b3996e6b786826990bd51382c14606fd1b5240d413bc8d217fac37becd9baccd89de15d30b22 +DIST lxc-2.0.6.tar.gz 788483 SHA256 8723ef5973a47e7b2c439002c28590d74689e871d36f03089965503c0c0d50b2 SHA512 f44c0498876462d78e57d19816eab666e90470badc2bbd38fed9f504e8b21c3e68e4d0f63a8676fa8716be60481befb3db44098228fd71b480972af2b5dcf1e3 WHIRLPOOL 5bb2648637a46e3547edeba2ad46eb131b2ae194f5efe52a688157cfa3f361f51a832554a94bcd47074e65cbf8d1e1119d23548bdf83ca62c131400c40aff34a +DIST lxc-2.0.7.tar.gz 792557 SHA256 e74ee4a61a8ff426051ce86664f85b028052dd5664cc8e4cf710205c75ded356 SHA512 eb48dc800ce43d2f4d46e0cecc4d0a714b3e22c6a4975776b54d17d1d20d5a1411e6b605215282f1f77286ddf22b61c80b86b83752191fc18023894ef7a1c44d WHIRLPOOL 81da3116450a7c41c7aa4de95e0094a56e6dee29ef2a111bfe87a61d9b7b97846f77984ec4b9b45aaf776a2c8103b5957c129f6d05b9ebf46455450129653502 +DIST lxc-2.0.8.tar.gz 1308705 SHA256 0d8e34b302cfe4c40c6c9ae5097096aa5cc2c1dfceea3f0f22e3e16c4a4e8494 SHA512 ed9fd47e92007f433695cffea659180866a5ac2778712f4eb13b6629bb18292589f5b674b734853ca196ba1f6d38bdbf3cc8a2bb28e25d3540b06b945fcf9096 WHIRLPOOL 10485c76f43c6358fc09a7843f13d16b178b1fbc1c3741d04293e170716bd253d1f7b4c3d6529829d135b381debf857263aea6070f2157d3c095d49209b7113e +EBUILD lxc-1.0.8.ebuild 5932 SHA256 ff8c10cc5fc29b800d29152a64fe8f563aa2d7c5ce2ac85b885b300cea20a06a SHA512 6af1e114ecc64264eafb85e77fba744e4b8dfdf19c8d2b769959d642df237e29813f71bcf370ea75685cb728592c6b9f9a9637d0b4b00f13d40ee8c110045619 WHIRLPOOL 9b495520cd262aff22912ae1404b6a4ec7001191774a4221a29a40f9989616f5da68618f95888e5e31102fcc591d0439fa47d8eca47c6b802383946b7953b625 +EBUILD lxc-2.0.3-r1.ebuild 6246 SHA256 4c2de89b614ad04defc97c02d40386bf6481905a29dba67b819d2ceba08fc23a SHA512 8886a1d54e42367ed32aecd4e151dd46edea205a4ff6734dcfddc7d4029bba0ae22978aeded5e76e22f709660b45c15fedf7b498536b8c9e090ee0359f860eaf WHIRLPOOL 3ab5c05d378c338b53bd1a5a52639196cf7ea1c89abbd67f0a50feb1a7853dfc28247a762a005423bce4088f2cef4797da93e4934068b25c07b53ee3e18e4583 +EBUILD lxc-2.0.4.ebuild 6309 SHA256 9d9bd96381602b2ec6a6fc13d94e0fb76976fa57b22b7979aeb1f3b69c01339f SHA512 c4ebc644ac33bd976308b191f6fbad170872056879071562bae1e80e8082f0882e942d2757207aafce1ebdb1c7d8d8cee3f45339b5be6d205421541fef9594de WHIRLPOOL 2e6ace147e77c1f582b7ca7d6d5fa1985f004a4b0d2708b931b616e2ab9f0b40e8700a8170695e9f4e4a9804b1f79d7d69a3a23d2e1f1f93584a7665c31b5c0d +EBUILD lxc-2.0.5.ebuild 6309 SHA256 9d9bd96381602b2ec6a6fc13d94e0fb76976fa57b22b7979aeb1f3b69c01339f SHA512 c4ebc644ac33bd976308b191f6fbad170872056879071562bae1e80e8082f0882e942d2757207aafce1ebdb1c7d8d8cee3f45339b5be6d205421541fef9594de WHIRLPOOL 2e6ace147e77c1f582b7ca7d6d5fa1985f004a4b0d2708b931b616e2ab9f0b40e8700a8170695e9f4e4a9804b1f79d7d69a3a23d2e1f1f93584a7665c31b5c0d +EBUILD lxc-2.0.6-r1.ebuild 6362 SHA256 c6214bb9886d05bed8cdc6b51f297250953041037c51b95bd35bab27e0ee4d23 SHA512 57ed76595bfe00f8a924793832ea5b8ab4c08b68d978b91343cb43f0299b06a10baa0e65766b37a4a9dcb432cfc6cd1da93d8abd526967ccc5cf40693f748cf8 WHIRLPOOL b17dc35ab7af1e82bfc0cd44bd6bce79fe2a3ea1a550f966ad33c1f727bda20f3d410c7ccd9ab810e67440c64a67296c6f9d9ea8e3592d23a9b5e5e12345eb83 +EBUILD lxc-2.0.7.ebuild 6343 SHA256 a86fe2f27af090ff94537efc0dde8d73b867f9fb377d0d446d3fb46dda3b77f5 SHA512 91312a9209a731026aa53f3d7bb73a0dc8f90f9fc37680cf56439067bd63aa3f35c60d2d320d5fae3d8469ea1a3fcd8e83ee5093ea4252643fd82e776ea5d58f WHIRLPOOL 0085faa8d54e65338c149530f5060320f17c53e7b778f051df43210992d8df2f9a3618cca72045591c22211569886a59775084c656aa52e726a2f1ab85e92148 +EBUILD lxc-2.0.8.ebuild 6351 SHA256 74a9ccedef00b13e078063edcb73538d4219b95494c3c22e059e3a3b1f970635 SHA512 a210cbfc88c8010977a03dfe64d29d7e9193eccd2bffb463698df9d18b8fe994d705704074be0fe9204fabeb134c6fe6407de9e89c7e8ff4ef702aadf9273fb9 WHIRLPOOL 43d19ca00c789ccb8cdb73ac3c54d1f9509a2dcce529587a6cff9fc2645972747a0c3bff5f2074d8baf934eaa913a7a640f95003635075973f0337b4e5d6e32e +MISC ChangeLog 8797 SHA256 5711cccd5a871d9fa0df3728422d0bf02db636520f586ad9a332227a429e7b21 SHA512 08ea3917b8b910af4ccbd4986a4147302138bb23a3eee8a0d130ddfbe9ecd3c4044daba508ab4b53542e46ce33dca88328fc7a4652517a258286a2d286dee8ad WHIRLPOOL 5b85b0e1447cea8d93d8c38196624798b7f760803634c546a6e343bcc4804ff6da4cb2152cd584a37487806b2ddb0d9d790229ae2ff1b8754acd48d3ce645290 +MISC ChangeLog-2015 16297 SHA256 14a9b5072facfe49b0c62131adff2be1185bacb7a44a0511fe447e22ac7aeb32 SHA512 d71746fdc367f4e5833ccde0cf1bcc047db4cb0582a00fac51f5b97c3fc1a160e3add6409185f9197faaa58b94f82f8532e7291344e8cc66a6ff49d48aa719c5 WHIRLPOOL fb28525b3c00a96e7f34beb01b28a486e5071041275f332ab0971ec6ae78159ad3361e3280c9d76b66d0ab6ea2aada06eb1d3530f5fb5ade8f80b073a4ce2416 +MISC metadata.xml 811 SHA256 5bd0e8948d73e86844f03feaf3cf8276c0fc101355b29b86db03c2674ce06340 SHA512 fea5f647ca7eb616307378375af86051034e03170f6ce62e2219f78343797072902102515f93cc0f809558fbfbca88eb81e9f8d0fa621ae18381d39a12c31aa2 WHIRLPOOL 732d83aba86a12ed0ba0d3691cef7d56dd83382b7cdfed73935d65c47667323befb5ebb8e9e3f8bbec0f7dc8730125aad28fb7e000deeacd701b5f8a0ccef25d diff --git a/app-emulation/lxc/files/lxc-1.0.8-bash-completion.patch b/app-emulation/lxc/files/lxc-1.0.8-bash-completion.patch new file mode 100644 index 000000000000..e9e0e6c98dfd --- /dev/null +++ b/app-emulation/lxc/files/lxc-1.0.8-bash-completion.patch @@ -0,0 +1,35 @@ +Index: lxc-lxc-1.0.8/config/bash/Makefile.am +=================================================================== +--- lxc-lxc-1.0.8.orig/config/bash/Makefile.am ++++ lxc-lxc-1.0.8/config/bash/Makefile.am +@@ -2,12 +2,12 @@ EXTRA_DIST = lxc + + if ENABLE_BASH + install-bash: +- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/bash_completion.d/ +- $(INSTALL_DATA) lxc $(DESTDIR)$(sysconfdir)/bash_completion.d/ ++ $(MKDIR_P) $(DESTDIR)$(datarootdir)/bash-completion/completions/ ++ $(INSTALL_DATA) lxc $(DESTDIR)$(datarootdir)/bash-completion/completions/ + + uninstall-bash: +- rm -f $(DESTDIR)$(sysconfdir)/bash_completion.d/lxc +- rmdir $(DESTDIR)$(sysconfdir)/bash_completion.d/ || : ++ rm -f $(DESTDIR)$(datarootdir)/bash-completion/completions/lxc ++ rmdir $(DESTDIR)$(datarootdir)/bash-completion// || : + + install-data-local: install-bash + uninstall-local: uninstall-bash +Index: lxc-lxc-1.0.8/config/bash/lxc.in +=================================================================== +--- lxc-lxc-1.0.8.orig/config/bash/lxc.in ++++ lxc-lxc-1.0.8/config/bash/lxc.in +@@ -1,4 +1,3 @@ +-have lxc-start && { + _lxc_names() { + COMPREPLY=( $( compgen -W "$( lxc-ls )" "$cur" ) ) + } +@@ -100,4 +99,3 @@ have lxc-start && { + + complete -o default -F _lxc_generic_o lxc-clone + complete -o default -F _lxc_generic_o lxc-start-ephemeral +-} diff --git a/app-emulation/lxc/files/lxc-2.0.3-bash-completion.patch b/app-emulation/lxc/files/lxc-2.0.3-bash-completion.patch new file mode 100644 index 000000000000..9ef6013e5b6f --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.3-bash-completion.patch @@ -0,0 +1,31 @@ +--- lxc-lxc-2.0.1/config/bash/Makefile.am.orig 2016-05-18 20:40:42.238487678 +0000 ++++ lxc-lxc-2.0.1/config/bash/Makefile.am 2016-05-18 20:43:02.163497779 +0000 +@@ -2,12 +2,12 @@ + + if ENABLE_BASH + install-bash: +- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/bash_completion.d/ +- $(INSTALL_DATA) lxc $(DESTDIR)$(sysconfdir)/bash_completion.d/ ++ $(MKDIR_P) $(DESTDIR)$(datarootdir)/bash-completion/completions/ ++ $(INSTALL_DATA) lxc $(DESTDIR)$(datarootdir)/bash-completion/completions/ + + uninstall-bash: +- rm -f $(DESTDIR)$(sysconfdir)/bash_completion.d/lxc +- rmdir $(DESTDIR)$(sysconfdir)/bash_completion.d/ || : ++ rm -f $(DESTDIR)$(datarootdir)/bash-completion/completions/lxc ++ rmdir $(DESTDIR)$(datarootdir)/bash-completion/completions/ || : + + install-data-local: install-bash + uninstall-local: uninstall-bash +--- lxc-lxc-2.0.1/config/bash/lxc.in.orig 2016-05-18 20:40:51.079488316 +0000 ++++ lxc-lxc-2.0.1/config/bash/lxc.in 2016-05-18 20:45:03.506506538 +0000 +@@ -1,4 +1,3 @@ +-_have lxc-start && { + _lxc_names() { + COMPREPLY=( $( compgen -W "$( lxc-ls )" "$cur" ) ) + } +@@ -100,4 +99,3 @@ + + complete -o default -F _lxc_generic_o lxc-copy + complete -o default -F _lxc_generic_o lxc-start-ephemeral +-} diff --git a/app-emulation/lxc/files/lxc-2.0.3-omit-sysconfig.patch b/app-emulation/lxc/files/lxc-2.0.3-omit-sysconfig.patch new file mode 100644 index 000000000000..9b83a3b2687c --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.3-omit-sysconfig.patch @@ -0,0 +1,5 @@ +--- lxc-lxc-2.0.1/config/Makefile.am.orig 2016-05-19 02:56:11.891113982 +0000 ++++ lxc-lxc-2.0.1/config/Makefile.am 2016-05-19 02:56:32.596115476 +0000 +@@ -1 +1 @@ +-SUBDIRS = apparmor bash etc init selinux templates yum sysconfig ++SUBDIRS = apparmor bash etc init selinux templates yum diff --git a/app-emulation/lxc/files/lxc-2.0.4-bash-completion.patch b/app-emulation/lxc/files/lxc-2.0.4-bash-completion.patch new file mode 100644 index 000000000000..6feb4c2bb01c --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.4-bash-completion.patch @@ -0,0 +1,31 @@ +--- /config/bash/Makefile.am.orig 2016-05-18 20:40:42.238487678 +0000 ++++ /config/bash/Makefile.am 2016-05-18 20:43:02.163497779 +0000 +@@ -2,12 +2,12 @@ + + if ENABLE_BASH + install-bash: +- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/bash_completion.d/ +- $(INSTALL_DATA) lxc $(DESTDIR)$(sysconfdir)/bash_completion.d/ ++ $(MKDIR_P) $(DESTDIR)$(datarootdir)/bash-completion/completions/ ++ $(INSTALL_DATA) lxc $(DESTDIR)$(datarootdir)/bash-completion/completions/ + + uninstall-bash: +- rm -f $(DESTDIR)$(sysconfdir)/bash_completion.d/lxc +- rmdir $(DESTDIR)$(sysconfdir)/bash_completion.d/ || : ++ rm -f $(DESTDIR)$(datarootdir)/bash-completion/completions/lxc ++ rmdir $(DESTDIR)$(datarootdir)/bash-completion/completions/ || : + + install-data-local: install-bash + uninstall-local: uninstall-bash +--- /config/bash/lxc.in.orig 2016-05-18 20:40:51.079488316 +0000 ++++ /config/bash/lxc.in 2016-05-18 20:45:03.506506538 +0000 +@@ -1,4 +1,3 @@ +-_have lxc-start && { + _lxc_names() { + COMPREPLY=( $( compgen -W "$( lxc-ls )" "$cur" ) ) + } +@@ -100,4 +99,3 @@ + + complete -o default -F _lxc_generic_o lxc-copy + complete -o default -F _lxc_generic_o lxc-start-ephemeral +-} diff --git a/app-emulation/lxc/files/lxc-2.0.4-omit-sysconfig.patch b/app-emulation/lxc/files/lxc-2.0.4-omit-sysconfig.patch new file mode 100644 index 000000000000..3ec81356499e --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.4-omit-sysconfig.patch @@ -0,0 +1,5 @@ +--- /config/Makefile.am.orig 2016-05-19 02:56:11.891113982 +0000 ++++ /config/Makefile.am 2016-05-19 02:56:32.596115476 +0000 +@@ -1 +1 @@ +-SUBDIRS = apparmor bash etc init selinux templates yum sysconfig ++SUBDIRS = apparmor bash etc init selinux templates yum diff --git a/app-emulation/lxc/files/lxc-2.0.5-bash-completion.patch b/app-emulation/lxc/files/lxc-2.0.5-bash-completion.patch new file mode 100644 index 000000000000..6feb4c2bb01c --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.5-bash-completion.patch @@ -0,0 +1,31 @@ +--- /config/bash/Makefile.am.orig 2016-05-18 20:40:42.238487678 +0000 ++++ /config/bash/Makefile.am 2016-05-18 20:43:02.163497779 +0000 +@@ -2,12 +2,12 @@ + + if ENABLE_BASH + install-bash: +- $(MKDIR_P) $(DESTDIR)$(sysconfdir)/bash_completion.d/ +- $(INSTALL_DATA) lxc $(DESTDIR)$(sysconfdir)/bash_completion.d/ ++ $(MKDIR_P) $(DESTDIR)$(datarootdir)/bash-completion/completions/ ++ $(INSTALL_DATA) lxc $(DESTDIR)$(datarootdir)/bash-completion/completions/ + + uninstall-bash: +- rm -f $(DESTDIR)$(sysconfdir)/bash_completion.d/lxc +- rmdir $(DESTDIR)$(sysconfdir)/bash_completion.d/ || : ++ rm -f $(DESTDIR)$(datarootdir)/bash-completion/completions/lxc ++ rmdir $(DESTDIR)$(datarootdir)/bash-completion/completions/ || : + + install-data-local: install-bash + uninstall-local: uninstall-bash +--- /config/bash/lxc.in.orig 2016-05-18 20:40:51.079488316 +0000 ++++ /config/bash/lxc.in 2016-05-18 20:45:03.506506538 +0000 +@@ -1,4 +1,3 @@ +-_have lxc-start && { + _lxc_names() { + COMPREPLY=( $( compgen -W "$( lxc-ls )" "$cur" ) ) + } +@@ -100,4 +99,3 @@ + + complete -o default -F _lxc_generic_o lxc-copy + complete -o default -F _lxc_generic_o lxc-start-ephemeral +-} diff --git a/app-emulation/lxc/files/lxc-2.0.5-omit-sysconfig.patch b/app-emulation/lxc/files/lxc-2.0.5-omit-sysconfig.patch new file mode 100644 index 000000000000..3ec81356499e --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.5-omit-sysconfig.patch @@ -0,0 +1,5 @@ +--- /config/Makefile.am.orig 2016-05-19 02:56:11.891113982 +0000 ++++ /config/Makefile.am 2016-05-19 02:56:32.596115476 +0000 +@@ -1 +1 @@ +-SUBDIRS = apparmor bash etc init selinux templates yum sysconfig ++SUBDIRS = apparmor bash etc init selinux templates yum diff --git a/app-emulation/lxc/files/lxc-2.0.6-bash-completion.patch b/app-emulation/lxc/files/lxc-2.0.6-bash-completion.patch new file mode 100644 index 000000000000..6033e36c7985 --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.6-bash-completion.patch @@ -0,0 +1,27 @@ +diff --git a/config/bash/lxc.in b/config/bash/lxc.in +index 7dcf302..5927fe2 100644 +--- a/config/bash/lxc.in ++++ b/config/bash/lxc.in +@@ -1,4 +1,3 @@ +-_have lxc-start && { + _lxc_names() { + COMPREPLY=( $( compgen -W "$( lxc-ls )" "$cur" ) ) + } +@@ -100,4 +99,3 @@ _have lxc-start && { + + complete -o default -F _lxc_generic_o lxc-copy + complete -o default -F _lxc_generic_o lxc-start-ephemeral +-} +diff --git a/configure.ac b/configure.ac +index 4640c0d..14ccdd3 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -478,7 +478,7 @@ AM_CONDITIONAL([ENABLE_BASH], [test "x$enable_bash" = "xyes"]) + AM_COND_IF([ENABLE_BASH], + [AC_MSG_CHECKING([bash completion directory]) + PKG_CHECK_VAR(bashcompdir, [bash-completion], [completionsdir], , +- bashcompdir="${sysconfdir}/bash_completion.d") ++ bashcompdir="$datadir/bash-completion/completions") + AC_MSG_RESULT([$bashcompdir]) + AC_SUBST(bashcompdir) + ]) diff --git a/app-emulation/lxc/files/lxc-2.0.6-major.patch b/app-emulation/lxc/files/lxc-2.0.6-major.patch new file mode 100644 index 000000000000..beb379a53882 --- /dev/null +++ b/app-emulation/lxc/files/lxc-2.0.6-major.patch @@ -0,0 +1,74 @@ +Adapt to future removal of major()/minor()/makedev() from <sys/types.h> + +Gentoo removed it in glibc-2.24. + +https://bugs.gentoo.org/575232 +https://bugs.gentoo.org/604360 +diff --git a/configure.ac b/configure.ac +index 4640c0d..71e6450 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -620,4 +620,7 @@ AC_CHECK_DECLS([PR_CAPBSET_DROP], [], [], [#include <sys/prctl.h>]) + AC_CHECK_HEADERS([sys/signalfd.h pty.h ifaddrs.h sys/capability.h sys/personality.h utmpx.h sys/timerfd.h]) + ++# lookup major()/minor()/makedev() ++AC_HEADER_MAJOR ++ + # Check for some syscalls functions + AC_CHECK_FUNCS([setns pivot_root sethostname unshare rand_r confstr faccessat]) +diff --git a/src/lxc/bdev/lxclvm.c b/src/lxc/bdev/lxclvm.c +index 3d41b10..419d1c2 100644 +--- a/src/lxc/bdev/lxclvm.c ++++ b/src/lxc/bdev/lxclvm.c +@@ -33,8 +33,17 @@ + + #include "bdev.h" ++#include "config.h" + #include "log.h" + #include "lxclvm.h" + #include "utils.h" + ++/* major()/minor() */ ++#ifdef MAJOR_IN_MKDEV ++# include <sys/mkdev.h> ++#endif ++#ifdef MAJOR_IN_SYSMACROS ++# include <sys/sysmacros.h> ++#endif ++ + lxc_log_define(lxclvm, lxc); + +diff --git a/src/lxc/conf.c b/src/lxc/conf.c +index c54ee41..9a00e7f 100644 +--- a/src/lxc/conf.c ++++ b/src/lxc/conf.c +@@ -40,4 +40,12 @@ + #include <time.h> + ++/* makedev() */ ++#ifdef MAJOR_IN_MKDEV ++# include <sys/mkdev.h> ++#endif ++#ifdef MAJOR_IN_SYSMACROS ++# include <sys/sysmacros.h> ++#endif ++ + #ifdef HAVE_STATVFS + #include <sys/statvfs.h> +diff --git a/src/lxc/lxccontainer.c b/src/lxc/lxccontainer.c +index 3a9e1e3..fe75fcc 100644 +--- a/src/lxc/lxccontainer.c ++++ b/src/lxc/lxccontainer.c +@@ -62,4 +62,12 @@ + #include "version.h" + ++/* major()/minor() */ ++#ifdef MAJOR_IN_MKDEV ++# include <sys/mkdev.h> ++#endif ++#ifdef MAJOR_IN_SYSMACROS ++# include <sys/sysmacros.h> ++#endif ++ + #if HAVE_IFADDRS_H + #include <ifaddrs.h> diff --git a/app-emulation/lxc/files/lxc.initd.3 b/app-emulation/lxc/files/lxc.initd.3 new file mode 100644 index 000000000000..7725f5710179 --- /dev/null +++ b/app-emulation/lxc/files/lxc.initd.3 @@ -0,0 +1,117 @@ +#!/sbin/openrc-run +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +CONTAINER=${SVCNAME#*.} + +LXC_PATH=`lxc-config lxc.lxcpath` + +lxc_get_configfile() { + if [ -f "${LXC_PATH}/${CONTAINER}.conf" ]; then + echo "${LXC_PATH}/${CONTAINER}.conf" + elif [ -f "${LXC_PATH}/${CONTAINER}/config" ]; then + echo "${LXC_PATH}/${CONTAINER}/config" + else + eerror "Unable to find a suitable configuration file." + eerror "If you set up the container in a non-standard" + eerror "location, please set the CONFIGFILE variable." + return 1 + fi +} + +[ $CONTAINER != $SVCNAME ] && CONFIGFILE=${CONFIGFILE:-$(lxc_get_configfile)} + +lxc_get_var() { + awk 'BEGIN { FS="[ \t]*=[ \t]*" } $1 == "'$1'" { print $2; exit }' ${CONFIGFILE} +} + +lxc_get_net_link_type() { + awk 'BEGIN { FS="[ \t]*=[ \t]*"; _link=""; _type="" } + $1 == "lxc.network.type" {_type=$2;} + $1 == "lxc.network.link" {_link=$2;} + {if(_link != "" && _type != ""){ + printf("%s:%s\n", _link, _type ); + _link=""; _type=""; + }; }' <${CONFIGFILE} +} + +checkconfig() { + if [ ${CONTAINER} = ${SVCNAME} ]; then + eerror "You have to create an init script for each container:" + eerror " ln -s lxc /etc/init.d/lxc.container" + return 1 + fi + + # no need to output anything, the function takes care of that. + [ -z "${CONFIGFILE}" ] && return 1 + + utsname=$(lxc_get_var lxc.utsname) + if [ ${CONTAINER} != ${utsname} ]; then + eerror "You should use the same name for the service and the" + eerror "container. Right now the container is called ${utsname}" + return 1 + fi +} + +depend() { + # be quiet, since we have to run depend() also for the + # non-muxed init script, unfortunately. + checkconfig 2>/dev/null || return 0 + + config ${CONFIGFILE} + need localmount + + local _x _if + for _x in $(lxc_get_net_link_type); do + _if=${_x%:*} + case "${_x##*:}" in + # when the network type is set to phys, we can make use of a + # network service (for instance to set it up before we disable + # the net_admin capability), but we might also not set it up + # at all on the host and leave the net_admin capable service + # to take care of it. + phys) use net.${_if} ;; + *) need net.${_if} ;; + esac + done +} + +start() { + checkconfig || return 1 + rm -f /var/log/lxc/${CONTAINER}.log + + rootpath=$(lxc_get_var lxc.rootfs) + + # Check the format of our init and the chroot's init, to see + # if we have to use linux32 or linux64; always use setarch + # when required, as that makes it easier to deal with + # x32-based containers. + case $(scanelf -BF '%a#f' ${rootpath}/sbin/init) in + EM_X86_64) setarch=linux64;; + EM_386) setarch=linux32;; + esac + + ebegin "Starting ${CONTAINER}" + env -i ${setarch} $(type -p lxc-start) -l WARN -n ${CONTAINER} -f ${CONFIGFILE} -d -o /var/log/lxc/${CONTAINER}.log + sleep 0.5 + + # lxc-start -d will _always_ report a correct startup, even if it + # failed, so rather than trust that, check that the cgroup exists. + [ -d /sys/fs/cgroup/cpuset/lxc/${CONTAINER} ] + eend $? +} + +stop() { + checkconfig || return 1 + + + if ! [ -d /sys/fs/cgroup/cpuset/lxc/${CONTAINER} ]; then + ewarn "${CONTAINER} doesn't seem to be started." + return 0 + fi + + # 10s should be enough to shut everything down + ebegin "Stopping ${CONTAINER}" + lxc-stop -t 10 -n ${CONTAINER} + eend $? +} diff --git a/app-emulation/lxc/files/lxc.initd.5 b/app-emulation/lxc/files/lxc.initd.5 new file mode 100644 index 000000000000..b28d0bfa7aad --- /dev/null +++ b/app-emulation/lxc/files/lxc.initd.5 @@ -0,0 +1,118 @@ +#!/sbin/openrc-run +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +CONTAINER=${SVCNAME#*.} + +LXC_PATH=`lxc-config lxc.lxcpath` + +lxc_get_configfile() { + if [ -f "${LXC_PATH}/${CONTAINER}.conf" ]; then + echo "${LXC_PATH}/${CONTAINER}.conf" + elif [ -f "${LXC_PATH}/${CONTAINER}/config" ]; then + echo "${LXC_PATH}/${CONTAINER}/config" + else + eerror "Unable to find a suitable configuration file." + eerror "If you set up the container in a non-standard" + eerror "location, please set the CONFIGFILE variable." + return 1 + fi +} + +[ $CONTAINER != $SVCNAME ] && CONFIGFILE=${CONFIGFILE:-$(lxc_get_configfile)} + +lxc_get_var() { + awk 'BEGIN { FS="[ \t]*=[ \t]*" } $1 == "'$1'" { print $2; exit }' ${CONFIGFILE} +} + +lxc_get_net_link_type() { + awk 'BEGIN { FS="[ \t]*=[ \t]*"; _link=""; _type="" } + $1 == "lxc.network.type" {_type=$2;} + $1 == "lxc.network.link" {_link=$2;} + {if(_link != "" && _type != ""){ + printf("%s:%s\n", _link, _type ); + _link=""; _type=""; + }; }' <${CONFIGFILE} +} + +checkconfig() { + if [ ${CONTAINER} = ${SVCNAME} ]; then + eerror "You have to create an init script for each container:" + eerror " ln -s lxc /etc/init.d/lxc.container" + return 1 + fi + + # no need to output anything, the function takes care of that. + [ -z "${CONFIGFILE}" ] && return 1 + + utsname=$(lxc_get_var lxc.utsname) + if [ ${CONTAINER} != ${utsname} ]; then + eerror "You should use the same name for the service and the" + eerror "container. Right now the container is called ${utsname}" + return 1 + fi +} + +depend() { + # be quiet, since we have to run depend() also for the + # non-muxed init script, unfortunately. + checkconfig 2>/dev/null || return 0 + + config ${CONFIGFILE} + need localmount + use lxcfs + + local _x _if + for _x in $(lxc_get_net_link_type); do + _if=${_x%:*} + case "${_x##*:}" in + # when the network type is set to phys, we can make use of a + # network service (for instance to set it up before we disable + # the net_admin capability), but we might also not set it up + # at all on the host and leave the net_admin capable service + # to take care of it. + phys) use net.${_if} ;; + *) need net.${_if} ;; + esac + done +} + +start() { + checkconfig || return 1 + rm -f /var/log/lxc/${CONTAINER}.log + + rootpath=$(lxc_get_var lxc.rootfs) + + # Check the format of our init and the chroot's init, to see + # if we have to use linux32 or linux64; always use setarch + # when required, as that makes it easier to deal with + # x32-based containers. + case $(scanelf -BF '%a#f' ${rootpath}/sbin/init) in + EM_X86_64) setarch=linux64;; + EM_386) setarch=linux32;; + esac + + ebegin "Starting ${CONTAINER}" + env -i ${setarch} $(which lxc-start) -l WARN -n ${CONTAINER} -f ${CONFIGFILE} -d -o /var/log/lxc/${CONTAINER}.log + sleep 0.5 + + # lxc-start -d will _always_ report a correct startup, even if it + # failed, so rather than trust that, check that the cgroup exists. + [ -d /sys/fs/cgroup/cpuset/lxc/${CONTAINER} ] + eend $? +} + +stop() { + checkconfig || return 1 + + + if ! [ -d /sys/fs/cgroup/cpuset/lxc/${CONTAINER} ]; then + ewarn "${CONTAINER} doesn't seem to be started." + return 0 + fi + + # 10s should be enough to shut everything down + ebegin "Stopping ${CONTAINER}" + lxc-stop -t 10 -n ${CONTAINER} + eend $? +} diff --git a/app-emulation/lxc/files/lxc.initd.6 b/app-emulation/lxc/files/lxc.initd.6 new file mode 100644 index 000000000000..a66dfdd22b41 --- /dev/null +++ b/app-emulation/lxc/files/lxc.initd.6 @@ -0,0 +1,118 @@ +#!/sbin/openrc-run +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +CONTAINER=${SVCNAME#*.} + +LXC_PATH=`lxc-config lxc.lxcpath` + +lxc_get_configfile() { + if [ -f "${LXC_PATH}/${CONTAINER}.conf" ]; then + echo "${LXC_PATH}/${CONTAINER}.conf" + elif [ -f "${LXC_PATH}/${CONTAINER}/config" ]; then + echo "${LXC_PATH}/${CONTAINER}/config" + else + eerror "Unable to find a suitable configuration file." + eerror "If you set up the container in a non-standard" + eerror "location, please set the CONFIGFILE variable." + return 1 + fi +} + +[ $CONTAINER != $SVCNAME ] && CONFIGFILE=${CONFIGFILE:-$(lxc_get_configfile)} + +lxc_get_var() { + awk 'BEGIN { FS="[ \t]*=[ \t]*" } $1 == "'$1'" { print $2; exit }' ${CONFIGFILE} +} + +lxc_get_net_link_type() { + awk 'BEGIN { FS="[ \t]*=[ \t]*"; _link=""; _type="" } + $1 == "lxc.network.type" {_type=$2;} + $1 == "lxc.network.link" {_link=$2;} + {if(_link != "" && _type != ""){ + printf("%s:%s\n", _link, _type ); + _link=""; _type=""; + }; }' <${CONFIGFILE} +} + +checkconfig() { + if [ ${CONTAINER} = ${SVCNAME} ]; then + eerror "You have to create an init script for each container:" + eerror " ln -s lxc /etc/init.d/lxc.container" + return 1 + fi + + # no need to output anything, the function takes care of that. + [ -z "${CONFIGFILE}" ] && return 1 + + utsname=$(lxc_get_var lxc.utsname) + if [ ${CONTAINER} != ${utsname} ]; then + eerror "You should use the same name for the service and the" + eerror "container. Right now the container is called ${utsname}" + return 1 + fi +} + +depend() { + # be quiet, since we have to run depend() also for the + # non-muxed init script, unfortunately. + checkconfig 2>/dev/null || return 0 + + config ${CONFIGFILE} + need localmount + use lxcfs + + local _x _if + for _x in $(lxc_get_net_link_type); do + _if=${_x%:*} + case "${_x##*:}" in + # when the network type is set to phys, we can make use of a + # network service (for instance to set it up before we disable + # the net_admin capability), but we might also not set it up + # at all on the host and leave the net_admin capable service + # to take care of it. + phys) use net.${_if} ;; + *) need net.${_if} ;; + esac + done +} + +start() { + checkconfig || return 1 + rm -f /var/log/lxc/${CONTAINER}.log + + rootpath=$(lxc_get_var lxc.rootfs) + + # Check the format of our init and the chroot's init, to see + # if we have to use linux32 or linux64; always use setarch + # when required, as that makes it easier to deal with + # x32-based containers. + case $(scanelf -BF '%a#f' ${rootpath}/sbin/init) in + EM_X86_64) setarch=linux64;; + EM_386) setarch=linux32;; + esac + + ebegin "Starting ${CONTAINER}" + env -i ${setarch} $(which lxc-start) -l WARN -n ${CONTAINER} -f ${CONFIGFILE} -d -o /var/log/lxc/${CONTAINER}.log + sleep 1 + + # lxc-start -d will _always_ report a correct startup, even if it + # failed, so rather than trust that, check that the cgroup exists. + [ -d /sys/fs/cgroup/cpuset/lxc/${CONTAINER} ] + eend $? +} + +stop() { + checkconfig || return 1 + + + if ! [ -d /sys/fs/cgroup/cpuset/lxc/${CONTAINER} ]; then + ewarn "${CONTAINER} doesn't seem to be started." + return 0 + fi + + # 10s should be enough to shut everything down + ebegin "Stopping ${CONTAINER}" + lxc-stop -t 10 -n ${CONTAINER} + eend $? +} diff --git a/app-emulation/lxc/files/lxc_at.service b/app-emulation/lxc/files/lxc_at.service new file mode 100644 index 000000000000..1ef449775306 --- /dev/null +++ b/app-emulation/lxc/files/lxc_at.service @@ -0,0 +1,12 @@ +[Unit] +Description=Linux Container %I +After=network.target + +[Service] +Restart=always +ExecStart=/usr/sbin/lxc-start -n %i +ExecReload=/usr/sbin/lxc-restart -n %i +ExecStop=/usr/sbin/lxc-stop -n %i + +[Install] +WantedBy=multi-user.target diff --git a/app-emulation/lxc/files/lxc_at.service.4 b/app-emulation/lxc/files/lxc_at.service.4 new file mode 100644 index 000000000000..64ae7457096c --- /dev/null +++ b/app-emulation/lxc/files/lxc_at.service.4 @@ -0,0 +1,14 @@ +[Unit] +Description=Linux Container %I +After=network.target +Wants=lxcfs.service + +[Service] +Restart=always +ExecStart=/usr/bin/lxc-start -n %i -F +ExecReload=/usr/bin/lxc-restart -n %i +ExecStop=/usr/bin/lxc-stop -n %i +Delegate=yes + +[Install] +WantedBy=multi-user.target diff --git a/app-emulation/lxc/lxc-1.0.8.ebuild b/app-emulation/lxc/lxc-1.0.8.ebuild new file mode 100644 index 000000000000..1c55e5916100 --- /dev/null +++ b/app-emulation/lxc/lxc-1.0.8.ebuild @@ -0,0 +1,188 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +MY_P="${P/_/-}" +PYTHON_COMPAT=( python3_4 ) +DISTUTILS_OPTIONAL=1 + +inherit autotools bash-completion-r1 distutils-r1 eutils linux-info versionator flag-o-matic systemd + +DESCRIPTION="LinuX Containers userspace utilities" +HOMEPAGE="https://linuxcontainers.org/" +SRC_URI="https://github.com/lxc/lxc/archive/${MY_P}.tar.gz" + +KEYWORDS="amd64 ~arm ~arm64 ppc64 x86" + +LICENSE="LGPL-3" +SLOT="0" +IUSE="doc examples lua python seccomp" + +RDEPEND="net-libs/gnutls + sys-libs/libcap + lua? ( >=dev-lang/lua-5.1:= ) + python? ( ${PYTHON_DEPS} ) + seccomp? ( sys-libs/libseccomp )" + +DEPEND="${RDEPEND} + doc? ( app-text/docbook-sgml-utils ) + >=sys-kernel/linux-headers-3.2" + +RDEPEND="${RDEPEND} + sys-apps/util-linux + app-misc/pax-utils + virtual/awk" + +CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE + ~CPUSETS ~CGROUP_CPUACCT + ~RESOURCE_COUNTERS + ~CGROUP_SCHED + + ~NAMESPACES + ~IPC_NS ~USER_NS ~PID_NS + + ~DEVPTS_MULTIPLE_INSTANCES + ~CGROUP_FREEZER + ~UTS_NS ~NET_NS + ~VETH ~MACVLAN + + ~POSIX_MQUEUE + ~!NETPRIO_CGROUP + + ~!GRKERNSEC_CHROOT_MOUNT + ~!GRKERNSEC_CHROOT_DOUBLE + ~!GRKERNSEC_CHROOT_PIVOT + ~!GRKERNSEC_CHROOT_CHMOD + ~!GRKERNSEC_CHROOT_CAPS + ~!GRKERNSEC_PROC +" + +ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container" + +ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers" + +ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info" +ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network" + +ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking" +ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking" + +ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command" + +ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting." + +ERROR_GRKERNSEC_CHROOT_MOUNT=":CONFIG_GRKERNSEC_CHROOT_MOUNT some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_DOUBLE=":CONFIG_GRKERNSEC_CHROOT_DOUBLE some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_PIVOT=":CONFIG_GRKERNSEC_CHROOT_PIVOT some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CHMOD=":CONFIG_GRKERNSEC_CHROOT_CHMOD some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CAPS=":CONFIG_GRKERNSEC_CHROOT_CAPS some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_PROC=":CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers" + +DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt) + +S="${WORKDIR}/${PN}-${MY_P}" + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +src_prepare() { + sed -i 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/g' configure.ac || die + if [[ -n ${BACKPORTS} ]]; then + epatch "${WORKDIR}"/patches/* + fi + + epatch "${FILESDIR}"/${PN}-1.0.8-bash-completion.patch + + eautoreconf +} + +src_configure() { + append-flags -fno-strict-aliasing + + econf \ + --localstatedir=/var \ + --bindir=/usr/sbin \ + --docdir=/usr/share/doc/${PF} \ + --with-config-path=/etc/lxc \ + --with-rootfs-path=/usr/lib/lxc/rootfs \ + --with-distro=gentoo \ + $(use_enable doc) \ + --disable-apparmor \ + $(use_enable examples) \ + $(use_enable lua) \ + $(use_enable seccomp) \ + --disable-python +} + +python_compile() { + distutils-r1_python_compile build_ext -I ../ -L ../${PN} +} + +src_compile() { + default + + if use python; then + pushd "${S}/src/python-${PN}" > /dev/null + distutils-r1_src_compile + popd > /dev/null + fi +} + +src_install() { + default + + mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die + bashcomp_alias ${PN}-start \ + ${PN}-{attach,cgroup,clone,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait} + + if use python; then + pushd "${S}/src/python-lxc" > /dev/null + # Unset DOCS. This has been handled by the default target + unset DOCS + distutils-r1_src_install + popd > /dev/null + fi + + keepdir /etc/lxc /usr/lib/lxc/rootfs /var/log/lxc + + find "${D}" -name '*.la' -delete + + # Gentoo-specific additions! + # Use initd.3 per #517144 + newinitd "${FILESDIR}/${PN}.initd.3" ${PN} + + # lxc-devsetup script + exeinto /usr/libexec/${PN} + doexe config/init/systemd/${PN}-devsetup + # Use that script with the systemd service (Similar to upstream + # Makefile.am + cp "${FILESDIR}"/${PN}_at.service ${PN}_at.service || die + sed -i \ + "/Restart=always/a ExecStartPre=/usr/libexec/${PN}/${PN}-devsetup" \ + ${PN}_at.service \ + || die "Failed to add ${PN}-devsetup to the systemd service file" + systemd_newunit ${PN}_at.service "lxc@.service" +} + +pkg_postinst() { + elog "There is an init script provided with the package now; no documentation" + elog "is currently available though, so please check out /etc/init.d/lxc ." + elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname" + elog "to start the container defined into /etc/lxc/configname.conf ." + elog "For further information about LXC development see" + elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available + elog "" + ewarn "With version 0.7.4, the mountpoint syntax came back to the one used by 0.7.2" + ewarn "and previous versions. This means you'll have to use syntax like the following" + ewarn "" + ewarn " lxc.rootfs = /container" + ewarn " lxc.mount.entry = /usr/portage /container/usr/portage none bind 0 0" + ewarn "" + ewarn "To use the Fedora, Debian and (various) Ubuntu auto-configuration scripts, you" + ewarn "will need sys-apps/yum or dev-util/debootstrap." + ewarn "" + ewarn "Some GrSecurity settings in relation to chroot security will cause LXC not to" + ewarn "work, while others will actually make it much more secure. Please refer to" + ewarn "Diego Elio Pettenò's weblog at http://blog.flameeyes.eu/tag/lxc for further" + ewarn "details." +} diff --git a/app-emulation/lxc/lxc-2.0.3-r1.ebuild b/app-emulation/lxc/lxc-2.0.3-r1.ebuild new file mode 100644 index 000000000000..fbf2ce71f6d3 --- /dev/null +++ b/app-emulation/lxc/lxc-2.0.3-r1.ebuild @@ -0,0 +1,196 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="5" + +MY_P="${P/_/-}" +PYTHON_COMPAT=( python{3_4,3_5} ) +DISTUTILS_OPTIONAL=1 + +inherit autotools bash-completion-r1 distutils-r1 eutils linux-info versionator flag-o-matic systemd + +DESCRIPTION="LinuX Containers userspace utilities" +HOMEPAGE="https://linuxcontainers.org/" +SRC_URI="https://github.com/lxc/lxc/archive/${MY_P}.tar.gz" + +KEYWORDS="~amd64 ~arm ~arm64" + +LICENSE="LGPL-3" +SLOT="0" +IUSE="cgmanager doc examples lua python seccomp" + +RDEPEND="net-libs/gnutls + sys-libs/libcap + cgmanager? ( app-admin/cgmanager ) + lua? ( >=dev-lang/lua-5.1:= ) + python? ( ${PYTHON_DEPS} ) + seccomp? ( sys-libs/libseccomp )" + +DEPEND="${RDEPEND} + doc? ( app-text/docbook-sgml-utils ) + >=sys-kernel/linux-headers-3.2" + +RDEPEND="${RDEPEND} + sys-process/criu + sys-apps/util-linux + app-misc/pax-utils + virtual/awk" + +CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE + ~CPUSETS ~CGROUP_CPUACCT + ~CGROUP_SCHED + + ~NAMESPACES + ~IPC_NS ~USER_NS ~PID_NS + + ~NETLINK_DIAG ~PACKET_DIAG + ~INET_UDP_DIAG ~INET_TCP_DIAG + ~UNIX_DIAG ~CHECKPOINT_RESTORE + + ~DEVPTS_MULTIPLE_INSTANCES + ~CGROUP_FREEZER + ~UTS_NS ~NET_NS + ~VETH ~MACVLAN + + ~POSIX_MQUEUE + ~!NETPRIO_CGROUP + + ~!GRKERNSEC_CHROOT_MOUNT + ~!GRKERNSEC_CHROOT_DOUBLE + ~!GRKERNSEC_CHROOT_PIVOT + ~!GRKERNSEC_CHROOT_CHMOD + ~!GRKERNSEC_CHROOT_CAPS + ~!GRKERNSEC_PROC + ~!GRKERNSEC_SYSFS_RESTRICT +" + +ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container" + +ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers" + +ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info" +ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network" + +ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking" +ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking" + +ERROR_NETLINK_DIAG="CONFIG_NETLINK_DIAG: needed for lxc-checkpoint" +ERROR_PACKET_DIAG="CONFIG_PACKET_DIAG: needed for lxc-checkpoint" +ERROR_INET_UDP_DIAG="CONFIG_INET_UDP_DIAG: needed for lxc-checkpoint" +ERROR_INET_TCP_DIAG="CONFIG_INET_TCP_DIAG: needed for lxc-checkpoint" +ERROR_UNIX_DIAG="CONFIG_UNIX_DIAG: needed for lxc-checkpoint" +ERROR_CHECKPOINT_RESTORE="CONFIG_CHECKPOINT_RESTORE: needed for lxc-checkpoint" + +ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command" + +ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting." + +ERROR_GRKERNSEC_CHROOT_MOUNT="CONFIG_GRKERNSEC_CHROOT_MOUNT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_DOUBLE="CONFIG_GRKERNSEC_CHROOT_DOUBLE: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_PIVOT="CONFIG_GRKERNSEC_CHROOT_PIVOT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CHMOD="CONFIG_GRKERNSEC_CHROOT_CHMOD: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CAPS="CONFIG_GRKERNSEC_CHROOT_CAPS: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_PROC="CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers" +ERROR_GRKERNSEC_SYSFS_RESTRICT="CONFIG_GRKERNSEC_SYSFS_RESTRICT: this GRSEC feature is incompatible with unprivileged containers" + +DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt) + +S="${WORKDIR}/${PN}-${MY_P}" + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +src_prepare() { + epatch "${FILESDIR}"/${P}-bash-completion.patch + #558854 + epatch "${FILESDIR}"/${P}-omit-sysconfig.patch + eautoreconf +} + +src_configure() { + append-flags -fno-strict-aliasing + + if use python; then + #541932 + python_setup "python3*" + export PKG_CONFIG_PATH="${T}/${EPYTHON}/pkgconfig:${PKG_CONFIG_PATH}" + fi + + # I am not sure about the --with-rootfs-path + # /var/lib/lxc is probably more appropriate than + # /usr/lib/lxc. + econf \ + --localstatedir=/var \ + --bindir=/usr/bin \ + --sbindir=/usr/bin \ + --docdir=/usr/share/doc/${PF} \ + --with-config-path=/var/lib/lxc \ + --with-rootfs-path=/var/lib/lxc/rootfs \ + --with-distro=gentoo \ + --with-runtime-path=/run \ + --disable-apparmor \ + $(use_enable cgmanager) \ + $(use_enable doc) \ + $(use_enable examples) \ + $(use_enable lua) \ + $(use_enable python) \ + $(use_enable seccomp) +} + +python_compile() { + distutils-r1_python_compile build_ext -I ../ -L ../${PN} +} + +src_compile() { + default + + if use python; then + pushd "${S}/src/python-${PN}" > /dev/null + distutils-r1_src_compile + popd > /dev/null + fi +} + +src_install() { + default + + mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die + # start-ephemeral is no longer a command but removing it here + # generates QA warnings (still in upstream completion script) + bashcomp_alias ${PN}-start \ + ${PN}-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait} + + if use python; then + pushd "${S}/src/python-lxc" > /dev/null + # Unset DOCS. This has been handled by the default target + unset DOCS + distutils-r1_src_install + popd > /dev/null + fi + + keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc + + find "${D}" -name '*.la' -delete + + # Gentoo-specific additions! + newinitd "${FILESDIR}/${PN}.initd.5" ${PN} + + # Remember to compare our systemd unit file with the upstream one + # config/init/systemd/lxc.service.in + systemd_newunit "${FILESDIR}"/${PN}_at.service.4 "lxc@.service" +} + +pkg_postinst() { + elog "" + elog "Starting from version ${PN}-1.1.0-r3, the default lxc path has been" + elog "moved from /etc/lxc to /var/lib/lxc. If you still want to use /etc/lxc" + elog "please add the following to your /etc/lxc/default.conf" + elog "lxc.lxcpath = /etc/lxc" + elog "" + elog "There is an init script provided with the package now; no documentation" + elog "is currently available though, so please check out /etc/init.d/lxc ." + elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname" + elog "to start the container defined into /etc/lxc/configname.conf ." + elog "For further information about LXC development see" + elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available + elog "" +} diff --git a/app-emulation/lxc/lxc-2.0.4.ebuild b/app-emulation/lxc/lxc-2.0.4.ebuild new file mode 100644 index 000000000000..5cafe41f06e2 --- /dev/null +++ b/app-emulation/lxc/lxc-2.0.4.ebuild @@ -0,0 +1,200 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +MY_P="${P/_/-}" +PYTHON_COMPAT=( python{3_4,3_5} ) +DISTUTILS_OPTIONAL=1 + +inherit autotools bash-completion-r1 distutils-r1 linux-info versionator flag-o-matic systemd + +DESCRIPTION="LinuX Containers userspace utilities" +HOMEPAGE="https://linuxcontainers.org/" +SRC_URI="https://github.com/lxc/lxc/archive/${MY_P}.tar.gz" + +KEYWORDS="~amd64 ~arm ~arm64" + +LICENSE="LGPL-3" +SLOT="0" +IUSE="cgmanager doc examples lua python seccomp" + +RDEPEND="net-libs/gnutls + sys-libs/libcap + cgmanager? ( app-admin/cgmanager ) + lua? ( >=dev-lang/lua-5.1:= ) + python? ( ${PYTHON_DEPS} ) + seccomp? ( sys-libs/libseccomp )" + +DEPEND="${RDEPEND} + doc? ( app-text/docbook-sgml-utils ) + >=sys-kernel/linux-headers-3.2" + +RDEPEND="${RDEPEND} + sys-process/criu + sys-apps/util-linux + app-misc/pax-utils + virtual/awk" + +CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE + ~CPUSETS ~CGROUP_CPUACCT + ~CGROUP_SCHED + + ~NAMESPACES + ~IPC_NS ~USER_NS ~PID_NS + + ~NETLINK_DIAG ~PACKET_DIAG + ~INET_UDP_DIAG ~INET_TCP_DIAG + ~UNIX_DIAG ~CHECKPOINT_RESTORE + + ~CGROUP_FREEZER + ~UTS_NS ~NET_NS + ~VETH ~MACVLAN + + ~POSIX_MQUEUE + ~!NETPRIO_CGROUP + + ~!GRKERNSEC_CHROOT_MOUNT + ~!GRKERNSEC_CHROOT_DOUBLE + ~!GRKERNSEC_CHROOT_PIVOT + ~!GRKERNSEC_CHROOT_CHMOD + ~!GRKERNSEC_CHROOT_CAPS + ~!GRKERNSEC_PROC + ~!GRKERNSEC_SYSFS_RESTRICT +" + +ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container" + +ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers" + +ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info" +ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network" + +ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking" +ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking" + +ERROR_NETLINK_DIAG="CONFIG_NETLINK_DIAG: needed for lxc-checkpoint" +ERROR_PACKET_DIAG="CONFIG_PACKET_DIAG: needed for lxc-checkpoint" +ERROR_INET_UDP_DIAG="CONFIG_INET_UDP_DIAG: needed for lxc-checkpoint" +ERROR_INET_TCP_DIAG="CONFIG_INET_TCP_DIAG: needed for lxc-checkpoint" +ERROR_UNIX_DIAG="CONFIG_UNIX_DIAG: needed for lxc-checkpoint" +ERROR_CHECKPOINT_RESTORE="CONFIG_CHECKPOINT_RESTORE: needed for lxc-checkpoint" + +ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command" + +ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting." + +ERROR_GRKERNSEC_CHROOT_MOUNT="CONFIG_GRKERNSEC_CHROOT_MOUNT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_DOUBLE="CONFIG_GRKERNSEC_CHROOT_DOUBLE: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_PIVOT="CONFIG_GRKERNSEC_CHROOT_PIVOT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CHMOD="CONFIG_GRKERNSEC_CHROOT_CHMOD: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CAPS="CONFIG_GRKERNSEC_CHROOT_CAPS: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_PROC="CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers" +ERROR_GRKERNSEC_SYSFS_RESTRICT="CONFIG_GRKERNSEC_SYSFS_RESTRICT: this GRSEC feature is incompatible with unprivileged containers" + +DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt) + +S="${WORKDIR}/${PN}-${MY_P}" + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +pkg_setup() { + kernel_is -lt 4 7 && CONFIG_CHECK="${CONFIG_CHECK} ~DEVPTS_MULTIPLE_INSTANCES" + linux-info_pkg_setup +} + +src_prepare() { + eapply "${FILESDIR}"/${P}-bash-completion.patch + #558854 + eapply "${FILESDIR}"/${P}-omit-sysconfig.patch + eapply_user + eautoreconf +} + +src_configure() { + append-flags -fno-strict-aliasing + + if use python; then + #541932 + python_setup "python3*" + export PKG_CONFIG_PATH="${T}/${EPYTHON}/pkgconfig:${PKG_CONFIG_PATH}" + fi + + # I am not sure about the --with-rootfs-path + # /var/lib/lxc is probably more appropriate than + # /usr/lib/lxc. + econf \ + --localstatedir=/var \ + --bindir=/usr/bin \ + --sbindir=/usr/bin \ + --with-config-path=/var/lib/lxc \ + --with-rootfs-path=/var/lib/lxc/rootfs \ + --with-distro=gentoo \ + --with-runtime-path=/run \ + --disable-apparmor \ + $(use_enable cgmanager) \ + $(use_enable doc) \ + $(use_enable examples) \ + $(use_enable lua) \ + $(use_enable python) \ + $(use_enable seccomp) +} + +python_compile() { + distutils-r1_python_compile build_ext -I ../ -L ../${PN} +} + +src_compile() { + default + + if use python; then + pushd "${S}/src/python-${PN}" > /dev/null + distutils-r1_src_compile + popd > /dev/null + fi +} + +src_install() { + default + + mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die + # start-ephemeral is no longer a command but removing it here + # generates QA warnings (still in upstream completion script) + bashcomp_alias ${PN}-start \ + ${PN}-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait} + + if use python; then + pushd "${S}/src/python-lxc" > /dev/null + # Unset DOCS. This has been handled by the default target + unset DOCS + distutils-r1_src_install + popd > /dev/null + fi + + keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc + + find "${D}" -name '*.la' -delete + + # Gentoo-specific additions! + newinitd "${FILESDIR}/${PN}.initd.5" ${PN} + + # Remember to compare our systemd unit file with the upstream one + # config/init/systemd/lxc.service.in + systemd_newunit "${FILESDIR}"/${PN}_at.service.4 "lxc@.service" +} + +pkg_postinst() { + elog "" + elog "Starting from version ${PN}-1.1.0-r3, the default lxc path has been" + elog "moved from /etc/lxc to /var/lib/lxc. If you still want to use /etc/lxc" + elog "please add the following to your /etc/lxc/default.conf" + elog "lxc.lxcpath = /etc/lxc" + elog "" + elog "There is an init script provided with the package now; no documentation" + elog "is currently available though, so please check out /etc/init.d/lxc ." + elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname" + elog "to start the container defined into /etc/lxc/configname.conf ." + elog "For further information about LXC development see" + elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available + elog "" +} diff --git a/app-emulation/lxc/lxc-2.0.5.ebuild b/app-emulation/lxc/lxc-2.0.5.ebuild new file mode 100644 index 000000000000..5cafe41f06e2 --- /dev/null +++ b/app-emulation/lxc/lxc-2.0.5.ebuild @@ -0,0 +1,200 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +MY_P="${P/_/-}" +PYTHON_COMPAT=( python{3_4,3_5} ) +DISTUTILS_OPTIONAL=1 + +inherit autotools bash-completion-r1 distutils-r1 linux-info versionator flag-o-matic systemd + +DESCRIPTION="LinuX Containers userspace utilities" +HOMEPAGE="https://linuxcontainers.org/" +SRC_URI="https://github.com/lxc/lxc/archive/${MY_P}.tar.gz" + +KEYWORDS="~amd64 ~arm ~arm64" + +LICENSE="LGPL-3" +SLOT="0" +IUSE="cgmanager doc examples lua python seccomp" + +RDEPEND="net-libs/gnutls + sys-libs/libcap + cgmanager? ( app-admin/cgmanager ) + lua? ( >=dev-lang/lua-5.1:= ) + python? ( ${PYTHON_DEPS} ) + seccomp? ( sys-libs/libseccomp )" + +DEPEND="${RDEPEND} + doc? ( app-text/docbook-sgml-utils ) + >=sys-kernel/linux-headers-3.2" + +RDEPEND="${RDEPEND} + sys-process/criu + sys-apps/util-linux + app-misc/pax-utils + virtual/awk" + +CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE + ~CPUSETS ~CGROUP_CPUACCT + ~CGROUP_SCHED + + ~NAMESPACES + ~IPC_NS ~USER_NS ~PID_NS + + ~NETLINK_DIAG ~PACKET_DIAG + ~INET_UDP_DIAG ~INET_TCP_DIAG + ~UNIX_DIAG ~CHECKPOINT_RESTORE + + ~CGROUP_FREEZER + ~UTS_NS ~NET_NS + ~VETH ~MACVLAN + + ~POSIX_MQUEUE + ~!NETPRIO_CGROUP + + ~!GRKERNSEC_CHROOT_MOUNT + ~!GRKERNSEC_CHROOT_DOUBLE + ~!GRKERNSEC_CHROOT_PIVOT + ~!GRKERNSEC_CHROOT_CHMOD + ~!GRKERNSEC_CHROOT_CAPS + ~!GRKERNSEC_PROC + ~!GRKERNSEC_SYSFS_RESTRICT +" + +ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container" + +ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers" + +ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info" +ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network" + +ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking" +ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking" + +ERROR_NETLINK_DIAG="CONFIG_NETLINK_DIAG: needed for lxc-checkpoint" +ERROR_PACKET_DIAG="CONFIG_PACKET_DIAG: needed for lxc-checkpoint" +ERROR_INET_UDP_DIAG="CONFIG_INET_UDP_DIAG: needed for lxc-checkpoint" +ERROR_INET_TCP_DIAG="CONFIG_INET_TCP_DIAG: needed for lxc-checkpoint" +ERROR_UNIX_DIAG="CONFIG_UNIX_DIAG: needed for lxc-checkpoint" +ERROR_CHECKPOINT_RESTORE="CONFIG_CHECKPOINT_RESTORE: needed for lxc-checkpoint" + +ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command" + +ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting." + +ERROR_GRKERNSEC_CHROOT_MOUNT="CONFIG_GRKERNSEC_CHROOT_MOUNT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_DOUBLE="CONFIG_GRKERNSEC_CHROOT_DOUBLE: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_PIVOT="CONFIG_GRKERNSEC_CHROOT_PIVOT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CHMOD="CONFIG_GRKERNSEC_CHROOT_CHMOD: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CAPS="CONFIG_GRKERNSEC_CHROOT_CAPS: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_PROC="CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers" +ERROR_GRKERNSEC_SYSFS_RESTRICT="CONFIG_GRKERNSEC_SYSFS_RESTRICT: this GRSEC feature is incompatible with unprivileged containers" + +DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt) + +S="${WORKDIR}/${PN}-${MY_P}" + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +pkg_setup() { + kernel_is -lt 4 7 && CONFIG_CHECK="${CONFIG_CHECK} ~DEVPTS_MULTIPLE_INSTANCES" + linux-info_pkg_setup +} + +src_prepare() { + eapply "${FILESDIR}"/${P}-bash-completion.patch + #558854 + eapply "${FILESDIR}"/${P}-omit-sysconfig.patch + eapply_user + eautoreconf +} + +src_configure() { + append-flags -fno-strict-aliasing + + if use python; then + #541932 + python_setup "python3*" + export PKG_CONFIG_PATH="${T}/${EPYTHON}/pkgconfig:${PKG_CONFIG_PATH}" + fi + + # I am not sure about the --with-rootfs-path + # /var/lib/lxc is probably more appropriate than + # /usr/lib/lxc. + econf \ + --localstatedir=/var \ + --bindir=/usr/bin \ + --sbindir=/usr/bin \ + --with-config-path=/var/lib/lxc \ + --with-rootfs-path=/var/lib/lxc/rootfs \ + --with-distro=gentoo \ + --with-runtime-path=/run \ + --disable-apparmor \ + $(use_enable cgmanager) \ + $(use_enable doc) \ + $(use_enable examples) \ + $(use_enable lua) \ + $(use_enable python) \ + $(use_enable seccomp) +} + +python_compile() { + distutils-r1_python_compile build_ext -I ../ -L ../${PN} +} + +src_compile() { + default + + if use python; then + pushd "${S}/src/python-${PN}" > /dev/null + distutils-r1_src_compile + popd > /dev/null + fi +} + +src_install() { + default + + mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die + # start-ephemeral is no longer a command but removing it here + # generates QA warnings (still in upstream completion script) + bashcomp_alias ${PN}-start \ + ${PN}-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait} + + if use python; then + pushd "${S}/src/python-lxc" > /dev/null + # Unset DOCS. This has been handled by the default target + unset DOCS + distutils-r1_src_install + popd > /dev/null + fi + + keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc + + find "${D}" -name '*.la' -delete + + # Gentoo-specific additions! + newinitd "${FILESDIR}/${PN}.initd.5" ${PN} + + # Remember to compare our systemd unit file with the upstream one + # config/init/systemd/lxc.service.in + systemd_newunit "${FILESDIR}"/${PN}_at.service.4 "lxc@.service" +} + +pkg_postinst() { + elog "" + elog "Starting from version ${PN}-1.1.0-r3, the default lxc path has been" + elog "moved from /etc/lxc to /var/lib/lxc. If you still want to use /etc/lxc" + elog "please add the following to your /etc/lxc/default.conf" + elog "lxc.lxcpath = /etc/lxc" + elog "" + elog "There is an init script provided with the package now; no documentation" + elog "is currently available though, so please check out /etc/init.d/lxc ." + elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname" + elog "to start the container defined into /etc/lxc/configname.conf ." + elog "For further information about LXC development see" + elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available + elog "" +} diff --git a/app-emulation/lxc/lxc-2.0.6-r1.ebuild b/app-emulation/lxc/lxc-2.0.6-r1.ebuild new file mode 100644 index 000000000000..c3ca8d9ee12c --- /dev/null +++ b/app-emulation/lxc/lxc-2.0.6-r1.ebuild @@ -0,0 +1,201 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +MY_P="${P/_/-}" +PYTHON_COMPAT=( python{3_4,3_5} ) +DISTUTILS_OPTIONAL=1 + +inherit autotools bash-completion-r1 distutils-r1 linux-info versionator flag-o-matic systemd + +DESCRIPTION="LinuX Containers userspace utilities" +HOMEPAGE="https://linuxcontainers.org/" +SRC_URI="https://github.com/lxc/lxc/archive/${MY_P}.tar.gz" + +KEYWORDS="~amd64 ~arm ~arm64" + +LICENSE="LGPL-3" +SLOT="0" +IUSE="cgmanager doc examples lua python seccomp" + +RDEPEND="net-libs/gnutls + sys-libs/libcap + cgmanager? ( app-admin/cgmanager ) + lua? ( >=dev-lang/lua-5.1:= ) + python? ( ${PYTHON_DEPS} ) + seccomp? ( sys-libs/libseccomp )" + +DEPEND="${RDEPEND} + doc? ( app-text/docbook-sgml-utils ) + >=sys-kernel/linux-headers-3.2" + +RDEPEND="${RDEPEND} + sys-process/criu + sys-apps/util-linux + app-misc/pax-utils + virtual/awk" + +CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE + ~CPUSETS ~CGROUP_CPUACCT + ~CGROUP_SCHED + + ~NAMESPACES + ~IPC_NS ~USER_NS ~PID_NS + + ~NETLINK_DIAG ~PACKET_DIAG + ~INET_UDP_DIAG ~INET_TCP_DIAG + ~UNIX_DIAG ~CHECKPOINT_RESTORE + + ~CGROUP_FREEZER + ~UTS_NS ~NET_NS + ~VETH ~MACVLAN + + ~POSIX_MQUEUE + ~!NETPRIO_CGROUP + + ~!GRKERNSEC_CHROOT_MOUNT + ~!GRKERNSEC_CHROOT_DOUBLE + ~!GRKERNSEC_CHROOT_PIVOT + ~!GRKERNSEC_CHROOT_CHMOD + ~!GRKERNSEC_CHROOT_CAPS + ~!GRKERNSEC_PROC + ~!GRKERNSEC_SYSFS_RESTRICT +" + +ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container" + +ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers" + +ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info" +ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network" + +ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking" +ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking" + +ERROR_NETLINK_DIAG="CONFIG_NETLINK_DIAG: needed for lxc-checkpoint" +ERROR_PACKET_DIAG="CONFIG_PACKET_DIAG: needed for lxc-checkpoint" +ERROR_INET_UDP_DIAG="CONFIG_INET_UDP_DIAG: needed for lxc-checkpoint" +ERROR_INET_TCP_DIAG="CONFIG_INET_TCP_DIAG: needed for lxc-checkpoint" +ERROR_UNIX_DIAG="CONFIG_UNIX_DIAG: needed for lxc-checkpoint" +ERROR_CHECKPOINT_RESTORE="CONFIG_CHECKPOINT_RESTORE: needed for lxc-checkpoint" + +ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command" + +ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting." + +ERROR_GRKERNSEC_CHROOT_MOUNT="CONFIG_GRKERNSEC_CHROOT_MOUNT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_DOUBLE="CONFIG_GRKERNSEC_CHROOT_DOUBLE: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_PIVOT="CONFIG_GRKERNSEC_CHROOT_PIVOT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CHMOD="CONFIG_GRKERNSEC_CHROOT_CHMOD: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CAPS="CONFIG_GRKERNSEC_CHROOT_CAPS: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_PROC="CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers" +ERROR_GRKERNSEC_SYSFS_RESTRICT="CONFIG_GRKERNSEC_SYSFS_RESTRICT: this GRSEC feature is incompatible with unprivileged containers" + +DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt) + +S="${WORKDIR}/${PN}-${MY_P}" + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +pkg_setup() { + kernel_is -lt 4 7 && CONFIG_CHECK="${CONFIG_CHECK} ~DEVPTS_MULTIPLE_INSTANCES" + linux-info_pkg_setup +} + +src_prepare() { + eapply "${FILESDIR}"/${P}-bash-completion.patch + #558854 + eapply "${FILESDIR}"/${PN}-2.0.5-omit-sysconfig.patch + eapply "${FILESDIR}"/${PN}-2.0.6-major.patch + eapply_user + eautoreconf +} + +src_configure() { + append-flags -fno-strict-aliasing + + if use python; then + #541932 + python_setup "python3*" + export PKG_CONFIG_PATH="${T}/${EPYTHON}/pkgconfig:${PKG_CONFIG_PATH}" + fi + + # I am not sure about the --with-rootfs-path + # /var/lib/lxc is probably more appropriate than + # /usr/lib/lxc. + econf \ + --localstatedir=/var \ + --bindir=/usr/bin \ + --sbindir=/usr/bin \ + --with-config-path=/var/lib/lxc \ + --with-rootfs-path=/var/lib/lxc/rootfs \ + --with-distro=gentoo \ + --with-runtime-path=/run \ + --disable-apparmor \ + $(use_enable cgmanager) \ + $(use_enable doc) \ + $(use_enable examples) \ + $(use_enable lua) \ + $(use_enable python) \ + $(use_enable seccomp) +} + +python_compile() { + distutils-r1_python_compile build_ext -I ../ -L ../${PN} +} + +src_compile() { + default + + if use python; then + pushd "${S}/src/python-${PN}" > /dev/null + distutils-r1_src_compile + popd > /dev/null + fi +} + +src_install() { + default + + mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die + # start-ephemeral is no longer a command but removing it here + # generates QA warnings (still in upstream completion script) + bashcomp_alias ${PN}-start \ + ${PN}-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait} + + if use python; then + pushd "${S}/src/python-lxc" > /dev/null + # Unset DOCS. This has been handled by the default target + unset DOCS + distutils-r1_src_install + popd > /dev/null + fi + + keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc + + find "${D}" -name '*.la' -delete + + # Gentoo-specific additions! + newinitd "${FILESDIR}/${PN}.initd.5" ${PN} + + # Remember to compare our systemd unit file with the upstream one + # config/init/systemd/lxc.service.in + systemd_newunit "${FILESDIR}"/${PN}_at.service.4 "lxc@.service" +} + +pkg_postinst() { + elog "" + elog "Starting from version ${PN}-1.1.0-r3, the default lxc path has been" + elog "moved from /etc/lxc to /var/lib/lxc. If you still want to use /etc/lxc" + elog "please add the following to your /etc/lxc/default.conf" + elog "lxc.lxcpath = /etc/lxc" + elog "" + elog "There is an init script provided with the package now; no documentation" + elog "is currently available though, so please check out /etc/init.d/lxc ." + elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname" + elog "to start the container defined into /etc/lxc/configname.conf ." + elog "For further information about LXC development see" + elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available + elog "" +} diff --git a/app-emulation/lxc/lxc-2.0.7.ebuild b/app-emulation/lxc/lxc-2.0.7.ebuild new file mode 100644 index 000000000000..22003a834e98 --- /dev/null +++ b/app-emulation/lxc/lxc-2.0.7.ebuild @@ -0,0 +1,201 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +MY_P="${P/_/-}" +PYTHON_COMPAT=( python{3_4,3_5} ) +DISTUTILS_OPTIONAL=1 + +inherit autotools bash-completion-r1 distutils-r1 linux-info versionator flag-o-matic systemd + +DESCRIPTION="LinuX Containers userspace utilities" +HOMEPAGE="https://linuxcontainers.org/" +SRC_URI="https://github.com/lxc/lxc/archive/${MY_P}.tar.gz" + +KEYWORDS="amd64 ~arm ~arm64" + +LICENSE="LGPL-3" +SLOT="0" +IUSE="cgmanager doc examples lua python seccomp" + +RDEPEND="net-libs/gnutls + sys-libs/libcap + cgmanager? ( app-admin/cgmanager ) + lua? ( >=dev-lang/lua-5.1:= ) + python? ( ${PYTHON_DEPS} ) + seccomp? ( sys-libs/libseccomp )" + +DEPEND="${RDEPEND} + doc? ( app-text/docbook-sgml-utils ) + >=sys-kernel/linux-headers-3.2" + +RDEPEND="${RDEPEND} + sys-process/criu + sys-apps/util-linux + app-misc/pax-utils + virtual/awk" + +CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE + ~CPUSETS ~CGROUP_CPUACCT + ~CGROUP_SCHED + + ~NAMESPACES + ~IPC_NS ~USER_NS ~PID_NS + + ~NETLINK_DIAG ~PACKET_DIAG + ~INET_UDP_DIAG ~INET_TCP_DIAG + ~UNIX_DIAG ~CHECKPOINT_RESTORE + + ~CGROUP_FREEZER + ~UTS_NS ~NET_NS + ~VETH ~MACVLAN + + ~POSIX_MQUEUE + ~!NETPRIO_CGROUP + + ~!GRKERNSEC_CHROOT_MOUNT + ~!GRKERNSEC_CHROOT_DOUBLE + ~!GRKERNSEC_CHROOT_PIVOT + ~!GRKERNSEC_CHROOT_CHMOD + ~!GRKERNSEC_CHROOT_CAPS + ~!GRKERNSEC_PROC + ~!GRKERNSEC_SYSFS_RESTRICT +" + +ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container" + +ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers" + +ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info" +ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network" + +ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking" +ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking" + +ERROR_NETLINK_DIAG="CONFIG_NETLINK_DIAG: needed for lxc-checkpoint" +ERROR_PACKET_DIAG="CONFIG_PACKET_DIAG: needed for lxc-checkpoint" +ERROR_INET_UDP_DIAG="CONFIG_INET_UDP_DIAG: needed for lxc-checkpoint" +ERROR_INET_TCP_DIAG="CONFIG_INET_TCP_DIAG: needed for lxc-checkpoint" +ERROR_UNIX_DIAG="CONFIG_UNIX_DIAG: needed for lxc-checkpoint" +ERROR_CHECKPOINT_RESTORE="CONFIG_CHECKPOINT_RESTORE: needed for lxc-checkpoint" + +ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command" + +ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting." + +ERROR_GRKERNSEC_CHROOT_MOUNT="CONFIG_GRKERNSEC_CHROOT_MOUNT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_DOUBLE="CONFIG_GRKERNSEC_CHROOT_DOUBLE: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_PIVOT="CONFIG_GRKERNSEC_CHROOT_PIVOT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CHMOD="CONFIG_GRKERNSEC_CHROOT_CHMOD: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CAPS="CONFIG_GRKERNSEC_CHROOT_CAPS: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_PROC="CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers" +ERROR_GRKERNSEC_SYSFS_RESTRICT="CONFIG_GRKERNSEC_SYSFS_RESTRICT: this GRSEC feature is incompatible with unprivileged containers" + +DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt) + +S="${WORKDIR}/${PN}-${MY_P}" + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +pkg_setup() { + kernel_is -lt 4 7 && CONFIG_CHECK="${CONFIG_CHECK} ~DEVPTS_MULTIPLE_INSTANCES" + linux-info_pkg_setup +} + +src_prepare() { + eapply "${FILESDIR}"/${PN}-2.0.6-bash-completion.patch + #558854 + eapply "${FILESDIR}"/${PN}-2.0.5-omit-sysconfig.patch + eapply_user + eautoreconf +} + +src_configure() { + append-flags -fno-strict-aliasing + + if use python; then + #541932 + python_setup "python3*" + export PKG_CONFIG_PATH="${T}/${EPYTHON}/pkgconfig:${PKG_CONFIG_PATH}" + fi + + # I am not sure about the --with-rootfs-path + # /var/lib/lxc is probably more appropriate than + # /usr/lib/lxc. + econf \ + --localstatedir=/var \ + --bindir=/usr/bin \ + --sbindir=/usr/bin \ + --with-config-path=/var/lib/lxc \ + --with-rootfs-path=/var/lib/lxc/rootfs \ + --with-distro=gentoo \ + --with-runtime-path=/run \ + --disable-apparmor \ + --disable-werror \ + $(use_enable cgmanager) \ + $(use_enable doc) \ + $(use_enable examples) \ + $(use_enable lua) \ + $(use_enable python) \ + $(use_enable seccomp) +} + +python_compile() { + distutils-r1_python_compile build_ext -I ../ -L ../${PN} +} + +src_compile() { + default + + if use python; then + pushd "${S}/src/python-${PN}" > /dev/null + distutils-r1_src_compile + popd > /dev/null + fi +} + +src_install() { + default + + mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die + # start-ephemeral is no longer a command but removing it here + # generates QA warnings (still in upstream completion script) + bashcomp_alias ${PN}-start \ + ${PN}-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait} + + if use python; then + pushd "${S}/src/python-lxc" > /dev/null + # Unset DOCS. This has been handled by the default target + unset DOCS + distutils-r1_src_install + popd > /dev/null + fi + + keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc + + find "${D}" -name '*.la' -delete + + # Gentoo-specific additions! + newinitd "${FILESDIR}/${PN}.initd.5" ${PN} + + # Remember to compare our systemd unit file with the upstream one + # config/init/systemd/lxc.service.in + systemd_newunit "${FILESDIR}"/${PN}_at.service.4 "lxc@.service" +} + +pkg_postinst() { + elog "" + elog "Starting from version ${PN}-1.1.0-r3, the default lxc path has been" + elog "moved from /etc/lxc to /var/lib/lxc. If you still want to use /etc/lxc" + elog "please add the following to your /etc/lxc/default.conf" + elog "lxc.lxcpath = /etc/lxc" + elog "" + elog "There is an init script provided with the package now; no documentation" + elog "is currently available though, so please check out /etc/init.d/lxc ." + elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname" + elog "to start the container defined into /etc/lxc/configname.conf ." + elog "For further information about LXC development see" + elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available + elog "" +} diff --git a/app-emulation/lxc/lxc-2.0.8.ebuild b/app-emulation/lxc/lxc-2.0.8.ebuild new file mode 100644 index 000000000000..ae0977801e10 --- /dev/null +++ b/app-emulation/lxc/lxc-2.0.8.ebuild @@ -0,0 +1,199 @@ +# Copyright 1999-2017 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +EAPI="6" + +PYTHON_COMPAT=( python{3_4,3_5} ) +DISTUTILS_OPTIONAL=1 + +inherit autotools bash-completion-r1 distutils-r1 linux-info versionator flag-o-matic systemd + +DESCRIPTION="LinuX Containers userspace utilities" +HOMEPAGE="https://linuxcontainers.org/" +SRC_URI="https://linuxcontainers.org/downloads/lxc/${P}.tar.gz" + +KEYWORDS="~amd64 ~arm ~arm64" + +LICENSE="LGPL-3" +SLOT="0" +IUSE="cgmanager doc examples lua python seccomp" + +RDEPEND="net-libs/gnutls + sys-libs/libcap + cgmanager? ( app-admin/cgmanager ) + lua? ( >=dev-lang/lua-5.1:= ) + python? ( ${PYTHON_DEPS} ) + seccomp? ( sys-libs/libseccomp )" + +DEPEND="${RDEPEND} + doc? ( app-text/docbook-sgml-utils ) + >=sys-kernel/linux-headers-3.2" + +RDEPEND="${RDEPEND} + sys-process/criu + sys-apps/util-linux + app-misc/pax-utils + virtual/awk" + +CONFIG_CHECK="~CGROUPS ~CGROUP_DEVICE + ~CPUSETS ~CGROUP_CPUACCT + ~CGROUP_SCHED + + ~NAMESPACES + ~IPC_NS ~USER_NS ~PID_NS + + ~NETLINK_DIAG ~PACKET_DIAG + ~INET_UDP_DIAG ~INET_TCP_DIAG + ~UNIX_DIAG ~CHECKPOINT_RESTORE + + ~CGROUP_FREEZER + ~UTS_NS ~NET_NS + ~VETH ~MACVLAN + + ~POSIX_MQUEUE + ~!NETPRIO_CGROUP + + ~!GRKERNSEC_CHROOT_MOUNT + ~!GRKERNSEC_CHROOT_DOUBLE + ~!GRKERNSEC_CHROOT_PIVOT + ~!GRKERNSEC_CHROOT_CHMOD + ~!GRKERNSEC_CHROOT_CAPS + ~!GRKERNSEC_PROC + ~!GRKERNSEC_SYSFS_RESTRICT +" + +ERROR_DEVPTS_MULTIPLE_INSTANCES="CONFIG_DEVPTS_MULTIPLE_INSTANCES: needed for pts inside container" + +ERROR_CGROUP_FREEZER="CONFIG_CGROUP_FREEZER: needed to freeze containers" + +ERROR_UTS_NS="CONFIG_UTS_NS: needed to unshare hostnames and uname info" +ERROR_NET_NS="CONFIG_NET_NS: needed for unshared network" + +ERROR_VETH="CONFIG_VETH: needed for internal (host-to-container) networking" +ERROR_MACVLAN="CONFIG_MACVLAN: needed for internal (inter-container) networking" + +ERROR_NETLINK_DIAG="CONFIG_NETLINK_DIAG: needed for lxc-checkpoint" +ERROR_PACKET_DIAG="CONFIG_PACKET_DIAG: needed for lxc-checkpoint" +ERROR_INET_UDP_DIAG="CONFIG_INET_UDP_DIAG: needed for lxc-checkpoint" +ERROR_INET_TCP_DIAG="CONFIG_INET_TCP_DIAG: needed for lxc-checkpoint" +ERROR_UNIX_DIAG="CONFIG_UNIX_DIAG: needed for lxc-checkpoint" +ERROR_CHECKPOINT_RESTORE="CONFIG_CHECKPOINT_RESTORE: needed for lxc-checkpoint" + +ERROR_POSIX_MQUEUE="CONFIG_POSIX_MQUEUE: needed for lxc-execute command" + +ERROR_NETPRIO_CGROUP="CONFIG_NETPRIO_CGROUP: as of kernel 3.3 and lxc 0.8.0_rc1 this causes LXCs to fail booting." + +ERROR_GRKERNSEC_CHROOT_MOUNT="CONFIG_GRKERNSEC_CHROOT_MOUNT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_DOUBLE="CONFIG_GRKERNSEC_CHROOT_DOUBLE: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_PIVOT="CONFIG_GRKERNSEC_CHROOT_PIVOT: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CHMOD="CONFIG_GRKERNSEC_CHROOT_CHMOD: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_CHROOT_CAPS="CONFIG_GRKERNSEC_CHROOT_CAPS: some GRSEC features make LXC unusable see postinst notes" +ERROR_GRKERNSEC_PROC="CONFIG_GRKERNSEC_PROC: this GRSEC feature is incompatible with unprivileged containers" +ERROR_GRKERNSEC_SYSFS_RESTRICT="CONFIG_GRKERNSEC_SYSFS_RESTRICT: this GRSEC feature is incompatible with unprivileged containers" + +DOCS=(AUTHORS CONTRIBUTING MAINTAINERS NEWS README doc/FAQ.txt) + +REQUIRED_USE="python? ( ${PYTHON_REQUIRED_USE} )" + +pkg_setup() { + kernel_is -lt 4 7 && CONFIG_CHECK="${CONFIG_CHECK} ~DEVPTS_MULTIPLE_INSTANCES" + linux-info_pkg_setup +} + +src_prepare() { + eapply "${FILESDIR}"/${PN}-2.0.6-bash-completion.patch + #558854 + eapply "${FILESDIR}"/${PN}-2.0.5-omit-sysconfig.patch + eapply_user + eautoreconf +} + +src_configure() { + append-flags -fno-strict-aliasing + + if use python; then + #541932 + python_setup "python3*" + export PKG_CONFIG_PATH="${T}/${EPYTHON}/pkgconfig:${PKG_CONFIG_PATH}" + fi + + # I am not sure about the --with-rootfs-path + # /var/lib/lxc is probably more appropriate than + # /usr/lib/lxc. + # Note by holgersson: Why is apparmor disabled? + econf \ + --localstatedir=/var \ + --bindir=/usr/bin \ + --sbindir=/usr/bin \ + --with-config-path=/var/lib/lxc \ + --with-rootfs-path=/var/lib/lxc/rootfs \ + --with-distro=gentoo \ + --with-runtime-path=/run \ + --disable-apparmor \ + --disable-werror \ + $(use_enable cgmanager) \ + $(use_enable doc) \ + $(use_enable examples) \ + $(use_enable lua) \ + $(use_enable python) \ + $(use_enable seccomp) +} + +python_compile() { + distutils-r1_python_compile build_ext -I ../ -L ../${PN} +} + +src_compile() { + default + + if use python; then + pushd "${S}/src/python-${PN}" > /dev/null + distutils-r1_src_compile + popd > /dev/null + fi +} + +src_install() { + default + + mv "${ED}"/usr/share/bash-completion/completions/${PN} "${ED}"/$(get_bashcompdir)/${PN}-start || die + # start-ephemeral is no longer a command but removing it here + # generates QA warnings (still in upstream completion script) + bashcomp_alias ${PN}-start \ + ${PN}-{attach,cgroup,copy,console,create,destroy,device,execute,freeze,info,monitor,snapshot,start-ephemeral,stop,unfreeze,wait} + + if use python; then + pushd "${S}/src/python-lxc" > /dev/null + # Unset DOCS. This has been handled by the default target + unset DOCS + distutils-r1_src_install + popd > /dev/null + fi + + keepdir /etc/lxc /var/lib/lxc/rootfs /var/log/lxc + + find "${D}" -name '*.la' -delete + + # Gentoo-specific additions! + newinitd "${FILESDIR}/${PN}.initd.5" ${PN} + + # Remember to compare our systemd unit file with the upstream one + # config/init/systemd/lxc.service.in + systemd_newunit "${FILESDIR}"/${PN}_at.service.4 "lxc@.service" +} + +pkg_postinst() { + elog "" + elog "Starting from version ${PN}-1.1.0-r3, the default lxc path has been" + elog "moved from /etc/lxc to /var/lib/lxc. If you still want to use /etc/lxc" + elog "please add the following to your /etc/lxc/default.conf" + elog "lxc.lxcpath = /etc/lxc" + elog "" + elog "There is an init script provided with the package now; no documentation" + elog "is currently available though, so please check out /etc/init.d/lxc ." + elog "You _should_ only need to symlink it to /etc/init.d/lxc.configname" + elog "to start the container defined into /etc/lxc/configname.conf ." + elog "For further information about LXC development see" + elog "http://blog.flameeyes.eu/tag/lxc" # remove once proper doc is available + elog "" +} diff --git a/app-emulation/lxc/metadata.xml b/app-emulation/lxc/metadata.xml new file mode 100644 index 000000000000..4257b067cda2 --- /dev/null +++ b/app-emulation/lxc/metadata.xml @@ -0,0 +1,26 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>dev-zero@gentoo.org</email> + </maintainer> + <maintainer type="person"> + <email>hwoarang@gentoo.org</email> + </maintainer> + <maintainer type="person"> + <email>stasibear@gentoo.org</email> + </maintainer> + <maintainer type="person"> + <email>dlan@gentoo.org</email> + </maintainer> + <maintainer type="project"> + <email>virtualization@gentoo.org</email> + <name>Gentoo Virtualization Project</name> + </maintainer> + <use> + <flag name="cgmanager">Enable support for cgroup management using <pkg>app-admin/cgmanager</pkg></flag> + </use> + <upstream> + <remote-id type="github">lxc/lxc</remote-id> + </upstream> +</pkgmetadata> |