]> iEval git - io-compress-brotli.git/commitdiff
Add a submodule for the official brotli repo, and use that instead of
authorQuim Rovira <quim@rovira.cat>
Sat, 13 Aug 2016 09:49:31 +0000 (11:49 +0200)
committerQuim Rovira <quim@rovira.cat>
Sat, 13 Aug 2016 09:49:31 +0000 (11:49 +0200)
the local copy of the decoder files.

.gitmodules [new file with mode: 0644]
Brotli.xs
Makefile.PL
brotli [new submodule]

diff --git a/.gitmodules b/.gitmodules
new file mode 100644 (file)
index 0000000..094a6d3
--- /dev/null
@@ -0,0 +1,3 @@
+[submodule "brotli"]
+    path = "brotli"
+    url = "https://github.com/google/brotli.git"
index 60b6428c3728c2a67c4e684b80d71c5470151c38..8cb26c90c2a36e1b7e13efe5eb8d15fd7739cfea 100644 (file)
--- a/Brotli.xs
+++ b/Brotli.xs
@@ -6,6 +6,7 @@
 #include "ppport.h"
 
 #include <dec/decode.h>
+#include <common/dictionary.h>
 
 #define BUFFER_SIZE 1048576
 static uint8_t buffer[BUFFER_SIZE]; /* It's almost 2016, is anyone still using ithreads? */
index a44b60729072c298cac248a078d4a514ce32f334..f522b93b6372bd7a2308d71d0ef1394cf794b7be 100644 (file)
@@ -13,10 +13,8 @@ WriteMakefile(
        BUILD_REQUIRES   => {
                qw/File::Slurp 0/,
        },
-       INC              => '-I.',
-       OBJECT           => 'Brotli.o bit_reader.o decode.o dictionary.o huffman.o state.o streams.o',
-       C                => [<dec/*c>],
-       depend           => {'$(INST_DYNAMIC)' => '$(O_FILES)'},
+       INC              => '-Ibrotli',
+       MYEXTLIB         => 'brotli/libbrotli$(LIB_EXT)',
        META_ADD         => {
                dynamic_config => 0,
                resources      => {
@@ -24,3 +22,10 @@ WriteMakefile(
                },
        }
 );
+
+sub MY::postamble {
+'
+$(MYEXTLIB): brotli/Makefile
+       cd brotli && CFLAGS=-fPIC $(MAKE) lib
+'
+}
diff --git a/brotli b/brotli
new file mode 160000 (submodule)
index 0000000..2e0d321
--- /dev/null
+++ b/brotli
@@ -0,0 +1 @@
+Subproject commit 2e0d3214c2b6248a486822d2c5267d1c961a29d0
This page took 0.034029 seconds and 4 git commands to generate.