Skip to content
This repository has been archived by the owner on Jul 4, 2023. It is now read-only.

Commit

Permalink
New formula: libwebsockets-1.22
Browse files Browse the repository at this point in the history
Libwebsockets is the main C library implementation of the latest websockets protocol.

Refs #16221.
  • Loading branch information
mxcl committed Apr 9, 2013
1 parent ee61521 commit 2186333
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions Library/Formula/libwebsockets.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
require 'formula'

class Libwebsockets < Formula
homepage 'http://git.warmcat.com/cgi-bin/cgit/libwebsockets'
url 'http://git.warmcat.com/cgi-bin/cgit/libwebsockets/snapshot/libwebsockets-1.22-chrome26-firefox18.tar.gz'

This comment has been minimized.

Copy link
@adamv

adamv Apr 9, 2013

Contributor

Max, you can't use these snapshot URLs. The generated tarball has a timestamp in it and the SHA changes on every download:

$ brew fetch -f libwebsockets
==> Downloading http://git.warmcat.com/cgi-bin/cgit/libwebsockets/snapshot/libwebsockets-1.22-chrome26-firefox18.tar
######################################################################## 100.0%
SHA1: 4d9328e8359f9928787a18ea402aae5c1b65a4da
SHA256: dd611b1d93f4b3824b0dbcdc3fbd600c7c795bfbcfb880d12e890381a54a5ba3
Warning: Formula reports different SHA1: e1bc750cf206699a7fbafc59db82c33c49948680

This comment has been minimized.

Copy link
@jacknagel

jacknagel Apr 9, 2013

Contributor

Can get it from git:

diff --git a/Library/Formula/libwebsockets.rb b/Library/Formula/libwebsockets.rb
index bfab02e..8b404fa 100644
--- a/Library/Formula/libwebsockets.rb
+++ b/Library/Formula/libwebsockets.rb
@@ -2,9 +2,8 @@

 class Libwebsockets < Formula
   homepage 'http://git.warmcat.com/cgi-bin/cgit/libwebsockets'
-  url 'http://git.warmcat.com/cgi-bin/cgit/libwebsockets/snapshot/libwebsockets-1.22-chrome26-firefox18.tar.gz'
+  url 'git://git.warmcat.com/libwebsockets', :tag => 'v1.22-chrome26-firefox18'
   version '1.22'
-  sha1 'e1bc750cf206699a7fbafc59db82c33c49948680'

   depends_on 'cmake' => :build

This comment has been minimized.

Copy link
@mxcl

mxcl Apr 12, 2013

Author Contributor

Thanks for applying the fix.

version '1.22'
sha1 'e1bc750cf206699a7fbafc59db82c33c49948680'

depends_on 'cmake' => :build

def install
system "cmake", ".", *std_cmake_args
system "make"

# The `make install` target doesn’t work (FFS) so here’s what I think
# should be installed:
lib.install 'lib/libwebsockets.dylib'
include.install 'lib/libwebsockets.h'
end
end

0 comments on commit 2186333

Please sign in to comment.