Changeset 1247


Ignore:
Timestamp:
02/17/10 22:00:05 (2 years ago)
Author:
jdunn
Message:

Mostly patches for osx, but also a couple minor rephrasings.

Location:
trunk/software/usb_ir
Files:
3 added
8 edited
1 moved

Legend:

Unmodified
Added
Removed
  • trunk/software/usb_ir/Make.settings.in

    r1100 r1247  
    4040    LIBNAME=libiguanaIR.dylib 
    4141    SHAREARG = -dynamiclib 
    42     OSSUPPORT = daemonosx.o 
     42    OSSUPPORT = osx/daemonosx.o 
    4343  endif 
    4444endif 
  • trunk/software/usb_ir/Makefile.in

    r1245 r1247  
    22 
    33CFLAGS += -I. -fvisibility=hidden -DIGUANAIR_EXPORTS 
    4 LINKARGS = -Wl,-soname=$(LIBNAME),--version-script=$(srcdir)/ig.ver 
    5 ifeq ($(shell uname -s),Darwin) 
    6   LINKARGS = -Wl,-dylib_current_version,1.0.0,-dylib_compatibility_version,1.0.0 
     4 
     5ifdef DARWIN 
     6  LINKARGS   = -Wl,-dylib_current_version,1.0.0,-dylib_compatibility_version,1.0.0 -install_name $(prefix)/$(LIBDIR)/$(LIBNAME) 
     7  EXPORTARGS = 
     8else 
     9  LINKARGS   = -Wl,-soname=$(LIBNAME),--version-script=$(srcdir)/ig.ver 
     10  EXPORTARGS = -Wl,-export-dynamic 
    711endif 
    812 
     
    2125          list.o protocol-versions.o pipes.o dataPackets.o compat-unix.o \ 
    2226          support.c $(OSSUPPORT) 
    23         $(CC) -Wl,-export-dynamic $(CPPFLAGS) $(CFLAGS) -DSUPPORT_EXPORTS \ 
     27        $(CC) $(EXPORTARGS) $(CPPFLAGS) $(CFLAGS) -DSUPPORT_EXPORTS \ 
    2428              $(LDFLAGS) $^ -lpopt -lusb -lpthread -ldl $(LIBNAME) -o $@ 
    2529 
     
    108112        install -d $(DESTDIR)$(prefix)/include 
    109113        install $(srcdir)/iguanaIR.h $(DESTDIR)$(prefix)/include/iguanaIR.h 
    110 ifeq ($(DARWIN),) 
     114ifdef DARWIN 
     115        install -D --mode 644 osx/com.iguana.igdaemon.plist \ 
     116                              /Library/LaunchDaemons/com.iguana.igdaemon.plist 
     117        launchctl load -w /Library/LaunchDaemons/com.iguana.igdaemon.plist 
     118else 
    111119        install -D $(srcdir)/iguanaIR.init $(DESTDIR)/etc/init.d/iguanaIR 
    112120        install -D --mode 644 $(srcdir)/iguanaIR.options $(DESTDIR)/etc/default/iguanaIR 
     
    119127.PHONY: uninstall 
    120128uninstall: 
    121 ifeq ($(DARWIN),) 
     129ifdef DARWIN 
     130        launchctl unload -w /Library/LaunchDaemons/com.iguana.igdaemon.plist || true 
     131        rm -f /Library/LaunchDaemons/com.iguana.igdaemon.plist 
     132else 
    122133        /etc/init.d/iguanaIR stop || true 
     134        rm -f $(DESTDIR)/etc/init.d/iguanaIR 
     135        rm -f $(DESTDIR)/etc/default/iguanaIR 
     136        rm -f $(DESTDIR)/etc/udev/rules.d/iguanaIR.rules 
     137        rmdir $(DESTDIR)/lib/udev/devices/iguanaIR 2>/dev/null || true 
     138        rmdir $(DESTDIR)/dev/iguanaIR 2>/dev/null || true 
    123139endif 
    124140        rm -f $(DESTDIR)$(prefix)/bin/igclient 
     
    127143        rm -f $(DESTDIR)$(prefix)/$(LIBDIR)/libiguanaIR.$(SHAREEXT) 
    128144        rm -f $(DESTDIR)$(prefix)/include/iguanaIR.h 
    129 ifeq ($(DARWIN),) 
    130         rm -f $(DESTDIR)/etc/init.d/iguanaIR 
    131         rm -f $(DESTDIR)/etc/default/iguanaIR 
    132         rm -f $(DESTDIR)/etc/udev/rules.d/iguanaIR.rules 
    133         rmdir $(DESTDIR)/lib/udev/devices/iguanaIR 2>/dev/null || true 
    134         rmdir $(DESTDIR)/dev/iguanaIR 2>/dev/null || true 
    135 endif 
     145        rm -fr $(DESTDIR)$(prefix)/$(LIBDIR)/iguanaIR 
     146        rm -fr $(DESTDIR)$(prefix)/$(LIBDIR)/iguanaIR-reflasher 
    136147 
    137148.PHONY: clean drivers-clean 
  • trunk/software/usb_ir/compat.h

    r1165 r1247  
    103103    #if __APPLE__ 
    104104        #define SwitchToThread() pthread_yield_np() 
    105         #define DYNLIB_EXT ".dynlib" 
     105        #define DYNLIB_EXT ".dylib" 
    106106    #else 
    107107        #define SwitchToThread() pthread_yield() 
  • trunk/software/usb_ir/daemon.c

    r1162 r1247  
    130130{ 
    131131    /* generic actions */ 
    132     ARG_LOG_FILE, 
     132    ARG_LOG_FILE = 1, /* popt in MacPorts does not like starting w 0 */ 
    133133    ARG_QUIETER, 
    134134    ARG_LOUDER, 
  • trunk/software/usb_ir/drivers/Makefile.in

    r1100 r1247  
    44LISTS=../list.o 
    55 
     6ifdef DARWIN 
     7  LDFLAGS += -undefined dynamic_lookup 
     8endif 
     9 
    610all: $(DRIVERS) 
    711 
    812libusb.so: libusb.c $(LISTS) Makefile 
    9 #       $(CC) $(CPPFLAGS) $(CFLAGS) $(SHAREARG) $(LDFLAGS) -lusb-1.0 $< $(LISTS) -o $@ 
    10         $(CC) $(CPPFLAGS) $(CFLAGS) $(SHAREARG) -lusb-1.0 $< $(LISTS) -o $@ 
     13        $(CC) $(CPPFLAGS) $(CFLAGS) $(SHAREARG) $(LDFLAGS) -lusb-1.0 $< \ 
     14                $(LISTS) -o $@ 
    1115 
    1216libusbpre1.so: libusbpre1.c $(LISTS) Makefile 
    13         $(CC) $(CPPFLAGS) $(CFLAGS) $(SHAREARG) -lusb $< $(LISTS) -o $@ 
     17        $(CC) $(CPPFLAGS) $(CFLAGS) $(SHAREARG) $(LDFLAGS) -lusb $< \ 
     18                $(LISTS) -o $@ 
    1419 
    1520.PHONY: clean 
  • trunk/software/usb_ir/drivers/libusbpre1.c

    r1164 r1247  
    192192} 
    193193 
     194/* the list must be allocated here where the struct is defined */ 
    194195static deviceList* prepareDeviceList(usbId *ids, deviceFunc ndf) 
    195196{ 
  • trunk/software/usb_ir/reflasher/iguanaIR-reflasher

    r1225 r1247  
    10631063           version != 3 and \ 
    10641064           version != 4: 
    1065             message(LOG_ERROR, 
    1066                     "This script cannot test a version %s device.\n" % version) 
     1065            message(LOG_ERROR, "This script cannot test a version 0x%x device.\n" % version) 
    10671066            continue 
    10681067 
  • trunk/software/usb_ir/win32/service.c

    r1164 r1247  
    194194    { "startsvc", 0, POPT_ARG_NONE, NULL, 's', "Start the system igdaemon service.", NULL }, 
    195195    { "stopsvc", 0, POPT_ARG_NONE, NULL, 't', "Stop the system igdaemon service.", NULL }, 
    196     { "installinf", 0, POPT_ARG_NONE, NULL, 'i', "Stop the system igdaemon service.", NULL }, 
     196    { "installinf", 0, POPT_ARG_NONE, NULL, 'i', "Manually install the INF for the device.", NULL }, 
    197197 
    198198    /* options specific to the drivers */ 
Note: See TracChangeset for help on using the changeset viewer.