fork
Configure Feed
Select the types of activity you want to include in your feed.
lol
fork
Configure Feed
Select the types of activity you want to include in your feed.
1{ lib, stdenv, fetchpatch, fetchurl, bison, perl }:
2
3let
4 version = "0.0.6";
5 debianRevision = "7";
6 debianPatch = patchname: hash: fetchpatch {
7 name = "${patchname}.patch";
8 url = "https://sources.debian.org/data/main/b/bulletml/${version}-${debianRevision}/debian/patches/${patchname}.patch";
9 sha256 = hash;
10 };
11
12in stdenv.mkDerivation {
13 pname = "bulletml";
14 inherit version;
15
16 srcs = [
17 (fetchurl {
18 url = "http://shinh.skr.jp/libbulletml/libbulletml-${version}.tar.bz2";
19 sha256 = "0yda0zgj2ydgkmby5676f5iiawabxadzh5p7bmy42998sp9g6dvw";
20 })
21 (fetchurl {
22 url = "http://shinh.skr.jp/d/d_cpp.tar.bz2";
23 sha256 = "1ly9qmbb8q9nyadmdap1gmxs3vkniqgchlv2hw7riansz4gg1agh";
24 })
25 ];
26 sourceRoot = "bulletml";
27 postUnpack = "mv d_cpp bulletml/";
28
29 patches = [
30 (debianPatch "fixes" "0cnr968n0h50fjmjijx7idsa2pg2pv5cwy6nvfbkx9z8w2zf0mkl")
31 (debianPatch "bulletml_d" "03d1dgln3gkiw019pxn3gwgjkmvzisq8kp3n6fpn38yfwh4fp4hv")
32 (debianPatch "d_cpp" "04g9c7c89w7cgrxw75mcbdhzxqmz1716li49mhl98znakchrlb9h")
33 (debianPatch "warnings" "18px79x4drvm6dy6w6js53nzlyvha7qaxhz5a99b97pyk3qc7i9g")
34 (debianPatch "makefile" "0z6yxanxmarx0s08gh12pk2wfqjk8g797wmfcqczdv1i6xc7nqzp")
35 (debianPatch "includes" "1n11j5695hs9pspslf748w2cq5d78s6bwhyl476wp6gcq6jw20bw")
36 ];
37
38 makeFlags = [
39 "-C src"
40 ];
41 nativeBuildInputs = [ bison perl ];
42 hardeningDisable = [ "format" ];
43
44 installPhase = ''
45 install -D -m 644 src/bulletml.d "$out"/include/d/bulletml.d
46 install -d "$out"/include/bulletml/tinyxml
47 install -m 644 src/*.h "$out"/include/bulletml
48 install -m 644 src/tinyxml/tinyxml.h "$out"/include/bulletml/tinyxml
49 cp -r src/boost $out/include/boost
50
51 install -d "$out"/lib
52 install -m 644 src/libbulletml.{a,so}* "$out"/lib
53
54 install -D -m 644 README "$out"/share/doc/libbulletml/README.jp
55 install -m 644 README.en "$out"/share/doc/libbulletml
56 install -m 644 README.bulletml "$out"/share/doc/libbulletml
57 install -D -m 644 README "$out"/share/licenses/libbulletml/README.jp
58 install -m 644 README.en "$out"/share/licenses/libbulletml
59 '';
60
61 meta = with lib; {
62 description = "C++ library to handle BulletML easily";
63 longDescription = ''
64 BulletML is the Bullet Markup Language. BulletML can describe the barrage
65 of bullets in shooting games.
66 '';
67 homepage = "http://www.asahi-net.or.jp/~cs8k-cyu/bulletml/index_e.html";
68 license = licenses.bsd3;
69 maintainers = with maintainers; [ fgaz ];
70 # See https://github.com/NixOS/nixpkgs/pull/35482
71 # for some attempts in getting it to build on darwin
72 platforms = platforms.linux;
73 };
74}