Skip to content

Instantly share code, notes, and snippets.

@pexcn
Last active June 19, 2021 05:11
Show Gist options
  • Save pexcn/de6c76897b15e4d4ec733bcc2c277c3b to your computer and use it in GitHub Desktop.
Save pexcn/de6c76897b15e4d4ec733bcc2c277c3b to your computer and use it in GitHub Desktop.

ChinaDNS

Deprecated

git clone https://github.com/pexcn/ChinaDNS.git && pushd ChinaDNS
./autogen.sh
CFLAGS="-O3 -ffast-math" ./configure --enable-static
make
strip src/chinadns.exe
popd

simple-obfs

20210619 UPDATE

# libev
./configure \
  --prefix="/d/build/libev" \
  --disable-shared \
  --enable-static \
  CFLAGS="-O3 -pipe"

# simple-obfs
./configure \
  --prefix="/d/build/simple-obfs" \
  --with-ev="/d/build/libev" \
  --disable-documentation \
  --disable-assert \
  --enable-static \
  LIBS="-lpthread -lm" \
  CFLAGS="-O3 -pipe -Wno-char-subscripts" \
  LDFLAGS="-static -static-libgcc"

20191126 UPDATE (not working)

apt-get install --no-install-recommends -y \
  binutils-mingw-w64-x86-64 \
  gcc-mingw-w64-x86-64

# reference:
# https://github.com/pexcn/static-build-ci/blob/c1b75aa1d95f194f11f2d677456665f7dd384c63/build.sh#L165-L182

Deprecated

git clone https://github.com/shadowsocks/simple-obfs.git && pushd simple-obfs
git submodule update --init --recursive
./autogen.sh
LIBS="-lev" LDFLAGS="-static -static-libgcc" CFLAGS="-O3 -ffast-math -Wno-attributes" ./configure --disable-documentation --disable-assert --disable-ssp --enable-static
make
strip src/obfs-server.exe src/obfs-local.exe
popd
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment