brp-pacu/0000755000175000017500000000000012153127664011240 5ustar miramirabrp-pacu/INSTALL-Mac.txt0000644000175000017500000000346512153127664013615 0ustar miramiraBRP-PACU Web site _______________________________________ http://sourceforge.net/projects/brp-pacu Intel Mac 32 bits or 64 bits Mac OS X Leopard or Snow Leopard === FOR USERS === You should first download and install: Jack-OS X from http://www.jackosx.com/ To install BRP-PACU, drag the BRP-PACU icon into the Application folder. Then double-click on BRP-PACU to start. If Jack-OS X is not present or not running, a warning will appear, and Jack Pilot will open. CLick on "Start" on the JackPilot window, then on "Continue"" on the warning box. If Jack Pilot does not open, this means that Jack-OS X is not installed correctly. === FOR DEVELOPERS === If you want to modify the program, you have to use the source distribution. You will find it at: https://sourceforge.net/projects/brp-pacu/files/brp-pacu-v2-any/ Building instruction for Mac 1. Dependencies: To build the system, you should first download and install: Jack-OSX from http://www.jackosx.com/ GTK+ for OX X The easiest way to install GTK+ is to follow the instructions at: https://sourceforge.net/apps/trac/gtk-osx/wiki/Build Also, you will need the development versions of: fftw version 2.1.5 from http://www.fftw.org/download.html (fttw version 3 does not work yet) GtkDatabox 0.9.1.1 or later from https://sourceforge.net/projects/gtkdatabox/ Before installing these packages, do the following from the command line: export PPKG_CONFIG_PATH='/usr/lib/pkgconfig/:\ /usr/local/lib/pkgconfig/:'$HOME'/gtk/inst/lib/pkgconfig' sudo cat > /usr/share/aclocal/dirlist echo '/usr/local/share/aclocal' | \ sudo tee /usr/share/aclocal/dirlist then follow the usual installation procedure (see INSTALL) Use the same procedure for installing BRP-PACU from the source distribution. To make the disk image containing the BRP-PACU application, enter: make macdist brp-pacu/NCC.i0000644000175000017500000030145112153127664012021 0ustar miramira# 1 "gui.c" # 1 "" # 1 "" # 1 "/usr/include/nognu" 1 # 1 "" 2 # 1 "gui.c" # 23 "gui.c" # 1 "/usr/include/stdio.h" 1 3 4 # 28 "/usr/include/stdio.h" 3 4 # 1 "/usr/include/features.h" 1 3 4 # 330 "/usr/include/features.h" 3 4 # 1 "/usr/include/sys/cdefs.h" 1 3 4 # 348 "/usr/include/sys/cdefs.h" 3 4 # 1 "/usr/include/bits/wordsize.h" 1 3 4 # 349 "/usr/include/sys/cdefs.h" 2 3 4 # 331 "/usr/include/features.h" 2 3 4 # 354 "/usr/include/features.h" 3 4 # 1 "/usr/include/gnu/stubs.h" 1 3 4 # 1 "/usr/include/bits/wordsize.h" 1 3 4 # 5 "/usr/include/gnu/stubs.h" 2 3 4 # 1 "/usr/include/gnu/stubs-64.h" 1 3 4 # 10 "/usr/include/gnu/stubs.h" 2 3 4 # 355 "/usr/include/features.h" 2 3 4 # 29 "/usr/include/stdio.h" 2 3 4 # 1 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 1 3 4 # 214 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 3 4 typedef long unsigned int size_t; # 35 "/usr/include/stdio.h" 2 3 4 # 1 "/usr/include/bits/types.h" 1 3 4 # 28 "/usr/include/bits/types.h" 3 4 # 1 "/usr/include/bits/wordsize.h" 1 3 4 # 29 "/usr/include/bits/types.h" 2 3 4 typedef unsigned char __u_char; typedef unsigned short int __u_short; typedef unsigned int __u_int; typedef unsigned long int __u_long; typedef signed char __int8_t; typedef unsigned char __uint8_t; typedef signed short int __int16_t; typedef unsigned short int __uint16_t; typedef signed int __int32_t; typedef unsigned int __uint32_t; typedef signed long int __int64_t; typedef unsigned long int __uint64_t; typedef long int __quad_t; typedef unsigned long int __u_quad_t; # 131 "/usr/include/bits/types.h" 3 4 # 1 "/usr/include/bits/typesizes.h" 1 3 4 # 132 "/usr/include/bits/types.h" 2 3 4 typedef unsigned long int __dev_t; typedef unsigned int __uid_t; typedef unsigned int __gid_t; typedef unsigned long int __ino_t; typedef unsigned long int __ino64_t; typedef unsigned int __mode_t; typedef unsigned long int __nlink_t; typedef long int __off_t; typedef long int __off64_t; typedef int __pid_t; typedef struct { int __val[2]; } __fsid_t; typedef long int __clock_t; typedef unsigned long int __rlim_t; typedef unsigned long int __rlim64_t; typedef unsigned int __id_t; typedef long int __time_t; typedef unsigned int __useconds_t; typedef long int __suseconds_t; typedef int __daddr_t; typedef long int __swblk_t; typedef int __key_t; typedef int __clockid_t; typedef void * __timer_t; typedef long int __blksize_t; typedef long int __blkcnt_t; typedef long int __blkcnt64_t; typedef unsigned long int __fsblkcnt_t; typedef unsigned long int __fsblkcnt64_t; typedef unsigned long int __fsfilcnt_t; typedef unsigned long int __fsfilcnt64_t; typedef long int __ssize_t; typedef __off64_t __loff_t; typedef __quad_t *__qaddr_t; typedef char *__caddr_t; typedef long int __intptr_t; typedef unsigned int __socklen_t; # 37 "/usr/include/stdio.h" 2 3 4 # 45 "/usr/include/stdio.h" 3 4 struct _IO_FILE; typedef struct _IO_FILE FILE; # 65 "/usr/include/stdio.h" 3 4 typedef struct _IO_FILE __FILE; # 75 "/usr/include/stdio.h" 3 4 # 1 "/usr/include/libio.h" 1 3 4 # 32 "/usr/include/libio.h" 3 4 # 1 "/usr/include/_G_config.h" 1 3 4 # 15 "/usr/include/_G_config.h" 3 4 # 1 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 1 3 4 # 16 "/usr/include/_G_config.h" 2 3 4 # 1 "/usr/include/wchar.h" 1 3 4 # 78 "/usr/include/wchar.h" 3 4 typedef struct { int __count; union { unsigned int __wch; char __wchb[4]; } __value; } __mbstate_t; # 21 "/usr/include/_G_config.h" 2 3 4 typedef struct { __off_t __pos; __mbstate_t __state; } _G_fpos_t; typedef struct { __off64_t __pos; __mbstate_t __state; } _G_fpos64_t; # 53 "/usr/include/_G_config.h" 3 4 typedef int _G_int16_t ; typedef int _G_int32_t ; typedef unsigned int _G_uint16_t ; typedef unsigned int _G_uint32_t ; # 33 "/usr/include/libio.h" 2 3 4 # 53 "/usr/include/libio.h" 3 4 # 1 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stdarg.h" 1 3 4 # 43 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stdarg.h" 3 4 typedef char* __gnuc_va_list; # 54 "/usr/include/libio.h" 2 3 4 # 170 "/usr/include/libio.h" 3 4 struct _IO_jump_t; struct _IO_FILE; # 180 "/usr/include/libio.h" 3 4 typedef void _IO_lock_t; struct _IO_marker { struct _IO_marker *_next; struct _IO_FILE *_sbuf; int _pos; # 203 "/usr/include/libio.h" 3 4 }; enum __codecvt_result { __codecvt_ok, __codecvt_partial, __codecvt_error, __codecvt_noconv }; # 271 "/usr/include/libio.h" 3 4 struct _IO_FILE { int _flags; char* _IO_read_ptr; char* _IO_read_end; char* _IO_read_base; char* _IO_write_base; char* _IO_write_ptr; char* _IO_write_end; char* _IO_buf_base; char* _IO_buf_end; char *_IO_save_base; char *_IO_backup_base; char *_IO_save_end; struct _IO_marker *_markers; struct _IO_FILE *_chain; int _fileno; int _flags2; __off_t _old_offset; unsigned short _cur_column; signed char _vtable_offset; char _shortbuf[1]; _IO_lock_t *_lock; # 319 "/usr/include/libio.h" 3 4 __off64_t _offset; # 328 "/usr/include/libio.h" 3 4 void *__pad1; void *__pad2; void *__pad3; void *__pad4; size_t __pad5; int _mode; char _unused2[15 * sizeof (int) - 4 * sizeof (void *) - sizeof (size_t)]; }; typedef struct _IO_FILE _IO_FILE; struct _IO_FILE_plus; extern struct _IO_FILE_plus _IO_2_1_stdin_; extern struct _IO_FILE_plus _IO_2_1_stdout_; extern struct _IO_FILE_plus _IO_2_1_stderr_; # 364 "/usr/include/libio.h" 3 4 typedef __ssize_t __io_read_fn (void *__cookie, char *__buf, size_t __nbytes); typedef __ssize_t __io_write_fn (void *__cookie, const char *__buf, size_t __n); typedef int __io_seek_fn (void *__cookie, __off64_t *__pos, int __w); typedef int __io_close_fn (void *__cookie); # 416 "/usr/include/libio.h" 3 4 extern int __underflow (_IO_FILE *); extern int __uflow (_IO_FILE *); extern int __overflow (_IO_FILE *, int); # 458 "/usr/include/libio.h" 3 4 extern int _IO_getc (_IO_FILE *__fp); extern int _IO_putc (int __c, _IO_FILE *__fp); extern int _IO_feof (_IO_FILE *__fp) ; extern int _IO_ferror (_IO_FILE *__fp) ; extern int _IO_peekc_locked (_IO_FILE *__fp); extern void _IO_flockfile (_IO_FILE *) ; extern void _IO_funlockfile (_IO_FILE *) ; extern int _IO_ftrylockfile (_IO_FILE *) ; # 488 "/usr/include/libio.h" 3 4 extern int _IO_vfscanf (_IO_FILE * , const char * , __gnuc_va_list, int *); extern int _IO_vfprintf (_IO_FILE *, const char *, __gnuc_va_list); extern __ssize_t _IO_padn (_IO_FILE *, int, __ssize_t); extern size_t _IO_sgetn (_IO_FILE *, void *, size_t); extern __off64_t _IO_seekoff (_IO_FILE *, __off64_t, int, int); extern __off64_t _IO_seekpos (_IO_FILE *, __off64_t, int); extern void _IO_free_backup_area (_IO_FILE *) ; # 76 "/usr/include/stdio.h" 2 3 4 # 89 "/usr/include/stdio.h" 3 4 typedef _G_fpos_t fpos_t; # 141 "/usr/include/stdio.h" 3 4 # 1 "/usr/include/bits/stdio_lim.h" 1 3 4 # 142 "/usr/include/stdio.h" 2 3 4 extern struct _IO_FILE *stdin; extern struct _IO_FILE *stdout; extern struct _IO_FILE *stderr; extern int remove (const char *__filename) ; extern int rename (const char *__old, const char *__new) ; extern FILE *tmpfile (void) ; # 186 "/usr/include/stdio.h" 3 4 extern char *tmpnam (char *__s) ; extern char *tmpnam_r (char *__s) ; # 204 "/usr/include/stdio.h" 3 4 extern char *tempnam (const char *__dir, const char *__pfx) ; extern int fclose (FILE *__stream); extern int fflush (FILE *__stream); # 229 "/usr/include/stdio.h" 3 4 extern int fflush_unlocked (FILE *__stream); # 243 "/usr/include/stdio.h" 3 4 extern FILE *fopen (const char * __filename, const char * __modes) ; extern FILE *freopen (const char * __filename, const char * __modes, FILE * __stream) ; # 272 "/usr/include/stdio.h" 3 4 # 283 "/usr/include/stdio.h" 3 4 extern FILE *fdopen (int __fd, const char *__modes) ; # 304 "/usr/include/stdio.h" 3 4 extern void setbuf (FILE * __stream, char * __buf) ; extern int setvbuf (FILE * __stream, char * __buf, int __modes, size_t __n) ; extern void setbuffer (FILE * __stream, char * __buf, size_t __size) ; extern void setlinebuf (FILE *__stream) ; extern int fprintf (FILE * __stream, const char * __format, ...); extern int printf (const char * __format, ...); extern int sprintf (char * __s, const char * __format, ...) ; extern int vfprintf (FILE * __s, const char * __format, __gnuc_va_list __arg); extern int vprintf (const char * __format, __gnuc_va_list __arg); extern int vsprintf (char * __s, const char * __format, __gnuc_va_list __arg) ; extern int snprintf (char * __s, size_t __maxlen, const char * __format, ...) ; extern int vsnprintf (char * __s, size_t __maxlen, const char * __format, __gnuc_va_list __arg) ; # 398 "/usr/include/stdio.h" 3 4 extern int fscanf (FILE * __stream, const char * __format, ...) ; extern int scanf (const char * __format, ...) ; extern int sscanf (const char * __s, const char * __format, ...) ; # 441 "/usr/include/stdio.h" 3 4 # 504 "/usr/include/stdio.h" 3 4 extern int fgetc (FILE *__stream); extern int getc (FILE *__stream); extern int getchar (void); # 528 "/usr/include/stdio.h" 3 4 extern int getc_unlocked (FILE *__stream); extern int getchar_unlocked (void); # 539 "/usr/include/stdio.h" 3 4 extern int fgetc_unlocked (FILE *__stream); extern int fputc (int __c, FILE *__stream); extern int putc (int __c, FILE *__stream); extern int putchar (int __c); # 572 "/usr/include/stdio.h" 3 4 extern int fputc_unlocked (int __c, FILE *__stream); extern int putc_unlocked (int __c, FILE *__stream); extern int putchar_unlocked (int __c); extern int getw (FILE *__stream); extern int putw (int __w, FILE *__stream); extern char *fgets (char * __s, int __n, FILE * __stream) ; extern char *gets (char *__s) ; # 653 "/usr/include/stdio.h" 3 4 extern int fputs (const char * __s, FILE * __stream); extern int puts (const char *__s); extern int ungetc (int __c, FILE *__stream); extern size_t fread (void * __ptr, size_t __size, size_t __n, FILE * __stream) ; extern size_t fwrite (const void * __ptr, size_t __size, size_t __n, FILE * __s) ; # 706 "/usr/include/stdio.h" 3 4 extern size_t fread_unlocked (void * __ptr, size_t __size, size_t __n, FILE * __stream) ; extern size_t fwrite_unlocked (const void * __ptr, size_t __size, size_t __n, FILE * __stream) ; extern int fseek (FILE *__stream, long int __off, int __whence); extern long int ftell (FILE *__stream) ; extern void rewind (FILE *__stream); # 742 "/usr/include/stdio.h" 3 4 extern int fseeko (FILE *__stream, __off_t __off, int __whence); extern __off_t ftello (FILE *__stream) ; # 761 "/usr/include/stdio.h" 3 4 extern int fgetpos (FILE * __stream, fpos_t * __pos); extern int fsetpos (FILE *__stream, const fpos_t *__pos); # 784 "/usr/include/stdio.h" 3 4 # 793 "/usr/include/stdio.h" 3 4 extern void clearerr (FILE *__stream) ; extern int feof (FILE *__stream) ; extern int ferror (FILE *__stream) ; extern void clearerr_unlocked (FILE *__stream) ; extern int feof_unlocked (FILE *__stream) ; extern int ferror_unlocked (FILE *__stream) ; extern void perror (const char *__s); # 1 "/usr/include/bits/sys_errlist.h" 1 3 4 # 27 "/usr/include/bits/sys_errlist.h" 3 4 extern int sys_nerr; extern const char *const sys_errlist[]; # 823 "/usr/include/stdio.h" 2 3 4 extern int fileno (FILE *__stream) ; extern int fileno_unlocked (FILE *__stream) ; # 842 "/usr/include/stdio.h" 3 4 extern FILE *popen (const char *__command, const char *__modes) ; extern int pclose (FILE *__stream); extern char *ctermid (char *__s) ; # 882 "/usr/include/stdio.h" 3 4 extern void flockfile (FILE *__stream) ; extern int ftrylockfile (FILE *__stream) ; extern void funlockfile (FILE *__stream) ; # 912 "/usr/include/stdio.h" 3 4 # 24 "gui.c" 2 # 33 "gui.c" # 1 "/usr/local/include/gtkdatabox.h" 1 3 # 23 "/usr/local/include/gtkdatabox.h" 3 # 1 "/usr/local/include/gtkdatabox_typedefs.h" 1 3 # 25 "/usr/local/include/gtkdatabox_typedefs.h" 3 G_BEGIN_DECLS # 38 "/usr/local/include/gtkdatabox_typedefs.h" 3 typedef struct _GtkDatabox GtkDatabox; # 51 "/usr/local/include/gtkdatabox_typedefs.h" 3 typedef struct _GtkDataboxGraph GtkDataboxGraph; G_END_DECLS # 24 "/usr/local/include/gtkdatabox.h" 2 3 # 1 "/usr/local/include/gtkdatabox_graph.h" 1 3 # 40 "/usr/local/include/gtkdatabox_graph.h" 3 # 1 "/usr/local/include/gtkdatabox.h" 1 3 # 41 "/usr/local/include/gtkdatabox_graph.h" 2 3 G_BEGIN_DECLS # 58 "/usr/local/include/gtkdatabox_graph.h" 3 typedef struct _GtkDataboxGraphClass GtkDataboxGraphClass; # 67 "/usr/local/include/gtkdatabox_graph.h" 3 typedef struct _GtkDataboxGraphPrivate GtkDataboxGraphPrivate; # 77 "/usr/local/include/gtkdatabox_graph.h" 3 struct _GtkDataboxGraph { GObject parent; GtkDataboxGraphPrivate *priv; }; struct _GtkDataboxGraphClass { GObjectClass parent_class; void (*draw) (GtkDataboxGraph * graph, GtkDatabox * box); gint (*calculate_extrema) (GtkDataboxGraph * graph, gfloat * min_x, gfloat * max_x, gfloat * min_y, gfloat * max_y); GdkGC* (*create_gc) (GtkDataboxGraph * graph, GtkDatabox * box); }; GType gtk_databox_graph_get_type (void); GdkGC* gtk_databox_graph_get_gc (GtkDataboxGraph * graph); void gtk_databox_graph_set_gc (GtkDataboxGraph * graph, GdkGC *gc); void gtk_databox_graph_set_hide (GtkDataboxGraph * graph, gboolean hide); gboolean gtk_databox_graph_get_hide (GtkDataboxGraph * graph); void gtk_databox_graph_set_color (GtkDataboxGraph * graph, GdkColor * color); GdkColor *gtk_databox_graph_get_color (GtkDataboxGraph * graph); void gtk_databox_graph_set_size (GtkDataboxGraph * graph, gint size); gint gtk_databox_graph_get_size (GtkDataboxGraph * graph); gint gtk_databox_graph_calculate_extrema (GtkDataboxGraph * graph, gfloat * min_x, gfloat * max_x, gfloat * min_y, gfloat * max_y); void gtk_databox_graph_draw (GtkDataboxGraph * graph, GtkDatabox * box); GdkGC* gtk_databox_graph_create_gc (GtkDataboxGraph * graph, GtkDatabox * box); G_END_DECLS # 25 "/usr/local/include/gtkdatabox.h" 2 3 # 1 "/usr/local/include/gtkdatabox_ruler.h" 1 3 # 67 "/usr/local/include/gtkdatabox_ruler.h" 3 # 1 "/usr/local/include/gtkdatabox_scale.h" 1 3 # 32 "/usr/local/include/gtkdatabox_scale.h" 3 G_BEGIN_DECLS # 43 "/usr/local/include/gtkdatabox_scale.h" 3 typedef enum { GTK_DATABOX_SCALE_LINEAR = 0, GTK_DATABOX_SCALE_LOG, GTK_DATABOX_SCALE_LOG2 } GtkDataboxScaleType; GType gtk_databox_scale_type_get_type (void); G_END_DECLS # 68 "/usr/local/include/gtkdatabox_ruler.h" 2 3 G_BEGIN_DECLS # 82 "/usr/local/include/gtkdatabox_ruler.h" 3 typedef struct _GtkDataboxRuler GtkDataboxRuler; typedef struct _GtkDataboxRulerClass GtkDataboxRulerClass; # 99 "/usr/local/include/gtkdatabox_ruler.h" 3 typedef struct _GtkDataboxRulerPrivate GtkDataboxRulerPrivate; struct _GtkDataboxRuler { GtkWidget widget; GtkDataboxRulerPrivate *priv; }; struct _GtkDataboxRulerClass { GtkWidgetClass parent_class; }; GType gtk_databox_ruler_get_type (void) G_GNUC_CONST; GtkWidget *gtk_databox_ruler_new (GtkOrientation orientation); void gtk_databox_ruler_set_range (GtkDataboxRuler * ruler, gdouble lower, gdouble upper, gdouble position); void gtk_databox_ruler_set_max_length (GtkDataboxRuler * ruler, guint max_length); void gtk_databox_ruler_set_scale_type (GtkDataboxRuler * ruler, guint scale_type); void gtk_databox_ruler_get_range (GtkDataboxRuler * ruler, gdouble * lower, gdouble * upper, gdouble * position); guint gtk_databox_ruler_get_max_length (GtkDataboxRuler * ruler); GtkDataboxScaleType gtk_databox_ruler_get_scale_type (GtkDataboxRuler * ruler); void gtk_databox_ruler_set_orientation (GtkDataboxRuler * ruler, GtkOrientation orientation); GtkOrientation gtk_databox_ruler_get_orientation (GtkDataboxRuler * ruler); G_END_DECLS # 26 "/usr/local/include/gtkdatabox.h" 2 3 # 54 "/usr/local/include/gtkdatabox.h" 3 G_BEGIN_DECLS # 71 "/usr/local/include/gtkdatabox.h" 3 typedef struct _GtkDataboxClass GtkDataboxClass; # 80 "/usr/local/include/gtkdatabox.h" 3 typedef struct _GtkDataboxPrivate GtkDataboxPrivate; typedef struct { gfloat x1; gfloat x2; gfloat y1; gfloat y2; } GtkDataboxValueRectangle; # 98 "/usr/local/include/gtkdatabox.h" 3 struct _GtkDatabox { GtkWidget box; GtkDataboxPrivate *priv; }; struct _GtkDataboxClass { GtkWidgetClass parent_class; void (*zoomed) (GtkDatabox * box); void (*selection_started) (GtkDatabox * box, GtkDataboxValueRectangle * selectionValues); void (*selection_changed) (GtkDatabox * box, GtkDataboxValueRectangle * selectionValues); void (*selection_finalized) (GtkDatabox * box, GtkDataboxValueRectangle * selectionValues); void (*selection_canceled) (GtkDatabox * box); }; GType gtk_databox_get_type (void); GtkWidget *gtk_databox_new (void); gint gtk_databox_graph_add (GtkDatabox * box, GtkDataboxGraph * graph); gint gtk_databox_graph_remove (GtkDatabox * box, GtkDataboxGraph * graph); gint gtk_databox_graph_remove_all (GtkDatabox * box); gint gtk_databox_auto_rescale (GtkDatabox * box, gfloat border); gint gtk_databox_calculate_extrema (GtkDatabox * box, gfloat * min_x, gfloat * max_x, gfloat * min_y, gfloat * max_y); void gtk_databox_set_total_limits (GtkDatabox * box, gfloat left, gfloat right, gfloat top, gfloat bottom); void gtk_databox_set_visible_limits (GtkDatabox * box, gfloat left, gfloat right, gfloat top, gfloat bottom); void gtk_databox_get_total_limits (GtkDatabox * box, gfloat * left, gfloat * right, gfloat * top, gfloat * bottom); void gtk_databox_get_visible_limits (GtkDatabox * box, gfloat * left, gfloat * right, gfloat * top, gfloat * bottom); void gtk_databox_set_adjustment_x (GtkDatabox * box, GtkAdjustment * adj); void gtk_databox_set_adjustment_y (GtkDatabox * box, GtkAdjustment * adj); GtkAdjustment *gtk_databox_get_adjustment_x (GtkDatabox * box); GtkAdjustment *gtk_databox_get_adjustment_y (GtkDatabox * box); void gtk_databox_set_ruler_x (GtkDatabox * box, GtkDataboxRuler * ruler); void gtk_databox_set_ruler_y (GtkDatabox * box, GtkDataboxRuler * ruler); GtkDataboxRuler *gtk_databox_get_ruler_x (GtkDatabox * box); GtkDataboxRuler *gtk_databox_get_ruler_y (GtkDatabox * box); void gtk_databox_set_scale_type_x (GtkDatabox * box, GtkDataboxScaleType scale_type); void gtk_databox_set_scale_type_y (GtkDatabox * box, GtkDataboxScaleType scale_type); GtkDataboxScaleType gtk_databox_get_scale_type_x (GtkDatabox * box); GtkDataboxScaleType gtk_databox_get_scale_type_y (GtkDatabox * box); void gtk_databox_set_enable_selection (GtkDatabox * box, gboolean enable); void gtk_databox_set_enable_zoom (GtkDatabox * box, gboolean enable); gboolean gtk_databox_get_enable_selection (GtkDatabox * box); gboolean gtk_databox_get_enable_zoom (GtkDatabox * box); void gtk_databox_zoom_to_selection (GtkDatabox * box); void gtk_databox_zoom_out (GtkDatabox * box); void gtk_databox_zoom_home (GtkDatabox * box); gint16 gtk_databox_value_to_pixel_x (GtkDatabox * box, gfloat value); gint16 gtk_databox_value_to_pixel_y (GtkDatabox * box, gfloat value); gfloat gtk_databox_pixel_to_value_x (GtkDatabox * box, gint16 pixel); gfloat gtk_databox_pixel_to_value_y (GtkDatabox * box, gint16 pixel); void gtk_databox_values_to_pixels (GtkDatabox * box, guint len, const gfloat * values_x, const gfloat * values_y, GdkPoint * pixels); void gtk_databox_create_box_with_scrollbars_and_rulers (GtkWidget ** p_box, GtkWidget ** p_table, gboolean scrollbar_x, gboolean scrollbar_y, gboolean ruler_x, gboolean ruler_y); GdkPixmap* gtk_databox_get_backing_pixmap(GtkDatabox * box); G_END_DECLS # 34 "gui.c" 2 # 1 "/usr/local/include/gtkdatabox_points.h" 1 3 # 33 "/usr/local/include/gtkdatabox_points.h" 3 # 1 "/usr/local/include/gtkdatabox_xyc_graph.h" 1 3 # 37 "/usr/local/include/gtkdatabox_xyc_graph.h" 3 G_BEGIN_DECLS # 61 "/usr/local/include/gtkdatabox_xyc_graph.h" 3 typedef struct _GtkDataboxXYCGraph GtkDataboxXYCGraph; typedef struct _GtkDataboxXYCGraphClass GtkDataboxXYCGraphClass; # 72 "/usr/local/include/gtkdatabox_xyc_graph.h" 3 typedef struct _GtkDataboxXYCGraphPrivate GtkDataboxXYCGraphPrivate; struct _GtkDataboxXYCGraph { GtkDataboxGraph parent; GtkDataboxXYCGraphPrivate *priv; }; struct _GtkDataboxXYCGraphClass { GtkDataboxGraphClass parent_class; }; GType gtk_databox_xyc_graph_get_type (void); guint gtk_databox_xyc_graph_get_length (GtkDataboxXYCGraph * xyc_graph); gfloat *gtk_databox_xyc_graph_get_X (GtkDataboxXYCGraph * xyc_graph); gfloat *gtk_databox_xyc_graph_get_Y (GtkDataboxXYCGraph * xyc_graph); G_END_DECLS # 34 "/usr/local/include/gtkdatabox_points.h" 2 3 G_BEGIN_DECLS # 59 "/usr/local/include/gtkdatabox_points.h" 3 typedef struct _GtkDataboxPoints GtkDataboxPoints; typedef struct _GtkDataboxPointsClass GtkDataboxPointsClass; # 70 "/usr/local/include/gtkdatabox_points.h" 3 typedef struct _GtkDataboxPointsPrivate GtkDataboxPointsPrivate; struct _GtkDataboxPoints { GtkDataboxXYCGraph parent; GtkDataboxPointsPrivate *priv; }; struct _GtkDataboxPointsClass { GtkDataboxXYCGraphClass parent_class; }; GType gtk_databox_points_get_type (void); GtkDataboxGraph *gtk_databox_points_new (guint len, gfloat * X, gfloat * Y, GdkColor * color, gint size); G_END_DECLS # 35 "gui.c" 2 # 1 "/usr/local/include/gtkdatabox_lines.h" 1 3 # 35 "/usr/local/include/gtkdatabox_lines.h" 3 G_BEGIN_DECLS # 57 "/usr/local/include/gtkdatabox_lines.h" 3 typedef struct _GtkDataboxLines GtkDataboxLines; typedef struct _GtkDataboxLinesClass GtkDataboxLinesClass; # 69 "/usr/local/include/gtkdatabox_lines.h" 3 typedef struct _GtkDataboxLinesPrivate GtkDataboxLinesPrivate; struct _GtkDataboxLines { GtkDataboxXYCGraph parent; GtkDataboxLinesPrivate *priv; }; struct _GtkDataboxLinesClass { GtkDataboxXYCGraphClass parent_class; }; GType gtk_databox_lines_get_type (void); GtkDataboxGraph *gtk_databox_lines_new (guint len, gfloat * X, gfloat * Y, GdkColor * color, guint size); G_END_DECLS # 36 "gui.c" 2 # 1 "/usr/local/include/gtkdatabox_grid.h" 1 3 # 36 "/usr/local/include/gtkdatabox_grid.h" 3 G_BEGIN_DECLS # 60 "/usr/local/include/gtkdatabox_grid.h" 3 typedef struct _GtkDataboxGrid GtkDataboxGrid; typedef struct _GtkDataboxGridClass GtkDataboxGridClass; # 71 "/usr/local/include/gtkdatabox_grid.h" 3 typedef struct _GtkDataboxGridPrivate GtkDataboxGridPrivate; struct _GtkDataboxGrid { GtkDataboxGraph parent; GtkDataboxGridPrivate *priv; }; struct _GtkDataboxGridClass { GtkDataboxGraphClass parent_class; }; GType gtk_databox_grid_get_type (void); GtkDataboxGraph *gtk_databox_grid_new (gint hlines, gint vlines, GdkColor * color, guint size); void gtk_databox_grid_set_hlines (GtkDataboxGrid * grid, gint hlines); gint gtk_databox_grid_get_hlines (GtkDataboxGrid * grid); void gtk_databox_grid_set_vlines (GtkDataboxGrid * grid, gint vlines); gint gtk_databox_grid_get_vlines (GtkDataboxGrid * grid); G_END_DECLS # 39 "gui.c" 2 # 1 "/usr/include/math.h" 1 3 4 # 30 "/usr/include/math.h" 3 4 # 1 "/usr/include/bits/huge_val.h" 1 3 4 # 35 "/usr/include/math.h" 2 3 4 # 47 "/usr/include/math.h" 3 4 # 1 "/usr/include/bits/mathdef.h" 1 3 4 # 48 "/usr/include/math.h" 2 3 4 # 71 "/usr/include/math.h" 3 4 # 1 "/usr/include/bits/mathcalls.h" 1 3 4 # 53 "/usr/include/bits/mathcalls.h" 3 4 extern double acos (double __x) ; extern double __acos (double __x) ; extern double asin (double __x) ; extern double __asin (double __x) ; extern double atan (double __x) ; extern double __atan (double __x) ; extern double atan2 (double __y, double __x) ; extern double __atan2 (double __y, double __x) ; extern double cos (double __x) ; extern double __cos (double __x) ; extern double sin (double __x) ; extern double __sin (double __x) ; extern double tan (double __x) ; extern double __tan (double __x) ; extern double cosh (double __x) ; extern double __cosh (double __x) ; extern double sinh (double __x) ; extern double __sinh (double __x) ; extern double tanh (double __x) ; extern double __tanh (double __x) ; # 87 "/usr/include/bits/mathcalls.h" 3 4 extern double acosh (double __x) ; extern double __acosh (double __x) ; extern double asinh (double __x) ; extern double __asinh (double __x) ; extern double atanh (double __x) ; extern double __atanh (double __x) ; extern double exp (double __x) ; extern double __exp (double __x) ; extern double frexp (double __x, int *__exponent) ; extern double __frexp (double __x, int *__exponent) ; extern double ldexp (double __x, int __exponent) ; extern double __ldexp (double __x, int __exponent) ; extern double log (double __x) ; extern double __log (double __x) ; extern double log10 (double __x) ; extern double __log10 (double __x) ; extern double modf (double __x, double *__iptr) ; extern double __modf (double __x, double *__iptr) ; # 127 "/usr/include/bits/mathcalls.h" 3 4 extern double expm1 (double __x) ; extern double __expm1 (double __x) ; extern double log1p (double __x) ; extern double __log1p (double __x) ; extern double logb (double __x) ; extern double __logb (double __x) ; # 152 "/usr/include/bits/mathcalls.h" 3 4 extern double pow (double __x, double __y) ; extern double __pow (double __x, double __y) ; extern double sqrt (double __x) ; extern double __sqrt (double __x) ; extern double hypot (double __x, double __y) ; extern double __hypot (double __x, double __y) ; extern double cbrt (double __x) ; extern double __cbrt (double __x) ; extern double ceil (double __x) ; extern double __ceil (double __x) ; extern double fabs (double __x) ; extern double __fabs (double __x) ; extern double floor (double __x) ; extern double __floor (double __x) ; extern double fmod (double __x, double __y) ; extern double __fmod (double __x, double __y) ; extern int __isinf (double __value) ; extern int __finite (double __value) ; extern int isinf (double __value) ; extern int finite (double __value) ; extern double drem (double __x, double __y) ; extern double __drem (double __x, double __y) ; extern double significand (double __x) ; extern double __significand (double __x) ; extern double copysign (double __x, double __y) ; extern double __copysign (double __x, double __y) ; # 231 "/usr/include/bits/mathcalls.h" 3 4 extern int __isnan (double __value) ; extern int isnan (double __value) ; extern double j0 (double) ; extern double __j0 (double) ; extern double j1 (double) ; extern double __j1 (double) ; extern double jn (int, double) ; extern double __jn (int, double) ; extern double y0 (double) ; extern double __y0 (double) ; extern double y1 (double) ; extern double __y1 (double) ; extern double yn (int, double) ; extern double __yn (int, double) ; extern double erf (double) ; extern double __erf (double) ; extern double erfc (double) ; extern double __erfc (double) ; extern double lgamma (double) ; extern double __lgamma (double) ; # 265 "/usr/include/bits/mathcalls.h" 3 4 extern double gamma (double) ; extern double __gamma (double) ; extern double lgamma_r (double, int *__signgamp) ; extern double __lgamma_r (double, int *__signgamp) ; extern double rint (double __x) ; extern double __rint (double __x) ; extern double nextafter (double __x, double __y) ; extern double __nextafter (double __x, double __y) ; extern double remainder (double __x, double __y) ; extern double __remainder (double __x, double __y) ; extern double scalbn (double __x, int __n) ; extern double __scalbn (double __x, int __n) ; extern int ilogb (double __x) ; extern int __ilogb (double __x) ; # 359 "/usr/include/bits/mathcalls.h" 3 4 extern double scalb (double __x, double __n) ; extern double __scalb (double __x, double __n) ; # 72 "/usr/include/math.h" 2 3 4 # 94 "/usr/include/math.h" 3 4 # 1 "/usr/include/bits/mathcalls.h" 1 3 4 # 53 "/usr/include/bits/mathcalls.h" 3 4 extern float acosf (float __x) ; extern float __acosf (float __x) ; extern float asinf (float __x) ; extern float __asinf (float __x) ; extern float atanf (float __x) ; extern float __atanf (float __x) ; extern float atan2f (float __y, float __x) ; extern float __atan2f (float __y, float __x) ; extern float cosf (float __x) ; extern float __cosf (float __x) ; extern float sinf (float __x) ; extern float __sinf (float __x) ; extern float tanf (float __x) ; extern float __tanf (float __x) ; extern float coshf (float __x) ; extern float __coshf (float __x) ; extern float sinhf (float __x) ; extern float __sinhf (float __x) ; extern float tanhf (float __x) ; extern float __tanhf (float __x) ; # 87 "/usr/include/bits/mathcalls.h" 3 4 extern float acoshf (float __x) ; extern float __acoshf (float __x) ; extern float asinhf (float __x) ; extern float __asinhf (float __x) ; extern float atanhf (float __x) ; extern float __atanhf (float __x) ; extern float expf (float __x) ; extern float __expf (float __x) ; extern float frexpf (float __x, int *__exponent) ; extern float __frexpf (float __x, int *__exponent) ; extern float ldexpf (float __x, int __exponent) ; extern float __ldexpf (float __x, int __exponent) ; extern float logf (float __x) ; extern float __logf (float __x) ; extern float log10f (float __x) ; extern float __log10f (float __x) ; extern float modff (float __x, float *__iptr) ; extern float __modff (float __x, float *__iptr) ; # 127 "/usr/include/bits/mathcalls.h" 3 4 extern float expm1f (float __x) ; extern float __expm1f (float __x) ; extern float log1pf (float __x) ; extern float __log1pf (float __x) ; extern float logbf (float __x) ; extern float __logbf (float __x) ; # 152 "/usr/include/bits/mathcalls.h" 3 4 extern float powf (float __x, float __y) ; extern float __powf (float __x, float __y) ; extern float sqrtf (float __x) ; extern float __sqrtf (float __x) ; extern float hypotf (float __x, float __y) ; extern float __hypotf (float __x, float __y) ; extern float cbrtf (float __x) ; extern float __cbrtf (float __x) ; extern float ceilf (float __x) ; extern float __ceilf (float __x) ; extern float fabsf (float __x) ; extern float __fabsf (float __x) ; extern float floorf (float __x) ; extern float __floorf (float __x) ; extern float fmodf (float __x, float __y) ; extern float __fmodf (float __x, float __y) ; extern int __isinff (float __value) ; extern int __finitef (float __value) ; extern int isinff (float __value) ; extern int finitef (float __value) ; extern float dremf (float __x, float __y) ; extern float __dremf (float __x, float __y) ; extern float significandf (float __x) ; extern float __significandf (float __x) ; extern float copysignf (float __x, float __y) ; extern float __copysignf (float __x, float __y) ; # 231 "/usr/include/bits/mathcalls.h" 3 4 extern int __isnanf (float __value) ; extern int isnanf (float __value) ; extern float j0f (float) ; extern float __j0f (float) ; extern float j1f (float) ; extern float __j1f (float) ; extern float jnf (int, float) ; extern float __jnf (int, float) ; extern float y0f (float) ; extern float __y0f (float) ; extern float y1f (float) ; extern float __y1f (float) ; extern float ynf (int, float) ; extern float __ynf (int, float) ; extern float erff (float) ; extern float __erff (float) ; extern float erfcf (float) ; extern float __erfcf (float) ; extern float lgammaf (float) ; extern float __lgammaf (float) ; # 265 "/usr/include/bits/mathcalls.h" 3 4 extern float gammaf (float) ; extern float __gammaf (float) ; extern float lgammaf_r (float, int *__signgamp) ; extern float __lgammaf_r (float, int *__signgamp) ; extern float rintf (float __x) ; extern float __rintf (float __x) ; extern float nextafterf (float __x, float __y) ; extern float __nextafterf (float __x, float __y) ; extern float remainderf (float __x, float __y) ; extern float __remainderf (float __x, float __y) ; extern float scalbnf (float __x, int __n) ; extern float __scalbnf (float __x, int __n) ; extern int ilogbf (float __x) ; extern int __ilogbf (float __x) ; # 359 "/usr/include/bits/mathcalls.h" 3 4 extern float scalbf (float __x, float __n) ; extern float __scalbf (float __x, float __n) ; # 95 "/usr/include/math.h" 2 3 4 # 141 "/usr/include/math.h" 3 4 # 1 "/usr/include/bits/mathcalls.h" 1 3 4 # 53 "/usr/include/bits/mathcalls.h" 3 4 extern long double acosl (long double __x) ; extern long double __acosl (long double __x) ; extern long double asinl (long double __x) ; extern long double __asinl (long double __x) ; extern long double atanl (long double __x) ; extern long double __atanl (long double __x) ; extern long double atan2l (long double __y, long double __x) ; extern long double __atan2l (long double __y, long double __x) ; extern long double cosl (long double __x) ; extern long double __cosl (long double __x) ; extern long double sinl (long double __x) ; extern long double __sinl (long double __x) ; extern long double tanl (long double __x) ; extern long double __tanl (long double __x) ; extern long double coshl (long double __x) ; extern long double __coshl (long double __x) ; extern long double sinhl (long double __x) ; extern long double __sinhl (long double __x) ; extern long double tanhl (long double __x) ; extern long double __tanhl (long double __x) ; # 87 "/usr/include/bits/mathcalls.h" 3 4 extern long double acoshl (long double __x) ; extern long double __acoshl (long double __x) ; extern long double asinhl (long double __x) ; extern long double __asinhl (long double __x) ; extern long double atanhl (long double __x) ; extern long double __atanhl (long double __x) ; extern long double expl (long double __x) ; extern long double __expl (long double __x) ; extern long double frexpl (long double __x, int *__exponent) ; extern long double __frexpl (long double __x, int *__exponent) ; extern long double ldexpl (long double __x, int __exponent) ; extern long double __ldexpl (long double __x, int __exponent) ; extern long double logl (long double __x) ; extern long double __logl (long double __x) ; extern long double log10l (long double __x) ; extern long double __log10l (long double __x) ; extern long double modfl (long double __x, long double *__iptr) ; extern long double __modfl (long double __x, long double *__iptr) ; # 127 "/usr/include/bits/mathcalls.h" 3 4 extern long double expm1l (long double __x) ; extern long double __expm1l (long double __x) ; extern long double log1pl (long double __x) ; extern long double __log1pl (long double __x) ; extern long double logbl (long double __x) ; extern long double __logbl (long double __x) ; # 152 "/usr/include/bits/mathcalls.h" 3 4 extern long double powl (long double __x, long double __y) ; extern long double __powl (long double __x, long double __y) ; extern long double sqrtl (long double __x) ; extern long double __sqrtl (long double __x) ; extern long double hypotl (long double __x, long double __y) ; extern long double __hypotl (long double __x, long double __y) ; extern long double cbrtl (long double __x) ; extern long double __cbrtl (long double __x) ; extern long double ceill (long double __x) ; extern long double __ceill (long double __x) ; extern long double fabsl (long double __x) ; extern long double __fabsl (long double __x) ; extern long double floorl (long double __x) ; extern long double __floorl (long double __x) ; extern long double fmodl (long double __x, long double __y) ; extern long double __fmodl (long double __x, long double __y) ; extern int __isinfl (long double __value) ; extern int __finitel (long double __value) ; extern int isinfl (long double __value) ; extern int finitel (long double __value) ; extern long double dreml (long double __x, long double __y) ; extern long double __dreml (long double __x, long double __y) ; extern long double significandl (long double __x) ; extern long double __significandl (long double __x) ; extern long double copysignl (long double __x, long double __y) ; extern long double __copysignl (long double __x, long double __y) ; # 231 "/usr/include/bits/mathcalls.h" 3 4 extern int __isnanl (long double __value) ; extern int isnanl (long double __value) ; extern long double j0l (long double) ; extern long double __j0l (long double) ; extern long double j1l (long double) ; extern long double __j1l (long double) ; extern long double jnl (int, long double) ; extern long double __jnl (int, long double) ; extern long double y0l (long double) ; extern long double __y0l (long double) ; extern long double y1l (long double) ; extern long double __y1l (long double) ; extern long double ynl (int, long double) ; extern long double __ynl (int, long double) ; extern long double erfl (long double) ; extern long double __erfl (long double) ; extern long double erfcl (long double) ; extern long double __erfcl (long double) ; extern long double lgammal (long double) ; extern long double __lgammal (long double) ; # 265 "/usr/include/bits/mathcalls.h" 3 4 extern long double gammal (long double) ; extern long double __gammal (long double) ; extern long double lgammal_r (long double, int *__signgamp) ; extern long double __lgammal_r (long double, int *__signgamp) ; extern long double rintl (long double __x) ; extern long double __rintl (long double __x) ; extern long double nextafterl (long double __x, long double __y) ; extern long double __nextafterl (long double __x, long double __y) ; extern long double remainderl (long double __x, long double __y) ; extern long double __remainderl (long double __x, long double __y) ; extern long double scalbnl (long double __x, int __n) ; extern long double __scalbnl (long double __x, int __n) ; extern int ilogbl (long double __x) ; extern int __ilogbl (long double __x) ; # 359 "/usr/include/bits/mathcalls.h" 3 4 extern long double scalbl (long double __x, long double __n) ; extern long double __scalbl (long double __x, long double __n) ; # 142 "/usr/include/math.h" 2 3 4 # 157 "/usr/include/math.h" 3 4 extern int signgam; # 284 "/usr/include/math.h" 3 4 typedef enum { _IEEE_ = -1, _SVID_, _XOPEN_, _POSIX_, _ISOC_ } _LIB_VERSION_TYPE; extern _LIB_VERSION_TYPE _LIB_VERSION; # 309 "/usr/include/math.h" 3 4 struct exception { int type; char *name; double arg1; double arg2; double retval; }; extern int matherr (struct exception *__exc); # 465 "/usr/include/math.h" 3 4 # 41 "gui.c" 2 # 1 "/usr/include/errno.h" 1 3 4 # 32 "/usr/include/errno.h" 3 4 # 1 "/usr/include/bits/errno.h" 1 3 4 # 25 "/usr/include/bits/errno.h" 3 4 # 1 "/usr/include/linux/errno.h" 1 3 4 # 1 "/usr/include/asm/errno.h" 1 3 4 # 1 "/usr/include/asm-generic/errno.h" 1 3 4 # 1 "/usr/include/asm-generic/errno-base.h" 1 3 4 # 5 "/usr/include/asm-generic/errno.h" 2 3 4 # 1 "/usr/include/asm/errno.h" 2 3 4 # 5 "/usr/include/linux/errno.h" 2 3 4 # 26 "/usr/include/bits/errno.h" 2 3 4 # 43 "/usr/include/bits/errno.h" 3 4 extern int *__errno_location (void) ; # 37 "/usr/include/errno.h" 2 3 4 # 59 "/usr/include/errno.h" 3 4 # 42 "gui.c" 2 # 1 "/usr/include/string.h" 1 3 4 # 28 "/usr/include/string.h" 3 4 # 1 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 1 3 4 # 34 "/usr/include/string.h" 2 3 4 extern void *memcpy (void * __dest, const void * __src, size_t __n) ; extern void *memmove (void *__dest, const void *__src, size_t __n) ; extern void *memccpy (void * __dest, const void * __src, int __c, size_t __n) ; extern void *memset (void *__s, int __c, size_t __n) ; extern int memcmp (const void *__s1, const void *__s2, size_t __n) ; extern void *memchr (const void *__s, int __c, size_t __n) ; # 82 "/usr/include/string.h" 3 4 extern char *strcpy (char * __dest, const char * __src) ; extern char *strncpy (char * __dest, const char * __src, size_t __n) ; extern char *strcat (char * __dest, const char * __src) ; extern char *strncat (char * __dest, const char * __src, size_t __n) ; extern int strcmp (const char *__s1, const char *__s2) ; extern int strncmp (const char *__s1, const char *__s2, size_t __n) ; extern int strcoll (const char *__s1, const char *__s2) ; extern size_t strxfrm (char * __dest, const char * __src, size_t __n) ; # 130 "/usr/include/string.h" 3 4 extern char *strdup (const char *__s) ; # 165 "/usr/include/string.h" 3 4 extern char *strchr (const char *__s, int __c) ; extern char *strrchr (const char *__s, int __c) ; # 181 "/usr/include/string.h" 3 4 extern size_t strcspn (const char *__s, const char *__reject) ; extern size_t strspn (const char *__s, const char *__accept) ; extern char *strpbrk (const char *__s, const char *__accept) ; extern char *strstr (const char *__haystack, const char *__needle) ; extern char *strtok (char * __s, const char * __delim) ; extern char *__strtok_r (char * __s, const char * __delim, char ** __save_ptr) ; extern char *strtok_r (char * __s, const char * __delim, char ** __save_ptr) ; # 240 "/usr/include/string.h" 3 4 extern size_t strlen (const char *__s) ; # 254 "/usr/include/string.h" 3 4 extern char *strerror (int __errnum) ; # 270 "/usr/include/string.h" 3 4 extern int strerror_r (int __errnum, char *__buf, size_t __buflen) __asm__ ("" "__xpg_strerror_r") ; # 294 "/usr/include/string.h" 3 4 extern void __bzero (void *__s, size_t __n) ; extern void bcopy (const void *__src, void *__dest, size_t __n) ; extern void bzero (void *__s, size_t __n) ; extern int bcmp (const void *__s1, const void *__s2, size_t __n) ; extern char *index (const char *__s, int __c) ; extern char *rindex (const char *__s, int __c) ; extern int ffs (int __i) ; # 331 "/usr/include/string.h" 3 4 extern int strcasecmp (const char *__s1, const char *__s2) ; extern int strncasecmp (const char *__s1, const char *__s2, size_t __n) ; # 354 "/usr/include/string.h" 3 4 extern char *strsep (char ** __stringp, const char * __delim) ; # 432 "/usr/include/string.h" 3 4 # 43 "gui.c" 2 # 1 "gui.h" 1 # 23 "gui.h" # 1 "main.h" 1 # 27 "main.h" # 1 "/usr/include/fftw.h" 1 3 4 # 28 "/usr/include/fftw.h" 3 4 # 1 "/usr/include/stdlib.h" 1 3 4 # 33 "/usr/include/stdlib.h" 3 4 # 1 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 1 3 4 # 326 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 3 4 typedef int wchar_t; # 34 "/usr/include/stdlib.h" 2 3 4 # 96 "/usr/include/stdlib.h" 3 4 typedef struct { int quot; int rem; } div_t; typedef struct { long int quot; long int rem; } ldiv_t; # 140 "/usr/include/stdlib.h" 3 4 extern size_t __ctype_get_mb_cur_max (void) ; extern double atof (const char *__nptr) ; extern int atoi (const char *__nptr) ; extern long int atol (const char *__nptr) ; extern long long int atoll (const char *__nptr) ; extern double strtod (const char * __nptr, char ** __endptr) ; # 182 "/usr/include/stdlib.h" 3 4 extern long int strtol (const char * __nptr, char ** __endptr, int __base) ; extern unsigned long int strtoul (const char * __nptr, char ** __endptr, int __base) ; extern long long int strtoq (const char * __nptr, char ** __endptr, int __base) ; extern unsigned long long int strtouq (const char * __nptr, char ** __endptr, int __base) ; extern long long int strtoll (const char * __nptr, char ** __endptr, int __base) ; extern unsigned long long int strtoull (const char * __nptr, char ** __endptr, int __base) ; # 311 "/usr/include/stdlib.h" 3 4 extern char *l64a (long int __n) ; extern long int a64l (const char *__s) ; # 1 "/usr/include/sys/types.h" 1 3 4 # 29 "/usr/include/sys/types.h" 3 4 typedef __u_char u_char; typedef __u_short u_short; typedef __u_int u_int; typedef __u_long u_long; typedef __quad_t quad_t; typedef __u_quad_t u_quad_t; typedef __fsid_t fsid_t; typedef __loff_t loff_t; typedef __ino_t ino_t; # 62 "/usr/include/sys/types.h" 3 4 typedef __dev_t dev_t; typedef __gid_t gid_t; typedef __mode_t mode_t; typedef __nlink_t nlink_t; typedef __uid_t uid_t; typedef __off_t off_t; # 100 "/usr/include/sys/types.h" 3 4 typedef __pid_t pid_t; typedef __id_t id_t; typedef __ssize_t ssize_t; typedef __daddr_t daddr_t; typedef __caddr_t caddr_t; typedef __key_t key_t; # 133 "/usr/include/sys/types.h" 3 4 # 1 "/usr/include/time.h" 1 3 4 # 75 "/usr/include/time.h" 3 4 typedef __time_t time_t; # 93 "/usr/include/time.h" 3 4 typedef __clockid_t clockid_t; # 105 "/usr/include/time.h" 3 4 typedef __timer_t timer_t; # 134 "/usr/include/sys/types.h" 2 3 4 # 147 "/usr/include/sys/types.h" 3 4 # 1 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 1 3 4 # 148 "/usr/include/sys/types.h" 2 3 4 typedef unsigned long int ulong; typedef unsigned short int ushort; typedef unsigned int uint; # 195 "/usr/include/sys/types.h" 3 4 typedef int int8_t ; typedef int int16_t ; typedef int int32_t ; typedef int int64_t ; typedef unsigned int u_int8_t ; typedef unsigned int u_int16_t ; typedef unsigned int u_int32_t ; typedef unsigned int u_int64_t ; typedef int register_t ; # 217 "/usr/include/sys/types.h" 3 4 # 1 "/usr/include/endian.h" 1 3 4 # 37 "/usr/include/endian.h" 3 4 # 1 "/usr/include/bits/endian.h" 1 3 4 # 38 "/usr/include/endian.h" 2 3 4 # 218 "/usr/include/sys/types.h" 2 3 4 # 1 "/usr/include/sys/select.h" 1 3 4 # 31 "/usr/include/sys/select.h" 3 4 # 1 "/usr/include/bits/select.h" 1 3 4 # 32 "/usr/include/sys/select.h" 2 3 4 # 1 "/usr/include/bits/sigset.h" 1 3 4 # 24 "/usr/include/bits/sigset.h" 3 4 typedef int __sig_atomic_t; typedef struct { unsigned long int __val[(1024 / (8 * sizeof (unsigned long int)))]; } __sigset_t; # 35 "/usr/include/sys/select.h" 2 3 4 typedef __sigset_t sigset_t; # 1 "/usr/include/time.h" 1 3 4 # 121 "/usr/include/time.h" 3 4 struct timespec { __time_t tv_sec; long int tv_nsec; }; # 45 "/usr/include/sys/select.h" 2 3 4 # 1 "/usr/include/bits/time.h" 1 3 4 # 69 "/usr/include/bits/time.h" 3 4 struct timeval { __time_t tv_sec; __suseconds_t tv_usec; }; # 47 "/usr/include/sys/select.h" 2 3 4 typedef __suseconds_t suseconds_t; typedef long int __fd_mask; # 67 "/usr/include/sys/select.h" 3 4 typedef struct { __fd_mask __fds_bits[1024 / (8 * sizeof (__fd_mask))]; } fd_set; typedef __fd_mask fd_mask; # 99 "/usr/include/sys/select.h" 3 4 # 109 "/usr/include/sys/select.h" 3 4 extern int select (int __nfds, fd_set * __readfds, fd_set * __writefds, fd_set * __exceptfds, struct timeval * __timeout); # 121 "/usr/include/sys/select.h" 3 4 extern int pselect (int __nfds, fd_set * __readfds, fd_set * __writefds, fd_set * __exceptfds, const struct timespec * __timeout, const __sigset_t * __sigmask); # 221 "/usr/include/sys/types.h" 2 3 4 # 1 "/usr/include/sys/sysmacros.h" 1 3 4 # 30 "/usr/include/sys/sysmacros.h" 3 4 extern unsigned int gnu_dev_major (unsigned long long int __dev) ; extern unsigned int gnu_dev_minor (unsigned long long int __dev) ; extern unsigned long long int gnu_dev_makedev (unsigned int __major, unsigned int __minor) ; # 224 "/usr/include/sys/types.h" 2 3 4 # 235 "/usr/include/sys/types.h" 3 4 typedef __blkcnt_t blkcnt_t; typedef __fsblkcnt_t fsblkcnt_t; typedef __fsfilcnt_t fsfilcnt_t; # 270 "/usr/include/sys/types.h" 3 4 # 1 "/usr/include/bits/pthreadtypes.h" 1 3 4 # 23 "/usr/include/bits/pthreadtypes.h" 3 4 # 1 "/usr/include/bits/wordsize.h" 1 3 4 # 24 "/usr/include/bits/pthreadtypes.h" 2 3 4 # 50 "/usr/include/bits/pthreadtypes.h" 3 4 typedef unsigned long int pthread_t; typedef union { char __size[56]; long int __align; } pthread_attr_t; typedef struct __pthread_internal_list { struct __pthread_internal_list *__prev; struct __pthread_internal_list *__next; } __pthread_list_t; # 76 "/usr/include/bits/pthreadtypes.h" 3 4 typedef union { struct __pthread_mutex_s { int __lock; unsigned int __count; int __owner; unsigned int __nusers; int __kind; int __spins; __pthread_list_t __list; # 101 "/usr/include/bits/pthreadtypes.h" 3 4 } __data; char __size[40]; long int __align; } pthread_mutex_t; typedef union { char __size[4]; int __align; } pthread_mutexattr_t; typedef union { struct { int __lock; unsigned int __futex; unsigned long long int __total_seq; unsigned long long int __wakeup_seq; unsigned long long int __woken_seq; void *__mutex; unsigned int __nwaiters; unsigned int __broadcast_seq; } __data; char __size[48]; long long int __align; } pthread_cond_t; typedef union { char __size[4]; int __align; } pthread_condattr_t; typedef unsigned int pthread_key_t; typedef int pthread_once_t; typedef union { struct { int __lock; unsigned int __nr_readers; unsigned int __readers_wakeup; unsigned int __writer_wakeup; unsigned int __nr_readers_queued; unsigned int __nr_writers_queued; int __writer; int __shared; unsigned long int __pad1; unsigned long int __pad2; unsigned int __flags; } __data; # 187 "/usr/include/bits/pthreadtypes.h" 3 4 char __size[56]; long int __align; } pthread_rwlock_t; typedef union { char __size[8]; long int __align; } pthread_rwlockattr_t; typedef volatile int pthread_spinlock_t; typedef union { char __size[32]; long int __align; } pthread_barrier_t; typedef union { char __size[4]; int __align; } pthread_barrierattr_t; # 271 "/usr/include/sys/types.h" 2 3 4 # 321 "/usr/include/stdlib.h" 2 3 4 extern long int random (void) ; extern void srandom (unsigned int __seed) ; extern char *initstate (unsigned int __seed, char *__statebuf, size_t __statelen) ; extern char *setstate (char *__statebuf) ; struct random_data { int32_t *fptr; int32_t *rptr; int32_t *state; int rand_type; int rand_deg; int rand_sep; int32_t *end_ptr; }; extern int random_r (struct random_data * __buf, int32_t * __result) ; extern int srandom_r (unsigned int __seed, struct random_data *__buf) ; extern int initstate_r (unsigned int __seed, char * __statebuf, size_t __statelen, struct random_data * __buf) ; extern int setstate_r (char * __statebuf, struct random_data * __buf) ; extern int rand (void) ; extern void srand (unsigned int __seed) ; extern int rand_r (unsigned int *__seed) ; extern double drand48 (void) ; extern double erand48 (unsigned short int __xsubi[3]) ; extern long int lrand48 (void) ; extern long int nrand48 (unsigned short int __xsubi[3]) ; extern long int mrand48 (void) ; extern long int jrand48 (unsigned short int __xsubi[3]) ; extern void srand48 (long int __seedval) ; extern unsigned short int *seed48 (unsigned short int __seed16v[3]) ; extern void lcong48 (unsigned short int __param[7]) ; struct drand48_data { unsigned short int __x[3]; unsigned short int __old_x[3]; unsigned short int __c; unsigned short int __init; unsigned long long int __a; }; extern int drand48_r (struct drand48_data * __buffer, double * __result) ; extern int erand48_r (unsigned short int __xsubi[3], struct drand48_data * __buffer, double * __result) ; extern int lrand48_r (struct drand48_data * __buffer, long int * __result) ; extern int nrand48_r (unsigned short int __xsubi[3], struct drand48_data * __buffer, long int * __result) ; extern int mrand48_r (struct drand48_data * __buffer, long int * __result) ; extern int jrand48_r (unsigned short int __xsubi[3], struct drand48_data * __buffer, long int * __result) ; extern int srand48_r (long int __seedval, struct drand48_data *__buffer) ; extern int seed48_r (unsigned short int __seed16v[3], struct drand48_data *__buffer) ; extern int lcong48_r (unsigned short int __param[7], struct drand48_data *__buffer) ; extern void *malloc (size_t __size) ; extern void *calloc (size_t __nmemb, size_t __size) ; extern void *realloc (void *__ptr, size_t __size) ; extern void free (void *__ptr) ; extern void cfree (void *__ptr) ; # 1 "/usr/include/alloca.h" 1 3 4 # 25 "/usr/include/alloca.h" 3 4 # 1 "/usr/lib/gcc/x86_64-linux-gnu/4.3.2/include/stddef.h" 1 3 4 # 26 "/usr/include/alloca.h" 2 3 4 extern void *alloca (size_t __size) ; # 498 "/usr/include/stdlib.h" 2 3 4 extern void *valloc (size_t __size) ; extern int posix_memalign (void **__memptr, size_t __alignment, size_t __size) ; extern void abort (void) ; extern int atexit (void (*__func) (void)) ; extern int on_exit (void (*__func) (int __status, void *__arg), void *__arg) ; extern void exit (int __status) ; # 543 "/usr/include/stdlib.h" 3 4 extern char *getenv (const char *__name) ; extern char *__secure_getenv (const char *__name) ; extern int putenv (char *__string) ; extern int setenv (const char *__name, const char *__value, int __replace) ; extern int unsetenv (const char *__name) ; extern int clearenv (void) ; # 583 "/usr/include/stdlib.h" 3 4 extern char *mktemp (char *__template) ; # 594 "/usr/include/stdlib.h" 3 4 extern int mkstemp (char *__template) ; # 614 "/usr/include/stdlib.h" 3 4 extern char *mkdtemp (char *__template) ; # 640 "/usr/include/stdlib.h" 3 4 extern int system (const char *__command) ; # 662 "/usr/include/stdlib.h" 3 4 extern char *realpath (const char * __name, char * __resolved) ; typedef int (*__compar_fn_t) (const void *, const void *); # 680 "/usr/include/stdlib.h" 3 4 extern void *bsearch (const void *__key, const void *__base, size_t __nmemb, size_t __size, __compar_fn_t __compar) ; extern void qsort (void *__base, size_t __nmemb, size_t __size, __compar_fn_t __compar) ; # 699 "/usr/include/stdlib.h" 3 4 extern int abs (int __x) ; extern long int labs (long int __x) ; extern div_t div (int __numer, int __denom) ; extern ldiv_t ldiv (long int __numer, long int __denom) ; # 735 "/usr/include/stdlib.h" 3 4 extern char *ecvt (double __value, int __ndigit, int * __decpt, int * __sign) ; extern char *fcvt (double __value, int __ndigit, int * __decpt, int * __sign) ; extern char *gcvt (double __value, int __ndigit, char *__buf) ; extern char *qecvt (long double __value, int __ndigit, int * __decpt, int * __sign) ; extern char *qfcvt (long double __value, int __ndigit, int * __decpt, int * __sign) ; extern char *qgcvt (long double __value, int __ndigit, char *__buf) ; extern int ecvt_r (double __value, int __ndigit, int * __decpt, int * __sign, char * __buf, size_t __len) ; extern int fcvt_r (double __value, int __ndigit, int * __decpt, int * __sign, char * __buf, size_t __len) ; extern int qecvt_r (long double __value, int __ndigit, int * __decpt, int * __sign, char * __buf, size_t __len) ; extern int qfcvt_r (long double __value, int __ndigit, int * __decpt, int * __sign, char * __buf, size_t __len) ; extern int mblen (const char *__s, size_t __n) ; extern int mbtowc (wchar_t * __pwc, const char * __s, size_t __n) ; extern int wctomb (char *__s, wchar_t __wchar) ; extern size_t mbstowcs (wchar_t * __pwcs, const char * __s, size_t __n) ; extern size_t wcstombs (char * __s, const wchar_t * __pwcs, size_t __n) ; extern int rpmatch (const char *__response) ; # 840 "/usr/include/stdlib.h" 3 4 extern int posix_openpt (int __oflag) ; # 875 "/usr/include/stdlib.h" 3 4 extern int getloadavg (double __loadavg[], int __nelem) ; # 891 "/usr/include/stdlib.h" 3 4 # 29 "/usr/include/fftw.h" 2 3 4 # 46 "/usr/include/fftw.h" 3 4 typedef double fftw_real; typedef struct { fftw_real re, im; } fftw_complex; typedef enum { FFTW_FORWARD = -1, FFTW_BACKWARD = 1 } fftw_direction; typedef fftw_complex FFTW_COMPLEX; typedef fftw_real FFTW_REAL; # 81 "/usr/include/fftw.h" 3 4 typedef enum { FFTW_SUCCESS = 0, FFTW_FAILURE = -1 } fftw_status; typedef void (fftw_notw_codelet) (const fftw_complex *, fftw_complex *, int, int); typedef void (fftw_twiddle_codelet) (fftw_complex *, const fftw_complex *, int, int, int); typedef void (fftw_generic_codelet) (fftw_complex *, const fftw_complex *, int, int, int, int); typedef void (fftw_real2hc_codelet) (const fftw_real *, fftw_real *, fftw_real *, int, int, int); typedef void (fftw_hc2real_codelet) (const fftw_real *, const fftw_real *, fftw_real *, int, int, int); typedef void (fftw_hc2hc_codelet) (fftw_real *, const fftw_complex *, int, int, int); typedef void (fftw_rgeneric_codelet) (fftw_real *, const fftw_complex *, int, int, int, int); # 116 "/usr/include/fftw.h" 3 4 enum fftw_node_type { FFTW_NOTW, FFTW_TWIDDLE, FFTW_GENERIC, FFTW_RADER, FFTW_REAL2HC, FFTW_HC2REAL, FFTW_HC2HC, FFTW_RGENERIC }; typedef struct { const char *name; void (*codelet) (); int size; fftw_direction dir; enum fftw_node_type type; int signature; int ntwiddle; const int *twiddle_order; } fftw_codelet_desc; # 151 "/usr/include/fftw.h" 3 4 extern const char * fftw_version; # 166 "/usr/include/fftw.h" 3 4 typedef struct fftw_twiddle_struct { int n; const fftw_codelet_desc *cdesc; fftw_complex *twarray; struct fftw_twiddle_struct *next; int refcnt; } fftw_twiddle; typedef struct fftw_rader_data_struct { struct fftw_plan_struct *plan; fftw_complex *omega; int g, ginv; int p, flags, refcount; struct fftw_rader_data_struct *next; fftw_codelet_desc *cdesc; } fftw_rader_data; typedef void (fftw_rader_codelet) (fftw_complex *, const fftw_complex *, int, int, int, fftw_rader_data *); typedef struct fftw_plan_node_struct { enum fftw_node_type type; union { struct { int size; fftw_notw_codelet *codelet; const fftw_codelet_desc *codelet_desc; } notw; struct { int size; fftw_twiddle_codelet *codelet; fftw_twiddle *tw; struct fftw_plan_node_struct *recurse; const fftw_codelet_desc *codelet_desc; } twiddle; struct { int size; fftw_generic_codelet *codelet; fftw_twiddle *tw; struct fftw_plan_node_struct *recurse; } generic; struct { int size; fftw_rader_codelet *codelet; fftw_rader_data *rader_data; fftw_twiddle *tw; struct fftw_plan_node_struct *recurse; } rader; struct { int size; fftw_real2hc_codelet *codelet; const fftw_codelet_desc *codelet_desc; } real2hc; struct { int size; fftw_hc2real_codelet *codelet; const fftw_codelet_desc *codelet_desc; } hc2real; struct { int size; fftw_direction dir; fftw_hc2hc_codelet *codelet; fftw_twiddle *tw; struct fftw_plan_node_struct *recurse; const fftw_codelet_desc *codelet_desc; } hc2hc; struct { int size; fftw_direction dir; fftw_rgeneric_codelet *codelet; fftw_twiddle *tw; struct fftw_plan_node_struct *recurse; } rgeneric; } nodeu; int refcnt; } fftw_plan_node; typedef enum { FFTW_NORMAL_RECURSE = 0, FFTW_VECTOR_RECURSE = 1 } fftw_recurse_kind; struct fftw_plan_struct { int n; int refcnt; fftw_direction dir; int flags; int wisdom_signature; enum fftw_node_type wisdom_type; struct fftw_plan_struct *next; fftw_plan_node *root; double cost; fftw_recurse_kind recurse_kind; int vector_size; }; typedef struct fftw_plan_struct *fftw_plan; # 301 "/usr/include/fftw.h" 3 4 extern fftw_plan fftw_create_plan_specific(int n, fftw_direction dir, int flags, fftw_complex *in, int istride, fftw_complex *out, int ostride); extern fftw_plan fftw_create_plan(int n, fftw_direction dir, int flags); extern void fftw_print_plan(fftw_plan plan); extern void fftw_destroy_plan(fftw_plan plan); extern void fftw(fftw_plan plan, int howmany, fftw_complex *in, int istride, int idist, fftw_complex *out, int ostride, int odist); extern void fftw_one(fftw_plan plan, fftw_complex *in, fftw_complex *out); extern void fftw_die(const char *s); extern void *fftw_malloc(size_t n); extern void fftw_free(void *p); extern void fftw_check_memory_leaks(void); extern void fftw_print_max_memory_usage(void); typedef void *(*fftw_malloc_type_function) (size_t n); typedef void (*fftw_free_type_function) (void *p); typedef void (*fftw_die_type_function) (const char *errString); extern fftw_malloc_type_function fftw_malloc_hook; extern fftw_free_type_function fftw_free_hook; extern fftw_die_type_function fftw_die_hook; extern size_t fftw_sizeof_fftw_real(void); extern void fftw_forget_wisdom(void); extern void fftw_export_wisdom(void (*emitter) (char c, void *), void *data); extern fftw_status fftw_import_wisdom(int (*g) (void *), void *data); extern void fftw_export_wisdom_to_file(FILE *output_file); extern fftw_status fftw_import_wisdom_from_file(FILE *input_file); extern char *fftw_export_wisdom_to_string(void); extern fftw_status fftw_import_wisdom_from_string(const char *input_string); extern void fftw_fprint_plan(FILE *f, fftw_plan plan); typedef struct { int is_in_place; int rank; int *n; fftw_direction dir; int *n_before; int *n_after; fftw_plan *plans; int nbuffers, nwork; fftw_complex *work; } fftwnd_data; typedef fftwnd_data *fftwnd_plan; extern fftwnd_plan fftw2d_create_plan(int nx, int ny, fftw_direction dir, int flags); extern fftwnd_plan fftw3d_create_plan(int nx, int ny, int nz, fftw_direction dir, int flags); extern fftwnd_plan fftwnd_create_plan(int rank, const int *n, fftw_direction dir, int flags); extern fftwnd_plan fftw2d_create_plan_specific(int nx, int ny, fftw_direction dir, int flags, fftw_complex *in, int istride, fftw_complex *out, int ostride); extern fftwnd_plan fftw3d_create_plan_specific(int nx, int ny, int nz, fftw_direction dir, int flags, fftw_complex *in, int istride, fftw_complex *out, int ostride); extern fftwnd_plan fftwnd_create_plan_specific(int rank, const int *n, fftw_direction dir, int flags, fftw_complex *in, int istride, fftw_complex *out, int ostride); extern void fftwnd_destroy_plan(fftwnd_plan plan); extern void fftwnd_fprint_plan(FILE *f, fftwnd_plan p); extern void fftwnd_print_plan(fftwnd_plan p); extern void fftwnd(fftwnd_plan plan, int howmany, fftw_complex *in, int istride, int idist, fftw_complex *out, int ostride, int odist); extern void fftwnd_one(fftwnd_plan p, fftw_complex *in, fftw_complex *out); # 28 "main.h" 2 struct dat { double k; }; struct FFT_Frame { fftw_plan plan; fftw_plan reverse_plan; short * prewin_buffer_data_1; short * prewin_buffer_data_2; short * buffer_data_1; short * buffer_data_2; double * fft_returned_1; double * fft_returned_2; double * rfft_returned_1; float volume_pink; char pink_muted; short * delay; int delay_size; char find_delay; char find_impulse; }; static gint MyGTKFunction (struct FFT_Frame * frame_data); # 24 "gui.h" 2 # 38 "gui.h" gboolean gui_idle_func (struct FFT_Frame * data); gboolean create_gui (struct FFT_Frame * data); # 44 "gui.c" 2 # 1 "testfft.h" 1 # 24 "testfft.h" # 1 "main.h" 1 # 25 "testfft.h" 2 # 39 "testfft.h" struct AUDIO_SESSION { fftw_plan plan; short * buffer_data; double * fft_returned; }; int fft_capture(struct FFT_Frame * session); int impulse_capture(struct FFT_Frame * session); # 45 "gui.c" 2 # 1 "config.h" 1 # 46 "gui.c" 2 static GdkPixmap *measured_pixmap = ((void *)0); static GdkPixmap *reference_pixmap = ((void *)0); static GtkWidget *measured_draw; static GtkWidget *reference_draw; static GtkDataboxGraph **graph; static GtkDataboxGraph *graph_impulse; static GtkWidget *box; static GtkWidget *impulse_box; static GtkWidget *about_me_window = ((void *)0); static GtkWidget *about_ok = ((void *)0); static GtkWidget *delay_window = ((void *)0); static GtkWidget *impulse_window = ((void *)0); static GtkWidget *volume_pink_gui = ((void *)0); static GtkWidget *pinknoise_button = ((void *)0); static GtkWidget *transfer_function_toggle = ((void *)0); static GtkWidget *buffer_button[5] = { ((void *)0), ((void *)0), ((void *)0), ((void *)0), ((void *)0) }; static GtkWidget *buffer_menu[5] = { ((void *)0), ((void *)0), ((void *)0), ((void *)0), ((void *)0) }; static gfloat volume_pink_value = 0; static gfloat *guiX = ((void *)0); static gfloat *guiY = ((void *)0); static gfloat *gui_impulse_Y = ((void *)0); static gfloat *gui_impulse_X = ((void *)0); static gfloat guiYBuf[5][8192/2]; static gfloat guiYBufAvgHold[8192/2]; static char* save_name = ((void *)0); static char * home_string, *file_path1, *file_path2; static char pinknoise_muted = 0; static char find_delay = 0; static char update_delay = 0; static char buffer[5] = {2, 2, 2, 2, 2}; static gfloat avg_gain = 0; static int buffer_last_clicked; static GtkWidget *bkg_dialog; static GtkWidget *cb; static GtkWidget *save_now; static GtkWidget *save_as; static GtkWidget *open_menuitem; static gint avg_index = 0; static gchar tf = 1; static gfloat avgY[8192/2][32]; static gint gui_idle = 0; static gfloat gui_frequency = 3. * G_PI / 2.; static GtkWidget *gui_label = ((void *)0); static GtkWidget *gui_db_label = ((void *)0); static GtkWidget *gui_status_delay_label = ((void *)0); static GtkWidget *gui_sb_label = ((void *)0); static GtkWidget *gui_sb = ((void *)0); static GtkWidget *open_dialog = ((void *)0); static GtkWidget *save_as_dialog = ((void *)0); static guint gui_counter = 0; static GdkColor background_color; static GdkColor grid_color; static GdkColor trace_transfer_color; static GdkColor trace_impulse_color; static GdkColor line_color[5] = { {0, 16384 ,16384 ,65535 }, {0, 0 ,65535 ,0 }, {0, 65535 ,0 ,0 }, {0, 65535 ,16384 ,65535 }, {0, 65535 ,65535 ,65535 } }; # 161 "gui.c" gboolean gui_idle_func (struct FFT_Frame *data) { gfloat tmp[8192/2]; gint smoothing; gint index; gint i; gint j, k; gint max; gfloat temp, max_x, min_x, max_y, min_y, tmp_spin; gchar * label = ((void *)0); GdkColor myColor1 = { 0, 0x3333, 0x3333, 0x3333 }; GdkColor myColor2 = { 0, 0x3333, 0x3333, 0x3333 }; GdkGC *gc1 = ((void *)0); GdkGC *gc2 = ((void *)0); if (!(G_TYPE_CHECK_INSTANCE_TYPE ((box), (gtk_databox_get_type ())))) { fprintf(stderr, "Box not a gtk_databox\n"); return FALSE; } gc1 = gdk_gc_new(measured_draw->window); gc2 = gdk_gc_new(reference_draw->window); data->pink_muted = pinknoise_muted; data->volume_pink = volume_pink_value; avg_index++; if (avg_index == 32) avg_index = 0; min_y = 0.0; max_y = 0.0; if (data->find_impulse == 2) { for (i = 0; i < 8192; i++) { index = i; temp = (gfloat)data->rfft_returned_1[index] / 32767.0; gui_impulse_Y[i] = temp; if (temp > max_y) max_y = temp; if (temp < min_y) min_y = temp; } } else { for (i = 0; i < 8192/2; i++) { index = i; if (tf) avgY[i][avg_index] = (0.0 + 20.0 * log10((gfloat)data->fft_returned_1[index] / (gfloat)data->fft_returned_2[index])); else avgY[i][avg_index] = (0.0 + 20.0 * log10((gfloat)data->fft_returned_1[index])); tmp[i] = 0; for (k = 0; k < 32; k++) { tmp[i] += avgY[i][k]; } tmp[i] /= 32; } } for (i = 0; i < 8192/2; i++) { smoothing = (int)pow(10, (((float)i) / ((float)(8192 / 4)) + 1.0)); smoothing = smoothing > 0 ? smoothing : 0; guiY[i] = tmp[i]; for (j = 1; j <= smoothing; j++) { guiY[i] += tmp[(i-j)>=0?(i-j):0]; guiY[i] += tmp[(i+j)<8192/2?(i+j):(8192/2 -1)]; } guiY[i] /= (smoothing * 2.0 + 1.0); } guiY[0] = tmp[3]; guiY[1] = tmp[3]; guiY[2] = tmp[4]; guiY[8192/2 -1] = tmp[8192/2 -1]; guiY[8192/2 -2] = tmp[8192/2 -2]; if (data->find_impulse == 2) { min_x = 0.0; max_x = ((gfloat) 8192) / 44100/2; gtk_databox_set_total_limits ((G_TYPE_CHECK_INSTANCE_CAST ((impulse_box), (gtk_databox_get_type ()), GtkDatabox)), min_x, max_x, max_y, min_y); gtk_widget_queue_draw(GTK_WIDGET (impulse_box)); data->find_impulse = 0; } if (data->find_delay == 1) { label = g_strdup_printf ( "Finding Delay....." ); gtk_label_set_markup (GTK_LABEL (gui_sb_label), label); g_free((gpointer)label); } if (data->find_delay == 2) { label = g_strdup_printf ( " Found: %g secs ", (float) data->delay_size * (1.0 / (float)44100) ); gtk_label_set_markup (GTK_LABEL (gui_sb_label), label); g_free((gpointer)label); data->find_delay = 0; } if (update_delay) { tmp_spin = gtk_spin_button_get_value_as_float(GTK_SPIN_BUTTON (gui_sb)); data->delay_size = (int) (((gfloat)tmp_spin) * (gfloat) 44100); update_delay = 0; gtk_widget_hide_all (delay_window); } label = g_strdup_printf ( "Current Delay %g msecs", (float) data->delay_size * (1.0 / (float)44100) * 1000.0 ); gtk_label_set_text (GTK_LABEL (gui_status_delay_label), label); g_free((gpointer)label); max = 0; for (k = 8192 - 2000; k < 8192; k++) { if (max < data->buffer_data_1[k]) max = data->buffer_data_1[k]; } if (max > 20000) { myColor1.red = 0xFFFF; myColor1.green = 0x3333; myColor1.blue = 0x3333; } else if (max > 5000) { myColor1.red = 0xCCCC; myColor1.green = 0xFFFF; myColor1.blue = 0x3333; } else if (max > 1000) { myColor1.red = 0x3333; myColor1.green = 0xDDDD; myColor1.blue = 0x3333; } else if (max > 40) { myColor1.red = 0x3333; myColor1.green = 0x8888; myColor1.blue = 0x3333; } gdk_gc_set_rgb_fg_color (gc1, &myColor1); gdk_draw_rectangle (measured_pixmap, gc1, TRUE, 7, 7, 16, 16); gdk_draw_drawable (measured_draw->window, measured_draw->style->fg_gc[GTK_WIDGET_STATE (measured_draw)], measured_pixmap, 5, 5, 5, 5, 20, 20); max = 0; for (k = 8192 - 2000; k < 8192; k++) { if (max < data->buffer_data_2[k]) max = data->buffer_data_2[k]; } if (max > 20000) { myColor2.red = 0xFFFF; myColor2.green = 0x3333; myColor2.blue = 0x3333; } else if (max > 5000) { myColor2.red = 0xCCCC; myColor2.green = 0xFFFF; myColor2.blue = 0x3333; } else if (max > 1000) { myColor2.red = 0x3333; myColor2.green = 0xDDDD; myColor2.blue = 0x3333; } else if (max > 40) { myColor2.red = 0x3333; myColor2.green = 0x8888; myColor2.blue = 0x3333; } gdk_gc_set_rgb_fg_color (gc2, &myColor2); gdk_draw_rectangle (reference_pixmap, gc2, TRUE, 7, 7, 16, 16); gdk_draw_drawable (reference_draw->window, reference_draw->style->fg_gc[GTK_WIDGET_STATE (reference_draw)], reference_pixmap, 5, 5, 5, 5, 20, 20); gtk_widget_queue_draw(GTK_WIDGET (box)); g_object_unref(gc1); g_object_unref(gc2); return TRUE; } static void delay_custom_cb(GtkWidget *widget) { update_delay = 1; } static void pinknoise_mute(GtkWidget *widget) { pinknoise_muted ^= 1; } static void volume_gui(GtkWidget *widget) { volume_pink_value = gtk_spin_button_get_value_as_float(GTK_SPIN_BUTTON (volume_pink_gui)); } static void delay_keep_cb(GtkWidget *widget) { gtk_widget_hide_all (delay_window); } static void about_ok_cb(GtkWidget *widget) { gtk_widget_hide_all (about_me_window); } static void about_me_cb(GtkWidget *widget) { gtk_widget_show_all (about_me_window); gtk_window_present (about_me_window); } static void transfer_fxn_cb(GtkWidget *widget) { tf = (tf == 0); } static void transfer_function_toggled_cb(GtkWidget *widget) { gtk_toggle_button_set_active(transfer_function_toggle, !gtk_toggle_button_get_active(transfer_function_toggle)); } static void capture_cb(GtkWidget *widget, GtkWidget *box) { int i, k, write_output; float avg_avg = 0; FILE *file_handle; gint tmp_array[1]; if (buffer[buffer_last_clicked] == 1) { if (buffer_last_clicked == 5 - 1) { for (k = 0; k < 8192/2; k++) { guiYBuf[5 -1][k] = 0.0; for (i = 0; i < 5 - 1; i++) guiYBuf[5 -1][k] += guiYBuf[i][k]; guiYBuf[5 -1][k] /= 4.0; avg_avg += guiYBuf[5 -1][k] * (1.0 / ((float) 8192/2)); } for (k = 0; k < 8192/2; k++) { guiYBufAvgHold[k] = 0.0 - guiYBuf[5 -1][k] + (avg_avg * 2); guiYBuf[5 -1][k] = avg_gain + guiYBufAvgHold[k]; } } else for (k = 0; k < 8192/2; k++) guiYBuf[buffer_last_clicked][k] = guiY[k]; } write_output = mkdir(file_path1, 0770); if ( ((write_output == -1) && ((*__errno_location ()) == 17)) || (write_output == 0) ) write_output = 1; if ( write_output == 1) { file_handle = fopen(file_path2, "wb"); if (file_handle == ((void *)0)) { write_output = 0; fprintf(stderr, "Could not open file %s, permissions issue?\n", file_path2); } } if (write_output == 1) { tmp_array[0] = 8192/2; fprintf(stderr, "Writing %d elements per buffer to %s\n", tmp_array[0], file_path2); fwrite (tmp_array, sizeof(gint), 1, file_handle ); for (i = 0; i < 5; i++) fwrite (guiYBuf[i], sizeof(gfloat), 8192/2, file_handle ); fclose(file_handle); } } static void gain_cb( GtkWidget *widget, GtkSpinButton *spin ) { int k; avg_gain = gtk_spin_button_get_value_as_float (spin); for (k = 0; k < 8192/2; k++) guiYBuf[5 - 1][k] = avg_gain + guiYBufAvgHold[k]; } static void buffer_button_cb(GtkWidget *widget, gpointer p) { GtkWidget *bufferwid; GtkWidget *bufferwid_m; gint i; i = GPOINTER_TO_INT(p); bufferwid = buffer_button[i]; bufferwid_m = buffer_menu[i]; if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (bufferwid))) { if (buffer[i] != 1) { gtk_databox_graph_add ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), graph[i+1]); buffer[i] = 1; gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(bufferwid_m), TRUE); } } else { if (buffer[i] == 1) { gtk_databox_graph_remove ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), graph[i+1]); buffer[i] = 0; gtk_check_menu_item_set_active(GTK_CHECK_MENU_ITEM(bufferwid_m), FALSE); } } buffer_last_clicked = i; } static void buffer_menu_cb(GtkWidget *widget, gpointer p) { GtkWidget *bufferwid; GtkWidget *bufferwid_m; gint i; i = GPOINTER_TO_INT(p); bufferwid = buffer_button[i]; bufferwid_m = buffer_menu[i]; if (gtk_check_menu_item_get_active (GTK_CHECK_MENU_ITEM (bufferwid_m))) { if (buffer[i] != 1) { gtk_databox_graph_add ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), graph[i+1]); buffer[i] = 1; gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (bufferwid), TRUE); } } else { if (buffer[i] == 1) { gtk_databox_graph_remove ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), graph[i+1]); buffer[i] = 0; gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (bufferwid), FALSE); } } buffer_last_clicked = i; } static void impulse_hide(GtkWidget *widget, struct FFT_Frame * data) { printf("Delete event\n"); gtk_widget_hide_all (impulse_window); } static void delay_hide(GtkWidget *widget, struct FFT_Frame * data) { gtk_widget_hide_all (delay_window); } static void cleanup_gui(GtkWidget *widget, struct FFT_Frame * data) { gtk_widget_destroy (GTK_WIDGET(open_dialog)); gtk_widget_destroy (GTK_WIDGET(save_as_dialog)); gtk_main_quit(); printf("GUI is done with cleanup\n"); } void open_file(char *fn) { int k; FILE *file_handle; gint read_plot_pts[1]; printf("%s is being opened\n", fn ); file_handle = fopen( fn, "rb"); if (file_handle != ((void *)0)) { fread (read_plot_pts, sizeof(gint), 1, file_handle ); if (read_plot_pts[0] == 8192/2) { for (k = 0; k < 5; k++) fread (guiYBuf[k], sizeof(gfloat), 8192/2, file_handle ); save_name = fn; } else fprintf (stderr, "PLOT_PTS is different from PLOT_PTS last captured size, N has been changed from N=%d * 2 since your last capture.\n", read_plot_pts ); } else fprintf (stderr, "Couldn't open file %s for reading\n", save_name); fclose(file_handle); } static void open_cb(GtkWidget *widget, char *data) { GtkFileFilter *file_filter= ((void *)0); gint result; if (open_dialog != ((void *)0)) { gtk_window_present (open_dialog); return(0); } open_dialog = gtk_file_chooser_dialog_new ("Open Capture Buffers From", GTK_WINDOW(bkg_dialog), GTK_FILE_CHOOSER_ACTION_OPEN, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OPEN, GTK_RESPONSE_ACCEPT, ((void *)0)); if(save_name) gtk_file_chooser_select_filename(GTK_FILE_CHOOSER(open_dialog),save_name); else gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(open_dialog),home_string); file_filter = gtk_file_filter_new (); gtk_file_filter_add_pattern (file_filter, "*.brp"); gtk_file_filter_set_name(file_filter, "BRP-PACU files"); gtk_file_chooser_set_filter (GTK_FILE_CHOOSER(open_dialog), GTK_FILE_FILTER(file_filter)); gtk_widget_set_sensitive(save_as, 0); gtk_widget_set_sensitive(save_now, 0); result = gtk_dialog_run (GTK_DIALOG (open_dialog)); switch (result) { case GTK_RESPONSE_ACCEPT: open_file(gtk_file_chooser_get_filename (GTK_FILE_CHOOSER(open_dialog))); break; default: break; } gtk_widget_destroy (open_dialog); gtk_widget_set_sensitive(save_as, 1); gtk_widget_set_sensitive(save_now, 1); open_dialog = ((void *)0); return(0); } static void save_file(char* fn) { int k; gint tmp_array[1]; FILE *file_handle; printf("%s is being saved\n", fn); file_handle = fopen(fn, "wb"); if (file_handle != ((void *)0)) { tmp_array[0] = 8192/2; fwrite (tmp_array, sizeof(gint), 1, file_handle ); for (k = 0; k < 5; k++) fwrite (guiYBuf[k], sizeof(gfloat), 8192/2, file_handle ); save_name = fn; fclose(file_handle); } else fprintf (stderr, "Couldn't open file %s for writing. Usually this is a permissions issue\n", save_name); } static void save_as_cb(GtkWidget *widget, char *data) { int k; gint result; GtkFileFilter *file_filter= ((void *)0); if (save_as_dialog != ((void *)0)) { gtk_window_present (save_as_dialog); return(0); } save_as_dialog = gtk_file_chooser_dialog_new ("Save Capture Buffers As (*.brp recommended)", GTK_WINDOW(bkg_dialog), GTK_FILE_CHOOSER_ACTION_SAVE, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_SAVE_AS, GTK_RESPONSE_ACCEPT, ((void *)0)); if(!gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(save_as_dialog),save_name)) gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(save_as_dialog),home_string); gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(save_as_dialog), save_name==((void *)0)?"Untitled.brp":strrchr(save_name,'/')+1); file_filter = gtk_file_filter_new (); gtk_file_filter_add_pattern (file_filter, "*.brp"); gtk_file_filter_set_name(file_filter, "BRP-PACU files"); gtk_file_chooser_set_filter (GTK_FILE_CHOOSER(save_as_dialog), GTK_FILE_FILTER(file_filter)); gtk_file_chooser_set_do_overwrite_confirmation (GTK_FILE_CHOOSER (save_as_dialog), TRUE); gtk_widget_set_sensitive(open_menuitem, 0); result = gtk_dialog_run (GTK_DIALOG (save_as_dialog)); switch (result) { case GTK_RESPONSE_ACCEPT: save_file(gtk_file_chooser_get_filename (GTK_FILE_CHOOSER(save_as_dialog))); break; default: break; } gtk_widget_destroy (save_as_dialog); save_as_dialog = ((void *)0); gtk_widget_set_sensitive(open_menuitem, 1); return(0); } static void save_now_cb(GtkWidget *widget, char *data) { if (save_name == ((void *)0)) { save_as_cb(widget, data); } else save_file(save_name); } static void impulse_cb(GtkWidget *widget, struct FFT_Frame * data) { gtk_widget_show_all(GTK_DIALOG(impulse_window)); gtk_widget_show_all(GTK_DIALOG(impulse_window)); data->find_impulse = 1; data->find_delay = 1; } static void delay_cb(GtkWidget *widget, struct FFT_Frame * data) { gtk_widget_show_all(GTK_DIALOG(delay_window)); gtk_window_present (delay_window); data->find_delay = 1; } static void resize_default_cb(GtkWidget *widget, GtkWidget *box ) { gfloat min_x, min_y, max_x, max_y; min_x = 30.0; max_x = (gfloat) 44100/2; min_y = -100.0; max_y = 100.0; gtk_databox_set_total_limits ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), min_x, max_x, max_y, min_y); gtk_widget_queue_draw(GTK_WIDGET (box)); } static void resize_cb(GtkWidget *widget, GtkWidget *box ) { gint k; gfloat min_x, min_y, max_x, max_y, tempY; min_x = 30.0; max_x = (gfloat) 44100/2; max_y = -100.0; min_y = 100.0; for (k = min_x * (gfloat)(float) ((float) 44100)/( ((float)8192)/1.0) + 10; k < 8192/2 - 10; k++) { tempY = guiY[k]; max_y = (max_y > tempY) ? max_y : tempY; min_y = (min_y < tempY) ? min_y : tempY; } gtk_databox_set_total_limits ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), min_x, max_x, max_y + 10, min_y - 10); gtk_widget_queue_draw(GTK_WIDGET (box)); } static gint show_motion_notify_cb(GtkWidget *widget, GdkEventMotion *event) { gfloat x; gfloat y; GtkDatabox *box_coords = (G_TYPE_CHECK_INSTANCE_CAST ((widget), (gtk_databox_get_type ()), GtkDatabox)); x = gtk_databox_pixel_to_value_x (box_coords, event->x); y = gtk_databox_pixel_to_value_y (box_coords, event->y); gchar *label; label = g_strdup_printf ( "%g Hz", x); gtk_label_set_text (GTK_LABEL (gui_label), label); g_free((gpointer)label); label = g_strdup_printf ( "%g dB", (y) ); gtk_label_set_text (GTK_LABEL (gui_db_label), label); g_free((gpointer)label); return FALSE; } static gboolean configure_event_measured( GtkWidget *widget, GdkEventConfigure *event ) { GdkGC *gc = ((void *)0); gc = gdk_gc_new(measured_draw->window); GdkColor myColor = { 0, 0x8888, 0x8888, 0x8888 }; gdk_gc_set_rgb_fg_color (gc, &myColor); if (measured_pixmap) g_object_unref (measured_pixmap); measured_pixmap = gdk_pixmap_new (measured_draw->window, widget->allocation.width, widget->allocation.height, -1); gdk_draw_rectangle (measured_pixmap, gc, TRUE, 0, 0, widget->allocation.width, widget->allocation.height); myColor.red = 0x3333; myColor.green = 0x3333; myColor.blue = 0x3333; gdk_gc_set_rgb_fg_color (gc, &myColor); gdk_draw_rectangle (measured_pixmap, gc, TRUE, 7, 7, 16, 16); printf("config\n"); g_object_unref(gc); return TRUE; } static gboolean configure_event_reference( GtkWidget *widget, GdkEventConfigure *event ) { GdkGC *gc = ((void *)0); gc = gdk_gc_new(reference_draw->window); GdkColor myColor = { 0, 0x8888, 0x8888, 0x8888 }; gdk_gc_set_rgb_fg_color (gc, &myColor); if (reference_pixmap) g_object_unref (reference_pixmap); reference_pixmap = gdk_pixmap_new (reference_draw->window, widget->allocation.width, widget->allocation.height, -1); gdk_draw_rectangle (reference_pixmap, gc, TRUE, 0, 0, widget->allocation.width, widget->allocation.height); myColor.red = 0x3333; myColor.green = 0x3333; myColor.blue = 0x3333; gdk_gc_set_rgb_fg_color (gc, &myColor); gdk_draw_rectangle (reference_pixmap, gc, TRUE, 7, 7, 16, 16); printf("config\n"); g_object_unref(gc); return TRUE; } gboolean create_gui (struct FFT_Frame * data) { GtkWidget *window = ((void *)0); GtkWidget *box_container; GtkWidget *box_container_impulse; GtkWidget *table; GtkWidget *table_impulse; GtkWidget *separator; GladeXML *xml = ((void *)0); GtkDataboxGrid *my_grid; FILE * file_handle; gint read_plot_pts[1]; char tmp_string[] = "BRP-PACU vxx.xx.xx "; graph = g_new0 (GtkDataboxGraph *, 10); graph_impulse = g_new0 (GtkDataboxGraph, 1); gint k; gint i; gfloat min_x, max_x, min_y, max_y; min_x = 30.0; max_x = (gfloat) 44100/2; min_y = -100.0; max_y = 100.0; # 890 "gui.c" xml = glade_xml_new ("gui.glade", ((void *)0), ((void *)0)); if (!xml) { xml = glade_xml_new (DATADIR"/BRP_PACU/gui.glade", ((void *)0), ((void *)0)); if (!xml) { fprintf(stderr, "Couldn't find glade file\n"); return(FALSE); } } window = glade_xml_get_widget (xml, "window1"); bkg_dialog = glade_xml_get_widget (xml, "bkg_dialog"); about_me_window = glade_xml_get_widget (xml, "about_me_window"); about_ok = glade_xml_get_widget (xml, "about_ok"); delay_window = glade_xml_get_widget (xml, "delay1"); impulse_window = glade_xml_get_widget (xml, "impulse_window"); box_container = glade_xml_get_widget (xml, "vbox1"); gui_label = glade_xml_get_widget (xml, "label3"); gui_sb_label = glade_xml_get_widget (xml, "delay_label"); gui_sb = glade_xml_get_widget (xml, "spinbutton1"); gui_db_label = glade_xml_get_widget (xml, "label4"); save_as = glade_xml_get_widget (xml, "save_as"); save_now = glade_xml_get_widget (xml, "save_now"); open_menuitem = glade_xml_get_widget (xml, "open"); box_container_impulse = glade_xml_get_widget (xml, "vbox_impulse"); measured_draw = glade_xml_get_widget(xml, "Measured_Draw"); reference_draw = glade_xml_get_widget(xml, "Reference_Draw"); gui_status_delay_label = glade_xml_get_widget (xml, "delay_status_label"); volume_pink_gui = glade_xml_get_widget (xml, "volumebutton1"); pinknoise_button = glade_xml_get_widget (xml, "pinknoise_button"); transfer_function_toggle = glade_xml_get_widget (xml, "TransferFxn"); buffer_button[0] = glade_xml_get_widget (xml, "buff0"); buffer_button[1] = glade_xml_get_widget (xml, "buff1"); buffer_button[2] = glade_xml_get_widget (xml, "buff2"); buffer_button[3] = glade_xml_get_widget (xml, "buff3"); buffer_button[4] = glade_xml_get_widget (xml, "buffAvg"); buffer_menu[0] = glade_xml_get_widget (xml, "buff0_m"); buffer_menu[1] = glade_xml_get_widget (xml, "buff1_m"); buffer_menu[2] = glade_xml_get_widget (xml, "buff2_m"); buffer_menu[3] = glade_xml_get_widget (xml, "buff3_m"); buffer_menu[4] = glade_xml_get_widget (xml, "buffAvg_m"); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "pinknoise_button")), "clicked", G_CALLBACK (pinknoise_mute), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "volumebutton1")), "value-changed", G_CALLBACK (volume_gui), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "quit_ap")), "activate", G_CALLBACK (cleanup_gui), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "save_as")), "activate", G_CALLBACK (save_as_cb), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "save_now")), "activate", G_CALLBACK (save_now_cb), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "open")), "activate", G_CALLBACK (open_cb), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "about_me")), "activate", G_CALLBACK (about_me_cb), ((void *)0)); g_signal_connect (G_OBJECT (about_me_window), "delete_event", G_CALLBACK (about_ok_cb), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "about_ok")), "clicked", G_CALLBACK (about_ok_cb), ((void *)0)); g_signal_connect (G_OBJECT (transfer_function_toggle), "toggled", G_CALLBACK (transfer_fxn_cb), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "transfer_fxn")), "activate", G_CALLBACK (transfer_function_toggled_cb), ((void *)0)); g_signal_connect (GTK_BUTTON (glade_xml_get_widget (xml, "find_delay")), "clicked", G_CALLBACK (delay_cb), data); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "find_delay_m")), "activate", G_CALLBACK (delay_cb), data); g_signal_connect (GTK_OBJECT (window), "destroy", G_CALLBACK (cleanup_gui), ((void *)0)); g_signal_connect (GTK_OBJECT (window), "delete_event", G_CALLBACK (cleanup_gui), ((void *)0)); g_signal_connect (GTK_OBJECT (delay_window), "delete_event", G_CALLBACK (delay_hide), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget(xml, "delay_keep_button")), "clicked", G_CALLBACK (delay_keep_cb), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "impulse_response")), "activate", G_CALLBACK (impulse_cb), data); g_signal_connect (GTK_OBJECT (impulse_window), "delete_event", G_CALLBACK (impulse_hide), ((void *)0)); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "delay_custom_button")), "clicked", G_CALLBACK (delay_custom_cb), ((void *)0)); gui_frequency = 0; gtk_widget_set_size_request (window, 1200, 650); sprintf(tmp_string, "BRP-PACU v%s", "2.0.7"); gtk_window_set_title (GTK_WINDOW (window), tmp_string); gtk_container_set_border_width (GTK_CONTAINER (window), 0); gtk_widget_set_size_request (impulse_window, 900, 500); sprintf(tmp_string, "BRP-PACU Impulse"); gtk_window_set_title (GTK_WINDOW (impulse_window), tmp_string); gtk_container_set_border_width (GTK_CONTAINER (impulse_window), 0); separator = gtk_hseparator_new (); gtk_box_pack_start (GTK_BOX (box_container), separator, FALSE, FALSE, 0); gtk_label_set_text (GTK_LABEL (gui_label), "0"); gui_idle = 0; gui_frequency = 3. * G_PI / 2.; gui_counter = 0; gtk_databox_create_box_with_scrollbars_and_rulers (&box, &table, TRUE, TRUE, TRUE, TRUE); gtk_databox_create_box_with_scrollbars_and_rulers (&impulse_box, &table_impulse, TRUE, TRUE, TRUE, TRUE); gtk_databox_set_total_limits ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), min_x, max_x, max_y, min_y); min_x = 30.0; max_x = (gfloat) 44100/2; min_y = -100.0; max_y = 100.0; gtk_databox_set_total_limits ((G_TYPE_CHECK_INSTANCE_CAST ((impulse_box), (gtk_databox_get_type ()), GtkDatabox)), min_x, max_x, max_y, min_y); gtk_databox_set_scale_type_x ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), GTK_DATABOX_SCALE_LOG); gtk_databox_set_scale_type_y ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), GTK_DATABOX_SCALE_LINEAR); g_signal_connect (G_OBJECT (box), "motion_notify_event", G_CALLBACK (show_motion_notify_cb), ((void *)0)); gtk_box_pack_start (GTK_BOX (box_container), table, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box_container_impulse), table_impulse, TRUE, TRUE, 0); background_color.red = 8192; background_color.green = 8192; background_color.blue = 8192; gtk_widget_modify_bg (box, GTK_STATE_NORMAL, &background_color); guiX = g_new0 (gfloat, 8192/2); guiY = g_new0 (gfloat, 8192/2); gui_impulse_Y = g_new0 (gfloat, 8192); gui_impulse_X = g_new0 (gfloat, 8192); for (i = 0; i < 8192/2; i++) { gui_impulse_Y[i] = .01; gui_impulse_X[i] = ((gfloat)i) / ((gfloat)44100); } for (i = 0; i < 8192/2; i++) { guiX[i] = ((gfloat)i) * (gfloat)(float) ((float) 44100)/( ((float)8192)/1.0); for (k = 0; k < 32; k++) avgY[i][k] = .01; guiY[i] = .01; for (k = 0; k < 5; k++) guiYBuf[k][i] = 0.0; guiYBufAvgHold[i] = 0.0; } trace_transfer_color.red = 16384; trace_transfer_color.green = 65535; trace_transfer_color.blue = 16384; graph[0] = gtk_databox_lines_new (8192/2, guiX, guiY, &trace_transfer_color, 1); gtk_databox_graph_add ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), graph[0]); for (i = 0; i < 5; i++) graph[i+1] = gtk_databox_lines_new (8192/2, guiX, guiYBuf[i], &line_color[i], 1); grid_color.red = 65535; grid_color.green = 65535; grid_color.blue = 16384; my_grid = gtk_databox_grid_new (19, 21.5, &grid_color, 1); gtk_databox_graph_add ((G_TYPE_CHECK_INSTANCE_CAST ((box), (gtk_databox_get_type ()), GtkDatabox)), my_grid); trace_impulse_color.red = 16384; trace_impulse_color.green = 16384; trace_impulse_color.blue = 65535; graph_impulse = gtk_databox_lines_new (8192/2, gui_impulse_X, gui_impulse_Y, &trace_impulse_color, 1); gtk_databox_graph_add ((G_TYPE_CHECK_INSTANCE_CAST ((impulse_box), (gtk_databox_get_type ()), GtkDatabox)), graph_impulse); buffer_button[0] = glade_xml_get_widget (xml, "buff1"); buffer_button[1] = glade_xml_get_widget (xml, "buff2"); buffer_button[2] = glade_xml_get_widget (xml, "buff3"); buffer_button[3] = glade_xml_get_widget (xml, "buff4"); buffer_button[4] = glade_xml_get_widget (xml, "buffAvg"); buffer_menu[0] = glade_xml_get_widget (xml, "buffer_1"); buffer_menu[1] = glade_xml_get_widget (xml, "buffer_2"); buffer_menu[2] = glade_xml_get_widget (xml, "buffer_3"); buffer_menu[3] = glade_xml_get_widget (xml, "buffer_4"); buffer_menu[4] = glade_xml_get_widget (xml, "bufferAvg"); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "auto_resize")), "clicked", G_CALLBACK (resize_cb), (gpointer) box); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "resize_default")), "clicked", G_CALLBACK (resize_default_cb), (gpointer) box); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "auto_resize_m")), "activate", G_CALLBACK (resize_cb), (gpointer) box); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "resize_default_m")), "activate", G_CALLBACK (resize_default_cb), (gpointer) box); for (i = 0; i < 5; i++) { g_signal_connect (G_OBJECT (buffer_button[i]), "clicked", G_CALLBACK (buffer_button_cb), GINT_TO_POINTER((gint) i)); g_signal_connect (G_OBJECT (buffer_menu[i]), "activate", G_CALLBACK (buffer_menu_cb), GINT_TO_POINTER((gint) i)); } g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "capt")), "clicked", G_CALLBACK (capture_cb), (gpointer) box); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "capt_m")), "activate", G_CALLBACK (capture_cb), (gpointer) box); g_signal_connect (G_OBJECT (glade_xml_get_widget (xml, "gain1")), "value-changed", G_CALLBACK (gain_cb), (G_OBJECT (glade_xml_get_widget (xml, "gain1")) )); g_signal_connect (G_OBJECT (reference_draw), "configure_event", G_CALLBACK (configure_event_reference), ((void *)0)); g_signal_connect (G_OBJECT (measured_draw), "configure_event", G_CALLBACK (configure_event_measured), ((void *)0)); volume_pink_value = gtk_spin_button_get_value_as_float(GTK_SPIN_BUTTON (volume_pink_gui)); gtk_widget_show_all (window); home_string = getenv ("HOME"); file_path1 = malloc(sizeof(home_string) + 30); file_path2 = malloc(sizeof(home_string) + 50); sprintf(file_path1, "%s/.BRP_PACU", home_string); sprintf(file_path2, "%s/buff_store.brp", file_path1 ); if ((file_handle = fopen(file_path2, "rb")) <= 0) fprintf(stderr, "\n\nNo BRP_PACU initialization file yet\nAre you running BRP_PACU for the 1st time?\nIf so, a file will be created for you on your next capture\n\n"); else { fread (read_plot_pts, sizeof(gint), 1, file_handle ); if (read_plot_pts[0] == 8192/2) { for (i = 0; i < 5; i++) fread (guiYBuf[i], sizeof(gfloat), 8192/2, file_handle ); } else fprintf (stderr, "PLOT_PTS is different from PLOT_PTS saved size, this is because you have changed N since your last capture. Please change it back to %d * 2. Otherwise making a new capture should overwrite the old file\n", read_plot_pts ); fclose(file_handle); } # 1161 "gui.c" g_object_unref (G_OBJECT(xml)); return(TRUE); } brp-pacu/aclocal.m40000644000175000017500000010676612153127664013120 0ustar miramira# generated automatically by aclocal 1.9.6 -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, # 2005 Free Software Foundation, Inc. # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY, to the extent permitted by law; without # even the implied warranty of MERCHANTABILITY or FITNESS FOR A # PARTICULAR PURPOSE. # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- # # Copyright © 2004 Scott James Remnant . # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # PKG_PROG_PKG_CONFIG([MIN-VERSION]) # ---------------------------------- AC_DEFUN([PKG_PROG_PKG_CONFIG], [m4_pattern_forbid([^_?PKG_[A-Z_]+$]) m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) fi if test -n "$PKG_CONFIG"; then _pkg_min_version=m4_default([$1], [0.9.0]) AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then AC_MSG_RESULT([yes]) else AC_MSG_RESULT([no]) PKG_CONFIG="" fi fi[]dnl ])# PKG_PROG_PKG_CONFIG # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) # # Check to see whether a particular set of modules exists. Similar # to PKG_CHECK_MODULES(), but does not set variables or print errors. # # # Similar to PKG_CHECK_MODULES, make sure that the first instance of # this or PKG_CHECK_MODULES is called, or make sure to call # PKG_CHECK_EXISTS manually # -------------------------------------------------------------- AC_DEFUN([PKG_CHECK_EXISTS], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl if test -n "$PKG_CONFIG" && \ AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then m4_ifval([$2], [$2], [:]) m4_ifvaln([$3], [else $3])dnl fi]) # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) # --------------------------------------------- m4_define([_PKG_CONFIG], [if test -n "$PKG_CONFIG"; then if test -n "$$1"; then pkg_cv_[]$1="$$1" else PKG_CHECK_EXISTS([$3], [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], [pkg_failed=yes]) fi else pkg_failed=untried fi[]dnl ])# _PKG_CONFIG # _PKG_SHORT_ERRORS_SUPPORTED # ----------------------------- AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], [AC_REQUIRE([PKG_PROG_PKG_CONFIG]) if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi[]dnl ])# _PKG_SHORT_ERRORS_SUPPORTED # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], # [ACTION-IF-NOT-FOUND]) # # # Note that if there is a possibility the first call to # PKG_CHECK_MODULES might not happen, you should be sure to include an # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac # # # -------------------------------------------------------------- AC_DEFUN([PKG_CHECK_MODULES], [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl pkg_failed=no AC_MSG_CHECKING([for $1]) _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) _PKG_CONFIG([$1][_LIBS], [libs], [$2]) m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS and $1[]_LIBS to avoid the need to call pkg-config. See the pkg-config man page for more details.]) if test $pkg_failed = yes; then _PKG_SHORT_ERRORS_SUPPORTED if test $_pkg_short_errors_supported = yes; then $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "$2"` else $1[]_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$2"` fi # Put the nasty error message in config.log where it belongs echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD ifelse([$4], , [AC_MSG_ERROR(dnl [Package requirements ($2) were not met: $$1_PKG_ERRORS Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. _PKG_TEXT ])], [AC_MSG_RESULT([no]) $4]) elif test $pkg_failed = untried; then ifelse([$4], , [AC_MSG_FAILURE(dnl [The pkg-config script could not be found or is too old. Make sure it is in your PATH or set the PKG_CONFIG environment variable to the full path to pkg-config. _PKG_TEXT To get pkg-config, see .])], [$4]) else $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS $1[]_LIBS=$pkg_cv_[]$1[]_LIBS AC_MSG_RESULT([yes]) ifelse([$3], , :, [$3]) fi[]dnl ])# PKG_CHECK_MODULES # Copyright (C) 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_AUTOMAKE_VERSION(VERSION) # ---------------------------- # Automake X.Y traces this macro to ensure aclocal.m4 has been # generated from the m4 files accompanying Automake X.Y. AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version="1.9"]) # AM_SET_CURRENT_AUTOMAKE_VERSION # ------------------------------- # Call AM_AUTOMAKE_VERSION so it can be traced. # This function is AC_REQUIREd by AC_INIT_AUTOMAKE. AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], [AM_AUTOMAKE_VERSION([1.9.6])]) # AM_AUX_DIR_EXPAND -*- Autoconf -*- # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to # `$srcdir', `$srcdir/..', or `$srcdir/../..'. # # Of course, Automake must honor this variable whenever it calls a # tool from the auxiliary directory. The problem is that $srcdir (and # therefore $ac_aux_dir as well) can be either absolute or relative, # depending on how configure is run. This is pretty annoying, since # it makes $ac_aux_dir quite unusable in subdirectories: in the top # source directory, any form will work fine, but in subdirectories a # relative path needs to be adjusted first. # # $ac_aux_dir/missing # fails when called from a subdirectory if $ac_aux_dir is relative # $top_srcdir/$ac_aux_dir/missing # fails if $ac_aux_dir is absolute, # fails when called from a subdirectory in a VPATH build with # a relative $ac_aux_dir # # The reason of the latter failure is that $top_srcdir and $ac_aux_dir # are both prefixed by $srcdir. In an in-source build this is usually # harmless because $srcdir is `.', but things will broke when you # start a VPATH build or use an absolute $srcdir. # # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, # iff we strip the leading $srcdir from $ac_aux_dir. That would be: # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` # and then we would define $MISSING as # MISSING="\${SHELL} $am_aux_dir/missing" # This will work as long as MISSING is not called from configure, because # unfortunately $(top_srcdir) has no meaning in configure. # However there are other variables, like CC, which are often used in # configure, and could therefore not use this "fixed" $ac_aux_dir. # # Another solution, used here, is to always expand $ac_aux_dir to an # absolute PATH. The drawback is that using absolute paths prevent a # configured tree to be moved without reconfiguration. AC_DEFUN([AM_AUX_DIR_EXPAND], [dnl Rely on autoconf to set up CDPATH properly. AC_PREREQ([2.50])dnl # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` ]) # AM_CONDITIONAL -*- Autoconf -*- # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 7 # AM_CONDITIONAL(NAME, SHELL-CONDITION) # ------------------------------------- # Define a conditional. AC_DEFUN([AM_CONDITIONAL], [AC_PREREQ(2.52)dnl ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl AC_SUBST([$1_TRUE]) AC_SUBST([$1_FALSE]) if $2; then $1_TRUE= $1_FALSE='#' else $1_TRUE='#' $1_FALSE= fi AC_CONFIG_COMMANDS_PRE( [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then AC_MSG_ERROR([[conditional "$1" was never defined. Usually this means the macro was only invoked conditionally.]]) fi])]) # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 8 # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be # written in clear, in which case automake, when reading aclocal.m4, # will think it sees a *use*, and therefore will trigger all it's # C support machinery. Also note that it means that autoscan, seeing # CC etc. in the Makefile, will ask for an AC_PROG_CC use... # _AM_DEPENDENCIES(NAME) # ---------------------- # See how the compiler implements dependency checking. # NAME is "CC", "CXX", "GCJ", or "OBJC". # We try a few techniques and use that to set a single cache variable. # # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular # dependency, and given that the user is not expected to run this macro, # just rely on AC_PROG_CC. AC_DEFUN([_AM_DEPENDENCIES], [AC_REQUIRE([AM_SET_DEPDIR])dnl AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl AC_REQUIRE([AM_MAKE_INCLUDE])dnl AC_REQUIRE([AM_DEP_TRACK])dnl ifelse([$1], CC, [depcc="$CC" am_compiler_list=], [$1], CXX, [depcc="$CXX" am_compiler_list=], [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], [depcc="$$1" am_compiler_list=]) AC_CACHE_CHECK([dependency style of $depcc], [am_cv_$1_dependencies_compiler_type], [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_$1_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_$1_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_$1_dependencies_compiler_type=none fi ]) AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) AM_CONDITIONAL([am__fastdep$1], [ test "x$enable_dependency_tracking" != xno \ && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) ]) # AM_SET_DEPDIR # ------------- # Choose a directory name for dependency files. # This macro is AC_REQUIREd in _AM_DEPENDENCIES AC_DEFUN([AM_SET_DEPDIR], [AC_REQUIRE([AM_SET_LEADING_DOT])dnl AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl ]) # AM_DEP_TRACK # ------------ AC_DEFUN([AM_DEP_TRACK], [AC_ARG_ENABLE(dependency-tracking, [ --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors]) if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) AC_SUBST([AMDEPBACKSLASH]) ]) # Generate code to set up dependency tracking. -*- Autoconf -*- # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. #serial 3 # _AM_OUTPUT_DEPENDENCY_COMMANDS # ------------------------------ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], [for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`AS_DIRNAME("$mf")` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`AS_DIRNAME(["$file"])` AS_MKDIR_P([$dirpart/$fdir]) # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ])# _AM_OUTPUT_DEPENDENCY_COMMANDS # AM_OUTPUT_DEPENDENCY_COMMANDS # ----------------------------- # This macro should only be invoked once -- use via AC_REQUIRE. # # This code is only required when automatic dependency tracking # is enabled. FIXME. This creates each `.P' file that we will # need in order to bootstrap the dependency handling code. AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], [AC_CONFIG_COMMANDS([depfiles], [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) ]) # Do all the work for Automake. -*- Autoconf -*- # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 12 # This macro actually does too much. Some checks are only needed if # your package does certain things. But this isn't really a big deal. # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) # AM_INIT_AUTOMAKE([OPTIONS]) # ----------------------------------------------- # The call with PACKAGE and VERSION arguments is the old style # call (pre autoconf-2.50), which is being phased out. PACKAGE # and VERSION should now be passed to AC_INIT and removed from # the call to AM_INIT_AUTOMAKE. # We support both call styles for the transition. After # the next Automake release, Autoconf can make the AC_INIT # arguments mandatory, and then we can depend on a new Autoconf # release and drop the old call support. AC_DEFUN([AM_INIT_AUTOMAKE], [AC_PREREQ([2.58])dnl dnl Autoconf wants to disallow AM_ names. We explicitly allow dnl the ones we care about. m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl AC_REQUIRE([AC_PROG_INSTALL])dnl # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi AC_SUBST([CYGPATH_W]) # Define the identity of the package. dnl Distinguish between old-style and new-style calls. m4_ifval([$2], [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl AC_SUBST([PACKAGE], [$1])dnl AC_SUBST([VERSION], [$2])], [_AM_SET_OPTIONS([$1])dnl AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl _AM_IF_OPTION([no-define],, [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl # Some tools Automake needs. AC_REQUIRE([AM_SANITY_CHECK])dnl AC_REQUIRE([AC_ARG_PROGRAM])dnl AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) AM_MISSING_PROG(AUTOCONF, autoconf) AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) AM_MISSING_PROG(AUTOHEADER, autoheader) AM_MISSING_PROG(MAKEINFO, makeinfo) AM_PROG_INSTALL_SH AM_PROG_INSTALL_STRIP AC_REQUIRE([AM_PROG_MKDIR_P])dnl # We need awk for the "check" target. The system "awk" is bad on # some platforms. AC_REQUIRE([AC_PROG_AWK])dnl AC_REQUIRE([AC_PROG_MAKE_SET])dnl AC_REQUIRE([AM_SET_LEADING_DOT])dnl _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], [_AM_PROG_TAR([v7])])]) _AM_IF_OPTION([no-dependencies],, [AC_PROVIDE_IFELSE([AC_PROG_CC], [_AM_DEPENDENCIES(CC)], [define([AC_PROG_CC], defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl AC_PROVIDE_IFELSE([AC_PROG_CXX], [_AM_DEPENDENCIES(CXX)], [define([AC_PROG_CXX], defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl ]) ]) # When config.status generates a header, we must update the stamp-h file. # This file resides in the same directory as the config header # that is generated. The stamp files are numbered to have different names. # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the # loop where config.status creates the headers, so we can generate # our stamp files there. AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], [# Compute $1's index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in $1 | $1:* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_SH # ------------------ # Define $install_sh. AC_DEFUN([AM_PROG_INSTALL_SH], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl install_sh=${install_sh-"$am_aux_dir/install-sh"} AC_SUBST(install_sh)]) # Copyright (C) 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # Check whether the underlying file-system supports filenames # with a leading dot. For instance MS-DOS doesn't. AC_DEFUN([AM_SET_LEADING_DOT], [rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null AC_SUBST([am__leading_dot])]) # Check to see how 'make' treats includes. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # AM_MAKE_INCLUDE() # ----------------- # Check to see how make treats includes. AC_DEFUN([AM_MAKE_INCLUDE], [am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. AC_MSG_CHECKING([for style of include used by $am_make]) am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi AC_SUBST([am__include]) AC_SUBST([am__quote]) AC_MSG_RESULT([$_am_result]) rm -f confinc confmf ]) # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 4 # AM_MISSING_PROG(NAME, PROGRAM) # ------------------------------ AC_DEFUN([AM_MISSING_PROG], [AC_REQUIRE([AM_MISSING_HAS_RUN]) $1=${$1-"${am_missing_run}$2"} AC_SUBST($1)]) # AM_MISSING_HAS_RUN # ------------------ # Define MISSING if not defined so far and test if it supports --run. # If it does, set am_missing_run to use it, otherwise, to nothing. AC_DEFUN([AM_MISSING_HAS_RUN], [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= AC_MSG_WARN([`missing' script is too old or missing]) fi ]) # Copyright (C) 2003, 2004, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_MKDIR_P # --------------- # Check whether `mkdir -p' is supported, fallback to mkinstalldirs otherwise. # # Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories # created by `make install' are always world readable, even if the # installer happens to have an overly restrictive umask (e.g. 077). # This was a mistake. There are at least two reasons why we must not # use `-m 0755': # - it causes special bits like SGID to be ignored, # - it may be too restrictive (some setups expect 775 directories). # # Do not use -m 0755 and let people choose whatever they expect by # setting umask. # # We cannot accept any implementation of `mkdir' that recognizes `-p'. # Some implementations (such as Solaris 8's) are not thread-safe: if a # parallel make tries to run `mkdir -p a/b' and `mkdir -p a/c' # concurrently, both version can detect that a/ is missing, but only # one can create it and the other will error out. Consequently we # restrict ourselves to GNU make (using the --version option ensures # this.) AC_DEFUN([AM_PROG_MKDIR_P], [if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then # We used to keeping the `.' as first argument, in order to # allow $(mkdir_p) to be used without argument. As in # $(mkdir_p) $(somedir) # where $(somedir) is conditionally defined. However this is wrong # for two reasons: # 1. if the package is installed by a user who cannot write `.' # make install will fail, # 2. the above comment should most certainly read # $(mkdir_p) $(DESTDIR)$(somedir) # so it does not work when $(somedir) is undefined and # $(DESTDIR) is not. # To support the latter case, we have to write # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir), # so the `.' trick is pointless. mkdir_p='mkdir -p --' else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. for d in ./-p ./--version; do test -d $d && rmdir $d done # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. if test -f "$ac_aux_dir/mkinstalldirs"; then mkdir_p='$(mkinstalldirs)' else mkdir_p='$(install_sh) -d' fi fi AC_SUBST([mkdir_p])]) # Helper functions for option handling. -*- Autoconf -*- # Copyright (C) 2001, 2002, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 3 # _AM_MANGLE_OPTION(NAME) # ----------------------- AC_DEFUN([_AM_MANGLE_OPTION], [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) # _AM_SET_OPTION(NAME) # ------------------------------ # Set option NAME. Presently that only means defining a flag for this option. AC_DEFUN([_AM_SET_OPTION], [m4_define(_AM_MANGLE_OPTION([$1]), 1)]) # _AM_SET_OPTIONS(OPTIONS) # ---------------------------------- # OPTIONS is a space-separated list of Automake options. AC_DEFUN([_AM_SET_OPTIONS], [AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) # ------------------------------------------- # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. AC_DEFUN([_AM_IF_OPTION], [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) # Check to make sure that the build environment is sane. -*- Autoconf -*- # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005 # Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 4 # AM_SANITY_CHECK # --------------- AC_DEFUN([AM_SANITY_CHECK], [AC_MSG_CHECKING([whether build environment is sane]) # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$[*]" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$[*]" != "X $srcdir/configure conftest.file" \ && test "$[*]" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken alias in your environment]) fi test "$[2]" = conftest.file ) then # Ok. : else AC_MSG_ERROR([newly created file is older than distributed files! Check your system clock]) fi AC_MSG_RESULT(yes)]) # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # AM_PROG_INSTALL_STRIP # --------------------- # One issue with vendor `install' (even GNU) is that you can't # specify the program used to strip binaries. This is especially # annoying in cross-compiling environments, where the build's strip # is unlikely to handle the host's binaries. # Fortunately install-sh will honor a STRIPPROG variable, so we # always use install-sh in `make install-strip', and initialize # STRIPPROG with the value of the STRIP variable (set by the user). AC_DEFUN([AM_PROG_INSTALL_STRIP], [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. dnl Don't test for $cross_compiling = yes, because it might be `maybe'. if test "$cross_compiling" != no; then AC_CHECK_TOOL([STRIP], [strip], :) fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" AC_SUBST([INSTALL_STRIP_PROGRAM])]) # Check how to create a tarball. -*- Autoconf -*- # Copyright (C) 2004, 2005 Free Software Foundation, Inc. # # This file is free software; the Free Software Foundation # gives unlimited permission to copy and/or distribute it, # with or without modifications, as long as this notice is preserved. # serial 2 # _AM_PROG_TAR(FORMAT) # -------------------- # Check how to create a tarball in format FORMAT. # FORMAT should be one of `v7', `ustar', or `pax'. # # Substitute a variable $(am__tar) that is a command # writing to stdout a FORMAT-tarball containing the directory # $tardir. # tardir=directory && $(am__tar) > result.tar # # Substitute a variable $(am__untar) that extract such # a tarball read from stdin. # $(am__untar) < result.tar AC_DEFUN([_AM_PROG_TAR], [# Always define AMTAR for backward compatibility. AM_MISSING_PROG([AMTAR], [tar]) m4_if([$1], [v7], [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], [m4_case([$1], [ustar],, [pax],, [m4_fatal([Unknown tar format])]) AC_MSG_CHECKING([how to create a $1 tar archive]) # Loop over all known methods to create a tar archive until one works. _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' _am_tools=${am_cv_prog_tar_$1-$_am_tools} # Do not fold the above two line into one, because Tru64 sh and # Solaris sh will not grok spaces in the rhs of `-'. for _am_tool in $_am_tools do case $_am_tool in gnutar) for _am_tar in tar gnutar gtar; do AM_RUN_LOG([$_am_tar --version]) && break done am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' am__untar="$_am_tar -xf -" ;; plaintar) # Must skip GNU tar: if it does not support --format= it doesn't create # ustar tarball either. (tar --version) >/dev/null 2>&1 && continue am__tar='tar chf - "$$tardir"' am__tar_='tar chf - "$tardir"' am__untar='tar xf -' ;; pax) am__tar='pax -L -x $1 -w "$$tardir"' am__tar_='pax -L -x $1 -w "$tardir"' am__untar='pax -r' ;; cpio) am__tar='find "$$tardir" -print | cpio -o -H $1 -L' am__tar_='find "$tardir" -print | cpio -o -H $1 -L' am__untar='cpio -i -H $1 -d' ;; none) am__tar=false am__tar_=false am__untar=false ;; esac # If the value was cached, stop now. We just wanted to have am__tar # and am__untar set. test -n "${am_cv_prog_tar_$1}" && break # tar/untar a dummy directory, and stop if the command works rm -rf conftest.dir mkdir conftest.dir echo GrepMe > conftest.dir/file AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) rm -rf conftest.dir if test -s conftest.tar; then AM_RUN_LOG([$am__untar /dev/null 2>&1 && break fi done rm -rf conftest.dir AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) AC_MSG_RESULT([$am_cv_prog_tar_$1])]) AC_SUBST([am__tar]) AC_SUBST([am__untar]) ]) # _AM_PROG_TAR brp-pacu/config.sub0000755000175000017500000007746012153127664013241 0ustar miramira#! /bin/sh # Configuration validation subroutine script. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, # Inc. timestamp='2006-09-20' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software # can handle that machine. It does not imply ALL GNU software can. # # This file is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA # 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # Configuration subroutine to validate and canonicalize a configuration type. # Supply the specified configuration type as an argument. # If it is invalid, we print an error message on stderr and exit with code 1. # Otherwise, we print the canonical config type on stdout and succeed. # This file is supposed to be the same for all GNU packages # and recognize all the CPU types, system types and aliases # that are meaningful with *any* GNU software. # Each package is responsible for reporting which valid configurations # it does not support. The user should be able to distinguish # a failure to support a valid configuration from a meaningless # configuration. # The goal of this file is to map all the various variations of a given # machine specification into a single specification in the form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM # or in some cases, the newer four-part form: # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM # It is wrong to echo any other type of specification. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] CPU-MFR-OPSYS $0 [OPTION] ALIAS Canonicalize a configuration name. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.sub ($timestamp) Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" exit 1 ;; *local*) # First pass through any local machine types. echo $1 exit ;; * ) break ;; esac done case $# in 0) echo "$me: missing argument$help" >&2 exit 1;; 1) ;; *) echo "$me: too many arguments$help" >&2 exit 1;; esac # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). # Here we must recognize all the valid KERNEL-OS combinations. maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` case $maybe_os in nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \ uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \ storm-chaos* | os2-emx* | rtmk-nova*) os=-$maybe_os basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` ;; *) basic_machine=`echo $1 | sed 's/-[^-]*$//'` if [ $basic_machine != $1 ] then os=`echo $1 | sed 's/.*-/-/'` else os=; fi ;; esac ### Let's recognize common machines as not being operating systems so ### that things like config.sub decstation-3100 work. We also ### recognize some manufacturers as not being operating systems, so we ### can provide default operating systems below. case $os in -sun*os*) # Prevent following clause from handling this invalid input. ;; -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ -apple | -axis | -knuth | -cray) os= basic_machine=$1 ;; -sim | -cisco | -oki | -wec | -winbond) os= basic_machine=$1 ;; -scout) ;; -wrs) os=-vxworks basic_machine=$1 ;; -chorusos*) os=-chorusos basic_machine=$1 ;; -chorusrdb) os=-chorusrdb basic_machine=$1 ;; -hiux*) os=-hiuxwe2 ;; -sco6) os=-sco5v6 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5) os=-sco3.2v5 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco4) os=-sco3.2v4 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2.[4-9]*) os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco3.2v[4-9]*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco5v6*) # Don't forget version if it is 3.2v4 or newer. basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -sco*) os=-sco3.2v2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -udk*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -isc) os=-isc2.2 basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -clix*) basic_machine=clipper-intergraph ;; -isc*) basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` ;; -lynx*) os=-lynxos ;; -ptx*) basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` ;; -windowsnt*) os=`echo $os | sed -e 's/windowsnt/winnt/'` ;; -psos*) os=-psos ;; -mint | -mint[0-9]*) basic_machine=m68k-atari os=-mint ;; esac # Decode aliases for certain CPU-COMPANY combinations. case $basic_machine in # Recognize the basic CPU types without company name. # Some are omitted here because they have special meanings below. 1750a | 580 \ | a29k \ | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | am33_2.0 \ | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | bfin \ | c4x | clipper \ | d10v | d30v | dlx | dsp16xx \ | fr30 | frv \ | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | i370 | i860 | i960 | ia64 \ | ip2k | iq2000 \ | m32c | m32r | m32rle | m68000 | m68k | m88k \ | maxq | mb | microblaze | mcore \ | mips | mipsbe | mipseb | mipsel | mipsle \ | mips16 \ | mips64 | mips64el \ | mips64vr | mips64vrel \ | mips64orion | mips64orionel \ | mips64vr4100 | mips64vr4100el \ | mips64vr4300 | mips64vr4300el \ | mips64vr5000 | mips64vr5000el \ | mips64vr5900 | mips64vr5900el \ | mipsisa32 | mipsisa32el \ | mipsisa32r2 | mipsisa32r2el \ | mipsisa64 | mipsisa64el \ | mipsisa64r2 | mipsisa64r2el \ | mipsisa64sb1 | mipsisa64sb1el \ | mipsisa64sr71k | mipsisa64sr71kel \ | mipstx39 | mipstx39el \ | mn10200 | mn10300 \ | mt \ | msp430 \ | nios | nios2 \ | ns16k | ns32k \ | or32 \ | pdp10 | pdp11 | pj | pjl \ | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | pyramid \ | score \ | sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | sh64 | sh64le \ | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ | spu | strongarm \ | tahoe | thumb | tic4x | tic80 | tron \ | v850 | v850e \ | we32k \ | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ | z8k) basic_machine=$basic_machine-unknown ;; m6811 | m68hc11 | m6812 | m68hc12) # Motorola 68HC11/12. basic_machine=$basic_machine-unknown os=-none ;; m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) ;; ms1) basic_machine=mt-unknown ;; # We use `pc' rather than `unknown' # because (1) that's what they normally are, and # (2) the word "unknown" tends to confuse beginning users. i*86 | x86_64) basic_machine=$basic_machine-pc ;; # Object if more than one company name word. *-*-*) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; # Recognize the basic CPU types with company name. 580-* \ | a29k-* \ | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | avr-* | avr32-* \ | bfin-* | bs2000-* \ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \ | clipper-* | craynv-* | cydra-* \ | d10v-* | d30v-* | dlx-* \ | elxsi-* \ | f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \ | h8300-* | h8500-* \ | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | i*86-* | i860-* | i960-* | ia64-* \ | ip2k-* | iq2000-* \ | m32c-* | m32r-* | m32rle-* \ | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ | m88110-* | m88k-* | maxq-* | mcore-* \ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | mips16-* \ | mips64-* | mips64el-* \ | mips64vr-* | mips64vrel-* \ | mips64orion-* | mips64orionel-* \ | mips64vr4100-* | mips64vr4100el-* \ | mips64vr4300-* | mips64vr4300el-* \ | mips64vr5000-* | mips64vr5000el-* \ | mips64vr5900-* | mips64vr5900el-* \ | mipsisa32-* | mipsisa32el-* \ | mipsisa32r2-* | mipsisa32r2el-* \ | mipsisa64-* | mipsisa64el-* \ | mipsisa64r2-* | mipsisa64r2el-* \ | mipsisa64sb1-* | mipsisa64sb1el-* \ | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | mipstx39-* | mipstx39el-* \ | mmix-* \ | mt-* \ | msp430-* \ | nios-* | nios2-* \ | none-* | np1-* | ns16k-* | ns32k-* \ | orion-* \ | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | pyramid-* \ | romp-* | rs6000-* \ | sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | sparclite-* \ | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ | tahoe-* | thumb-* \ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | tron-* \ | v850-* | v850e-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ | xstormy16-* | xtensa-* \ | ymp-* \ | z8k-*) ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) basic_machine=i386-unknown os=-bsd ;; 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) basic_machine=m68000-att ;; 3b*) basic_machine=we32k-att ;; a29khif) basic_machine=a29k-amd os=-udi ;; abacus) basic_machine=abacus-unknown ;; adobe68k) basic_machine=m68010-adobe os=-scout ;; alliant | fx80) basic_machine=fx80-alliant ;; altos | altos3068) basic_machine=m68k-altos ;; am29k) basic_machine=a29k-none os=-bsd ;; amd64) basic_machine=x86_64-pc ;; amd64-*) basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; amdahl) basic_machine=580-amdahl os=-sysv ;; amiga | amiga-*) basic_machine=m68k-unknown ;; amigaos | amigados) basic_machine=m68k-unknown os=-amigaos ;; amigaunix | amix) basic_machine=m68k-unknown os=-sysv4 ;; apollo68) basic_machine=m68k-apollo os=-sysv ;; apollo68bsd) basic_machine=m68k-apollo os=-bsd ;; aux) basic_machine=m68k-apple os=-aux ;; balance) basic_machine=ns32k-sequent os=-dynix ;; c90) basic_machine=c90-cray os=-unicos ;; convex-c1) basic_machine=c1-convex os=-bsd ;; convex-c2) basic_machine=c2-convex os=-bsd ;; convex-c32) basic_machine=c32-convex os=-bsd ;; convex-c34) basic_machine=c34-convex os=-bsd ;; convex-c38) basic_machine=c38-convex os=-bsd ;; cray | j90) basic_machine=j90-cray os=-unicos ;; craynv) basic_machine=craynv-cray os=-unicosmp ;; cr16c) basic_machine=cr16c-unknown os=-elf ;; crds | unos) basic_machine=m68k-crds ;; crisv32 | crisv32-* | etraxfs*) basic_machine=crisv32-axis ;; cris | cris-* | etrax*) basic_machine=cris-axis ;; crx) basic_machine=crx-unknown os=-elf ;; da30 | da30-*) basic_machine=m68k-da30 ;; decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) basic_machine=mips-dec ;; decsystem10* | dec10*) basic_machine=pdp10-dec os=-tops10 ;; decsystem20* | dec20*) basic_machine=pdp10-dec os=-tops20 ;; delta | 3300 | motorola-3300 | motorola-delta \ | 3300-motorola | delta-motorola) basic_machine=m68k-motorola ;; delta88) basic_machine=m88k-motorola os=-sysv3 ;; djgpp) basic_machine=i586-pc os=-msdosdjgpp ;; dpx20 | dpx20-*) basic_machine=rs6000-bull os=-bosx ;; dpx2* | dpx2*-bull) basic_machine=m68k-bull os=-sysv3 ;; ebmon29k) basic_machine=a29k-amd os=-ebmon ;; elxsi) basic_machine=elxsi-elxsi os=-bsd ;; encore | umax | mmax) basic_machine=ns32k-encore ;; es1800 | OSE68k | ose68k | ose | OSE) basic_machine=m68k-ericsson os=-ose ;; fx2800) basic_machine=i860-alliant ;; genix) basic_machine=ns32k-ns ;; gmicro) basic_machine=tron-gmicro os=-sysv ;; go32) basic_machine=i386-pc os=-go32 ;; h3050r* | hiux*) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; h8300hms) basic_machine=h8300-hitachi os=-hms ;; h8300xray) basic_machine=h8300-hitachi os=-xray ;; h8500hms) basic_machine=h8500-hitachi os=-hms ;; harris) basic_machine=m88k-harris os=-sysv3 ;; hp300-*) basic_machine=m68k-hp ;; hp300bsd) basic_machine=m68k-hp os=-bsd ;; hp300hpux) basic_machine=m68k-hp os=-hpux ;; hp3k9[0-9][0-9] | hp9[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k2[0-9][0-9] | hp9k31[0-9]) basic_machine=m68000-hp ;; hp9k3[2-9][0-9]) basic_machine=m68k-hp ;; hp9k6[0-9][0-9] | hp6[0-9][0-9]) basic_machine=hppa1.0-hp ;; hp9k7[0-79][0-9] | hp7[0-79][0-9]) basic_machine=hppa1.1-hp ;; hp9k78[0-9] | hp78[0-9]) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) # FIXME: really hppa2.0-hp basic_machine=hppa1.1-hp ;; hp9k8[0-9][13679] | hp8[0-9][13679]) basic_machine=hppa1.1-hp ;; hp9k8[0-9][0-9] | hp8[0-9][0-9]) basic_machine=hppa1.0-hp ;; hppa-next) os=-nextstep3 ;; hppaosf) basic_machine=hppa1.1-hp os=-osf ;; hppro) basic_machine=hppa1.1-hp os=-proelf ;; i370-ibm* | ibm*) basic_machine=i370-ibm ;; # I'm not sure what "Sysv32" means. Should this be sysv3.2? i*86v32) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv32 ;; i*86v4*) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv4 ;; i*86v) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-sysv ;; i*86sol2) basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` os=-solaris2 ;; i386mach) basic_machine=i386-mach os=-mach ;; i386-vsta | vsta) basic_machine=i386-unknown os=-vsta ;; iris | iris4d) basic_machine=mips-sgi case $os in -irix*) ;; *) os=-irix4 ;; esac ;; isi68 | isi) basic_machine=m68k-isi os=-sysv ;; m88k-omron*) basic_machine=m88k-omron ;; magnum | m3230) basic_machine=mips-mips os=-sysv ;; merlin) basic_machine=ns32k-utek os=-sysv ;; mingw32) basic_machine=i386-pc os=-mingw32 ;; miniframe) basic_machine=m68000-convergent ;; *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) basic_machine=m68k-atari os=-mint ;; mips3*-*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` ;; mips3*) basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown ;; monitor) basic_machine=m68k-rom68k os=-coff ;; morphos) basic_machine=powerpc-unknown os=-morphos ;; msdos) basic_machine=i386-pc os=-msdos ;; ms1-*) basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` ;; mvs) basic_machine=i370-ibm os=-mvs ;; ncr3000) basic_machine=i486-ncr os=-sysv4 ;; netbsd386) basic_machine=i386-unknown os=-netbsd ;; netwinder) basic_machine=armv4l-rebel os=-linux ;; news | news700 | news800 | news900) basic_machine=m68k-sony os=-newsos ;; news1000) basic_machine=m68030-sony os=-newsos ;; news-3600 | risc-news) basic_machine=mips-sony os=-newsos ;; necv70) basic_machine=v70-nec os=-sysv ;; next | m*-next ) basic_machine=m68k-next case $os in -nextstep* ) ;; -ns2*) os=-nextstep2 ;; *) os=-nextstep3 ;; esac ;; nh3000) basic_machine=m68k-harris os=-cxux ;; nh[45]000) basic_machine=m88k-harris os=-cxux ;; nindy960) basic_machine=i960-intel os=-nindy ;; mon960) basic_machine=i960-intel os=-mon960 ;; nonstopux) basic_machine=mips-compaq os=-nonstopux ;; np1) basic_machine=np1-gould ;; nsr-tandem) basic_machine=nsr-tandem ;; op50n-* | op60c-*) basic_machine=hppa1.1-oki os=-proelf ;; openrisc | openrisc-*) basic_machine=or32-unknown ;; os400) basic_machine=powerpc-ibm os=-os400 ;; OSE68000 | ose68000) basic_machine=m68000-ericsson os=-ose ;; os68k) basic_machine=m68k-none os=-os68k ;; pa-hitachi) basic_machine=hppa1.1-hitachi os=-hiuxwe2 ;; paragon) basic_machine=i860-intel os=-osf ;; pbd) basic_machine=sparc-tti ;; pbb) basic_machine=m68k-tti ;; pc532 | pc532-*) basic_machine=ns32k-pc532 ;; pc98) basic_machine=i386-pc ;; pc98-*) basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium | p5 | k5 | k6 | nexgen | viac3) basic_machine=i586-pc ;; pentiumpro | p6 | 6x86 | athlon | athlon_*) basic_machine=i686-pc ;; pentiumii | pentium2 | pentiumiii | pentium3) basic_machine=i686-pc ;; pentium4) basic_machine=i786-pc ;; pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumpro-* | p6-* | 6x86-* | athlon-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pentium4-*) basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` ;; pn) basic_machine=pn-gould ;; power) basic_machine=power-ibm ;; ppc) basic_machine=powerpc-unknown ;; ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppcle | powerpclittle | ppc-le | powerpc-little) basic_machine=powerpcle-unknown ;; ppcle-* | powerpclittle-*) basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64) basic_machine=powerpc64-unknown ;; ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ppc64le | powerpc64little | ppc64-le | powerpc64-little) basic_machine=powerpc64le-unknown ;; ppc64le-* | powerpc64little-*) basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` ;; ps2) basic_machine=i386-ibm ;; pw32) basic_machine=i586-unknown os=-pw32 ;; rdos) basic_machine=i386-pc os=-rdos ;; rom68k) basic_machine=m68k-rom68k os=-coff ;; rm[46]00) basic_machine=mips-siemens ;; rtpc | rtpc-*) basic_machine=romp-ibm ;; s390 | s390-*) basic_machine=s390-ibm ;; s390x | s390x-*) basic_machine=s390x-ibm ;; sa29200) basic_machine=a29k-amd os=-udi ;; sb1) basic_machine=mipsisa64sb1-unknown ;; sb1el) basic_machine=mipsisa64sb1el-unknown ;; sde) basic_machine=mipsisa32-sde os=-elf ;; sei) basic_machine=mips-sei os=-seiux ;; sequent) basic_machine=i386-sequent ;; sh) basic_machine=sh-hitachi os=-hms ;; sh64) basic_machine=sh64-unknown ;; sparclite-wrs | simso-wrs) basic_machine=sparclite-wrs os=-vxworks ;; sps7) basic_machine=m68k-bull os=-sysv2 ;; spur) basic_machine=spur-unknown ;; st2000) basic_machine=m68k-tandem ;; stratus) basic_machine=i860-stratus os=-sysv4 ;; sun2) basic_machine=m68000-sun ;; sun2os3) basic_machine=m68000-sun os=-sunos3 ;; sun2os4) basic_machine=m68000-sun os=-sunos4 ;; sun3os3) basic_machine=m68k-sun os=-sunos3 ;; sun3os4) basic_machine=m68k-sun os=-sunos4 ;; sun4os3) basic_machine=sparc-sun os=-sunos3 ;; sun4os4) basic_machine=sparc-sun os=-sunos4 ;; sun4sol2) basic_machine=sparc-sun os=-solaris2 ;; sun3 | sun3-*) basic_machine=m68k-sun ;; sun4) basic_machine=sparc-sun ;; sun386 | sun386i | roadrunner) basic_machine=i386-sun ;; sv1) basic_machine=sv1-cray os=-unicos ;; symmetry) basic_machine=i386-sequent os=-dynix ;; t3e) basic_machine=alphaev5-cray os=-unicos ;; t90) basic_machine=t90-cray os=-unicos ;; tic54x | c54x*) basic_machine=tic54x-unknown os=-coff ;; tic55x | c55x*) basic_machine=tic55x-unknown os=-coff ;; tic6x | c6x*) basic_machine=tic6x-unknown os=-coff ;; tx39) basic_machine=mipstx39-unknown ;; tx39el) basic_machine=mipstx39el-unknown ;; toad1) basic_machine=pdp10-xkl os=-tops20 ;; tower | tower-32) basic_machine=m68k-ncr ;; tpf) basic_machine=s390x-ibm os=-tpf ;; udi29k) basic_machine=a29k-amd os=-udi ;; ultra3) basic_machine=a29k-nyu os=-sym1 ;; v810 | necv810) basic_machine=v810-nec os=-none ;; vaxv) basic_machine=vax-dec os=-sysv ;; vms) basic_machine=vax-dec os=-vms ;; vpp*|vx|vx-*) basic_machine=f301-fujitsu ;; vxworks960) basic_machine=i960-wrs os=-vxworks ;; vxworks68) basic_machine=m68k-wrs os=-vxworks ;; vxworks29k) basic_machine=a29k-wrs os=-vxworks ;; w65*) basic_machine=w65-wdc os=-none ;; w89k-*) basic_machine=hppa1.1-winbond os=-proelf ;; xbox) basic_machine=i686-pc os=-mingw32 ;; xps | xps100) basic_machine=xps100-honeywell ;; ymp) basic_machine=ymp-cray os=-unicos ;; z8k-*-coff) basic_machine=z8k-unknown os=-sim ;; none) basic_machine=none-none os=-none ;; # Here we handle the default manufacturer of certain CPU types. It is in # some cases the only manufacturer, in others, it is the most popular. w89k) basic_machine=hppa1.1-winbond ;; op50n) basic_machine=hppa1.1-oki ;; op60c) basic_machine=hppa1.1-oki ;; romp) basic_machine=romp-ibm ;; mmix) basic_machine=mmix-knuth ;; rs6000) basic_machine=rs6000-ibm ;; vax) basic_machine=vax-dec ;; pdp10) # there are many clones, so DEC is not a safe bet basic_machine=pdp10-unknown ;; pdp11) basic_machine=pdp11-dec ;; we32k) basic_machine=we32k-att ;; sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele) basic_machine=sh-unknown ;; sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) basic_machine=sparc-sun ;; cydra) basic_machine=cydra-cydrome ;; orion) basic_machine=orion-highlevel ;; orion105) basic_machine=clipper-highlevel ;; mac | mpw | mac-mpw) basic_machine=m68k-apple ;; pmac | pmac-mpw) basic_machine=powerpc-apple ;; *-unknown) # Make sure to match an already-canonicalized machine name. ;; *) echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 exit 1 ;; esac # Here we canonicalize certain aliases for manufacturers. case $basic_machine in *-digital*) basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` ;; *-commodore*) basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` ;; *) ;; esac # Decode manufacturer-specific aliases for certain operating systems. if [ x"$os" != x"" ] then case $os in # First match some system type aliases # that might get confused with valid system types. # -solaris* is a basic system type, with this one exception. -solaris1 | -solaris1.*) os=`echo $os | sed -e 's|solaris1|sunos4|'` ;; -solaris) os=-solaris2 ;; -svr4*) os=-sysv4 ;; -unixware*) os=-sysv4.2uw ;; -gnu/linux*) os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` ;; # First accept the basic system types. # The portable systems comes first. # Each alternative MUST END IN A *, to match a version number. # -sysv* is not here because it comes later, after sysvr4. -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | -*vms* | -sco* | -esix* | -isc* | -aix* | -sunos | -sunos[34]*\ | -hpux* | -unos* | -osf* | -luna* | -dgux* | -solaris* | -sym* \ | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | -aos* \ | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ | -openbsd* | -solidbsd* \ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | -chorusos* | -chorusrdb* \ | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \ | -uxpv* | -beos* | -mpeix* | -udk* \ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ | -skyos* | -haiku* | -rdos* | -toppers*) # Remember, each alternative MUST END IN *, to match a version number. ;; -qnx*) case $basic_machine in x86-* | i*86-*) ;; *) os=-nto$os ;; esac ;; -nto-qnx*) ;; -nto*) os=`echo $os | sed -e 's|nto|nto-qnx|'` ;; -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) ;; -mac*) os=`echo $os | sed -e 's|mac|macos|'` ;; -linux-dietlibc) os=-linux-dietlibc ;; -linux*) os=`echo $os | sed -e 's|linux|linux-gnu|'` ;; -sunos5*) os=`echo $os | sed -e 's|sunos5|solaris2|'` ;; -sunos6*) os=`echo $os | sed -e 's|sunos6|solaris3|'` ;; -opened*) os=-openedition ;; -os400*) os=-os400 ;; -wince*) os=-wince ;; -osfrose*) os=-osfrose ;; -osf*) os=-osf ;; -utek*) os=-bsd ;; -dynix*) os=-bsd ;; -acis*) os=-aos ;; -atheos*) os=-atheos ;; -syllable*) os=-syllable ;; -386bsd) os=-bsd ;; -ctix* | -uts*) os=-sysv ;; -nova*) os=-rtmk-nova ;; -ns2 ) os=-nextstep2 ;; -nsk*) os=-nsk ;; # Preserve the version number of sinix5. -sinix5.*) os=`echo $os | sed -e 's|sinix|sysv|'` ;; -sinix*) os=-sysv4 ;; -tpf*) os=-tpf ;; -triton*) os=-sysv3 ;; -oss*) os=-sysv3 ;; -svr4) os=-sysv4 ;; -svr3) os=-sysv3 ;; -sysvr4) os=-sysv4 ;; # This must come after -sysvr4. -sysv*) ;; -ose*) os=-ose ;; -es1800*) os=-ose ;; -xenix) os=-xenix ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) os=-mint ;; -aros*) os=-aros ;; -kaos*) os=-kaos ;; -zvmoe) os=-zvmoe ;; -none) ;; *) # Get rid of the `-' at the beginning of $os. os=`echo $os | sed 's/[^-]*-//'` echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 exit 1 ;; esac else # Here we handle the default operating systems that come with various machines. # The value should be what the vendor currently ships out the door with their # machine or put another way, the most popular os provided with the machine. # Note that if you're going to try to match "-MANUFACTURER" here (say, # "-sun"), then you have to tell the case statement up towards the top # that MANUFACTURER isn't an operating system. Otherwise, code above # will signal an error saying that MANUFACTURER isn't an operating # system, and we'll never get to this point. case $basic_machine in score-*) os=-elf ;; spu-*) os=-elf ;; *-acorn) os=-riscix1.2 ;; arm*-rebel) os=-linux ;; arm*-semi) os=-aout ;; c4x-* | tic4x-*) os=-coff ;; # This must come before the *-dec entry. pdp10-*) os=-tops20 ;; pdp11-*) os=-none ;; *-dec | vax-*) os=-ultrix4.2 ;; m68*-apollo) os=-domain ;; i386-sun) os=-sunos4.0.2 ;; m68000-sun) os=-sunos3 # This also exists in the configure program, but was not the # default. # os=-sunos4 ;; m68*-cisco) os=-aout ;; mips*-cisco) os=-elf ;; mips*-*) os=-elf ;; or32-*) os=-coff ;; *-tti) # must be before sparc entry or we get the wrong os. os=-sysv3 ;; sparc-* | *-sun) os=-sunos4.1.1 ;; *-be) os=-beos ;; *-haiku) os=-haiku ;; *-ibm) os=-aix ;; *-knuth) os=-mmixware ;; *-wec) os=-proelf ;; *-winbond) os=-proelf ;; *-oki) os=-proelf ;; *-hp) os=-hpux ;; *-hitachi) os=-hiux ;; i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) os=-sysv ;; *-cbm) os=-amigaos ;; *-dg) os=-dgux ;; *-dolphin) os=-sysv3 ;; m68k-ccur) os=-rtu ;; m88k-omron*) os=-luna ;; *-next ) os=-nextstep ;; *-sequent) os=-ptx ;; *-crds) os=-unos ;; *-ns) os=-genix ;; i370-*) os=-mvs ;; *-next) os=-nextstep3 ;; *-gould) os=-sysv ;; *-highlevel) os=-bsd ;; *-encore) os=-bsd ;; *-sgi) os=-irix ;; *-siemens) os=-sysv4 ;; *-masscomp) os=-rtu ;; f30[01]-fujitsu | f700-fujitsu) os=-uxpv ;; *-rom68k) os=-coff ;; *-*bug) os=-coff ;; *-apple) os=-macos ;; *-atari*) os=-mint ;; *) os=-none ;; esac fi # Here we handle the case where we know the os, and the CPU type, but not the # manufacturer. We pick the logical manufacturer. vendor=unknown case $basic_machine in *-unknown) case $os in -riscix*) vendor=acorn ;; -sunos*) vendor=sun ;; -aix*) vendor=ibm ;; -beos*) vendor=be ;; -hpux*) vendor=hp ;; -mpeix*) vendor=hp ;; -hiux*) vendor=hitachi ;; -unos*) vendor=crds ;; -dgux*) vendor=dg ;; -luna*) vendor=omron ;; -genix*) vendor=ns ;; -mvs* | -opened*) vendor=ibm ;; -os400*) vendor=ibm ;; -ptx*) vendor=sequent ;; -tpf*) vendor=ibm ;; -vxsim* | -vxworks* | -windiss*) vendor=wrs ;; -aux*) vendor=apple ;; -hms*) vendor=hitachi ;; -mpw* | -macos*) vendor=apple ;; -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) vendor=atari ;; -vos*) vendor=stratus ;; esac basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` ;; esac echo $basic_machine$os exit # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: brp-pacu/ige-mac-dock.c0000644000175000017500000003007112153127664013625 0ustar miramira/* GTK+ Integration for the Mac OS X Dock. * * Copyright (C) 2007, 2008 Imendio AB * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; version 2.1 * of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ /* FIXME: Add example like this to docs for the open documents stuff: CFBundleDocumentTypes CFBundleTypeExtensions txt */ #include #include #include #include #include "ige-mac-dock.h" #include "ige-mac-bundle.h" #include "ige-mac-image-utils.h" #include "ige-mac-private.h" enum { CLICKED, QUIT_ACTIVATE, OPEN_DOCUMENTS, LAST_SIGNAL }; static guint signals[LAST_SIGNAL] = { 0 }; typedef struct IgeMacDockPriv IgeMacDockPriv; struct IgeMacDockPriv { glong id; }; static void mac_dock_finalize (GObject *object); static OSErr mac_dock_handle_quit (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefcon); static OSErr mac_dock_handle_open_documents (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefcon); static OSErr mac_dock_handle_open_application (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefcon); static OSErr mac_dock_handle_reopen_application (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefcon); G_DEFINE_TYPE (IgeMacDock, ige_mac_dock, G_TYPE_OBJECT) #define GET_PRIV(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), IGE_TYPE_MAC_DOCK, IgeMacDockPriv)) static GList *handlers; static IgeMacDock *global_dock; static void ige_mac_dock_class_init (IgeMacDockClass *class) { GObjectClass *object_class = G_OBJECT_CLASS (class); object_class->finalize = mac_dock_finalize; signals[CLICKED] = g_signal_new ("clicked", IGE_TYPE_MAC_DOCK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); /* FIXME: Need marshaller. */ signals[OPEN_DOCUMENTS] = g_signal_new ("open-documents", IGE_TYPE_MAC_DOCK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); signals[QUIT_ACTIVATE] = g_signal_new ("quit-activate", IGE_TYPE_MAC_DOCK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0); g_type_class_add_private (object_class, sizeof (IgeMacDockPriv)); /* FIXME: Just testing with triggering Carbon to take control over * the dock menu events instead of Cocoa (which happens when the * sharedApplication is created) to get custom dock menu working * with carbon menu code. However, doing this makes the dock icon * not get a "running triangle". */ #if 0 EventTypeSpec kFakeEventList[] = { { INT_MAX, INT_MAX } }; EventRef event; ReceiveNextEvent (GetEventTypeCount (kFakeEventList), kFakeEventList, kEventDurationNoWait, false, &event); #endif } static void ige_mac_dock_init (IgeMacDock *dock) { IgeMacDockPriv *priv = GET_PRIV (dock); static glong id; priv->id = ++id; handlers = g_list_prepend (handlers, dock); AEInstallEventHandler (kCoreEventClass, kAEQuitApplication, mac_dock_handle_quit, priv->id, true); AEInstallEventHandler (kCoreEventClass, kAEOpenApplication, mac_dock_handle_open_application, priv->id, true); AEInstallEventHandler (kCoreEventClass, kAEReopenApplication, mac_dock_handle_reopen_application, priv->id, true); AEInstallEventHandler (kCoreEventClass, kAEOpenDocuments, mac_dock_handle_open_documents, priv->id, true); } static void mac_dock_finalize (GObject *object) { IgeMacDockPriv *priv; priv = GET_PRIV (object); AERemoveEventHandler (kCoreEventClass, kAEQuitApplication, mac_dock_handle_quit, false); AERemoveEventHandler (kCoreEventClass, kAEReopenApplication, mac_dock_handle_reopen_application, false); AERemoveEventHandler (kCoreEventClass, kAEOpenApplication, mac_dock_handle_open_application, false); AERemoveEventHandler (kCoreEventClass, kAEOpenDocuments, mac_dock_handle_open_documents, false); handlers = g_list_remove (handlers, object); G_OBJECT_CLASS (ige_mac_dock_parent_class)->finalize (object); } IgeMacDock * ige_mac_dock_new (void) { return g_object_new (IGE_TYPE_MAC_DOCK, NULL); } IgeMacDock * ige_mac_dock_get_default (void) { if (!global_dock) global_dock = g_object_new (IGE_TYPE_MAC_DOCK, NULL); return global_dock; } /* For internal use only. Returns TRUE if there is a handled setup for the * Quit dock menu item (i.e. if there is a dock instance alive). */ gboolean _ige_mac_dock_is_quit_menu_item_handled (void) { return handlers != NULL; } static IgeMacDock * mac_dock_get_from_id (gulong id) { GList *l; IgeMacDock *dock = NULL; for (l = handlers; l; l = l->next) { dock = l->data; if (GET_PRIV (dock)->id == id) break; dock = NULL; } return dock; } static OSErr mac_dock_handle_quit (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefcon) { IgeMacDock *dock; dock = mac_dock_get_from_id (inHandlerRefcon); if (dock) g_signal_emit (dock, signals[QUIT_ACTIVATE], 0); return noErr; } static OSErr mac_dock_handle_open_application (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefCon) { /*g_print ("FIXME: mac_dock_handle_open_application\n");*/ return noErr; } static OSErr mac_dock_handle_reopen_application (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefcon) { IgeMacDock *dock; dock = mac_dock_get_from_id (inHandlerRefcon); if (dock) g_signal_emit (dock, signals[CLICKED], 0); return noErr; } static OSErr mac_dock_handle_open_documents (const AppleEvent *inAppleEvent, AppleEvent *outAppleEvent, long inHandlerRefCon) { IgeMacDock *dock; OSStatus status; AEDescList documents; gchar path[MAXPATHLEN]; /*g_print ("FIXME: mac_dock_handle_open_documents\n");*/ dock = mac_dock_get_from_id (inHandlerRefCon); status = AEGetParamDesc (inAppleEvent, keyDirectObject, typeAEList, &documents); if (status == noErr) { long count = 0; int i; AECountItems (&documents, &count); for (i = 0; i < count; i++) { FSRef ref; status = AEGetNthPtr (&documents, i + 1, typeFSRef, 0, 0, &ref, sizeof (ref), 0); if (status != noErr) continue; FSRefMakePath (&ref, (char *) path, MAXPATHLEN); /* FIXME: Add to a list, then emit the open-documents * signal. */ /*g_print (" %s\n", path);*/ } } return status; } void ige_mac_dock_set_icon_from_pixbuf (IgeMacDock *dock, GdkPixbuf *pixbuf) { if (!pixbuf) RestoreApplicationDockTileImage (); else { CGImageRef image; image = ige_mac_image_from_pixbuf (pixbuf); SetApplicationDockTileImage (image); CGImageRelease (image); } } void ige_mac_dock_set_icon_from_resource (IgeMacDock *dock, IgeMacBundle *bundle, const gchar *name, const gchar *type, const gchar *subdir) { gchar *path; g_return_if_fail (IGE_IS_MAC_DOCK (dock)); g_return_if_fail (name != NULL); path = ige_mac_bundle_get_resource_path (bundle, name, type, subdir); if (path) { GdkPixbuf *pixbuf; pixbuf = gdk_pixbuf_new_from_file (path, NULL); if (pixbuf) { ige_mac_dock_set_icon_from_pixbuf (dock, pixbuf); g_object_unref (pixbuf); } g_free (path); } } void ige_mac_dock_set_overlay_from_pixbuf (IgeMacDock *dock, GdkPixbuf *pixbuf) { CGImageRef image; g_return_if_fail (IGE_IS_MAC_DOCK (dock)); g_return_if_fail (pixbuf == NULL || GDK_IS_PIXBUF (pixbuf)); if (pixbuf) { image = ige_mac_image_from_pixbuf (pixbuf); OverlayApplicationDockTileImage (image); CGImageRelease (image); } else RestoreApplicationDockTileImage (); } void ige_mac_dock_set_overlay_from_resource (IgeMacDock *dock, IgeMacBundle *bundle, const gchar *name, const gchar *type, const gchar *subdir) { gchar *path; g_return_if_fail (IGE_IS_MAC_DOCK (dock)); g_return_if_fail (name != NULL); path = ige_mac_bundle_get_resource_path (bundle, name, type, subdir); if (path) { GdkPixbuf *pixbuf; pixbuf = gdk_pixbuf_new_from_file (path, NULL); if (pixbuf) { ige_mac_dock_set_overlay_from_pixbuf (dock, pixbuf); g_object_unref (pixbuf); } g_free (path); } } struct _IgeMacAttentionRequest { NMRec nm_request; guint timeout_id; gboolean is_cancelled; }; static gboolean mac_dock_attention_cb (IgeMacAttentionRequest *request) { request->timeout_id = 0; request->is_cancelled = TRUE; NMRemove (&request->nm_request); return FALSE; } /* FIXME: Add listener for "application activated" and cancel any * requests. */ IgeMacAttentionRequest * ige_mac_dock_attention_request (IgeMacDock *dock, IgeMacAttentionType type) { IgeMacAttentionRequest *request; request = g_new0 (IgeMacAttentionRequest, 1); request->nm_request.nmMark = 1; request->nm_request.qType = nmType; if (NMInstall (&request->nm_request) != noErr) { g_free (request); return NULL; } if (type == IGE_MAC_ATTENTION_INFO) request->timeout_id = gdk_threads_add_timeout ( 1000, (GSourceFunc) mac_dock_attention_cb, request); return request; } void ige_mac_dock_attention_cancel (IgeMacDock *dock, IgeMacAttentionRequest *request) { if (request->timeout_id) g_source_remove (request->timeout_id); if (!request->is_cancelled) NMRemove (&request->nm_request); g_free (request); } GType ige_mac_attention_type_get_type (void) { /* FIXME */ return 0; } brp-pacu/testfft.c0000644000175000017500000001120112153127664013056 0ustar miramira/* * testfft.c : Simply perform the fft of channel 1 and channel 2 inputs, * Assumes data is windowed. Modifies and reads input memory pointed * to by struct session. * * * Copyright (C) 2007 Brian Phelps(lm317t@gmail.com) * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. */ #include #include #include "main.h" #include "testfft.h" int fft_capture(struct FFT_Frame * session) { int k; double datapt; /////////////////////////////////// double * fft; short * buf; fftw_plan plan = session->plan; fft = (double *)malloc(sizeof(double) * N_FFT); fftw_complex * in, *out; //, power_spectrum[N/2+1]; in = fftw_malloc ( sizeof ( fftw_complex ) * N_FFT ); out = fftw_malloc ( sizeof ( fftw_complex ) * N_FFT ); /////////////////////////////////////////////////////////////////// buf = session->buffer_data_1; for (k = 0;k < N_FFT; k++) { // Fill empty slots with 0's, Copy interleaved audio data fft[k] = 0; } for (k = 0; k < N_FFT; k++) { c_re(in[k]) = (double) buf[k]; c_im(in[k]) = 0.0; } fftw_one(plan, in, out); for (k = 0; k < N_FFT; k++) { datapt = (double)(sqrt(c_re(out[k]) * c_re(out[k]) + c_im(out[k]) * c_im(out[k]) )); fft[k] = datapt; } for (k = 0; k < N_FFT; k++) { session->fft_returned_1[k] = fft[k] / 32767.0 + 0.00000001; } buf = session->buffer_data_2; for (k = 0;k < N_FFT; k++) { // Fill empty slots with 0's, Copy interleaved audio data fft[k] = 0; } for (k = 0; k < N_FFT; k++) { c_re(in[k]) = (double) buf[k]; c_im(in[k]) = 0.0; } fftw_one(plan, in, out); for (k = 0; k < N_FFT; k++) { datapt = (double)(sqrt(c_re(out[k]) * c_re(out[k]) + c_im(out[k]) * c_im(out[k]) )); fft[k] = datapt; //fft[k] = 20.0 * log10(datapt + 1); } for (k = 0; k < N_FFT; k++) { session->fft_returned_2[k] = fft[k] / 32767.0 + 0.00000001; } free(fft); fftw_free(in); fftw_free(out); return 0; } int impulse_capture(struct FFT_Frame * session) { int k; int tmr; /////////////////////////////////// short * buf; fftw_plan plan = session->plan; fftw_plan reverse_plan = session->reverse_plan; fftw_complex * in1, *out1; //, power_spectrum[N/2+1]; fftw_complex * in2, *out2; //, power_spectrum[N/2+1]; in1 = fftw_malloc ( sizeof ( fftw_complex ) * N_FFT ); out1 = fftw_malloc ( sizeof ( fftw_complex ) * N_FFT ); in2 = fftw_malloc ( sizeof ( fftw_complex ) * N_FFT ); out2 = fftw_malloc ( sizeof ( fftw_complex ) * N_FFT ); /////////////////////////////////////////////////////////////////// buf = session->buffer_data_1; for (k = 0; k < N_FFT; k++) { c_re(in1[k]) = (double) buf[k]; c_im(in1[k]) = 0.0; } fftw_one(plan, in1, out1); buf = session->buffer_data_2; for (k = 0; k < N_FFT; k++) { c_re(in2[k]) = (double) buf[k]; c_im(in2[k]) = 0.0; } fftw_one(plan, in2, out2); for (k = 0; k < N_FFT; k++) { c_re(in1[k]) = (double)( c_re(out1[k]) * c_re(out2[k]) + c_im(out2[k]) * c_im(out1[k]) ) / \ ( c_re(out2[k]) * c_re(out2[k]) + c_im(out2[k]) * c_im(out2[k]) ); c_im(in1[k]) = (double)( c_re(out2[k]) * c_im(out1[k]) - c_im(out2[k]) * c_re(out1[k]) ) / \ ( c_re(out2[k]) * c_re(out2[k]) + c_im(out2[k]) * c_im(out2[k]) ); // This code is an explanation for the above lines, do not delete // a = c_re(out1) // b = c_im(out1) // c = c_re(out2) // d = c_im(out2) // (a+b*i)/(c+d*i) = (a*c+c*b*i-d*i*a+d*b)/(c^2+d^2) // The impulse response, h(t) is the Inv Fourier Trxfm of the above line, H(f) = Y(f) / X(f) = ( Y(f) x X*(f) ) / ( X(f) x X*(f) ) } fftw_one(reverse_plan, in1, out1); for (k = 0; k < N_FFT; k++) { session->rfft_returned_1[k] = c_re(out1[k]) / 32767.0; } fftw_free(in1); fftw_free(out1); fftw_free(in2); fftw_free(out2); return 0; } brp-pacu/BRP_PACU.ui0000644000175000017500000013334212153127664013040 0ustar miramira 100 0 10 1 0 0 100 -100 10 0.25 0 0.25 15 -10 4 0.050000000000000003 0 5.0499999999999998 32 1 2 1 0 32 10 1 2 1 0 5 Brian's Reasonably Priced Professional Audio Configuration Utility * Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) * Macintosh application Copyright (C) 2009 Andreas Schwab * Macintosh synchronization Copyright (C) 2007 Pioneer Research Center USA, Inc. * Macintosh integration Copyright (C) 2007, 2008 Imendio AB * This program is based on the following libraries * FFTW: Copyright (c) 1997-1999, 2003 Massachusetts Institute of Technology * libglade: Copyright (C) 1998-2002 James Henstridge * gtkdatabox: Copyright (C) 1998 - 2008 Dr. Roland Bock * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * Written by Brian R. Phelps aka Electronjunkie http://electronjunkie.wordpress.com Questions or comments? Interested in contributing? Please email me at lm317t@gmail.com I need someone to help me package it for Debian/Ubuntu! Also a Redhat/Fedora rpm or any other packaging help would be much appreciated. menuitem1 _File gtk-open open gtk-save save_now gtk-save-as save_as gtk-quit quit_ap buffers _Buffers buffer_1 Buffer _1 buffer_2 Buffer _2 buffer_3 Buffer _3 buffer_4 Buffer _4 bufferAvg Buffer _Avg menuitem3 _View auto_resize_m Resize Window resize_default_m Resize Default plot_preferences Change how quickly the plot responds to input Plot Preferences menuitem6 Ac_tions impulse_response Record Impulse Response h(n) find_delay_m Find Delay capt_m Capture Trace pink_noise Pink Noise True transfer_fxn Calculate Transfer Function H(z) menuitem4 _Help gtk-about about_me About BRP-PACU True True True False GTK_JUSTIFY_FILL textbuffer1 True True True True OK 1 1 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 5 Delay GTK_WIN_POS_CENTER_ON_PARENT True GDK_WINDOW_TYPE_HINT_NORMAL True GDK_GRAVITY_CENTER window1 False True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Insert custom delay or found delay? True False 9 1 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK <b> Found: 0.000 secs</b> True 3 2 True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK adjustment1 3 3 1 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GTK_BUTTONBOX_END True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Custom True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Found 1 False GTK_PACK_END delay_custom_button delay_keep_button My Window sinc.png True True False 28 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 94 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Hz GTK_JUSTIFY_CENTER False False 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK False 2 1 82 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK dB GTK_JUSTIFY_CENTER False False 2 2 True False 2 3 True Delay 0.0ms True False False 3 4 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK _Capture Trace True False False 10 5 True Avg Gain False False 2 6 60 True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Gain for Averaging Buffer adjustment2 2 False False 1 7 True False 4 8 True True True Pink Noise False False 9 74 True True GDK_POINTER_MOTION_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_STRUCTURE_MASK GDK_EXTENSION_EVENTS_ALL adjustment3 2 False False 1 10 True False 11 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Measured False False 5 12 26 True True GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK False False 3 13 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Reference False False 3 14 26 True True GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK False False 3 15 False False 1 28 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _1 True True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _2 True 1 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _3 True 2 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _4 True 3 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK _Avg True 4 False GTK_PACK_END 4 33 True True True Transfer Function True True False True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK _Resize True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK gtk-refresh 1 1 True True True True True Resi_ze Default True True gtk-fullscreen 1 2 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Find _Delay True 3 False GTK_PACK_END 3 GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 5 Graph Preferences GTK_WIN_POS_CENTER_ON_PARENT True GDK_WINDOW_TYPE_HINT_NORMAL True GDK_GRAVITY_CENTER window1 False True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Averaging Value: True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Increasing this value slows down the response of the graph.. adjustment4 3 True False 7 4 True Smoothing Value 5 1 True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Increasing this value smooths the graph more. adjustment5 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GTK_BUTTONBOX_END True True True gtk-apply True True True True gtk-close True 1 False GTK_PACK_END apply_preferences close_preferences brp-pacu/sinc.icns0000644000175000017500000010000712153127664013050 0ustar miramiraicnsics#H??is32       #     >7577557> fU һq1&L< 3>s]E, Pcvc~dqbA3LC WL)>195oD97Jj571C    8       >;77475477;Cs8mk\\ggffffffffffffii55ICN#il32""""""%/991 11 19 911119 91 11 19 91 1119 91  1 1   1 9    95 50   0E!#I clmkmkkmkkmkkmk mkkmkkmkmoc/%"%(""+""+"hN%("%+""+""+?==5$55E(5= oG=5l 55 5==5.55G)5= iB=5 ` 55 5 =ځ= 5o( t5 5 |6 E % ZS 9 fja^_c be}^`pE %Vt H} ( <% 4; ` 4I%"##""f&!"#""!4G ""$!"(M clmkmkkmaakmkkmkadmkkmkmoc/"""%%""%%(/99111 19 91111991 11 19  91 1119911 1   1 5     9 5   54 4E" !     $I clmkmkkmkkmkkmk mkkmkkmkmocl8mkXXXXXXXXXXXXXXXXXXXXXXXXXX::>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>??;;gkkkkkkkkkkkkkkkkkkkkkkkkgich#Hih32 q# """-q         g   gg   gg   go   oo   og   gg   gg  gw   wg   gg   gg   go   oo  og   gg   gg   gw   wg    gg     gg    gg og og gg    gg   gw        wkHDHHDHHDIGDDCJGDDCJEDDCJEDJDPkEprqtqtqrpEq( " %% " %% " %# "f" (" (" (" 2q'g b/gg\ gg go(ooGog j3ggPggt gw  wg-ggCgg `-go Jooi ogу gg#gg8gw!U&!wg" y@gg]c .2gg4p Ӆ gw&".E)oWG686EC683bܨ4883dy?O/Z   %X _gbA=} WTgg = z| gwJ+!"wkNHKKH KKDoGJHHGMJHMD}ANHNHUkEpoq\gq^dqopEq(" "  "%%%-qg gg gggooo og gg gggwwg gg gg go oooggggg gw wg gg   gg gg oo og gg   gg gw  wkJEJIEJIE>BJHEJHEKH@BEKGEKEFUkEpoqopEh8mk   ؽ M`^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^`M it32!̐v`ci]c`u`c`u`c{`c]lc]~~]cl]c`}260$$/4)*437&        &4   4ȏV V(  (,   ,,   ,,   ,,  ,,   ,,   ,,   ,,   ,+  +5   5T T/   /,   ,,  ,,   ,,   ,,   ,,   ,,   ,,  ,*   *4   4L   L8   8*   *,  ,,   ,,   ,,   ,,   ,,   ,,   ,+  +2  2G   GA   A)   ),   ,,  ,,  ,,   ,,   ,,   ,,   ,,  ,/   /P P;   ;*   *,   ,,     ,,     ,,     ,,    ,,     ,,     ,,    ,)  (C$'# %' '& '"S4     <+    ,,    ,,    ,,    ,,       ,,      ,,  ,,    ,,   ,'    'N    N=            =:<4%  %4<9 -.:9>$mmfiwfdskfedefksdfwfduifeddfoofiufxpm$$\lmnlnllnllnlnllnllnllnml\$biigiibUicfciUfN]f]Nff̐zfofcxf{cfo~cfrffof9">6**6#;$00$;:=Ϗ,  Ft    ,ԏ:":ȏZ.TZ- r-3)33*N33L~33v33'33!ׄ=33Ao33V311:#:Y%݆EY46_43P}33s3333,33!Ո=33;`33Xy33t3118*8R ӊ<R=8Y=0Vp03j3333$33nj133*M338c33T31155K+KG%܎BG-1W-3T33n3333+33#ߐB330U33N~33e344U$U>ƒ1>0-S03=}  33 i _ J3 33 #{  RA 33U $0܂*33 $Ԕ@33 A~ 9c Lq 33†&S/33 |s }A 3&0 \+IEچ~DIHVڔlFIFaڇNIGs|j=896\܇594q܆495WW͇H  ljO  ),  (ևK/+<߆|n3ψ N^ 12 L*Oxn33Fڂ,id3 3:݀)Gd6y jN3 3!(33 g33&RE33@"ۃ3+/V +Sg9SB   ŀ    5    A?"B:,CK,9!B?&1b33&??B$mrghjxhftnh defhntfhxh wjhhdhfhpphjwhzrm$$\lmnllnllnlhhilnnllnlnllnnlhlnllnllnml\$biigiibUicfciUfN]f]Nf̐zficf`ufu`fxcf`ofc~`fo`f}682&'27 ,- 767Ϗ)     )ԏ7 7ȏX  X)  )-   --    --   --  --  --   --   --   -,  ,7  7V V1  1,   ,-  --  --  --   --    --   --  -+  +66N N; ;+   +-  --  --  --   --   --   --   -,  ,3  3I IC C*    *-   --  --  --  --   --    --   --   -11RR< <+    +-   --     --    --   --   --     --    --   -+   )?#&"&$#&$%& P/     <+   --    --   --    --        --      --  --   --   -)    )O O?           ><>6)   )6> ;! /0!<;?$mpgfiwfsmfdadfmsfhwfujffhdadfoofjwfxrm$$\lmnlnllnllnlnllnllnllnml\$biigiibUicfciUfN]f]Nft8mk@IUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUI./667777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777777778811/vv/'aa'3HMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMH3  brp-pacu/AUTHORS0000644000175000017500000000114612153127664012312 0ustar miramira Brian Phelps electronjunkie at users.sourceforge.net Macintosh implementation: Andreas Schwab andreasjs at users.sourceforge.net Macintosh desktop integration: Pioneer Research Center USA, Inc. Pink noise filter adapted from: Paul Kellet http://www.musicdsp.org/showone.php?id=76 Libraries used (and integrated into the Macintosh binary distribution) fftw ("Fastest Fourier Transform in the West") Matteo Frigo and Steven G. Johnson http://www.fftw.org/ GTK+ graphical user interface The GTK Team, http://www.gtk.org GtkDatabox Roland Bock, Brian Phelps https://sourceforge.net/projects/gtkdatabox/brp-pacu/COPYING0000644000175000017500000004312212153127664012275 0ustar miramira GNU GENERAL PUBLIC LICENSE Version 2, June 1991 Copyright (C) 1989, 1991 Free Software Foundation, Inc. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Preamble The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Library General Public License instead.) You can apply it to your programs, too. When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things. To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it. For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights. We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations. Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all. The precise terms and conditions for copying, distribution and modification follow. GNU GENERAL PUBLIC LICENSE TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION 0. This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The "Program", below, refers to any such program or work, and a "work based on the Program" means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term "modification".) Each licensee is addressed as "you". Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. 1. You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program. You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee. 2. You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions: a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change. b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License. c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.) These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it. Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program. In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License. 3. You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following: a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.) The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable. If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code. 4. You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance. 5. You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it. 6. Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein. You are not responsible for enforcing compliance by third parties to this License. 7. If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program. If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances. It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice. This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License. 8. If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License. 9. The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and "any later version", you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation. 10. If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally. NO WARRANTY 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION. 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. END OF TERMS AND CONDITIONS How to Apply These Terms to Your New Programs If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the "copyright" line and a pointer to where the full notice is found. Copyright (C) This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Also add information on how to contact you by electronic and paper mail. If the program is interactive, make it output a short notice like this when it starts in an interactive mode: Gnomovision version 69, Copyright (C) year name of author Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'. This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details. The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program. You should also get your employer (if you work as a programmer) or your school, if any, to sign a "copyright disclaimer" for the program, if necessary. Here is a sample; alter the names: Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. , 1 April 1989 Ty Coon, President of Vice This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Library General Public License instead of this License. brp-pacu/config.guess0000755000175000017500000012626012153127664013567 0ustar miramira#! /bin/sh # Attempt to guess a canonical system name. # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, # 2000, 2001, 2002, 2003, 2004, 2005, 2006 Free Software Foundation, # Inc. timestamp='2006-07-02' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA # 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Per Bothner . # Please send patches to . Submit a context # diff and a properly formatted ChangeLog entry. # # This script attempts to guess a canonical system name similar to # config.sub. If it succeeds, it prints the system name on stdout, and # exits with 0. Otherwise, it exits with 1. # # The plan is that this can be called by configure scripts if you # don't specify an explicit build system type. me=`echo "$0" | sed -e 's,.*/,,'` usage="\ Usage: $0 [OPTION] Output the configuration name of the system \`$me' is run on. Operation modes: -h, --help print this help, then exit -t, --time-stamp print date of last modification, then exit -v, --version print version number, then exit Report bugs and patches to ." version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." help=" Try \`$me --help' for more information." # Parse command line while test $# -gt 0 ; do case $1 in --time-stamp | --time* | -t ) echo "$timestamp" ; exit ;; --version | -v ) echo "$version" ; exit ;; --help | --h* | -h ) echo "$usage"; exit ;; -- ) # Stop option processing shift; break ;; - ) # Use stdin as input. break ;; -* ) echo "$me: invalid option $1$help" >&2 exit 1 ;; * ) break ;; esac done if test $# != 0; then echo "$me: too many arguments$help" >&2 exit 1 fi trap 'exit 1' 1 2 15 # CC_FOR_BUILD -- compiler used by this script. Note that the use of a # compiler to aid in system detection is discouraged as it requires # temporary files to be created and, as you can see below, it is a # headache to deal with in a portable fashion. # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still # use `HOST_CC' if defined, but it is deprecated. # Portable tmp directory creation inspired by the Autoconf team. set_cc_for_build=' trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ; : ${TMPDIR=/tmp} ; { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; dummy=$tmp/dummy ; tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; case $CC_FOR_BUILD,$HOST_CC,$CC in ,,) echo "int x;" > $dummy.c ; for c in cc gcc c89 c99 ; do if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then CC_FOR_BUILD="$c"; break ; fi ; done ; if test x"$CC_FOR_BUILD" = x ; then CC_FOR_BUILD=no_compiler_found ; fi ;; ,,*) CC_FOR_BUILD=$CC ;; ,*,*) CC_FOR_BUILD=$HOST_CC ;; esac ; set_cc_for_build= ;' # This is needed to find uname on a Pyramid OSx when run in the BSD universe. # (ghazi@noc.rutgers.edu 1994-08-24) if (test -f /.attbin/uname) >/dev/null 2>&1 ; then PATH=$PATH:/.attbin ; export PATH fi UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown # Note: order is significant - the case branches are not exclusive. case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in *:NetBSD:*:*) # NetBSD (nbsd) targets should (where applicable) match one or # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently # switched to ELF, *-*-netbsd* would select the old # object file format. This provides both forward # compatibility and a consistent mechanism for selecting the # object file format. # # Note: NetBSD doesn't particularly care about the vendor # portion of the name. We always set it to "unknown". sysctl="sysctl -n hw.machine_arch" UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ /usr/sbin/$sysctl 2>/dev/null || echo unknown)` case "${UNAME_MACHINE_ARCH}" in armeb) machine=armeb-unknown ;; arm*) machine=arm-unknown ;; sh3el) machine=shl-unknown ;; sh3eb) machine=sh-unknown ;; *) machine=${UNAME_MACHINE_ARCH}-unknown ;; esac # The Operating System including object format, if it has switched # to ELF recently, or will in the future. case "${UNAME_MACHINE_ARCH}" in arm*|i386|m68k|ns32k|sh3*|sparc|vax) eval $set_cc_for_build if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | grep __ELF__ >/dev/null then # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). # Return netbsd for either. FIX? os=netbsd else os=netbsdelf fi ;; *) os=netbsd ;; esac # The OS release # Debian GNU/NetBSD machines have a different userland, and # thus, need a distinct triplet. However, they do not need # kernel version information, so it can be replaced with a # suitable tag, in the style of linux-gnu. case "${UNAME_VERSION}" in Debian*) release='-gnu' ;; *) release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` ;; esac # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: # contains redundant information, the shorter form: # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. echo "${machine}-${os}${release}" exit ;; *:OpenBSD:*:*) UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} exit ;; *:ekkoBSD:*:*) echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} exit ;; *:SolidBSD:*:*) echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} exit ;; macppc:MirBSD:*:*) echo powerpc-unknown-mirbsd${UNAME_RELEASE} exit ;; *:MirBSD:*:*) echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} exit ;; alpha:OSF1:*:*) case $UNAME_RELEASE in *4.0) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` ;; *5.*) UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` ;; esac # According to Compaq, /usr/sbin/psrinfo has been available on # OSF/1 and Tru64 systems produced since 1995. I hope that # covers most systems running today. This code pipes the CPU # types through head -n 1, so we only detect the type of CPU 0. ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` case "$ALPHA_CPU_TYPE" in "EV4 (21064)") UNAME_MACHINE="alpha" ;; "EV4.5 (21064)") UNAME_MACHINE="alpha" ;; "LCA4 (21066/21068)") UNAME_MACHINE="alpha" ;; "EV5 (21164)") UNAME_MACHINE="alphaev5" ;; "EV5.6 (21164A)") UNAME_MACHINE="alphaev56" ;; "EV5.6 (21164PC)") UNAME_MACHINE="alphapca56" ;; "EV5.7 (21164PC)") UNAME_MACHINE="alphapca57" ;; "EV6 (21264)") UNAME_MACHINE="alphaev6" ;; "EV6.7 (21264A)") UNAME_MACHINE="alphaev67" ;; "EV6.8CB (21264C)") UNAME_MACHINE="alphaev68" ;; "EV6.8AL (21264B)") UNAME_MACHINE="alphaev68" ;; "EV6.8CX (21264D)") UNAME_MACHINE="alphaev68" ;; "EV6.9A (21264/EV69A)") UNAME_MACHINE="alphaev69" ;; "EV7 (21364)") UNAME_MACHINE="alphaev7" ;; "EV7.9 (21364A)") UNAME_MACHINE="alphaev79" ;; esac # A Pn.n version is a patched version. # A Vn.n version is a released version. # A Tn.n version is a released field test version. # A Xn.n version is an unreleased experimental baselevel. # 1.2 uses "1.2" for uname -r. echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` exit ;; Alpha\ *:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # Should we change UNAME_MACHINE based on the output of uname instead # of the specific Alpha model? echo alpha-pc-interix exit ;; 21064:Windows_NT:50:3) echo alpha-dec-winnt3.5 exit ;; Amiga*:UNIX_System_V:4.0:*) echo m68k-unknown-sysv4 exit ;; *:[Aa]miga[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-amigaos exit ;; *:[Mm]orph[Oo][Ss]:*:*) echo ${UNAME_MACHINE}-unknown-morphos exit ;; *:OS/390:*:*) echo i370-ibm-openedition exit ;; *:z/VM:*:*) echo s390-ibm-zvmoe exit ;; *:OS400:*:*) echo powerpc-ibm-os400 exit ;; arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) echo arm-acorn-riscix${UNAME_RELEASE} exit ;; arm:riscos:*:*|arm:RISCOS:*:*) echo arm-unknown-riscos exit ;; SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) echo hppa1.1-hitachi-hiuxmpp exit ;; Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. if test "`(/bin/universe) 2>/dev/null`" = att ; then echo pyramid-pyramid-sysv3 else echo pyramid-pyramid-bsd fi exit ;; NILE*:*:*:dcosx) echo pyramid-pyramid-svr4 exit ;; DRS?6000:unix:4.0:6*) echo sparc-icl-nx6 exit ;; DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) case `/usr/bin/uname -p` in sparc) echo sparc-icl-nx7; exit ;; esac ;; sun4H:SunOS:5.*:*) echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; i86pc:SunOS:5.*:*) echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) # According to config.sub, this is the proper way to canonicalize # SunOS6. Hard to guess exactly what SunOS6 will be like, but # it's likely to be more like Solaris than SunOS4. echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:*:*) case "`/usr/bin/arch -k`" in Series*|S4*) UNAME_RELEASE=`uname -v` ;; esac # Japanese Language versions have a version number like `4.1.3-JL'. echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` exit ;; sun3*:SunOS:*:*) echo m68k-sun-sunos${UNAME_RELEASE} exit ;; sun*:*:4.2BSD:*) UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 case "`/bin/arch`" in sun3) echo m68k-sun-sunos${UNAME_RELEASE} ;; sun4) echo sparc-sun-sunos${UNAME_RELEASE} ;; esac exit ;; aushp:SunOS:*:*) echo sparc-auspex-sunos${UNAME_RELEASE} exit ;; # The situation for MiNT is a little confusing. The machine name # can be virtually everything (everything which is not # "atarist" or "atariste" at least should have a processor # > m68000). The system name ranges from "MiNT" over "FreeMiNT" # to the lowercase version "mint" (or "freemint"). Finally # the system name "TOS" denotes a system which is actually not # MiNT. But MiNT is downward compatible to TOS, so this should # be no problem. atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) echo m68k-atari-mint${UNAME_RELEASE} exit ;; milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) echo m68k-milan-mint${UNAME_RELEASE} exit ;; hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) echo m68k-hades-mint${UNAME_RELEASE} exit ;; *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) echo m68k-unknown-mint${UNAME_RELEASE} exit ;; m68k:machten:*:*) echo m68k-apple-machten${UNAME_RELEASE} exit ;; powerpc:machten:*:*) echo powerpc-apple-machten${UNAME_RELEASE} exit ;; RISC*:Mach:*:*) echo mips-dec-mach_bsd4.3 exit ;; RISC*:ULTRIX:*:*) echo mips-dec-ultrix${UNAME_RELEASE} exit ;; VAX*:ULTRIX*:*:*) echo vax-dec-ultrix${UNAME_RELEASE} exit ;; 2020:CLIX:*:* | 2430:CLIX:*:*) echo clipper-intergraph-clix${UNAME_RELEASE} exit ;; mips:*:*:UMIPS | mips:*:*:RISCos) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #ifdef __cplusplus #include /* for printf() prototype */ int main (int argc, char *argv[]) { #else int main (argc, argv) int argc; char *argv[]; { #endif #if defined (host_mips) && defined (MIPSEB) #if defined (SYSTYPE_SYSV) printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_SVR4) printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); #endif #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); #endif #endif exit (-1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && SYSTEM_NAME=`$dummy $dummyarg` && { echo "$SYSTEM_NAME"; exit; } echo mips-mips-riscos${UNAME_RELEASE} exit ;; Motorola:PowerMAX_OS:*:*) echo powerpc-motorola-powermax exit ;; Motorola:*:4.3:PL8-*) echo powerpc-harris-powermax exit ;; Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) echo powerpc-harris-powermax exit ;; Night_Hawk:Power_UNIX:*:*) echo powerpc-harris-powerunix exit ;; m88k:CX/UX:7*:*) echo m88k-harris-cxux7 exit ;; m88k:*:4*:R4*) echo m88k-motorola-sysv4 exit ;; m88k:*:3*:R3*) echo m88k-motorola-sysv3 exit ;; AViiON:dgux:*:*) # DG/UX returns AViiON for all architectures UNAME_PROCESSOR=`/usr/bin/uname -p` if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] then if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ [ ${TARGET_BINARY_INTERFACE}x = x ] then echo m88k-dg-dgux${UNAME_RELEASE} else echo m88k-dg-dguxbcs${UNAME_RELEASE} fi else echo i586-dg-dgux${UNAME_RELEASE} fi exit ;; M88*:DolphinOS:*:*) # DolphinOS (SVR3) echo m88k-dolphin-sysv3 exit ;; M88*:*:R3*:*) # Delta 88k system running SVR3 echo m88k-motorola-sysv3 exit ;; XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) echo m88k-tektronix-sysv3 exit ;; Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) echo m68k-tektronix-bsd exit ;; *:IRIX*:*:*) echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` exit ;; ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' i*86:AIX:*:*) echo i386-ibm-aix exit ;; ia64:AIX:*:*) if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} exit ;; *:AIX:2:3) if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include main() { if (!__power_pc()) exit(1); puts("powerpc-ibm-aix3.2.5"); exit(0); } EOF if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` then echo "$SYSTEM_NAME" else echo rs6000-ibm-aix3.2.5 fi elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then echo rs6000-ibm-aix3.2.4 else echo rs6000-ibm-aix3.2 fi exit ;; *:AIX:*:[45]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 else IBM_ARCH=powerpc fi if [ -x /usr/bin/oslevel ] ; then IBM_REV=`/usr/bin/oslevel` else IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} fi echo ${IBM_ARCH}-ibm-aix${IBM_REV} exit ;; *:AIX:*:*) echo rs6000-ibm-aix exit ;; ibmrt:4.4BSD:*|romp-ibm:BSD:*) echo romp-ibm-bsd4.4 exit ;; ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to exit ;; # report: romp-ibm BSD 4.3 *:BOSX:*:*) echo rs6000-bull-bosx exit ;; DPX/2?00:B.O.S.:*:*) echo m68k-bull-sysv3 exit ;; 9000/[34]??:4.3bsd:1.*:*) echo m68k-hp-bsd exit ;; hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) echo m68k-hp-bsd4.4 exit ;; 9000/[34678]??:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` case "${UNAME_MACHINE}" in 9000/31? ) HP_ARCH=m68000 ;; 9000/[34]?? ) HP_ARCH=m68k ;; 9000/[678][0-9][0-9]) if [ -x /usr/bin/getconf ]; then sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` case "${sc_cpu_version}" in 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 532) # CPU_PA_RISC2_0 case "${sc_kernel_bits}" in 32) HP_ARCH="hppa2.0n" ;; 64) HP_ARCH="hppa2.0w" ;; '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 esac ;; esac fi if [ "${HP_ARCH}" = "" ]; then eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #define _HPUX_SOURCE #include #include int main () { #if defined(_SC_KERNEL_BITS) long bits = sysconf(_SC_KERNEL_BITS); #endif long cpu = sysconf (_SC_CPU_VERSION); switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0"); break; case CPU_PA_RISC1_1: puts ("hppa1.1"); break; case CPU_PA_RISC2_0: #if defined(_SC_KERNEL_BITS) switch (bits) { case 64: puts ("hppa2.0w"); break; case 32: puts ("hppa2.0n"); break; default: puts ("hppa2.0"); break; } break; #else /* !defined(_SC_KERNEL_BITS) */ puts ("hppa2.0"); break; #endif default: puts ("hppa1.0"); break; } exit (0); } EOF (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` test -z "$HP_ARCH" && HP_ARCH=hppa fi ;; esac if [ ${HP_ARCH} = "hppa2.0w" ] then eval $set_cc_for_build # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler # generating 64-bit code. GNU and HP use different nomenclature: # # $ CC_FOR_BUILD=cc ./config.guess # => hppa2.0w-hp-hpux11.23 # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess # => hppa64-hp-hpux11.23 if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | grep __LP64__ >/dev/null then HP_ARCH="hppa2.0w" else HP_ARCH="hppa64" fi fi echo ${HP_ARCH}-hp-hpux${HPUX_REV} exit ;; ia64:HP-UX:*:*) HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` echo ia64-hp-hpux${HPUX_REV} exit ;; 3050*:HI-UX:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include int main () { long cpu = sysconf (_SC_CPU_VERSION); /* The order matters, because CPU_IS_HP_MC68K erroneously returns true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct results, however. */ if (CPU_IS_PA_RISC (cpu)) { switch (cpu) { case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; default: puts ("hppa-hitachi-hiuxwe2"); break; } } else if (CPU_IS_HP_MC68K (cpu)) puts ("m68k-hitachi-hiuxwe2"); else puts ("unknown-hitachi-hiuxwe2"); exit (0); } EOF $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } echo unknown-hitachi-hiuxwe2 exit ;; 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) echo hppa1.1-hp-bsd exit ;; 9000/8??:4.3bsd:*:*) echo hppa1.0-hp-bsd exit ;; *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) echo hppa1.0-hp-mpeix exit ;; hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) echo hppa1.1-hp-osf exit ;; hp8??:OSF1:*:*) echo hppa1.0-hp-osf exit ;; i*86:OSF1:*:*) if [ -x /usr/sbin/sysversion ] ; then echo ${UNAME_MACHINE}-unknown-osf1mk else echo ${UNAME_MACHINE}-unknown-osf1 fi exit ;; parisc*:Lites*:*:*) echo hppa1.1-hp-lites exit ;; C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) echo c1-convex-bsd exit ;; C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) echo c34-convex-bsd exit ;; C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) echo c38-convex-bsd exit ;; C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) echo c4-convex-bsd exit ;; CRAY*Y-MP:*:*:*) echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*[A-Z]90:*:*:*) echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ -e 's/\.[^.]*$/.X/' exit ;; CRAY*TS:*:*:*) echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*T3E:*:*:*) echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; CRAY*SV1:*:*:*) echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; *:UNICOS/mp:*:*) echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' exit ;; F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; 5000:UNIX_System_V:4.*:*) FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" exit ;; i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} exit ;; sparc*:BSD/OS:*:*) echo sparc-unknown-bsdi${UNAME_RELEASE} exit ;; *:BSD/OS:*:*) echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} exit ;; *:FreeBSD:*:*) case ${UNAME_MACHINE} in pc98) echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; amd64) echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; *) echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; esac exit ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin exit ;; i*:MINGW*:*) echo ${UNAME_MACHINE}-pc-mingw32 exit ;; i*:windows32*:*) # uname -m includes "-pc" on this system. echo ${UNAME_MACHINE}-mingw32 exit ;; i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; x86:Interix*:[3456]*) echo i586-pc-interix${UNAME_RELEASE} exit ;; EM64T:Interix*:[3456]*) echo x86_64-unknown-interix${UNAME_RELEASE} exit ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; i*:Windows_NT*:* | Pentium*:Windows_NT*:*) # How do we know it's Interix rather than the generic POSIX subsystem? # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we # UNAME_MACHINE based on the output of uname instead of i386? echo i586-pc-interix exit ;; i*:UWIN*:*) echo ${UNAME_MACHINE}-pc-uwin exit ;; amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) echo x86_64-unknown-cygwin exit ;; p*:CYGWIN*:*) echo powerpcle-unknown-cygwin exit ;; prep*:SunOS:5.*:*) echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; *:GNU:*:*) # the GNU system echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` exit ;; *:GNU/*:*:*) # other systems with GNU libc and userland echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu exit ;; i*86:Minix:*:*) echo ${UNAME_MACHINE}-pc-minix exit ;; arm*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; cris:Linux:*:*) echo cris-axis-linux-gnu exit ;; crisv32:Linux:*:*) echo crisv32-axis-linux-gnu exit ;; frv:Linux:*:*) echo frv-unknown-linux-gnu exit ;; ia64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m32r*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; m68*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; mips:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips #undef mipsel #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mipsel #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^CPU/{ s: ::g p }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; mips64:Linux:*:*) eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #undef CPU #undef mips64 #undef mips64el #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) CPU=mips64el #else #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) CPU=mips64 #else CPU= #endif #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^CPU/{ s: ::g p }'`" test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } ;; or32:Linux:*:*) echo or32-unknown-linux-gnu exit ;; ppc:Linux:*:*) echo powerpc-unknown-linux-gnu exit ;; ppc64:Linux:*:*) echo powerpc64-unknown-linux-gnu exit ;; alpha:Linux:*:*) case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in EV5) UNAME_MACHINE=alphaev5 ;; EV56) UNAME_MACHINE=alphaev56 ;; PCA56) UNAME_MACHINE=alphapca56 ;; PCA57) UNAME_MACHINE=alphapca56 ;; EV6) UNAME_MACHINE=alphaev6 ;; EV67) UNAME_MACHINE=alphaev67 ;; EV68*) UNAME_MACHINE=alphaev68 ;; esac objdump --private-headers /bin/sh | grep ld.so.1 >/dev/null if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} exit ;; parisc:Linux:*:* | hppa:Linux:*:*) # Look for CPU level case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in PA7*) echo hppa1.1-unknown-linux-gnu ;; PA8*) echo hppa2.0-unknown-linux-gnu ;; *) echo hppa-unknown-linux-gnu ;; esac exit ;; parisc64:Linux:*:* | hppa64:Linux:*:*) echo hppa64-unknown-linux-gnu exit ;; s390:Linux:*:* | s390x:Linux:*:*) echo ${UNAME_MACHINE}-ibm-linux exit ;; sh64*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sh*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; sparc:Linux:*:* | sparc64:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; vax:Linux:*:*) echo ${UNAME_MACHINE}-dec-linux-gnu exit ;; x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; i*86:Linux:*:*) # The BFD linker knows what the default object file format is, so # first see if it will tell us. cd to the root directory to prevent # problems with other programs or directories called `ld' in the path. # Set LC_ALL=C to ensure ld outputs messages in English. ld_supported_targets=`cd /; LC_ALL=C ld --help 2>&1 \ | sed -ne '/supported targets:/!d s/[ ][ ]*/ /g s/.*supported targets: *// s/ .*// p'` case "$ld_supported_targets" in elf32-i386) TENTATIVE="${UNAME_MACHINE}-pc-linux-gnu" ;; a.out-i386-linux) echo "${UNAME_MACHINE}-pc-linux-gnuaout" exit ;; coff-i386) echo "${UNAME_MACHINE}-pc-linux-gnucoff" exit ;; "") # Either a pre-BFD a.out linker (linux-gnuoldld) or # one that does not give us useful --help. echo "${UNAME_MACHINE}-pc-linux-gnuoldld" exit ;; esac # Determine whether the default compiler is a.out or elf eval $set_cc_for_build sed 's/^ //' << EOF >$dummy.c #include #ifdef __ELF__ # ifdef __GLIBC__ # if __GLIBC__ >= 2 LIBC=gnu # else LIBC=gnulibc1 # endif # else LIBC=gnulibc1 # endif #else #if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC) LIBC=gnu #else LIBC=gnuaout #endif #endif #ifdef __dietlibc__ LIBC=dietlibc #endif EOF eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n ' /^LIBC/{ s: ::g p }'`" test x"${LIBC}" != x && { echo "${UNAME_MACHINE}-pc-linux-${LIBC}" exit } test x"${TENTATIVE}" != x && { echo "${TENTATIVE}"; exit; } ;; i*86:DYNIX/ptx:4*:*) # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. # earlier versions are messed up and put the nodename in both # sysname and nodename. echo i386-sequent-sysv4 exit ;; i*86:UNIX_SV:4.2MP:2.*) # Unixware is an offshoot of SVR4, but it has its own version # number series starting with 2... # I am not positive that other SVR4 systems won't match this, # I just have to hope. -- rms. # Use sysv4.2uw... so that sysv4* matches it. echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} exit ;; i*86:OS/2:*:*) # If we were able to find `uname', then EMX Unix compatibility # is probably installed. echo ${UNAME_MACHINE}-pc-os2-emx exit ;; i*86:XTS-300:*:STOP) echo ${UNAME_MACHINE}-unknown-stop exit ;; i*86:atheos:*:*) echo ${UNAME_MACHINE}-unknown-atheos exit ;; i*86:syllable:*:*) echo ${UNAME_MACHINE}-pc-syllable exit ;; i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*) echo i386-unknown-lynxos${UNAME_RELEASE} exit ;; i*86:*DOS:*:*) echo ${UNAME_MACHINE}-pc-msdosdjgpp exit ;; i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} else echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} fi exit ;; i*86:*:5:[678]*) # UnixWare 7.x, OpenUNIX and OpenServer 6. case `/bin/uname -X | grep "^Machine"` in *486*) UNAME_MACHINE=i486 ;; *Pentium) UNAME_MACHINE=i586 ;; *Pent*|*Celeron) UNAME_MACHINE=i686 ;; esac echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} exit ;; i*86:*:3.2:*) if test -f /usr/options/cb.name; then UNAME_REL=`sed -n 's/.*Version //p' /dev/null >/dev/null ; then UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ && UNAME_MACHINE=i586 (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ && UNAME_MACHINE=i686 (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ && UNAME_MACHINE=i686 echo ${UNAME_MACHINE}-pc-sco$UNAME_REL else echo ${UNAME_MACHINE}-pc-sysv32 fi exit ;; pc:*:*:*) # Left here for compatibility: # uname -m prints for DJGPP always 'pc', but it prints nothing about # the processor, so we play safe by assuming i386. echo i386-pc-msdosdjgpp exit ;; Intel:Mach:3*:*) echo i386-pc-mach3 exit ;; paragon:*:*:*) echo i860-intel-osf1 exit ;; i860:*:4.*:*) # i860-SVR4 if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 else # Add other i860-SVR4 vendors below as they are discovered. echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 fi exit ;; mini*:CTIX:SYS*5:*) # "miniframe" echo m68010-convergent-sysv exit ;; mc68k:UNIX:SYSTEM5:3.51m) echo m68k-convergent-sysv exit ;; M680?0:D-NIX:5.3:*) echo m68k-diab-dnix exit ;; M68*:*:R3V[5678]*:*) test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) OS_REL='' test -r /etc/.relid \ && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4.3${OS_REL}; exit; } /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ && { echo i486-ncr-sysv4; exit; } ;; m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) echo m68k-unknown-lynxos${UNAME_RELEASE} exit ;; mc68030:UNIX_System_V:4.*:*) echo m68k-atari-sysv4 exit ;; TSUNAMI:LynxOS:2.*:*) echo sparc-unknown-lynxos${UNAME_RELEASE} exit ;; rs6000:LynxOS:2.*:*) echo rs6000-unknown-lynxos${UNAME_RELEASE} exit ;; PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.0*:*) echo powerpc-unknown-lynxos${UNAME_RELEASE} exit ;; SM[BE]S:UNIX_SV:*:*) echo mips-dde-sysv${UNAME_RELEASE} exit ;; RM*:ReliantUNIX-*:*:*) echo mips-sni-sysv4 exit ;; RM*:SINIX-*:*:*) echo mips-sni-sysv4 exit ;; *:SINIX-*:*:*) if uname -p 2>/dev/null >/dev/null ; then UNAME_MACHINE=`(uname -p) 2>/dev/null` echo ${UNAME_MACHINE}-sni-sysv4 else echo ns32k-sni-sysv fi exit ;; PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort # says echo i586-unisys-sysv4 exit ;; *:UNIX_System_V:4*:FTX*) # From Gerald Hewes . # How about differentiating between stratus architectures? -djm echo hppa1.1-stratus-sysv4 exit ;; *:*:*:FTX*) # From seanf@swdc.stratus.com. echo i860-stratus-sysv4 exit ;; i*86:VOS:*:*) # From Paul.Green@stratus.com. echo ${UNAME_MACHINE}-stratus-vos exit ;; *:VOS:*:*) # From Paul.Green@stratus.com. echo hppa1.1-stratus-vos exit ;; mc68*:A/UX:*:*) echo m68k-apple-aux${UNAME_RELEASE} exit ;; news*:NEWS-OS:6*:*) echo mips-sony-newsos6 exit ;; R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) if [ -d /usr/nec ]; then echo mips-nec-sysv${UNAME_RELEASE} else echo mips-unknown-sysv${UNAME_RELEASE} fi exit ;; BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. echo powerpc-be-beos exit ;; BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. echo powerpc-apple-beos exit ;; BePC:BeOS:*:*) # BeOS running on Intel PC compatible. echo i586-pc-beos exit ;; SX-4:SUPER-UX:*:*) echo sx4-nec-superux${UNAME_RELEASE} exit ;; SX-5:SUPER-UX:*:*) echo sx5-nec-superux${UNAME_RELEASE} exit ;; SX-6:SUPER-UX:*:*) echo sx6-nec-superux${UNAME_RELEASE} exit ;; Power*:Rhapsody:*:*) echo powerpc-apple-rhapsody${UNAME_RELEASE} exit ;; *:Rhapsody:*:*) echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} exit ;; *:Darwin:*:*) UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown case $UNAME_PROCESSOR in unknown) UNAME_PROCESSOR=powerpc ;; esac echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} exit ;; *:procnto*:*:* | *:QNX:[0123456789]*:*) UNAME_PROCESSOR=`uname -p` if test "$UNAME_PROCESSOR" = "x86"; then UNAME_PROCESSOR=i386 UNAME_MACHINE=pc fi echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} exit ;; *:QNX:*:4*) echo i386-pc-qnx exit ;; NSE-?:NONSTOP_KERNEL:*:*) echo nse-tandem-nsk${UNAME_RELEASE} exit ;; NSR-?:NONSTOP_KERNEL:*:*) echo nsr-tandem-nsk${UNAME_RELEASE} exit ;; *:NonStop-UX:*:*) echo mips-compaq-nonstopux exit ;; BS2000:POSIX*:*:*) echo bs2000-siemens-sysv exit ;; DS/*:UNIX_System_V:*:*) echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} exit ;; *:Plan9:*:*) # "uname -m" is not consistent, so use $cputype instead. 386 # is converted to i386 for consistency with other x86 # operating systems. if test "$cputype" = "386"; then UNAME_MACHINE=i386 else UNAME_MACHINE="$cputype" fi echo ${UNAME_MACHINE}-unknown-plan9 exit ;; *:TOPS-10:*:*) echo pdp10-unknown-tops10 exit ;; *:TENEX:*:*) echo pdp10-unknown-tenex exit ;; KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) echo pdp10-dec-tops20 exit ;; XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) echo pdp10-xkl-tops20 exit ;; *:TOPS-20:*:*) echo pdp10-unknown-tops20 exit ;; *:ITS:*:*) echo pdp10-unknown-its exit ;; SEI:*:*:SEIUX) echo mips-sei-seiux${UNAME_RELEASE} exit ;; *:DragonFly:*:*) echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit ;; *:*VMS:*:*) UNAME_MACHINE=`(uname -p) 2>/dev/null` case "${UNAME_MACHINE}" in A*) echo alpha-dec-vms ; exit ;; I*) echo ia64-dec-vms ; exit ;; V*) echo vax-dec-vms ; exit ;; esac ;; *:XENIX:*:SysV) echo i386-pc-xenix exit ;; i*86:skyos:*:*) echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' exit ;; i*86:rdos:*:*) echo ${UNAME_MACHINE}-pc-rdos exit ;; esac #echo '(No uname command or uname output not recognized.)' 1>&2 #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 eval $set_cc_for_build cat >$dummy.c < # include #endif main () { #if defined (sony) #if defined (MIPSEB) /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, I don't know.... */ printf ("mips-sony-bsd\n"); exit (0); #else #include printf ("m68k-sony-newsos%s\n", #ifdef NEWSOS4 "4" #else "" #endif ); exit (0); #endif #endif #if defined (__arm) && defined (__acorn) && defined (__unix) printf ("arm-acorn-riscix\n"); exit (0); #endif #if defined (hp300) && !defined (hpux) printf ("m68k-hp-bsd\n"); exit (0); #endif #if defined (NeXT) #if !defined (__ARCHITECTURE__) #define __ARCHITECTURE__ "m68k" #endif int version; version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; if (version < 4) printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); else printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); exit (0); #endif #if defined (MULTIMAX) || defined (n16) #if defined (UMAXV) printf ("ns32k-encore-sysv\n"); exit (0); #else #if defined (CMU) printf ("ns32k-encore-mach\n"); exit (0); #else printf ("ns32k-encore-bsd\n"); exit (0); #endif #endif #endif #if defined (__386BSD__) printf ("i386-pc-bsd\n"); exit (0); #endif #if defined (sequent) #if defined (i386) printf ("i386-sequent-dynix\n"); exit (0); #endif #if defined (ns32000) printf ("ns32k-sequent-dynix\n"); exit (0); #endif #endif #if defined (_SEQUENT_) struct utsname un; uname(&un); if (strncmp(un.version, "V2", 2) == 0) { printf ("i386-sequent-ptx2\n"); exit (0); } if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ printf ("i386-sequent-ptx1\n"); exit (0); } printf ("i386-sequent-ptx\n"); exit (0); #endif #if defined (vax) # if !defined (ultrix) # include # if defined (BSD) # if BSD == 43 printf ("vax-dec-bsd4.3\n"); exit (0); # else # if BSD == 199006 printf ("vax-dec-bsd4.3reno\n"); exit (0); # else printf ("vax-dec-bsd\n"); exit (0); # endif # endif # else printf ("vax-dec-bsd\n"); exit (0); # endif # else printf ("vax-dec-ultrix\n"); exit (0); # endif #endif #if defined (alliant) && defined (i860) printf ("i860-alliant-bsd\n"); exit (0); #endif exit (1); } EOF $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && { echo "$SYSTEM_NAME"; exit; } # Apollos put the system type in the environment. test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } # Convex versions that predate uname can use getsysinfo(1) if [ -x /usr/convex/getsysinfo ] then case `getsysinfo -f cpu_type` in c1*) echo c1-convex-bsd exit ;; c2*) if getsysinfo -f scalar_acc then echo c32-convex-bsd else echo c2-convex-bsd fi exit ;; c34*) echo c34-convex-bsd exit ;; c38*) echo c38-convex-bsd exit ;; c4*) echo c4-convex-bsd exit ;; esac fi cat >&2 < in order to provide the needed information to handle your system. config.guess timestamp = $timestamp uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` /bin/uname -X = `(/bin/uname -X) 2>/dev/null` hostinfo = `(hostinfo) 2>/dev/null` /bin/universe = `(/bin/universe) 2>/dev/null` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` /bin/arch = `(/bin/arch) 2>/dev/null` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` UNAME_MACHINE = ${UNAME_MACHINE} UNAME_RELEASE = ${UNAME_RELEASE} UNAME_SYSTEM = ${UNAME_SYSTEM} UNAME_VERSION = ${UNAME_VERSION} EOF exit 1 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "timestamp='" # time-stamp-format: "%:y-%02m-%02d" # time-stamp-end: "'" # End: brp-pacu/config.h0000644000175000017500000000157412153127664012665 0ustar miramira/* config.h. Generated from config.h.in by configure. */ /* config.h.in. Generated from configure.ac by autoheader. */ /* Define to 1 if you have the `fftw' library (-lfftw). */ /* #undef HAVE_LIBFFTW */ /* Define to 1 if you have the `m' library (-lm). */ /* #undef HAVE_LIBM */ /* Name of package */ #define PACKAGE "BRP_PACU" /* Define to the address where bug reports for this package should be sent. */ #define PACKAGE_BUGREPORT "" /* Define to the full name of this package. */ #define PACKAGE_NAME "" /* Define to the full name and version of this package. */ #define PACKAGE_STRING "" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "" /* Define to the home page for this package. */ #define PACKAGE_URL "" /* Define to the version of this package. */ #define PACKAGE_VERSION "" /* Version number of package */ #define VERSION "2.1.1" brp-pacu/brpData.icns0000644000175000017500000011641312153127664013501 0ustar miramiraicns ics#H????????????????????????????????is32 „ ߓ οߌ ̈߆ נ}ǰÁЁ   „ ߓ οߌ ̈߆ נ}ǰ eU!ÁòЁ؀ ( Xtnf||T EL?!C „ ߓ οߌ ̈߆ נ}ǰ ÁЁ    s8mk%<999'9>9D9I9N9N9N9N9N9N;P=CICN#il32²¹ ©ь ʷՋ Ͽʊ ţ̉ʟɈͧɇ ӶƇ ʲ ź ‡#$χׇۇ߇&%#  $²¹ ©ь ʷՋ Ͽʊ ţ̉ ʟɈͧɇ ӶƇ ʲ ź ‡* " " " h " " " ,χ έ ׇ!ޅ!ۇ!B$!߇ hF "j"  "" Ԅ "1" J0U6<>  <^( |[\ŋ[Ů[[ŏ5pOp!t** " "G& " 43 " ,²¹ ©ь ʷՋ Ͽʊ ţ̉ ʟɈͧɇ ӶƇ ʲ ź ‡%'χׇۇ߇          %  'l8mk 1 AZAAAAA4AA A,A@AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABB778BAAAAAAAAAAAAAAAAAAB8ich#Hih32 9yŽŻö ɼȧ­ӤȳӦ ̸ѦμӤѿӦ ¥Ǯvuw| κɾþŴνċˋ*!!!# !!!.ϋҋՋ׋!!ڋۋ݋!!ߋ!!!! #   %(&-!!%!!! $!!1yŽŻö ɼȧ­ӤȳӦ ̸ѦμӤѿӦ ¥Ǯvuw| κɾþŴνċˋ1$$($($($$x$$($($$($5ϋ&"̊&ҋ$R%$Ջ$S$׋((ڋ$$ۋ$ ̉$݋(=(ߋ$d0$$U$$x$(́($$$0$(Q%($d9xJMP$$}!r;O$ .:zЃ $0}E uN!* )=ց2}%$u$4$$($(CX($$($(+($$($8yÂŽŻö ɼȧ­ӤȳӦ ̸ѦμӤѿӦ ¥Ǯvuw| κɾþŴνċˋ- # # #  # # # 1ϋ""ӋՋ ׋# #ڋۋ݋##ߋ   # ###     &    '     / # ## # ## # 3h8mk +NQQQQQQQQQQQQQQQQQPM* i '/12 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 1 ,5Wgiiiiiiiiiiiiiiiiiiiiiiiiiiiii_C#)*****************************& it324߂݀ րv߂ڀ¿Uހہÿހہ¿ހہ¾d߀ۀրf߀ۀրd߀ۀր¾Ƚf߀ہ»ʼf߀ۀÿʼfۀʼbրüʻbހ ƿʻbހۀ¹ʻaހۀüʻa߀ ƿʻa߀ ʻa߀ۀºʻa߀ۀ ûʻa߀ۀ üʻażʻbǾʻbʻbʻbøʻf!ùvnnʼf$Ļ{slifddegimptʼf$Ƽxsnljjklnqsvzfzwts ttvy|~dú~|} Yž º ƿ ?, ʁу ¿ր  ܀ڀ¿äǤʤΤФҤդפN1N1N1N12A51N1N1N1>^ڤ22ۤNNܤ22ݤ22ޤ22ߤ2222222222NN2222222222222222NN2222222222222222NN2222222222222222NN2222222222222222S6567675767576[5222222222222222NNN1N1N169711N1N1N1149821N1N1>^߂݀ րv߂܀Հ¿Uހہÿހہ¿ހہ¾d߀ۀրf߀ۀրd߀ۀր¾Ƚf߀ہ»ʼf߀ۀÿʼfۀʼbրüʻbހ ƿʻbހۀ¹ʻaހۀüʻa߀ ƿʻa߀ ʻa߀ۀºʻa߀ۀ ûʻa߀ۀ üʻażʻbǾʻbʻbʻbøʻf!ùvnnʼf$Ļ{slifddegimptʼf$Ƽxsnljjklnqsvzfzwts ttvy|~dú~|} Yž º ƿ ?, ʁс ¿ր  ܀ڀ¿ äǤ ݀ʤΤФҤդפT8T8T8T8Pގ8T8T8T8Ecڤ9G9ۤTATܤ9%9ݤ9ۀ^9ޤ9:9ߤ9_¡99,99ӂS99'p99>9ToT9+99D99 ׅ]99599M99{ҟ99/99†B9Tڇ]T9;99J99q99$99;99ˉK99-{99A9TZT9 99299ŋC99!݋d99=99K99z99-9T>T9׍\99599?%Nm}995xh99#ق4+^99,ЏN$99J/}099˅$HR9ɅÆƆЅ$uliA97M'.99c=u+ с699mR@C)+99\99#Fh99WЁ99(!u9Tlu#TT8T8T89;8T8T8T88pO8T8T8Ec߂݀ րv߁ ׀ԀUހہÿހہ¿ހہ¾d߀ۀրf߀ۀրd߀ۀր¾Ƚf߀ہ»ʼf߀ۀÿʼfۀʼbրüʻbހ ƿʻbހۀ¹ʻaހۀüʻa߀ ƿʻa߀ ʻa߀ۀºʻa߀ۀ ûʻa߀ۀ üʻażʻbǾʻbʻbʻbøʻf!ùvnnʼf$Ļ{slifddegimptʼf$Ƽxsnljjklnqsvzfzwts ttvy|~dú~|} Yž º ƿ ?, ʁу ¿ր  ܀ڀ¿ äǤʤΤФҤդפQ4P4P4P421-4P4P4P4A`ڤ44ۤPPܤ4 4ݤ44ޤ4 4ߤ4 44 4444 44 4P P4 444444 4444 44 444PP4 4444 44 444444 444PP4 44 4444 44 4444 44 4PP444 44  44   44 44 44  44 4H+*+-+*+*,-)+)-(+T.   44  44    44 44 44  44 44  4P  PQ4P4P4+$)44P4P4P440%&24P4P4A`t8mk@    E   9  ,n  %6|  *>Y .EZ 1I[ 3KZ 3LZ 3LZ 3M[ 3M[ 3M[ 3M\ 3M\ 3M\ 3M\ 3M\ 3M\ 3M\ 3M[ 3M[ 3M[ 3M[ 3MZ 3MZ 3MZ 3MZ 3MY 3MG 3M'3M$ 3MD 3M' 3M03M7# 3M>( 3MC, 3MG/3MI13MJ23MK33ML33ML33ML33ML33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33MM33LL33LL33KK31II1.EE. *>>*  %6I[itz~~zti[I6%  ,;IU]befffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffeb]UI;,   ,6>EIKLLMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMLLKIE>6,  %*.133333333333333333333333333333333333333333333333333333333333333333333333333333331.*%    brp-pacu/README0000644000175000017500000001234512153127664012125 0ustar miramiraBRP-PACU - An Audio Configuration utility To compile BRP-PACU on Linux, this must be installed: * JACK. Any recent version will work, just take what the distribution provides, the package is probably named "jackd". – Tip: If jack is not already installed on your system, try to install the package "qjackctl" which depends on JACK. * The development files that matches the installed version of JACK. – Finding the right development package: Search for packages with libjack in their names. Notice the name of the installed libjack*, and find the most similar named package which name is ending in "-dev", and install that one. * GTK databox, library and header files, in version 0.9.1-1 (that will work) or preferable newer. – In Ubuntu 10.10 you can install the package libgtkdatabox-0.9.1-1-dev , but: – It is recommended to use a newer version, because there are a few UI tweaks in the latest gtkdatabox. Get it from the source code released on https://sourceforge.net/projects/gtkdatabox * FFTW version 2.1.5, the package is probably named “fftw-dev”, or download it from http://www.fftw.org/download.html (note: v. 3 is not supported) * the GTK+ and Glade stuff (including its dependencies such as Glib and Pango), with these packages (and their dependencies) libglade2-dev libgtk2.0-dev libglib2.0-dev GTK+ stable release from http://gtk.org * The building tools in these packages: build-essential autotools-dev autoconf automake pkg-config make gcc If the source code comes directly from the GIT repository, instead of a release in a tar ball, you must run “aclocal && autoconf && automake” before running “./configure”. Details about the actual compilation procedure (run ./configure, then make, then sudo make install) are found in the file “INSTALL” =========================================== A tip for JACK and PulseAudio co-existense (not unique to BRP-PACU) ------------------------------------------- A way to automate the switching betweenf which software that can get direct (and thus exclusive) access to the audio hardware ins and outs. In ubuntu (at least) the file /etc/pulse/client.conf needs to have the line: autospawn = no and put “pulseaudio -k” in the jackd start script and “pulseaudio --start” in the jackd stop script (can be done from qjackctl under setup->options-> execute script at startup). Otherwise pulseaudio will grab ownership instantly on any sound card you try and you will never get jackd to start. =========================================== When BRP-PACU is installed, the executable is named “BRP_PACU”. It can be started from the Run dialog (that comes up when pressing ALt-F2), or from a command line which will give extra debugging information. =========================================== Some other info is placed on Wikipedia: en.wikipedia.org/wiki/BRP-PACU =========================================== A binary pakcage for Debian can be found at http://packages.debian.org/sid/brp-pacu . =========================================== Never before asked questions ------------------------------------------- What is BRP-PACU? - It is an analysis tool to configure any sound system with an equalizer. It compares the output of the system to the input of the system and allows you to use this data to perform final equalization by matching the results with actual DSP/EQ. How do you do this? - There are many tutorials on doing this, but it takes practice, experience, and a good ear. You could try: http://www.sounddevices.com/notes/usbpre/usbpre-with-sia-smaart-software/ its a brief introduction to the concept, although the USBPre is not supported by linux as of writing this, so you couldn't use it with this software. Try the M-Audio usb preamp, its what I use. You also need a decent omnidirectional calibrated mic (reasonably flat 20Hz-20kHz). Isn't this software basically like what XYZ company sells for $1100? - Yes Why are you giving it away for free? - There currently is no Linux port for any of these programs and I needed one. Also I believe anyone who knows how to perform the transfer function properly on an audio system should be able to without selling your soul with some ridiculous EULA and forking over $1100. The barrier to entry in any market should be knowledge and skill, not overpriced tools. There are many markets already headed in this direction. What if I try it and it doesn't work? - Email me and I can probably figure it out. My email is lm317t@gmail.com. Also try the mailing list, it should be working. Why is there no documentation? - Channel 1 is the output of the system we are observing (measured), channel 2 is the input (reference). You also need a decent calibrated omnidrectional microphone (reasonably flat 20Hz-20kHz) and either a USB-Preamp like the 2-channel M-Audio, or a mixer with a 30dB pad or so going into the laptop mic input. No Pad is neccessary if you are lucky enough to have a laptop or PC with a line input. The headphone out will have the pink noise. How do you handle a delay between measured and referenced signals? - There is an automatic delay finding button. You can also insert a custom delay if you want. Is there a way to find the impulse response? - It is in the menu under action brp-pacu/description-pak0000644000175000017500000000004412153127664014255 0ustar miramiraBRP_PACU Dual FFT Transfer Function brp-pacu/config.h.in0000644000175000017500000000141012153127664013257 0ustar miramira/* config.h.in. Generated from configure.ac by autoheader. */ /* Define to 1 if you have the `fftw' library (-lfftw). */ #undef HAVE_LIBFFTW /* Define to 1 if you have the `m' library (-lm). */ #undef HAVE_LIBM /* Name of package */ #undef PACKAGE /* Define to the address where bug reports for this package should be sent. */ #undef PACKAGE_BUGREPORT /* Define to the full name of this package. */ #undef PACKAGE_NAME /* Define to the full name and version of this package. */ #undef PACKAGE_STRING /* Define to the one symbol short name of this package. */ #undef PACKAGE_TARNAME /* Define to the home page for this package. */ #undef PACKAGE_URL /* Define to the version of this package. */ #undef PACKAGE_VERSION /* Version number of package */ #undef VERSION brp-pacu/missing0000755000175000017500000002540612153127664012646 0ustar miramira#! /bin/sh # Common stub for a few missing GNU programs while installing. scriptversion=2005-06-08.21 # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005 # Free Software Foundation, Inc. # Originally by Fran,cois Pinard , 1996. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. if test $# -eq 0; then echo 1>&2 "Try \`$0 --help' for more information" exit 1 fi run=: # In the cases where this matters, `missing' is being run in the # srcdir already. if test -f configure.ac; then configure_ac=configure.ac else configure_ac=configure.in fi msg="missing on your system" case "$1" in --run) # Try to run requested program, and just exit if it succeeds. run= shift "$@" && exit 0 # Exit code 63 means version mismatch. This often happens # when the user try to use an ancient version of a tool on # a file that requires a minimum version. In this case we # we should proceed has if the program had been absent, or # if --run hadn't been passed. if test $? = 63; then run=: msg="probably too old" fi ;; -h|--h|--he|--hel|--help) echo "\ $0 [OPTION]... PROGRAM [ARGUMENT]... Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an error status if there is no known handling for PROGRAM. Options: -h, --help display this help and exit -v, --version output version information and exit --run try to run the given command, and emulate it if it fails Supported PROGRAM values: aclocal touch file \`aclocal.m4' autoconf touch file \`configure' autoheader touch file \`config.h.in' automake touch all \`Makefile.in' files bison create \`y.tab.[ch]', if possible, from existing .[ch] flex create \`lex.yy.c', if possible, from existing .c help2man touch the output file lex create \`lex.yy.c', if possible, from existing .c makeinfo touch the output file tar try tar, gnutar, gtar, then tar without non-portable flags yacc create \`y.tab.[ch]', if possible, from existing .[ch] Send bug reports to ." exit $? ;; -v|--v|--ve|--ver|--vers|--versi|--versio|--version) echo "missing $scriptversion (GNU Automake)" exit $? ;; -*) echo 1>&2 "$0: Unknown \`$1' option" echo 1>&2 "Try \`$0 --help' for more information" exit 1 ;; esac # Now exit if we have it, but it failed. Also exit now if we # don't have it and --version was passed (most likely to detect # the program). case "$1" in lex|yacc) # Not GNU programs, they don't have --version. ;; tar) if test -n "$run"; then echo 1>&2 "ERROR: \`tar' requires --run" exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then exit 1 fi ;; *) if test -z "$run" && ($1 --version) > /dev/null 2>&1; then # We have it, but it failed. exit 1 elif test "x$2" = "x--version" || test "x$2" = "x--help"; then # Could not run --version or --help. This is probably someone # running `$TOOL --version' or `$TOOL --help' to check whether # $TOOL exists and not knowing $TOOL uses missing. exit 1 fi ;; esac # If it does not exist, or fails to run (possibly an outdated version), # try to emulate it. case "$1" in aclocal*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." touch aclocal.m4 ;; autoconf) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." touch configure ;; autoheader) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`acconfig.h' or \`${configure_ac}'. You might want to install the \`Autoconf' and \`GNU m4' packages. Grab them from any GNU archive site." files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` test -z "$files" && files="config.h" touch_files= for f in $files; do case "$f" in *:*) touch_files="$touch_files "`echo "$f" | sed -e 's/^[^:]*://' -e 's/:.*//'`;; *) touch_files="$touch_files $f.in";; esac done touch $touch_files ;; automake*) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. You might want to install the \`Automake' and \`Perl' packages. Grab them from any GNU archive site." find . -type f -name Makefile.am -print | sed 's/\.am$/.in/' | while read f; do touch "$f"; done ;; autom4te) echo 1>&2 "\ WARNING: \`$1' is needed, but is $msg. You might have modified some files without having the proper tools for further handling them. You can get \`$1' as part of \`Autoconf' from any GNU archive site." file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'` test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'` if test -f "$file"; then touch $file else test -z "$file" || exec >$file echo "#! /bin/sh" echo "# Created by GNU Automake missing as a replacement of" echo "# $ $@" echo "exit 0" chmod +x $file exit 1 fi ;; bison|yacc) echo 1>&2 "\ WARNING: \`$1' $msg. You should only need it if you modified a \`.y' file. You may need the \`Bison' package in order for those modifications to take effect. You can get \`Bison' from any GNU archive site." rm -f y.tab.c y.tab.h if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.y) SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.c fi SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" y.tab.h fi ;; esac fi if [ ! -f y.tab.h ]; then echo >y.tab.h fi if [ ! -f y.tab.c ]; then echo 'main() { return 0; }' >y.tab.c fi ;; lex|flex) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.l' file. You may need the \`Flex' package in order for those modifications to take effect. You can get \`Flex' from any GNU archive site." rm -f lex.yy.c if [ $# -ne 1 ]; then eval LASTARG="\${$#}" case "$LASTARG" in *.l) SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` if [ -f "$SRCFILE" ]; then cp "$SRCFILE" lex.yy.c fi ;; esac fi if [ ! -f lex.yy.c ]; then echo 'main() { return 0; }' >lex.yy.c fi ;; help2man) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a dependency of a manual page. You may need the \`Help2man' package in order for those modifications to take effect. You can get \`Help2man' from any GNU archive site." file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'` fi if [ -f "$file" ]; then touch $file else test -z "$file" || exec >$file echo ".ab help2man is required to generate this page" exit 1 fi ;; makeinfo) echo 1>&2 "\ WARNING: \`$1' is $msg. You should only need it if you modified a \`.texi' or \`.texinfo' file, or any other file indirectly affecting the aspect of the manual. The spurious call might also be the consequence of using a buggy \`make' (AIX, DU, IRIX). You might want to install the \`Texinfo' package or the \`GNU make' package. Grab either from any GNU archive site." # The file to touch is that specified with -o ... file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'` if test -z "$file"; then # ... or it is the one specified with @setfilename ... infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` file=`sed -n '/^@setfilename/ { s/.* \([^ ]*\) *$/\1/; p; q; }' $infile` # ... or it is derived from the source name (dir/f.texi becomes f.info) test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info fi # If the file does not exist, the user really needs makeinfo; # let's fail without touching anything. test -f $file || exit 1 touch $file ;; tar) shift # We have already tried tar in the generic part. # Look for gnutar/gtar before invocation to avoid ugly error # messages. if (gnutar --version > /dev/null 2>&1); then gnutar "$@" && exit 0 fi if (gtar --version > /dev/null 2>&1); then gtar "$@" && exit 0 fi firstarg="$1" if shift; then case "$firstarg" in *o*) firstarg=`echo "$firstarg" | sed s/o//` tar "$firstarg" "$@" && exit 0 ;; esac case "$firstarg" in *h*) firstarg=`echo "$firstarg" | sed s/h//` tar "$firstarg" "$@" && exit 0 ;; esac fi echo 1>&2 "\ WARNING: I can't seem to be able to run \`tar' with the given arguments. You may want to install GNU tar or Free paxutils, or check the command line arguments." exit 1 ;; *) echo 1>&2 "\ WARNING: \`$1' is needed, and is $msg. You might have modified some files without having the proper tools for further handling them. Check the \`README' file, it often tells you about the needed prerequisites for installing this package. You may also peek at any GNU archive site, in case some other package would contain this missing \`$1' program." exit 1 ;; esac exit 0 # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: brp-pacu/ige-mac-menu.c0000644000175000017500000007655212153127664013667 0ustar miramira/* GTK+ Integration for the Mac OS X Menubar. * * Copyright (C) 2007 Pioneer Research Center USA, Inc. * Copyright (C) 2007, 2008 Imendio AB * * For further information, see: * http://developer.imendio.com/projects/gtk-macosx/menubar * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; version 2.1 * of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ #include "config.h" #include #include #include #include #import #include "ige-mac-menu.h" #include "ige-mac-private.h" /* TODO * * - Adding a standard Window menu (Minimize etc)? * - Sync reordering items? Does that work now? * - Create on demand? (can this be done with gtk+? ie fill in menu items when the menu is opened) * * - Deleting a menu item that is not the last one in a menu doesn't work */ #define IGE_QUARTZ_MENU_CREATOR 'IGEC' #define IGE_QUARTZ_ITEM_WIDGET 'IWID' #define IGE_MAC_KEY_HANDLER "ige-mac-key-handler" static MenuID last_menu_id; static gboolean global_key_handler_enabled = TRUE; static void sync_menu_shell (GtkMenuShell *menu_shell, MenuRef carbon_menu, gboolean toplevel, gboolean debug); /* A category that exposes the protected carbon event for an NSEvent. */ @interface NSEvent (GdkQuartzNSEvent) - (void *)gdk_quartz_event_ref; @end @implementation NSEvent (GdkQuartzNSEvent) - (void *)gdk_quartz_event_ref { return _eventRef; } @end static gboolean menu_flash_off_cb (gpointer data) { /* Disable flash by flashing a non-existing menu id. */ FlashMenuBar (last_menu_id + 1); return FALSE; } /* * utility functions */ static GtkWidget * find_menu_label (GtkWidget *widget) { GtkWidget *label = NULL; if (GTK_IS_LABEL (widget)) return widget; if (GTK_IS_CONTAINER (widget)) { GList *children; GList *l; children = gtk_container_get_children (GTK_CONTAINER (widget)); for (l = children; l; l = l->next) { label = find_menu_label (l->data); if (label) break; } g_list_free (children); } return label; } static const gchar * get_menu_label_text (GtkWidget *menu_item, GtkWidget **label) { GtkWidget *my_label; my_label = find_menu_label (menu_item); if (label) *label = my_label; if (my_label) return gtk_label_get_text (GTK_LABEL (my_label)); return NULL; } static gboolean accel_find_func (GtkAccelKey *key, GClosure *closure, gpointer data) { return (GClosure *) data == closure; } /* * CarbonMenu functions */ typedef struct { MenuRef menu; guint toplevel : 1; } CarbonMenu; static GQuark carbon_menu_quark = 0; static CarbonMenu * carbon_menu_new (void) { return g_slice_new0 (CarbonMenu); } static void carbon_menu_free (CarbonMenu *menu) { g_slice_free (CarbonMenu, menu); } static CarbonMenu * carbon_menu_get (GtkWidget *widget) { return g_object_get_qdata (G_OBJECT (widget), carbon_menu_quark); } static void carbon_menu_connect (GtkWidget *menu, MenuRef menuRef, gboolean toplevel) { CarbonMenu *carbon_menu = carbon_menu_get (menu); if (!carbon_menu) { carbon_menu = carbon_menu_new (); g_object_set_qdata_full (G_OBJECT (menu), carbon_menu_quark, carbon_menu, (GDestroyNotify) carbon_menu_free); } carbon_menu->menu = menuRef; carbon_menu->toplevel = toplevel; } /* * CarbonMenuItem functions */ typedef struct { MenuRef menu; MenuItemIndex index; MenuRef submenu; GClosure *accel_closure; } CarbonMenuItem; static GQuark carbon_menu_item_quark = 0; static CarbonMenuItem * carbon_menu_item_new (void) { return g_slice_new0 (CarbonMenuItem); } static void carbon_menu_item_free (CarbonMenuItem *menu_item) { if (menu_item->accel_closure) g_closure_unref (menu_item->accel_closure); g_slice_free (CarbonMenuItem, menu_item); } static CarbonMenuItem * carbon_menu_item_get (GtkWidget *widget) { return g_object_get_qdata (G_OBJECT (widget), carbon_menu_item_quark); } static void carbon_menu_item_update_state (CarbonMenuItem *carbon_item, GtkWidget *widget) { gboolean sensitive; gboolean visible; UInt32 set_attrs = 0; UInt32 clear_attrs = 0; g_object_get (widget, "sensitive", &sensitive, "visible", &visible, NULL); if (!sensitive) set_attrs |= kMenuItemAttrDisabled; else clear_attrs |= kMenuItemAttrDisabled; if (!visible) set_attrs |= kMenuItemAttrHidden; else clear_attrs |= kMenuItemAttrHidden; ChangeMenuItemAttributes (carbon_item->menu, carbon_item->index, set_attrs, clear_attrs); } static void carbon_menu_item_update_active (CarbonMenuItem *carbon_item, GtkWidget *widget) { gboolean active; g_object_get (widget, "active", &active, NULL); CheckMenuItem (carbon_item->menu, carbon_item->index, active); } static void carbon_menu_item_update_submenu (CarbonMenuItem *carbon_item, GtkWidget *widget) { GtkWidget *submenu; submenu = gtk_menu_item_get_submenu (GTK_MENU_ITEM (widget)); if (submenu) { const gchar *label_text; CFStringRef cfstr = NULL; label_text = get_menu_label_text (widget, NULL); if (label_text) cfstr = CFStringCreateWithCString (NULL, label_text, kCFStringEncodingUTF8); CreateNewMenu (++last_menu_id, 0, &carbon_item->submenu); SetMenuTitleWithCFString (carbon_item->submenu, cfstr); SetMenuItemHierarchicalMenu (carbon_item->menu, carbon_item->index, carbon_item->submenu); /* FIXME: This makes it possible to hide toplevel menu items * completely, but it only works if you hide the menu item before * setting up the menu, not dynamically afterwards. */ if (!GTK_WIDGET_VISIBLE (widget)) { ChangeMenuAttributes (carbon_item->submenu, kMenuAttrHidden, 0); } sync_menu_shell (GTK_MENU_SHELL (submenu), carbon_item->submenu, FALSE, FALSE); if (cfstr) CFRelease (cfstr); } else { SetMenuItemHierarchicalMenu (carbon_item->menu, carbon_item->index, NULL); carbon_item->submenu = NULL; } } static void carbon_menu_item_update_label (CarbonMenuItem *carbon_item, GtkWidget *widget) { const gchar *label_text; CFStringRef cfstr = NULL; label_text = get_menu_label_text (widget, NULL); if (label_text) cfstr = CFStringCreateWithCString (NULL, label_text, kCFStringEncodingUTF8); SetMenuItemTextWithCFString (carbon_item->menu, carbon_item->index, cfstr); if (cfstr) CFRelease (cfstr); } static void carbon_menu_item_update_accelerator (CarbonMenuItem *carbon_item, GtkWidget *widget) { GtkWidget *label; get_menu_label_text (widget, &label); if (GTK_IS_ACCEL_LABEL (label) && GTK_ACCEL_LABEL (label)->accel_closure) { GtkAccelKey *key; key = gtk_accel_group_find (GTK_ACCEL_LABEL (label)->accel_group, accel_find_func, GTK_ACCEL_LABEL (label)->accel_closure); if (key && key->accel_key && key->accel_flags & GTK_ACCEL_VISIBLE) { GdkDisplay *display = gtk_widget_get_display (widget); GdkKeymap *keymap = gdk_keymap_get_for_display (display); GdkKeymapKey *keys; gint n_keys; if (gdk_keymap_get_entries_for_keyval (keymap, key->accel_key, &keys, &n_keys)) { UInt8 modifiers = 0; SetMenuItemCommandKey (carbon_item->menu, carbon_item->index, true, keys[0].keycode); g_free (keys); if (key->accel_mods) { if (key->accel_mods & GDK_SHIFT_MASK) modifiers |= kMenuShiftModifier; if (key->accel_mods & GDK_MOD1_MASK) modifiers |= kMenuOptionModifier; } if (!(key->accel_mods & GDK_CONTROL_MASK)) { modifiers |= kMenuNoCommandModifier; } SetMenuItemModifiers (carbon_item->menu, carbon_item->index, modifiers); return; } } } /* otherwise, clear the menu shortcut */ SetMenuItemModifiers (carbon_item->menu, carbon_item->index, kMenuNoModifiers | kMenuNoCommandModifier); ChangeMenuItemAttributes (carbon_item->menu, carbon_item->index, 0, kMenuItemAttrUseVirtualKey); SetMenuItemCommandKey (carbon_item->menu, carbon_item->index, false, 0); } static void carbon_menu_item_accel_changed (GtkAccelGroup *accel_group, guint keyval, GdkModifierType modifier, GClosure *accel_closure, GtkWidget *widget) { CarbonMenuItem *carbon_item = carbon_menu_item_get (widget); GtkWidget *label; get_menu_label_text (widget, &label); if (GTK_IS_ACCEL_LABEL (label) && GTK_ACCEL_LABEL (label)->accel_closure == accel_closure) carbon_menu_item_update_accelerator (carbon_item, widget); } static void carbon_menu_item_update_accel_closure (CarbonMenuItem *carbon_item, GtkWidget *widget) { GtkAccelGroup *group; GtkWidget *label; get_menu_label_text (widget, &label); if (carbon_item->accel_closure) { group = gtk_accel_group_from_accel_closure (carbon_item->accel_closure); g_signal_handlers_disconnect_by_func (group, carbon_menu_item_accel_changed, widget); g_closure_unref (carbon_item->accel_closure); carbon_item->accel_closure = NULL; } if (GTK_IS_ACCEL_LABEL (label)) carbon_item->accel_closure = GTK_ACCEL_LABEL (label)->accel_closure; if (carbon_item->accel_closure) { g_closure_ref (carbon_item->accel_closure); group = gtk_accel_group_from_accel_closure (carbon_item->accel_closure); g_signal_connect_object (group, "accel-changed", G_CALLBACK (carbon_menu_item_accel_changed), widget, 0); } carbon_menu_item_update_accelerator (carbon_item, widget); } static void carbon_menu_item_notify (GObject *object, GParamSpec *pspec, CarbonMenuItem *carbon_item) { if (!strcmp (pspec->name, "sensitive") || !strcmp (pspec->name, "visible")) { carbon_menu_item_update_state (carbon_item, GTK_WIDGET (object)); } else if (!strcmp (pspec->name, "active")) { carbon_menu_item_update_active (carbon_item, GTK_WIDGET (object)); } else if (!strcmp (pspec->name, "submenu")) { carbon_menu_item_update_submenu (carbon_item, GTK_WIDGET (object)); } } static void carbon_menu_item_notify_label (GObject *object, GParamSpec *pspec, gpointer data) { CarbonMenuItem *carbon_item = carbon_menu_item_get (GTK_WIDGET (object)); if (!strcmp (pspec->name, "label")) { carbon_menu_item_update_label (carbon_item, GTK_WIDGET (object)); } else if (!strcmp (pspec->name, "accel-closure")) { carbon_menu_item_update_accel_closure (carbon_item, GTK_WIDGET (object)); } } static CarbonMenuItem * carbon_menu_item_connect (GtkWidget *menu_item, GtkWidget *label, MenuRef menu, MenuItemIndex index) { CarbonMenuItem *carbon_item = carbon_menu_item_get (menu_item); if (!carbon_item) { carbon_item = carbon_menu_item_new (); g_object_set_qdata_full (G_OBJECT (menu_item), carbon_menu_item_quark, carbon_item, (GDestroyNotify) carbon_menu_item_free); g_signal_connect (menu_item, "notify", G_CALLBACK (carbon_menu_item_notify), carbon_item); if (label) g_signal_connect_swapped (label, "notify::label", G_CALLBACK (carbon_menu_item_notify_label), menu_item); } carbon_item->menu = menu; carbon_item->index = index; return carbon_item; } typedef struct { GtkWidget *widget; } ActivateIdleData; static void activate_destroy_cb (gpointer user_data) { ActivateIdleData *data = user_data; if (data->widget) g_object_remove_weak_pointer (G_OBJECT (data->widget), (gpointer) &data->widget); g_free (data); } static gboolean activate_idle_cb (gpointer user_data) { ActivateIdleData *data = user_data; if (data->widget) gtk_menu_item_activate (GTK_MENU_ITEM (data->widget)); return FALSE; } /* * carbon event handler */ static OSStatus menu_event_handler_func (EventHandlerCallRef event_handler_call_ref, EventRef event_ref, void *data) { UInt32 event_class = GetEventClass (event_ref); UInt32 event_kind = GetEventKind (event_ref); switch (event_class) { case kEventClassCommand: /* This is called when activating (is that the right GTK+ term?) * a menu item. */ if (event_kind == kEventCommandProcess) { HICommand command; OSStatus err; /*g_printerr ("Menu: kEventClassCommand/kEventCommandProcess\n");*/ err = GetEventParameter (event_ref, kEventParamDirectObject, typeHICommand, 0, sizeof (command), 0, &command); if (err == noErr) { GtkWidget *widget = NULL; /* Get any GtkWidget associated with the item. */ err = GetMenuItemProperty (command.menu.menuRef, command.menu.menuItemIndex, IGE_QUARTZ_MENU_CREATOR, IGE_QUARTZ_ITEM_WIDGET, sizeof (widget), 0, &widget); if (err == noErr && GTK_IS_WIDGET (widget)) { ActivateIdleData *data; /* Activate from an idle handler so that the event is * emitted from the main loop instead of in the middle of * handling quartz events. */ data = g_new0 (ActivateIdleData, 1); data->widget = widget; g_object_add_weak_pointer (G_OBJECT (widget), (gpointer) &data->widget); g_idle_add_full (G_PRIORITY_HIGH, activate_idle_cb, data, activate_destroy_cb); return noErr; } } } break; case kEventClassMenu: if (event_kind == kEventMenuEndTracking) g_idle_add (menu_flash_off_cb, NULL); break; default: break; } return CallNextEventHandler (event_handler_call_ref, event_ref); } static gboolean nsevent_handle_menu_key (NSEvent *nsevent) { EventRef event_ref; MenuRef menu_ref; MenuItemIndex index; if ([nsevent type] != NSKeyDown) return FALSE; event_ref = [nsevent gdk_quartz_event_ref]; if (IsMenuKeyEvent (NULL, event_ref, kMenuEventQueryOnly, &menu_ref, &index)) { MenuCommand menu_command; HICommand hi_command; if (GetMenuItemCommandID (menu_ref, index, &menu_command) != noErr) return FALSE; hi_command.commandID = menu_command; hi_command.menu.menuRef = menu_ref; hi_command.menu.menuItemIndex = index; CreateEvent (NULL, kEventClassCommand, kEventCommandProcess, 0, kEventAttributeUserEvent, &event_ref); SetEventParameter (event_ref, kEventParamDirectObject, typeHICommand, sizeof (HICommand), &hi_command); FlashMenuBar (GetMenuID (menu_ref)); g_timeout_add (30, menu_flash_off_cb, NULL); SendEventToEventTarget (event_ref, GetMenuEventTarget (menu_ref)); ReleaseEvent (event_ref); return TRUE; } return FALSE; } gboolean ige_mac_menu_handle_menu_event (GdkEventKey *event) { NSEvent *nsevent; /* FIXME: If the event here is unallocated, we crash. */ nsevent = gdk_quartz_event_get_nsevent ((GdkEvent *) event); if (nsevent) return nsevent_handle_menu_key (nsevent); return FALSE; } static GdkFilterReturn global_event_filter_func (gpointer windowing_event, GdkEvent *event, gpointer user_data) { NSEvent *nsevent = windowing_event; /* Handle menu events with no window, since they won't go through the * regular event processing. */ if ([nsevent window] == nil) { if (nsevent_handle_menu_key (nsevent)) return GDK_FILTER_REMOVE; } else if (global_key_handler_enabled && [nsevent type] == NSKeyDown) { GList *toplevels, *l; GtkWindow *focus = NULL; toplevels = gtk_window_list_toplevels (); for (l = toplevels; l; l = l->next) { if (gtk_window_has_toplevel_focus (l->data)) { focus = l->data; break; } } g_list_free (toplevels); /* FIXME: We could do something to skip menu events if there is a * modal dialog... */ if (!focus || !g_object_get_data (G_OBJECT (focus), IGE_MAC_KEY_HANDLER)) { if (nsevent_handle_menu_key (nsevent)) return GDK_FILTER_REMOVE; } } return GDK_FILTER_CONTINUE; } static gboolean key_press_event (GtkWidget *widget, GdkEventKey *event, gpointer user_data) { GtkWindow *window = GTK_WINDOW (widget); GtkWidget *focus = gtk_window_get_focus (window); gboolean handled = FALSE; /* Text widgets get all key events first. */ if (GTK_IS_EDITABLE (focus) || GTK_IS_TEXT_VIEW (focus)) handled = gtk_window_propagate_key_event (window, event); if (!handled) handled = ige_mac_menu_handle_menu_event (event); /* Invoke control/alt accelerators. */ if (!handled && event->state & (GDK_CONTROL_MASK | GDK_MOD1_MASK)) handled = gtk_window_activate_key (window, event); /* Invoke focus widget handlers. */ if (!handled) handled = gtk_window_propagate_key_event (window, event); /* Invoke non-(control/alt) accelerators. */ if (!handled && !(event->state & (GDK_CONTROL_MASK | GDK_MOD1_MASK))) handled = gtk_window_activate_key (window, event); return handled; } static void setup_menu_event_handler (void) { static gboolean is_setup = FALSE; EventHandlerUPP menu_event_handler_upp; EventHandlerRef menu_event_handler_ref; const EventTypeSpec menu_events[] = { { kEventClassCommand, kEventCommandProcess }, { kEventClassMenu, kEventMenuEndTracking } }; if (is_setup) return; gdk_window_add_filter (NULL, global_event_filter_func, NULL); menu_event_handler_upp = NewEventHandlerUPP (menu_event_handler_func); InstallEventHandler (GetApplicationEventTarget (), menu_event_handler_upp, GetEventTypeCount (menu_events), menu_events, 0, &menu_event_handler_ref); #if 0 /* Note: If we want to supporting shutting down, remove the handler * with: */ RemoveEventHandler(menu_event_handler_ref); DisposeEventHandlerUPP(menu_event_handler_upp); #endif is_setup = TRUE; } static void sync_menu_shell (GtkMenuShell *menu_shell, MenuRef carbon_menu, gboolean toplevel, gboolean debug) { GList *children; GList *l; MenuItemIndex carbon_index = 1; if (debug) g_printerr ("%s: syncing shell %p\n", G_STRFUNC, menu_shell); carbon_menu_connect (GTK_WIDGET (menu_shell), carbon_menu, toplevel); children = gtk_container_get_children (GTK_CONTAINER (menu_shell)); for (l = children; l; l = l->next) { GtkWidget *menu_item = l->data; CarbonMenuItem *carbon_item; if (GTK_IS_TEAROFF_MENU_ITEM (menu_item)) continue; if (toplevel && (g_object_get_data (G_OBJECT (menu_item), "gtk-empty-menu-item") || GTK_IS_SEPARATOR_MENU_ITEM (menu_item))) continue; carbon_item = carbon_menu_item_get (menu_item); if (debug) g_printerr ("%s: carbon_item %d for menu_item %d (%s, %s)\n", G_STRFUNC, carbon_item ? carbon_item->index : -1, carbon_index, get_menu_label_text (menu_item, NULL), g_type_name (G_TYPE_FROM_INSTANCE (menu_item))); if (carbon_item && carbon_item->index != carbon_index) { if (debug) g_printerr ("%s: -> not matching, deleting\n", G_STRFUNC); DeleteMenuItem (carbon_item->menu, carbon_index); carbon_item = NULL; } if (!carbon_item) { GtkWidget *label = NULL; const gchar *label_text; CFStringRef cfstr = NULL; MenuItemAttributes attributes = 0; if (debug) g_printerr ("%s: -> creating new\n", G_STRFUNC); label_text = get_menu_label_text (menu_item, &label); if (label_text) cfstr = CFStringCreateWithCString (NULL, label_text, kCFStringEncodingUTF8); if (GTK_IS_SEPARATOR_MENU_ITEM (menu_item)) attributes |= kMenuItemAttrSeparator; if (!GTK_WIDGET_IS_SENSITIVE (menu_item)) attributes |= kMenuItemAttrDisabled; if (!GTK_WIDGET_VISIBLE (menu_item)) attributes |= kMenuItemAttrHidden; InsertMenuItemTextWithCFString (carbon_menu, cfstr, carbon_index - 1, attributes, 0); SetMenuItemProperty (carbon_menu, carbon_index, IGE_QUARTZ_MENU_CREATOR, IGE_QUARTZ_ITEM_WIDGET, sizeof (menu_item), &menu_item); if (cfstr) CFRelease (cfstr); carbon_item = carbon_menu_item_connect (menu_item, label, carbon_menu, carbon_index); if (GTK_IS_CHECK_MENU_ITEM (menu_item)) carbon_menu_item_update_active (carbon_item, menu_item); carbon_menu_item_update_accel_closure (carbon_item, menu_item); if (gtk_menu_item_get_submenu (GTK_MENU_ITEM (menu_item))) carbon_menu_item_update_submenu (carbon_item, menu_item); } carbon_index++; } g_list_free (children); } static gulong emission_hook_id = 0; static gint emission_hook_count = 0; static gboolean parent_set_emission_hook (GSignalInvocationHint *ihint, guint n_param_values, const GValue *param_values, gpointer data) { GtkWidget *instance = g_value_get_object (param_values); if (GTK_IS_MENU_ITEM (instance)) { GtkWidget *previous_parent = g_value_get_object (param_values + 1); GtkWidget *menu_shell = NULL; if (GTK_IS_MENU_SHELL (previous_parent)) { menu_shell = previous_parent; } else if (GTK_IS_MENU_SHELL (instance->parent)) { menu_shell = instance->parent; } if (menu_shell) { CarbonMenu *carbon_menu = carbon_menu_get (menu_shell); if (carbon_menu) { #if 0 g_printerr ("%s: item %s %p (%s, %s)\n", G_STRFUNC, previous_parent ? "removed from" : "added to", menu_shell, get_menu_label_text (instance, NULL), g_type_name (G_TYPE_FROM_INSTANCE (instance))); #endif sync_menu_shell (GTK_MENU_SHELL (menu_shell), carbon_menu->menu, carbon_menu->toplevel, FALSE); } } } return TRUE; } static void parent_set_emission_hook_remove (GtkWidget *widget, gpointer data) { emission_hook_count--; if (emission_hook_count > 0) return; g_signal_remove_emission_hook (g_signal_lookup ("parent-set", GTK_TYPE_WIDGET), emission_hook_id); emission_hook_id = 0; } /* * public functions */ void ige_mac_menu_set_menu_bar (GtkMenuShell *menu_shell) { CarbonMenu *current_menu; MenuRef carbon_menubar; g_return_if_fail (GTK_IS_MENU_SHELL (menu_shell)); if (carbon_menu_quark == 0) carbon_menu_quark = g_quark_from_static_string ("CarbonMenu"); if (carbon_menu_item_quark == 0) carbon_menu_item_quark = g_quark_from_static_string ("CarbonMenuItem"); current_menu = carbon_menu_get (GTK_WIDGET (menu_shell)); if (current_menu) { SetRootMenu (current_menu->menu); return; } CreateNewMenu (0 /*id*/, 0 /*options*/, &carbon_menubar); SetRootMenu (carbon_menubar); setup_menu_event_handler (); if (emission_hook_id == 0) { emission_hook_id = g_signal_add_emission_hook (g_signal_lookup ("parent-set", GTK_TYPE_WIDGET), 0, parent_set_emission_hook, NULL, NULL); } emission_hook_count++; g_signal_connect (menu_shell, "destroy", G_CALLBACK (parent_set_emission_hook_remove), NULL); sync_menu_shell (menu_shell, carbon_menubar, TRUE, FALSE); } void ige_mac_menu_set_quit_menu_item (GtkMenuItem *menu_item) { MenuRef appmenu; MenuItemIndex index; g_return_if_fail (GTK_IS_MENU_ITEM (menu_item)); setup_menu_event_handler (); if (GetIndMenuItemWithCommandID (NULL, kHICommandQuit, 1, &appmenu, &index) == noErr) { SetMenuItemCommandID (appmenu, index, 0); SetMenuItemProperty (appmenu, index, IGE_QUARTZ_MENU_CREATOR, IGE_QUARTZ_ITEM_WIDGET, sizeof (menu_item), &menu_item); gtk_widget_hide (GTK_WIDGET (menu_item)); } } void ige_mac_menu_connect_window_key_handler (GtkWindow *window) { if (g_object_get_data (G_OBJECT (window), IGE_MAC_KEY_HANDLER)) { g_warning ("Window %p is already connected", window); return; } g_signal_connect (window, "key-press-event", G_CALLBACK (key_press_event), NULL); g_object_set_data (G_OBJECT (window), IGE_MAC_KEY_HANDLER, GINT_TO_POINTER (1)); } /* Most applications will want to have this enabled (which is the * defalt). For apps that need to deal with the events themselves, the * global handling can be disabled. */ void ige_mac_menu_set_global_key_handler_enabled (gboolean enabled) { global_key_handler_enabled = enabled; } /* For internal use only. Returns TRUE if there is a GtkMenuItem assigned to * the Quit menu item. */ gboolean _ige_mac_menu_is_quit_menu_item_handled (void) { MenuRef appmenu; MenuItemIndex index; if (GetIndMenuItemWithCommandID (NULL, kHICommandQuit, 1, &appmenu, &index) == noErr) { return FALSE; } return TRUE; } struct _IgeMacMenuGroup { GList *items; }; static GList *app_menu_groups = NULL; IgeMacMenuGroup * ige_mac_menu_add_app_menu_group (void) { IgeMacMenuGroup *group = g_slice_new0 (IgeMacMenuGroup); app_menu_groups = g_list_append (app_menu_groups, group); return group; } void ige_mac_menu_add_app_menu_item (IgeMacMenuGroup *group, GtkMenuItem *menu_item, const gchar *label) { MenuRef appmenu; GList *list; gint index = 0; g_return_if_fail (group != NULL); g_return_if_fail (GTK_IS_MENU_ITEM (menu_item)); setup_menu_event_handler (); if (GetIndMenuItemWithCommandID (NULL, kHICommandHide, 1, &appmenu, NULL) != noErr) { g_warning ("%s: retrieving app menu failed", G_STRFUNC); return; } for (list = app_menu_groups; list; list = g_list_next (list)) { IgeMacMenuGroup *list_group = list->data; index += g_list_length (list_group->items); /* adjust index for the separator between groups, but not * before the first group */ if (list_group->items && list->prev) index++; if (group == list_group) { CFStringRef cfstr; /* add a separator before adding the first item, but not * for the first group */ if (!group->items && list->prev) { InsertMenuItemTextWithCFString (appmenu, NULL, index, kMenuItemAttrSeparator, 0); index++; } if (!label) label = get_menu_label_text (GTK_WIDGET (menu_item), NULL); cfstr = CFStringCreateWithCString (NULL, label, kCFStringEncodingUTF8); InsertMenuItemTextWithCFString (appmenu, cfstr, index, 0, 0); SetMenuItemProperty (appmenu, index + 1, IGE_QUARTZ_MENU_CREATOR, IGE_QUARTZ_ITEM_WIDGET, sizeof (menu_item), &menu_item); CFRelease (cfstr); gtk_widget_hide (GTK_WIDGET (menu_item)); group->items = g_list_append (group->items, menu_item); return; } } if (!list) g_warning ("%s: app menu group %p does not exist", G_STRFUNC, group); } brp-pacu/BRP_PACU.c0000644000175000017500000004653712153127664012656 0ustar miramira/* * BRP_PACU.c : Contains main, calls creation of the gui, initialization of * main FFT data struct and its array variables, creates the audio capture * thread, creates the 100ms gui callback, handles the gui callback and * on quitting tries to free all allocated memory * * Some of this should probably moved out of this huge c file and organized * better. * * Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. */ #include #include #include #include #include #include #include #include #include "main.h" #include "testfft.h" #include "gui.h" #include #include volatile struct FFT_Frame *fill_it; volatile struct FFT_Frame * temp_frame_data; // tmp copy so mutexes don't need to wait static float audio1[8192]; static float audio2[8192]; static float pink_noise[8192]; volatile char run = 1; static guint timer_id = 0; // static guint BUF_SIZE = BUFSIZE; float b0, b1, b2, b3, b4, b5, b6, white; float tmp_time = 0.0; float scale_it = 0.98; float volume = 0.5; GMutex *thread_mutex; jack_port_t *input_port1; jack_port_t *input_port2; jack_port_t *output_port; jack_client_t *client; /* a simple state machine for this client */ volatile enum { Init, Run, Started, Exit } client_state = Init; /*static void on_quit (GtkObject *object) { gtk_object_destroy (object); gtk_main_quit (); }*/ int Fill_Buffer(jack_nframes_t nframes, void *arg) { //fill_it = (struct FFT_Frame *) malloc(sizeof(struct FFT_Frame )); int k, j, period_size; jack_default_audio_sample_t *in_buffer1, *in_buffer2, *out_buffer; g_mutex_lock (thread_mutex); // if (pthread_mutex_trylock(&p_mutex)) { jack_transport_state_t ts = jack_transport_query(client, NULL); if (ts == JackTransportRolling) { if (client_state == Init) client_state = Run; in_buffer1 = jack_port_get_buffer (input_port1, nframes); in_buffer2 = jack_port_get_buffer (input_port2, nframes); out_buffer = jack_port_get_buffer (output_port, nframes); for (k = 0; k < nframes; k++) { white = ((float) (rand() % 10000) - 10000.0 / 2.0) / 999900.0; // Shamelessly taken from http://www.firstpr.com.au/dsp/pink-noise/ // Based on a filter by Robert Bristow-Johnson b0 = (0.99886 * b0 + white * 0.0555179) * scale_it ; b1 = (0.99332 * b1 + white * 0.0750759) * scale_it; b2 = (0.96900 * b2 + white * 0.1538520) * scale_it; b3 = (0.86650 * b3 + white * 0.3104856) * scale_it; b4 = (0.55000 * b4 + white * 0.5329522) * scale_it; b5 = (-0.7616 * b5 - white * 0.0168980) * scale_it; tmp_time = tmp_time + 1.0 / 44100; if (fill_it->pink_muted) pink_noise[k] = (b0 + b1 + b2 + b3 + b4 + b5 + b6 + (white * 0.5362) * scale_it) * (pow(2.0, fill_it->volume_pink + 29) / (pow(2.0, 32.0))); else pink_noise[k] = 0.0; b6 = (white * 0.115926) * scale_it; } memcpy (audio1, in_buffer1, sizeof (jack_default_audio_sample_t) * nframes); memcpy (audio2, in_buffer2, sizeof (jack_default_audio_sample_t) * nframes); memcpy (out_buffer, pink_noise, sizeof (jack_default_audio_sample_t) * nframes); } else if (ts == JackTransportStopped) { if (client_state == Run) client_state = Exit; jack_transport_start(client); } period_size = nframes; //fprintf(stderr, "The period size is %d\n",period_size); // // Fill delay with old data for ( k = 0; k < (DELAY_BUFFER_SIZE - period_size); k++) { // Rotate dellay data to the left to make room for new samples fill_it->delay[k] = fill_it->delay[k + period_size]; } j=N_FFT - period_size; for ( k = DELAY_BUFFER_SIZE - period_size; k < DELAY_BUFFER_SIZE; k++) { //// Copy old delay data to end of delayed buffer 2 // Copy old buffer data to end of delay buffer fill_it->delay[k] = fill_it->prewin_buffer_data_2[j - N_FFT + period_size ]; j++; } // Rotate data to the left to make room for new samples for ( k = 0; k < (N_FFT - period_size ); k++) { fill_it->prewin_buffer_data_1[k ] = fill_it->prewin_buffer_data_1[k + period_size ]; fill_it->prewin_buffer_data_2[k ] = fill_it->prewin_buffer_data_2[k + period_size ]; } j = 0; for (k = N_FFT - period_size; k < N_FFT ; k++) { // copy channels to the end of the data fill_it->prewin_buffer_data_1[k] = (short) 32767.0 * audio1[j]; // Copy Begining of Audio buff to end of delay from last buffer fill fill_it->prewin_buffer_data_2[k] = (short) 32767.0 * audio2[j]; j++; } for (k = 0; k < N_FFT; k++) { // Copy data to working buffer #2 fill_it->buffer_data_1[k] = fill_it->prewin_buffer_data_1[k]; // Copy data to working #1 and apply delay if (k - fill_it->delay_size >= 0) fill_it->buffer_data_2[k] = fill_it->prewin_buffer_data_2[k - fill_it->delay_size]; // copy end of normal buffer to working buffer else fill_it->buffer_data_2[k] = fill_it->delay[k + DELAY_BUFFER_SIZE - fill_it->delay_size]; // copy most recent samples of the delay buffer to beginning (oldest) buffer_data_2 } //for (k = 0; k < N_FFT; k++) //{ // Apply Window function // Blackman window // For some reason this causes errors in the response, maybe someone knows better than me why? //fill_it->buffer_data_1[k] = (short)( // ( ((float)fill_it->buffer_data_1[k])*(0.42 - 0.5 * cos(2.0 * pi * ((float)k) / ( ((float)N) - 1.0)) // + 0.08 * cos(4.0 * pi * ((float)k) / (((float)N) - 1.0))) )); //fill_it->buffer_data_2[k] = (short)( // ((float)fill_it->buffer_data_2[k])*(0.42 - 0.5 * cos(2.0 * pi * ((float)k) / ( ((float)N) - 1.0)) // + 0.08 * cos(4.0 * pi * ((float)k) / (((float)N) - 1.0)))); // //} } g_mutex_unlock (thread_mutex); return 0; } static gboolean MyGTKFunction (struct FFT_Frame * frame_data) { int j, max_index = 0; // float avg[2000], min; double max, tmp; g_mutex_lock (thread_mutex); memcpy(temp_frame_data->buffer_data_1, frame_data->buffer_data_1, N_FFT*sizeof(short)); memcpy(temp_frame_data->buffer_data_2, frame_data->buffer_data_2, N_FFT*sizeof(short)); memcpy(temp_frame_data->plan, frame_data->plan, sizeof(frame_data->plan)); g_mutex_unlock (thread_mutex); fft_capture((struct FFT_Frame *)temp_frame_data); // This fxn does the FFT, frame_data->buffer_data_n is used to get frame_data->fft_returned_n g_mutex_lock (thread_mutex); memcpy(frame_data->fft_returned_1, temp_frame_data->fft_returned_1, N_FFT*sizeof(double)); memcpy(frame_data->fft_returned_2, temp_frame_data->fft_returned_2, N_FFT*sizeof(double)); g_mutex_unlock (thread_mutex); if (frame_data->find_delay == 1) // Delay button pressed, set delay to new value { g_source_remove(timer_id); gui_idle_func(frame_data); frame_data->delay_size = 0; frame_data->find_delay = 3; // Signal to gui that we are waiting while the delay sets in timer_id = g_timeout_add(1000, (GSourceFunc) MyGTKFunction, (gpointer) frame_data ); // Start the initial delay printf("Finding delay....\n"); return TRUE; } else if (frame_data->find_delay == 3) { g_source_remove(timer_id); g_mutex_lock (thread_mutex); impulse_capture(frame_data); g_mutex_unlock (thread_mutex); max = 0.0; for (j = 0; j < N_FFT; j++) { tmp = frame_data->rfft_returned_1[j]; // find the maximum impulse response sample to find the delay. if (max < (tmp*tmp)) { max = (tmp * tmp); max_index = j; } // printf("tmp:%f max:%f j:%d max_index:%d\n ", tmp, max, j, max_index); } printf("Done Finding delay\n"); printf("min value is %f, min time is %f\n", max, ((float)max_index)*(1.0 / ((float)FSAMP)) ); //frame_data->delay_size=10000; if ( max_index < N_FFT) // Protect against delay being larger than malloc'd size of N frame_data->delay_size = max_index; timer_id = g_timeout_add(90, (GSourceFunc) MyGTKFunction, (gpointer) frame_data ); // Start back to normal frame_data->find_delay = 2; // Indicate to gui that we are done finding the delay if (frame_data->find_impulse == 1) { frame_data->find_impulse = 2; // Signal to gui that impulse response has been done } } g_mutex_lock (thread_mutex); temp_frame_data->pink_muted = frame_data->pink_muted; temp_frame_data->volume_pink = frame_data->volume_pink; temp_frame_data->find_delay = frame_data->find_delay; temp_frame_data->find_impulse = frame_data->find_impulse; temp_frame_data->delay_size = frame_data->delay_size; // memcpy(temp_frame_data->delay_size, frame_data->delay, N_FFT*sizeof(short)); memcpy(temp_frame_data->fft_returned_1, frame_data->fft_returned_1, N_FFT*sizeof(double)); memcpy(temp_frame_data->fft_returned_2, frame_data->fft_returned_2, N_FFT*sizeof(double)); memcpy(temp_frame_data->buffer_data_1, frame_data->buffer_data_1, N_FFT*sizeof(short)); memcpy(temp_frame_data->buffer_data_2, frame_data->buffer_data_2, N_FFT*sizeof(short)); memcpy(temp_frame_data->rfft_returned_1, frame_data->rfft_returned_1, N_FFT*sizeof(double)); g_mutex_unlock (thread_mutex); gui_idle_func((struct FFT_Frame *)temp_frame_data); g_mutex_lock (thread_mutex); frame_data->pink_muted = temp_frame_data->pink_muted; frame_data->volume_pink = temp_frame_data->volume_pink; frame_data->find_delay = temp_frame_data->find_delay; frame_data->find_impulse = temp_frame_data->find_impulse; frame_data->delay_size = temp_frame_data->delay_size; g_mutex_unlock (thread_mutex); return TRUE; } struct FFT_Frame *init_fft_frame(void) { int k; struct FFT_Frame *FFT_Kit = (struct FFT_Frame *) malloc(sizeof(struct FFT_Frame)); //p_mutex = PTHREAD_MUTEX_INITIALIZER; FFT_Kit->fft_returned_1 = (double *) malloc(sizeof(double) * N_FFT); FFT_Kit->fft_returned_2 = (double *) malloc(sizeof(double) * N_FFT); FFT_Kit->rfft_returned_1 = (double *) malloc(sizeof(double) * N_FFT); FFT_Kit->prewin_buffer_data_1 = (short *) malloc(sizeof(short) * N_FFT); FFT_Kit->prewin_buffer_data_2 = (short *) malloc(sizeof(short) * N_FFT); FFT_Kit->buffer_data_1 = (short *) malloc(sizeof(short) * N_FFT); FFT_Kit->buffer_data_2 = (short *) malloc(sizeof(short) * N_FFT); FFT_Kit->delay = (short *) malloc(sizeof(short) * DELAY_BUFFER_SIZE); FFT_Kit->delay_size = 0; FFT_Kit->volume_pink = 0.0; FFT_Kit->find_delay = 0; FFT_Kit->find_impulse = 0; for (k = 0; k < N_FFT; k++) { FFT_Kit->delay[k] = 0; //FFT_Kit->audio[k] = 0; FFT_Kit->prewin_buffer_data_1[k] = 0; FFT_Kit->prewin_buffer_data_2[k] = 0; FFT_Kit->buffer_data_1[k] = 0; FFT_Kit->buffer_data_2[k] = 0; FFT_Kit->fft_returned_1[k] = 0; FFT_Kit->fft_returned_2[k] = 0; FFT_Kit->delay[k] = 0; } FFT_Kit->plan = fftw_create_plan(N_FFT, FFTW_FORWARD, FFTW_ESTIMATE); FFT_Kit->reverse_plan = fftw_create_plan(N_FFT, FFTW_BACKWARD, FFTW_ESTIMATE); return FFT_Kit; } void jack_shutdown (void *arg) { fprintf(stderr, "Jack shutdown! Exiting..\n"); gtk_main_quit(); } int jack_init() { const char **ports; char * client_name = "BRP_PACU"; const char *server_name = NULL; jack_options_t options = JackNullOption; jack_status_t status; /* open a client connection to the JACK server */ client = jack_client_open (client_name, options, &status, server_name); if (client == NULL) { fprintf (stderr, "jack_client_open() failed, " "status = 0x%2.0x\n", status); if (status & JackServerFailed) { fprintf (stderr, "Unable to connect to JACK server\n"); } return 1; } if (status & JackServerStarted) { fprintf (stderr, "JACK server started\n"); } if (status & JackNameNotUnique) { client_name = jack_get_client_name(client); fprintf (stderr, "unique name `%s' assigned\n", client_name); } /* tell the JACK server to call `process()' whenever there is work to be done. */ jack_set_process_callback (client, Fill_Buffer, 0); /* tell the JACK server to call `jack_shutdown()' if it ever shuts down, either entirely, or if it just decides to stop calling us. */ jack_on_shutdown (client, jack_shutdown, 0); /* display the current sample rate. */ printf ("engine sample rate: %d\n", jack_get_sample_rate (client)); /* create two ports */ input_port1 = jack_port_register (client, "input1", JACK_DEFAULT_AUDIO_TYPE, JackPortIsInput, 0); input_port2 = jack_port_register (client, "input2", JACK_DEFAULT_AUDIO_TYPE, JackPortIsInput, 0); output_port = jack_port_register (client, "output", JACK_DEFAULT_AUDIO_TYPE, JackPortIsOutput, 0); if ((input_port1 == NULL) || (input_port2 == NULL) || (output_port == NULL)) { fprintf(stderr, "no more JACK ports available\n"); return 2; } /* Tell the JACK server that we are ready to roll. Our * process() callback will start running now. */ if (jack_activate (client)) { fprintf (stderr, "cannot activate client"); return 3; } /* Connect the ports. You can't do this before the client is * activated, because we can't make connections to clients * that aren't running. Note the confusing (but necessary) * orientation of the driver backend ports: playback ports are * "input" to the backend, and capture ports are "output" from * it. */ ports = jack_get_ports (client, NULL, NULL, JackPortIsPhysical | JackPortIsOutput); if (ports == NULL) { fprintf(stderr, "no physical capture ports\n"); return 4; } if (jack_connect (client, ports[0], jack_port_name (input_port1))) { fprintf (stderr, "cannot connect input ports\n"); return 6; } if (jack_connect (client, ports[1], jack_port_name (input_port2))) { fprintf (stderr, "cannot connect input ports\n"); return 6; } // Connect the Pink Noise Output to the reference input. if (jack_connect (client, jack_port_name (output_port), jack_port_name (input_port2))) { fprintf (stderr, "cannot connect output ports\n"); return 7; } free (ports); ports = jack_get_ports (client, NULL, NULL, JackPortIsPhysical | JackPortIsInput); if (ports == NULL) { fprintf(stderr, "no physical playback ports\n"); return 5; } // Pink Noise Output if (jack_connect (client, jack_port_name (output_port), ports[1])) { fprintf (stderr, "cannot connect output ports\n"); return 7; } free (ports); /* keep running until the transport stops */ return 0; } int main (int argc, char *argv[]) { // struct FFT_Frame *FFT_Kit = g_new0 (struct FFT_Frame, 1); b0 = 0; b1 = 0; b2 = 0; white = 0; b3 = 0; b4 = 0; b5 = 0; b6 = 0; g_thread_init(NULL); gtk_init (&argc, &argv); int ierr = -1; thread_mutex = g_mutex_new (); char * jackErrMessage [8] = {"OK", "Unable to connect to JACK server", "No more JACK ports available", "Cannot activate client", "No physical capture ports", "No physical playback ports", "Cannot connect input ports", "Cannot connect output ports"}; fill_it = init_fft_frame(); temp_frame_data = init_fft_frame(); GtkWidget* jack_error_dialog = gtk_message_dialog_new(NULL, GTK_DIALOG_DESTROY_WITH_PARENT, GTK_MESSAGE_ERROR, GTK_BUTTONS_NONE, "Jack initialization Error"); gtk_window_set_decorated (GTK_WINDOW(jack_error_dialog), FALSE); gtk_window_set_position(GTK_WINDOW(jack_error_dialog), GTK_WIN_POS_CENTER); gtk_dialog_add_buttons(GTK_DIALOG(jack_error_dialog),"Continue",1,"Quit",2,NULL); while (ierr != 0) { ierr = jack_init(); if (ierr == 0) break; // If jack init, is successful, run GUI if (client != NULL) jack_client_close (client); fprintf(stderr, "////////\n BRP_PACU failed to start because jackd failed to initialize\n\n%s\n\nplease check your jackd sound card settings. QjackCtl (JackPilot with a mac) is an easy way to do this\n////////\n", jackErrMessage[ierr]); #ifdef __APPLE__ gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(jack_error_dialog), "BRP_PACU failed to start.\n-- %s --\nCheck the settings of Audio MIDI Setup and JackPilot, then click on \"Continue\"", jackErrMessage[ierr]); system("open -b gpl.elementicaotici.JackPilot"); // Launch JackPilot so that the user has not to search around #else gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(jack_error_dialog),"BRP_PACU failed to start.\n-- %s --\nCheck the settings of QjackCtl, then click on \"Continue\"",jackErrMessage[ierr]); #endif if (gtk_dialog_run (GTK_DIALOG(jack_error_dialog)) == 2) { //user clicked on "Quit" gtk_widget_destroy (GTK_WIDGET(jack_error_dialog)); printf("BRP-PACU terminated by user. Thank you for using BRP-PACU\n"); return (64 + ierr); // exit program with non-zero exit status } ; } gtk_widget_destroy (GTK_WIDGET(jack_error_dialog)); if (create_gui((struct FFT_Frame *)fill_it, DATADIR)) { timer_id = g_timeout_add(90, (GSourceFunc) MyGTKFunction, (gpointer) fill_it ); // Start the initial delay gtk_main (); g_source_remove(timer_id); run = 0; } else fprintf(stderr, "Gui did not start\n"); // Wait until thread execution has ended printf("Main Cleaning up.......\n"); jack_deactivate (client); jack_client_close (client); fftw_destroy_plan(fill_it->plan); fftw_destroy_plan(fill_it->reverse_plan); free(fill_it->delay); free(fill_it->buffer_data_1); free(fill_it->buffer_data_2); free(fill_it->prewin_buffer_data_1); free(fill_it->prewin_buffer_data_2); free(fill_it->fft_returned_1); free(fill_it->rfft_returned_1); free(fill_it->fft_returned_2); free((struct FFT_Frame *)fill_it); printf("Main has exited. Thank you for using BRP-PACU\n"); return 0; } brp-pacu/stamp-h10000644000175000017500000000002712153127664012614 0ustar miramiratimestamp for config.h brp-pacu/ige-mac-menu.h0000644000175000017500000000341112153127664013654 0ustar miramira/* GTK+ Integration for the Mac OS X Menubar. * * Copyright (C) 2007 Pioneer Research Center USA, Inc. * Copyright (C) 2007, 2008 Imendio AB * * For further information, see: * http://developer.imendio.com/projects/gtk-macosx/integration * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; version 2.1 * of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ #ifndef __IGE_MAC_MENU_H__ #define __IGE_MAC_MENU_H__ #include G_BEGIN_DECLS typedef struct _IgeMacMenuGroup IgeMacMenuGroup; void ige_mac_menu_set_menu_bar (GtkMenuShell *menu_shell); void ige_mac_menu_set_quit_menu_item (GtkMenuItem *menu_item); IgeMacMenuGroup *ige_mac_menu_add_app_menu_group (void); void ige_mac_menu_add_app_menu_item (IgeMacMenuGroup *group, GtkMenuItem *menu_item, const gchar *label); gboolean ige_mac_menu_handle_menu_event (GdkEventKey *event); void ige_mac_menu_set_global_key_handler_enabled (gboolean enabled); void ige_mac_menu_connect_window_key_handler (GtkWindow *window); G_END_DECLS #endif /* __IGE_MAC_MENU_H__ */ brp-pacu/ltmain.sh0000644000175000017500000060603112153127664013066 0ustar miramira# ltmain.sh - Provide generalized library-building support services. # NOTE: Changing this file will not affect anything until you rerun configure. # # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, # 2007, 2008 Free Software Foundation, Inc. # Originally by Gordon Matzigkeit , 1996 # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, but # WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU # General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. # # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. basename="s,^.*/,,g" # Work around backward compatibility issue on IRIX 6.5. On IRIX 6.4+, sh # is ksh but when the shell is invoked as "sh" and the current value of # the _XPG environment variable is not equal to 1 (one), the special # positional parameter $0, within a function call, is the name of the # function. progpath="$0" # The name of this program: progname=`echo "$progpath" | $SED $basename` modename="$progname" # Global variables: EXIT_SUCCESS=0 EXIT_FAILURE=1 PROGRAM=ltmain.sh PACKAGE=libtool VERSION=1.5.26 TIMESTAMP=" (1.1220.2.492 2008/01/30 06:40:56)" # Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # Check that we have a working $echo. if test "X$1" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test "X$1" = X--fallback-echo; then # Avoid inline document here, it may be left over : elif test "X`($echo '\t') 2>/dev/null`" = 'X\t'; then # Yippee, $echo works! : else # Restart under the correct shell, and then maybe $echo will work. exec $SHELL "$progpath" --no-reexec ${1+"$@"} fi if test "X$1" = X--fallback-echo; then # used as fallback echo shift cat <&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE fi # Global variables. mode=$default_mode nonopt= prev= prevopt= run= show="$echo" show_help= execute_dlfiles= duplicate_deps=no preserve_args= lo2o="s/\\.lo\$/.${objext}/" o2lo="s/\\.${objext}\$/.lo/" extracted_archives= extracted_serial=0 ##################################### # Shell function definitions: # This seems to be the best place for them # func_mktempdir [string] # Make a temporary directory that won't clash with other running # libtool processes, and avoids race conditions if possible. If # given, STRING is the basename for that directory. func_mktempdir () { my_template="${TMPDIR-/tmp}/${1-$progname}" if test "$run" = ":"; then # Return a directory name, but don't create it in dry-run mode my_tmpdir="${my_template}-$$" else # If mktemp works, use that first and foremost my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null` if test ! -d "$my_tmpdir"; then # Failing that, at least try and use $RANDOM to avoid a race my_tmpdir="${my_template}-${RANDOM-0}$$" save_mktempdir_umask=`umask` umask 0077 $mkdir "$my_tmpdir" umask $save_mktempdir_umask fi # If we're not in dry-run mode, bomb out on failure test -d "$my_tmpdir" || { $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2 exit $EXIT_FAILURE } fi $echo "X$my_tmpdir" | $Xsed } # func_win32_libid arg # return the library type of file 'arg' # # Need a lot of goo to handle *both* DLLs and import libs # Has to be a shell function in order to 'eat' the argument # that is supplied when $file_magic_command is called. func_win32_libid () { win32_libid_type="unknown" win32_fileres=`file -L $1 2>/dev/null` case $win32_fileres in *ar\ archive\ import\ library*) # definitely import win32_libid_type="x86 archive import" ;; *ar\ archive*) # could be an import, or static if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \ $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then win32_nmres=`eval $NM -f posix -A $1 | \ $SED -n -e '1,100{ / I /{ s,.*,import, p q } }'` case $win32_nmres in import*) win32_libid_type="x86 archive import";; *) win32_libid_type="x86 archive static";; esac fi ;; *DLL*) win32_libid_type="x86 DLL" ;; *executable*) # but shell scripts are "executable" too... case $win32_fileres in *MS\ Windows\ PE\ Intel*) win32_libid_type="x86 DLL" ;; esac ;; esac $echo $win32_libid_type } # func_infer_tag arg # Infer tagged configuration to use if any are available and # if one wasn't chosen via the "--tag" command line option. # Only attempt this if the compiler in the base compile # command doesn't match the default compiler. # arg is usually of the form 'gcc ...' func_infer_tag () { if test -n "$available_tags" && test -z "$tagname"; then CC_quoted= for arg in $CC; do case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac CC_quoted="$CC_quoted $arg" done case $@ in # Blanks in the command may have been stripped by the calling shell, # but not from the CC environment variable when configure was run. " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) ;; # Blanks at the start of $base_compile will cause this to fail # if we don't check for them as well. *) for z in $available_tags; do if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $z$" < "$progpath" > /dev/null; then # Evaluate the configuration. eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$z'$/,/^# ### END LIBTOOL TAG CONFIG: '$z'$/p' < $progpath`" CC_quoted= for arg in $CC; do # Double-quote args containing other shell metacharacters. case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac CC_quoted="$CC_quoted $arg" done case "$@ " in " $CC "* | "$CC "* | " `$echo $CC` "* | "`$echo $CC` "* | " $CC_quoted"* | "$CC_quoted "* | " `$echo $CC_quoted` "* | "`$echo $CC_quoted` "*) # The compiler in the base compile command matches # the one in the tagged configuration. # Assume this is the tagged configuration we want. tagname=$z break ;; esac fi done # If $tagname still isn't set, then no tagged configuration # was found and let the user know that the "--tag" command # line option must be used. if test -z "$tagname"; then $echo "$modename: unable to infer tagged configuration" $echo "$modename: specify a tag with \`--tag'" 1>&2 exit $EXIT_FAILURE # else # $echo "$modename: using $tagname tagged configuration" fi ;; esac fi } # func_extract_an_archive dir oldlib func_extract_an_archive () { f_ex_an_ar_dir="$1"; shift f_ex_an_ar_oldlib="$1" $show "(cd $f_ex_an_ar_dir && $AR x $f_ex_an_ar_oldlib)" $run eval "(cd \$f_ex_an_ar_dir && $AR x \$f_ex_an_ar_oldlib)" || exit $? if ($AR t "$f_ex_an_ar_oldlib" | sort | sort -uc >/dev/null 2>&1); then : else $echo "$modename: ERROR: object name conflicts: $f_ex_an_ar_dir/$f_ex_an_ar_oldlib" 1>&2 exit $EXIT_FAILURE fi } # func_extract_archives gentop oldlib ... func_extract_archives () { my_gentop="$1"; shift my_oldlibs=${1+"$@"} my_oldobjs="" my_xlib="" my_xabs="" my_xdir="" my_status="" $show "${rm}r $my_gentop" $run ${rm}r "$my_gentop" $show "$mkdir $my_gentop" $run $mkdir "$my_gentop" my_status=$? if test "$my_status" -ne 0 && test ! -d "$my_gentop"; then exit $my_status fi for my_xlib in $my_oldlibs; do # Extract the objects. case $my_xlib in [\\/]* | [A-Za-z]:[\\/]*) my_xabs="$my_xlib" ;; *) my_xabs=`pwd`"/$my_xlib" ;; esac my_xlib=`$echo "X$my_xlib" | $Xsed -e 's%^.*/%%'` my_xlib_u=$my_xlib while :; do case " $extracted_archives " in *" $my_xlib_u "*) extracted_serial=`expr $extracted_serial + 1` my_xlib_u=lt$extracted_serial-$my_xlib ;; *) break ;; esac done extracted_archives="$extracted_archives $my_xlib_u" my_xdir="$my_gentop/$my_xlib_u" $show "${rm}r $my_xdir" $run ${rm}r "$my_xdir" $show "$mkdir $my_xdir" $run $mkdir "$my_xdir" exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then exit $exit_status fi case $host in *-darwin*) $show "Extracting $my_xabs" # Do not bother doing anything if just a dry run if test -z "$run"; then darwin_orig_dir=`pwd` cd $my_xdir || exit $? darwin_archive=$my_xabs darwin_curdir=`pwd` darwin_base_archive=`$echo "X$darwin_archive" | $Xsed -e 's%^.*/%%'` darwin_arches=`lipo -info "$darwin_archive" 2>/dev/null | $EGREP Architectures 2>/dev/null` if test -n "$darwin_arches"; then darwin_arches=`echo "$darwin_arches" | $SED -e 's/.*are://'` darwin_arch= $show "$darwin_base_archive has multiple architectures $darwin_arches" for darwin_arch in $darwin_arches ; do mkdir -p "unfat-$$/${darwin_base_archive}-${darwin_arch}" lipo -thin $darwin_arch -output "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" "${darwin_archive}" cd "unfat-$$/${darwin_base_archive}-${darwin_arch}" func_extract_an_archive "`pwd`" "${darwin_base_archive}" cd "$darwin_curdir" $rm "unfat-$$/${darwin_base_archive}-${darwin_arch}/${darwin_base_archive}" done # $darwin_arches ## Okay now we have a bunch of thin objects, gotta fatten them up :) darwin_filelist=`find unfat-$$ -type f -name \*.o -print -o -name \*.lo -print| xargs basename | sort -u | $NL2SP` darwin_file= darwin_files= for darwin_file in $darwin_filelist; do darwin_files=`find unfat-$$ -name $darwin_file -print | $NL2SP` lipo -create -output "$darwin_file" $darwin_files done # $darwin_filelist ${rm}r unfat-$$ cd "$darwin_orig_dir" else cd "$darwin_orig_dir" func_extract_an_archive "$my_xdir" "$my_xabs" fi # $darwin_arches fi # $run ;; *) func_extract_an_archive "$my_xdir" "$my_xabs" ;; esac my_oldobjs="$my_oldobjs "`find $my_xdir -name \*.$objext -print -o -name \*.lo -print | $NL2SP` done func_extract_archives_result="$my_oldobjs" } # End of Shell function definitions ##################################### # Darwin sucks eval std_shrext=\"$shrext_cmds\" disable_libs=no # Parse our command line options once, thoroughly. while test "$#" -gt 0 do arg="$1" shift case $arg in -*=*) optarg=`$echo "X$arg" | $Xsed -e 's/[-_a-zA-Z0-9]*=//'` ;; *) optarg= ;; esac # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in execute_dlfiles) execute_dlfiles="$execute_dlfiles $arg" ;; tag) tagname="$arg" preserve_args="${preserve_args}=$arg" # Check whether tagname contains only valid characters case $tagname in *[!-_A-Za-z0-9,/]*) $echo "$progname: invalid tag name: $tagname" 1>&2 exit $EXIT_FAILURE ;; esac case $tagname in CC) # Don't test for the "default" C tag, as we know, it's there, but # not specially marked. ;; *) if grep "^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$" < "$progpath" > /dev/null; then taglist="$taglist $tagname" # Evaluate the configuration. eval "`${SED} -n -e '/^# ### BEGIN LIBTOOL TAG CONFIG: '$tagname'$/,/^# ### END LIBTOOL TAG CONFIG: '$tagname'$/p' < $progpath`" else $echo "$progname: ignoring unknown tag $tagname" 1>&2 fi ;; esac ;; *) eval "$prev=\$arg" ;; esac prev= prevopt= continue fi # Have we seen a non-optional argument yet? case $arg in --help) show_help=yes ;; --version) echo "\ $PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP Copyright (C) 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." exit $? ;; --config) ${SED} -e '1,/^# ### BEGIN LIBTOOL CONFIG/d' -e '/^# ### END LIBTOOL CONFIG/,$d' $progpath # Now print the configurations for the tags. for tagname in $taglist; do ${SED} -n -e "/^# ### BEGIN LIBTOOL TAG CONFIG: $tagname$/,/^# ### END LIBTOOL TAG CONFIG: $tagname$/p" < "$progpath" done exit $? ;; --debug) $echo "$progname: enabling shell trace mode" set -x preserve_args="$preserve_args $arg" ;; --dry-run | -n) run=: ;; --features) $echo "host: $host" if test "$build_libtool_libs" = yes; then $echo "enable shared libraries" else $echo "disable shared libraries" fi if test "$build_old_libs" = yes; then $echo "enable static libraries" else $echo "disable static libraries" fi exit $? ;; --finish) mode="finish" ;; --mode) prevopt="--mode" prev=mode ;; --mode=*) mode="$optarg" ;; --preserve-dup-deps) duplicate_deps="yes" ;; --quiet | --silent) show=: preserve_args="$preserve_args $arg" ;; --tag) prevopt="--tag" prev=tag preserve_args="$preserve_args --tag" ;; --tag=*) set tag "$optarg" ${1+"$@"} shift prev=tag preserve_args="$preserve_args --tag" ;; -dlopen) prevopt="-dlopen" prev=execute_dlfiles ;; -*) $echo "$modename: unrecognized option \`$arg'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; *) nonopt="$arg" break ;; esac done if test -n "$prevopt"; then $echo "$modename: option \`$prevopt' requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi case $disable_libs in no) ;; shared) build_libtool_libs=no build_old_libs=yes ;; static) build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac` ;; esac # If this variable is set in any of the actions, the command in it # will be execed at the end. This prevents here-documents from being # left over by shells. exec_cmd= if test -z "$show_help"; then # Infer the operation mode. if test -z "$mode"; then $echo "*** Warning: inferring the mode of operation is deprecated." 1>&2 $echo "*** Future versions of Libtool will require --mode=MODE be specified." 1>&2 case $nonopt in *cc | cc* | *++ | gcc* | *-gcc* | g++* | xlc*) mode=link for arg do case $arg in -c) mode=compile break ;; esac done ;; *db | *dbx | *strace | *truss) mode=execute ;; *install*|cp|mv) mode=install ;; *rm) mode=uninstall ;; *) # If we have no mode, but dlfiles were specified, then do execute mode. test -n "$execute_dlfiles" && mode=execute # Just use the default operation mode. if test -z "$mode"; then if test -n "$nonopt"; then $echo "$modename: warning: cannot infer operation mode from \`$nonopt'" 1>&2 else $echo "$modename: warning: cannot infer operation mode without MODE-ARGS" 1>&2 fi fi ;; esac fi # Only execute mode is allowed to have -dlopen flags. if test -n "$execute_dlfiles" && test "$mode" != execute; then $echo "$modename: unrecognized option \`-dlopen'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Change the help message to a mode-specific one. generic_help="$help" help="Try \`$modename --help --mode=$mode' for more information." # These modes are in order of execution frequency so that they run quickly. case $mode in # libtool compile mode compile) modename="$modename: compile" # Get the compilation command and the source file. base_compile= srcfile="$nonopt" # always keep a non-empty value in "srcfile" suppress_opt=yes suppress_output= arg_mode=normal libobj= later= for arg do case $arg_mode in arg ) # do not "continue". Instead, add this to base_compile lastarg="$arg" arg_mode=normal ;; target ) libobj="$arg" arg_mode=normal continue ;; normal ) # Accept any command-line options. case $arg in -o) if test -n "$libobj" ; then $echo "$modename: you cannot specify \`-o' more than once" 1>&2 exit $EXIT_FAILURE fi arg_mode=target continue ;; -static | -prefer-pic | -prefer-non-pic) later="$later $arg" continue ;; -no-suppress) suppress_opt=no continue ;; -Xcompiler) arg_mode=arg # the next one goes into the "base_compile" arg list continue # The current "srcfile" will either be retained or ;; # replaced later. I would guess that would be a bug. -Wc,*) args=`$echo "X$arg" | $Xsed -e "s/^-Wc,//"` lastarg= save_ifs="$IFS"; IFS=',' for arg in $args; do IFS="$save_ifs" # Double-quote args containing other shell metacharacters. # Many Bourne shells cannot handle close brackets correctly # in scan sets, so we specify it separately. case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac lastarg="$lastarg $arg" done IFS="$save_ifs" lastarg=`$echo "X$lastarg" | $Xsed -e "s/^ //"` # Add the arguments to base_compile. base_compile="$base_compile $lastarg" continue ;; * ) # Accept the current argument as the source file. # The previous "srcfile" becomes the current argument. # lastarg="$srcfile" srcfile="$arg" ;; esac # case $arg ;; esac # case $arg_mode # Aesthetically quote the previous argument. lastarg=`$echo "X$lastarg" | $Xsed -e "$sed_quote_subst"` case $lastarg in # Double-quote args containing other shell metacharacters. # Many Bourne shells cannot handle close brackets correctly # in scan sets, and some SunOS ksh mistreat backslash-escaping # in scan sets (worked around with variable expansion), # and furthermore cannot handle '|' '&' '(' ')' in scan sets # at all, so we specify them separately. *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") lastarg="\"$lastarg\"" ;; esac base_compile="$base_compile $lastarg" done # for arg case $arg_mode in arg) $echo "$modename: you must specify an argument for -Xcompile" exit $EXIT_FAILURE ;; target) $echo "$modename: you must specify a target with \`-o'" 1>&2 exit $EXIT_FAILURE ;; *) # Get the name of the library object. [ -z "$libobj" ] && libobj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%'` ;; esac # Recognize several different file suffixes. # If the user specifies -o file.o, it is replaced with file.lo xform='[cCFSifmso]' case $libobj in *.ada) xform=ada ;; *.adb) xform=adb ;; *.ads) xform=ads ;; *.asm) xform=asm ;; *.c++) xform=c++ ;; *.cc) xform=cc ;; *.ii) xform=ii ;; *.class) xform=class ;; *.cpp) xform=cpp ;; *.cxx) xform=cxx ;; *.[fF][09]?) xform=[fF][09]. ;; *.for) xform=for ;; *.java) xform=java ;; *.obj) xform=obj ;; *.sx) xform=sx ;; esac libobj=`$echo "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"` case $libobj in *.lo) obj=`$echo "X$libobj" | $Xsed -e "$lo2o"` ;; *) $echo "$modename: cannot determine name of library object from \`$libobj'" 1>&2 exit $EXIT_FAILURE ;; esac func_infer_tag $base_compile for arg in $later; do case $arg in -static) build_old_libs=yes continue ;; -prefer-pic) pic_mode=yes continue ;; -prefer-non-pic) pic_mode=no continue ;; esac done qlibobj=`$echo "X$libobj" | $Xsed -e "$sed_quote_subst"` case $qlibobj in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qlibobj="\"$qlibobj\"" ;; esac test "X$libobj" != "X$qlibobj" \ && $echo "X$libobj" | grep '[]~#^*{};<>?"'"'"' &()|`$[]' \ && $echo "$modename: libobj name \`$libobj' may not contain shell special characters." objname=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` xdir=`$echo "X$obj" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$obj"; then xdir= else xdir=$xdir/ fi lobj=${xdir}$objdir/$objname if test -z "$base_compile"; then $echo "$modename: you must specify a compilation command" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Delete any leftover library objects. if test "$build_old_libs" = yes; then removelist="$obj $lobj $libobj ${libobj}T" else removelist="$lobj $libobj ${libobj}T" fi $run $rm $removelist trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 # On Cygwin there's no "real" PIC flag so we must build both object types case $host_os in cygwin* | mingw* | pw32* | os2*) pic_mode=default ;; esac if test "$pic_mode" = no && test "$deplibs_check_method" != pass_all; then # non-PIC code in shared libraries is not supported pic_mode=default fi # Calculate the filename of the output object if compiler does # not support -o with -c if test "$compiler_c_o" = no; then output_obj=`$echo "X$srcfile" | $Xsed -e 's%^.*/%%' -e 's%\.[^.]*$%%'`.${objext} lockfile="$output_obj.lock" removelist="$removelist $output_obj $lockfile" trap "$run $rm $removelist; exit $EXIT_FAILURE" 1 2 15 else output_obj= need_locks=no lockfile= fi # Lock this critical section if it is needed # We use this script file to make the link, it avoids creating a new file if test "$need_locks" = yes; then until $run ln "$progpath" "$lockfile" 2>/dev/null; do $show "Waiting for $lockfile to be removed" sleep 2 done elif test "$need_locks" = warn; then if test -f "$lockfile"; then $echo "\ *** ERROR, $lockfile exists and contains: `cat $lockfile 2>/dev/null` This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi $echo "$srcfile" > "$lockfile" fi if test -n "$fix_srcfile_path"; then eval srcfile=\"$fix_srcfile_path\" fi qsrcfile=`$echo "X$srcfile" | $Xsed -e "$sed_quote_subst"` case $qsrcfile in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qsrcfile="\"$qsrcfile\"" ;; esac $run $rm "$libobj" "${libobj}T" # Create a libtool object file (analogous to a ".la" file), # but don't create it if we're doing a dry run. test -z "$run" && cat > ${libobj}T </dev/null`" != "X$srcfile"; then $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed, then go on to compile the next one if test -n "$output_obj" && test "X$output_obj" != "X$lobj"; then $show "$mv $output_obj $lobj" if $run $mv $output_obj $lobj; then : else error=$? $run $rm $removelist exit $error fi fi # Append the name of the PIC object to the libtool object file. test -z "$run" && cat >> ${libobj}T <> ${libobj}T </dev/null`" != "X$srcfile"; then $echo "\ *** ERROR, $lockfile contains: `cat $lockfile 2>/dev/null` but it should contain: $srcfile This indicates that another process is trying to use the same temporary object file, and libtool could not work around it because your compiler does not support \`-c' and \`-o' together. If you repeat this compilation, it may succeed, by chance, but you had better avoid parallel builds (make -j) in this platform, or get a better compiler." $run $rm $removelist exit $EXIT_FAILURE fi # Just move the object if needed if test -n "$output_obj" && test "X$output_obj" != "X$obj"; then $show "$mv $output_obj $obj" if $run $mv $output_obj $obj; then : else error=$? $run $rm $removelist exit $error fi fi # Append the name of the non-PIC object the libtool object file. # Only append if the libtool object file exists. test -z "$run" && cat >> ${libobj}T <> ${libobj}T <&2 fi if test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; -static) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=built ;; -static-libtool-libs) if test -z "$pic_flag" && test -n "$link_static_flag"; then dlopen_self=$dlopen_self_static fi prefer_static_libs=yes ;; esac build_libtool_libs=no build_old_libs=yes break ;; esac done # See if our shared archives depend on static archives. test -n "$old_archive_from_new_cmds" && build_old_libs=yes # Go through the arguments, transforming them on the way. while test "$#" -gt 0; do arg="$1" shift case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") qarg=\"`$echo "X$arg" | $Xsed -e "$sed_quote_subst"`\" ### testsuite: skip nested quoting test ;; *) qarg=$arg ;; esac libtool_args="$libtool_args $qarg" # If the previous option needs an argument, assign it. if test -n "$prev"; then case $prev in output) compile_command="$compile_command @OUTPUT@" finalize_command="$finalize_command @OUTPUT@" ;; esac case $prev in dlfiles|dlprefiles) if test "$preload" = no; then # Add the symbol object into the linking commands. compile_command="$compile_command @SYMFILE@" finalize_command="$finalize_command @SYMFILE@" preload=yes fi case $arg in *.la | *.lo) ;; # We handle these cases below. force) if test "$dlself" = no; then dlself=needless export_dynamic=yes fi prev= continue ;; self) if test "$prev" = dlprefiles; then dlself=yes elif test "$prev" = dlfiles && test "$dlopen_self" != yes; then dlself=yes else dlself=needless export_dynamic=yes fi prev= continue ;; *) if test "$prev" = dlfiles; then dlfiles="$dlfiles $arg" else dlprefiles="$dlprefiles $arg" fi prev= continue ;; esac ;; expsyms) export_symbols="$arg" if test ! -f "$arg"; then $echo "$modename: symbol file \`$arg' does not exist" exit $EXIT_FAILURE fi prev= continue ;; expsyms_regex) export_symbols_regex="$arg" prev= continue ;; inst_prefix) inst_prefix_dir="$arg" prev= continue ;; precious_regex) precious_files_regex="$arg" prev= continue ;; release) release="-$arg" prev= continue ;; objectlist) if test -f "$arg"; then save_arg=$arg moreargs= for fil in `cat $save_arg` do # moreargs="$moreargs $fil" arg=$fil # A libtool-controlled object. # Check to see that this really is a libtool object. if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then pic_object= non_pic_object= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac if test -z "$pic_object" || \ test -z "$non_pic_object" || test "$pic_object" = none && \ test "$non_pic_object" = none; then $echo "$modename: cannot find name of object for \`$arg'" 1>&2 exit $EXIT_FAILURE fi # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi if test "$pic_object" != none; then # Prepend the subdirectory the object is found in. pic_object="$xdir$pic_object" if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then dlfiles="$dlfiles $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" fi # Non-PIC object. if test "$non_pic_object" != none; then # Prepend the subdirectory the object is found in. non_pic_object="$xdir$non_pic_object" # A standard non-PIC object non_pic_objects="$non_pic_objects $non_pic_object" if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object="$pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. if test -z "$run"; then $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 exit $EXIT_FAILURE else # Dry-run case. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` libobjs="$libobjs $pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi fi done else $echo "$modename: link input file \`$save_arg' does not exist" exit $EXIT_FAILURE fi arg=$save_arg prev= continue ;; rpath | xrpath) # We need an absolute path. case $arg in [\\/]* | [A-Za-z]:[\\/]*) ;; *) $echo "$modename: only absolute run-paths are allowed" 1>&2 exit $EXIT_FAILURE ;; esac if test "$prev" = rpath; then case "$rpath " in *" $arg "*) ;; *) rpath="$rpath $arg" ;; esac else case "$xrpath " in *" $arg "*) ;; *) xrpath="$xrpath $arg" ;; esac fi prev= continue ;; xcompiler) compiler_flags="$compiler_flags $qarg" prev= compile_command="$compile_command $qarg" finalize_command="$finalize_command $qarg" continue ;; xlinker) linker_flags="$linker_flags $qarg" compiler_flags="$compiler_flags $wl$qarg" prev= compile_command="$compile_command $wl$qarg" finalize_command="$finalize_command $wl$qarg" continue ;; xcclinker) linker_flags="$linker_flags $qarg" compiler_flags="$compiler_flags $qarg" prev= compile_command="$compile_command $qarg" finalize_command="$finalize_command $qarg" continue ;; shrext) shrext_cmds="$arg" prev= continue ;; darwin_framework|darwin_framework_skip) test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" prev= continue ;; *) eval "$prev=\"\$arg\"" prev= continue ;; esac fi # test -n "$prev" prevarg="$arg" case $arg in -all-static) if test -n "$link_static_flag"; then compile_command="$compile_command $link_static_flag" finalize_command="$finalize_command $link_static_flag" fi continue ;; -allow-undefined) # FIXME: remove this flag sometime in the future. $echo "$modename: \`-allow-undefined' is deprecated because it is the default" 1>&2 continue ;; -avoid-version) avoid_version=yes continue ;; -dlopen) prev=dlfiles continue ;; -dlpreopen) prev=dlprefiles continue ;; -export-dynamic) export_dynamic=yes continue ;; -export-symbols | -export-symbols-regex) if test -n "$export_symbols" || test -n "$export_symbols_regex"; then $echo "$modename: more than one -exported-symbols argument is not allowed" exit $EXIT_FAILURE fi if test "X$arg" = "X-export-symbols"; then prev=expsyms else prev=expsyms_regex fi continue ;; -framework|-arch|-isysroot) case " $CC " in *" ${arg} ${1} "* | *" ${arg} ${1} "*) prev=darwin_framework_skip ;; *) compiler_flags="$compiler_flags $arg" prev=darwin_framework ;; esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" continue ;; -inst-prefix-dir) prev=inst_prefix continue ;; # The native IRIX linker understands -LANG:*, -LIST:* and -LNO:* # so, if we see these flags be careful not to treat them like -L -L[A-Z][A-Z]*:*) case $with_gcc/$host in no/*-*-irix* | /*-*-irix*) compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" ;; esac continue ;; -L*) dir=`$echo "X$arg" | $Xsed -e 's/^-L//'` # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2 absdir="$dir" notinst_path="$notinst_path $dir" fi dir="$absdir" ;; esac case "$deplibs " in *" -L$dir "*) ;; *) deplibs="$deplibs -L$dir" lib_search_path="$lib_search_path $dir" ;; esac case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$dir:"*) ;; *) dllsearchpath="$dllsearchpath:$dir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac continue ;; -l*) if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*) # These systems don't actually have a C or math library (as such) continue ;; *-*-os2*) # These systems don't actually have a C library (as such) test "X$arg" = "X-lc" && continue ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. test "X$arg" = "X-lc" && continue ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C and math libraries are in the System framework deplibs="$deplibs -framework System" continue ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype test "X$arg" = "X-lc" && continue ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work test "X$arg" = "X-lc" && continue ;; esac elif test "X$arg" = "X-lc_r"; then case $host in *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc_r directly, use -pthread flag. continue ;; esac fi deplibs="$deplibs $arg" continue ;; # Tru64 UNIX uses -model [arg] to determine the layout of C++ # classes, name mangling, and exception handling. -model) compile_command="$compile_command $arg" compiler_flags="$compiler_flags $arg" finalize_command="$finalize_command $arg" prev=xcompiler continue ;; -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) compiler_flags="$compiler_flags $arg" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" continue ;; -multi_module) single_module="${wl}-multi_module" continue ;; -module) module=yes continue ;; # -64, -mips[0-9] enable 64-bit mode on the SGI compiler # -r[0-9][0-9]* specifies the processor on the SGI compiler # -xarch=*, -xtarget=* enable 64-bit mode on the Sun compiler # +DA*, +DD* enable 64-bit mode on the HP compiler # -q* pass through compiler args for the IBM compiler # -m* pass through architecture-specific compiler args for GCC # -m*, -t[45]*, -txscale* pass through architecture-specific # compiler args for GCC # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC # -F/path gives path to uninstalled frameworks, gcc on darwin # @file GCC response files -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \ -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" compiler_flags="$compiler_flags $arg" continue ;; -shrext) prev=shrext continue ;; -no-fast-install) fast_install=no continue ;; -no-install) case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin*) # The PATH hackery in wrapper scripts is required on Windows # and Darwin in order for the loader to find any dlls it needs. $echo "$modename: warning: \`-no-install' is ignored for $host" 1>&2 $echo "$modename: warning: assuming \`-no-fast-install' instead" 1>&2 fast_install=no ;; *) no_install=yes ;; esac continue ;; -no-undefined) allow_undefined=no continue ;; -objectlist) prev=objectlist continue ;; -o) prev=output ;; -precious-files-regex) prev=precious_regex continue ;; -release) prev=release continue ;; -rpath) prev=rpath continue ;; -R) prev=xrpath continue ;; -R*) dir=`$echo "X$arg" | $Xsed -e 's/^-R//'` # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) $echo "$modename: only absolute run-paths are allowed" 1>&2 exit $EXIT_FAILURE ;; esac case "$xrpath " in *" $dir "*) ;; *) xrpath="$xrpath $dir" ;; esac continue ;; -static | -static-libtool-libs) # The effects of -static are defined in a previous loop. # We used to do the same as -all-static on platforms that # didn't have a PIC flag, but the assumption that the effects # would be equivalent was wrong. It would break on at least # Digital Unix and AIX. continue ;; -thread-safe) thread_safe=yes continue ;; -version-info) prev=vinfo continue ;; -version-number) prev=vinfo vinfo_number=yes continue ;; -Wc,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wc,//'` arg= save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") flag="\"$flag\"" ;; esac arg="$arg $wl$flag" compiler_flags="$compiler_flags $flag" done IFS="$save_ifs" arg=`$echo "X$arg" | $Xsed -e "s/^ //"` ;; -Wl,*) args=`$echo "X$arg" | $Xsed -e "$sed_quote_subst" -e 's/^-Wl,//'` arg= save_ifs="$IFS"; IFS=',' for flag in $args; do IFS="$save_ifs" case $flag in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") flag="\"$flag\"" ;; esac arg="$arg $wl$flag" compiler_flags="$compiler_flags $wl$flag" linker_flags="$linker_flags $flag" done IFS="$save_ifs" arg=`$echo "X$arg" | $Xsed -e "s/^ //"` ;; -Xcompiler) prev=xcompiler continue ;; -Xlinker) prev=xlinker continue ;; -XCClinker) prev=xcclinker continue ;; # Some other compiler flag. -* | +*) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac ;; *.$objext) # A standard object. objs="$objs $arg" ;; *.lo) # A libtool-controlled object. # Check to see that this really is a libtool object. if (${SED} -e '2q' $arg | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then pic_object= non_pic_object= # Read the .lo file # If there is no directory component, then add one. case $arg in */* | *\\*) . $arg ;; *) . ./$arg ;; esac if test -z "$pic_object" || \ test -z "$non_pic_object" || test "$pic_object" = none && \ test "$non_pic_object" = none; then $echo "$modename: cannot find name of object for \`$arg'" 1>&2 exit $EXIT_FAILURE fi # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi if test "$pic_object" != none; then # Prepend the subdirectory the object is found in. pic_object="$xdir$pic_object" if test "$prev" = dlfiles; then if test "$build_libtool_libs" = yes && test "$dlopen_support" = yes; then dlfiles="$dlfiles $pic_object" prev= continue else # If libtool objects are unsupported, then we need to preload. prev=dlprefiles fi fi # CHECK ME: I think I busted this. -Ossama if test "$prev" = dlprefiles; then # Preload the old-style object. dlprefiles="$dlprefiles $pic_object" prev= fi # A PIC object. libobjs="$libobjs $pic_object" arg="$pic_object" fi # Non-PIC object. if test "$non_pic_object" != none; then # Prepend the subdirectory the object is found in. non_pic_object="$xdir$non_pic_object" # A standard non-PIC object non_pic_objects="$non_pic_objects $non_pic_object" if test -z "$pic_object" || test "$pic_object" = none ; then arg="$non_pic_object" fi else # If the PIC object exists, use it instead. # $xdir was prepended to $pic_object above. non_pic_object="$pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi else # Only an error if not doing a dry-run. if test -z "$run"; then $echo "$modename: \`$arg' is not a valid libtool object" 1>&2 exit $EXIT_FAILURE else # Dry-run case. # Extract subdirectory from the argument. xdir=`$echo "X$arg" | $Xsed -e 's%/[^/]*$%%'` if test "X$xdir" = "X$arg"; then xdir= else xdir="$xdir/" fi pic_object=`$echo "X${xdir}${objdir}/${arg}" | $Xsed -e "$lo2o"` non_pic_object=`$echo "X${xdir}${arg}" | $Xsed -e "$lo2o"` libobjs="$libobjs $pic_object" non_pic_objects="$non_pic_objects $non_pic_object" fi fi ;; *.$libext) # An archive. deplibs="$deplibs $arg" old_deplibs="$old_deplibs $arg" continue ;; *.la) # A libtool-controlled library. if test "$prev" = dlfiles; then # This library was specified with -dlopen. dlfiles="$dlfiles $arg" prev= elif test "$prev" = dlprefiles; then # The library was specified with -dlpreopen. dlprefiles="$dlprefiles $arg" prev= else deplibs="$deplibs $arg" fi continue ;; # Some other compiler argument. *) # Unknown arguments in both finalize_command and compile_command need # to be aesthetically quoted because they are evaled later. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac ;; esac # arg # Now actually substitute the argument into the commands. if test -n "$arg"; then compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" fi done # argument parsing loop if test -n "$prev"; then $echo "$modename: the \`$prevarg' option requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test "$export_dynamic" = yes && test -n "$export_dynamic_flag_spec"; then eval arg=\"$export_dynamic_flag_spec\" compile_command="$compile_command $arg" finalize_command="$finalize_command $arg" fi oldlibs= # calculate the name of the file, without its directory outputname=`$echo "X$output" | $Xsed -e 's%^.*/%%'` libobjs_save="$libobjs" if test -n "$shlibpath_var"; then # get the directories listed in $shlibpath_var eval shlib_search_path=\`\$echo \"X\${$shlibpath_var}\" \| \$Xsed -e \'s/:/ /g\'\` else shlib_search_path= fi eval sys_lib_search_path=\"$sys_lib_search_path_spec\" eval sys_lib_dlsearch_path=\"$sys_lib_dlsearch_path_spec\" output_objdir=`$echo "X$output" | $Xsed -e 's%/[^/]*$%%'` if test "X$output_objdir" = "X$output"; then output_objdir="$objdir" else output_objdir="$output_objdir/$objdir" fi # Create the object directory. if test ! -d "$output_objdir"; then $show "$mkdir $output_objdir" $run $mkdir $output_objdir exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then exit $exit_status fi fi # Determine the type of output case $output in "") $echo "$modename: you must specify an output file" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; *.$libext) linkmode=oldlib ;; *.lo | *.$objext) linkmode=obj ;; *.la) linkmode=lib ;; *) linkmode=prog ;; # Anything else should be a program. esac case $host in *cygwin* | *mingw* | *pw32*) # don't eliminate duplications in $postdeps and $predeps duplicate_compiler_generated_deps=yes ;; *) duplicate_compiler_generated_deps=$duplicate_deps ;; esac specialdeplibs= libs= # Find all interdependent deplibs by searching for libraries # that are linked more than once (e.g. -la -lb -la) for deplib in $deplibs; do if test "X$duplicate_deps" = "Xyes" ; then case "$libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi libs="$libs $deplib" done if test "$linkmode" = lib; then libs="$predeps $libs $compiler_lib_search_path $postdeps" # Compute libraries that are listed more than once in $predeps # $postdeps and mark them as special (i.e., whose duplicates are # not to be eliminated). pre_post_deps= if test "X$duplicate_compiler_generated_deps" = "Xyes" ; then for pre_post_dep in $predeps $postdeps; do case "$pre_post_deps " in *" $pre_post_dep "*) specialdeplibs="$specialdeplibs $pre_post_deps" ;; esac pre_post_deps="$pre_post_deps $pre_post_dep" done fi pre_post_deps= fi deplibs= newdependency_libs= newlib_search_path= need_relink=no # whether we're linking any uninstalled libtool libraries notinst_deplibs= # not-installed libtool libraries case $linkmode in lib) passes="conv link" for file in $dlfiles $dlprefiles; do case $file in *.la) ;; *) $echo "$modename: libraries can \`-dlopen' only libtool libraries: $file" 1>&2 exit $EXIT_FAILURE ;; esac done ;; prog) compile_deplibs= finalize_deplibs= alldeplibs=no newdlfiles= newdlprefiles= passes="conv scan dlopen dlpreopen link" ;; *) passes="conv" ;; esac for pass in $passes; do if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan"; then libs="$deplibs" deplibs= fi if test "$linkmode" = prog; then case $pass in dlopen) libs="$dlfiles" ;; dlpreopen) libs="$dlprefiles" ;; link) libs="$deplibs %DEPLIBS% $dependency_libs" ;; esac fi if test "$pass" = dlopen; then # Collect dlpreopened libraries save_deplibs="$deplibs" deplibs= fi for deplib in $libs; do lib= found=no case $deplib in -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads) if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else compiler_flags="$compiler_flags $deplib" fi continue ;; -l*) if test "$linkmode" != lib && test "$linkmode" != prog; then $echo "$modename: warning: \`-l' is ignored for archives/objects" 1>&2 continue fi name=`$echo "X$deplib" | $Xsed -e 's/^-l//'` if test "$linkmode" = lib; then searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path" else searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path" fi for searchdir in $searchdirs; do for search_ext in .la $std_shrext .so .a; do # Search the libtool library lib="$searchdir/lib${name}${search_ext}" if test -f "$lib"; then if test "$search_ext" = ".la"; then found=yes else found=no fi break 2 fi done done if test "$found" != yes; then # deplib doesn't seem to be a libtool library if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" fi continue else # deplib is a libtool library # If $allow_libtool_libs_with_static_runtimes && $deplib is a stdlib, # We need to do some special things here, and not later. if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $deplib "*) if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then library_names= old_library= case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac for l in $old_library $library_names; do ll="$l" done if test "X$ll" = "X$old_library" ; then # only static version available found=no ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` test "X$ladir" = "X$lib" && ladir="." lib=$ladir/$old_library if test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else deplibs="$deplib $deplibs" test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs" fi continue fi fi ;; *) ;; esac fi fi ;; # -l -L*) case $linkmode in lib) deplibs="$deplib $deplibs" test "$pass" = conv && continue newdependency_libs="$deplib $newdependency_libs" newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; prog) if test "$pass" = conv; then deplibs="$deplib $deplibs" continue fi if test "$pass" = scan; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'` ;; *) $echo "$modename: warning: \`-L' is ignored for archives/objects" 1>&2 ;; esac # linkmode continue ;; # -L -R*) if test "$pass" = link; then dir=`$echo "X$deplib" | $Xsed -e 's/^-R//'` # Make sure the xrpath contains only unique directories. case "$xrpath " in *" $dir "*) ;; *) xrpath="$xrpath $dir" ;; esac fi deplibs="$deplib $deplibs" continue ;; *.la) lib="$deplib" ;; *.$libext) if test "$pass" = conv; then deplibs="$deplib $deplibs" continue fi case $linkmode in lib) valid_a_lib=no case $deplibs_check_method in match_pattern*) set dummy $deplibs_check_method match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` if eval $echo \"$deplib\" 2>/dev/null \ | $SED 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then valid_a_lib=yes fi ;; pass_all) valid_a_lib=yes ;; esac if test "$valid_a_lib" != yes; then $echo $echo "*** Warning: Trying to link with static lib archive $deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because the file extensions .$libext of this argument makes me believe" $echo "*** that it is just a static archive that I should not used here." else $echo $echo "*** Warning: Linking the shared library $output against the" $echo "*** static library $deplib is not portable!" deplibs="$deplib $deplibs" fi continue ;; prog) if test "$pass" != link; then deplibs="$deplib $deplibs" else compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" fi continue ;; esac # linkmode ;; # *.$libext *.lo | *.$objext) if test "$pass" = conv; then deplibs="$deplib $deplibs" elif test "$linkmode" = prog; then if test "$pass" = dlpreopen || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlopen support or we're linking statically, # we need to preload. newdlprefiles="$newdlprefiles $deplib" compile_deplibs="$deplib $compile_deplibs" finalize_deplibs="$deplib $finalize_deplibs" else newdlfiles="$newdlfiles $deplib" fi fi continue ;; %DEPLIBS%) alldeplibs=yes continue ;; esac # case $deplib if test "$found" = yes || test -f "$lib"; then : else $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2 exit $EXIT_FAILURE fi # Check to see that this really is a libtool archive. if (${SED} -e '2q' $lib | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi ladir=`$echo "X$lib" | $Xsed -e 's%/[^/]*$%%'` test "X$ladir" = "X$lib" && ladir="." dlname= dlopen= dlpreopen= libdir= library_names= old_library= # If the library was installed with an old release of libtool, # it will not redefine variables installed, or shouldnotlink installed=yes shouldnotlink=no avoidtemprpath= # Read the .la file case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac if test "$linkmode,$pass" = "lib,link" || test "$linkmode,$pass" = "prog,scan" || { test "$linkmode" != prog && test "$linkmode" != lib; }; then test -n "$dlopen" && dlfiles="$dlfiles $dlopen" test -n "$dlpreopen" && dlprefiles="$dlprefiles $dlpreopen" fi if test "$pass" = conv; then # Only check for convenience libraries deplibs="$lib $deplibs" if test -z "$libdir"; then if test -z "$old_library"; then $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 exit $EXIT_FAILURE fi # It is a libtool convenience library, so add in its objects. convenience="$convenience $ladir/$objdir/$old_library" old_convenience="$old_convenience $ladir/$objdir/$old_library" tmp_libs= for deplib in $dependency_libs; do deplibs="$deplib $deplibs" if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done elif test "$linkmode" != prog && test "$linkmode" != lib; then $echo "$modename: \`$lib' is not a convenience library" 1>&2 exit $EXIT_FAILURE fi continue fi # $pass = conv # Get the name of the library we link against. linklib= for l in $old_library $library_names; do linklib="$l" done if test -z "$linklib"; then $echo "$modename: cannot find name of link library for \`$lib'" 1>&2 exit $EXIT_FAILURE fi # This library was specified with -dlopen. if test "$pass" = dlopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlopen a convenience library: \`$lib'" 1>&2 exit $EXIT_FAILURE fi if test -z "$dlname" || test "$dlopen_support" != yes || test "$build_libtool_libs" = no; then # If there is no dlname, no dlopen support or we're linking # statically, we need to preload. We also need to preload any # dependent libraries so libltdl's deplib preloader doesn't # bomb out in the load deplibs phase. dlprefiles="$dlprefiles $lib $dependency_libs" else newdlfiles="$newdlfiles $lib" fi continue fi # $pass = dlopen # We need an absolute path. case $ladir in [\\/]* | [A-Za-z]:[\\/]*) abs_ladir="$ladir" ;; *) abs_ladir=`cd "$ladir" && pwd` if test -z "$abs_ladir"; then $echo "$modename: warning: cannot determine absolute directory name of \`$ladir'" 1>&2 $echo "$modename: passing it literally to the linker, although it might fail" 1>&2 abs_ladir="$ladir" fi ;; esac laname=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` # Find the relevant object directory and library name. if test "X$installed" = Xyes; then if test ! -f "$libdir/$linklib" && test -f "$abs_ladir/$linklib"; then $echo "$modename: warning: library \`$lib' was moved." 1>&2 dir="$ladir" absdir="$abs_ladir" libdir="$abs_ladir" else dir="$libdir" absdir="$libdir" fi test "X$hardcode_automatic" = Xyes && avoidtemprpath=yes else if test ! -f "$ladir/$objdir/$linklib" && test -f "$abs_ladir/$linklib"; then dir="$ladir" absdir="$abs_ladir" # Remove this search path later notinst_path="$notinst_path $abs_ladir" else dir="$ladir/$objdir" absdir="$abs_ladir/$objdir" # Remove this search path later notinst_path="$notinst_path $abs_ladir" fi fi # $installed = yes name=`$echo "X$laname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` # This library was specified with -dlpreopen. if test "$pass" = dlpreopen; then if test -z "$libdir"; then $echo "$modename: cannot -dlpreopen a convenience library: \`$lib'" 1>&2 exit $EXIT_FAILURE fi # Prefer using a static library (so that no silly _DYNAMIC symbols # are required to link). if test -n "$old_library"; then newdlprefiles="$newdlprefiles $dir/$old_library" # Otherwise, use the dlname, so that lt_dlopen finds it. elif test -n "$dlname"; then newdlprefiles="$newdlprefiles $dir/$dlname" else newdlprefiles="$newdlprefiles $dir/$linklib" fi fi # $pass = dlpreopen if test -z "$libdir"; then # Link the convenience library if test "$linkmode" = lib; then deplibs="$dir/$old_library $deplibs" elif test "$linkmode,$pass" = "prog,link"; then compile_deplibs="$dir/$old_library $compile_deplibs" finalize_deplibs="$dir/$old_library $finalize_deplibs" else deplibs="$lib $deplibs" # used for prog,scan pass fi continue fi if test "$linkmode" = prog && test "$pass" != link; then newlib_search_path="$newlib_search_path $ladir" deplibs="$lib $deplibs" linkalldeplibs=no if test "$link_all_deplibs" != no || test -z "$library_names" || test "$build_libtool_libs" = no; then linkalldeplibs=yes fi tmp_libs= for deplib in $dependency_libs; do case $deplib in -L*) newlib_search_path="$newlib_search_path "`$echo "X$deplib" | $Xsed -e 's/^-L//'`;; ### testsuite: skip nested quoting test esac # Need to link against all dependency_libs? if test "$linkalldeplibs" = yes; then deplibs="$deplib $deplibs" else # Need to hardcode shared library paths # or/and link against static libraries newdependency_libs="$deplib $newdependency_libs" fi if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done # for deplib continue fi # $linkmode = prog... if test "$linkmode,$pass" = "prog,link"; then if test -n "$library_names" && { { test "$prefer_static_libs" = no || test "$prefer_static_libs,$installed" = "built,yes"; } || test -z "$old_library"; }; then # We need to hardcode the library path if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then # Make sure the rpath contains only unique directories. case "$temp_rpath " in *" $dir "*) ;; *" $absdir "*) ;; *) temp_rpath="$temp_rpath $absdir" ;; esac fi # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) compile_rpath="$compile_rpath $absdir" esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" esac ;; esac fi # $linkmode,$pass = prog,link... if test "$alldeplibs" = yes && { test "$deplibs_check_method" = pass_all || { test "$build_libtool_libs" = yes && test -n "$library_names"; }; }; then # We only need to search for static libraries continue fi fi link_static=no # Whether the deplib will be linked statically use_static_libs=$prefer_static_libs if test "$use_static_libs" = built && test "$installed" = yes ; then use_static_libs=no fi if test -n "$library_names" && { test "$use_static_libs" = no || test -z "$old_library"; }; then if test "$installed" = no; then notinst_deplibs="$notinst_deplibs $lib" need_relink=yes fi # This is a shared library # Warn about portability, can't link against -module's on # some systems (darwin) if test "$shouldnotlink" = yes && test "$pass" = link ; then $echo if test "$linkmode" = prog; then $echo "*** Warning: Linking the executable $output against the loadable module" else $echo "*** Warning: Linking the shared library $output against the loadable module" fi $echo "*** $linklib is not portable!" fi if test "$linkmode" = lib && test "$hardcode_into_libs" = yes; then # Hardcode the library path. # Skip directories that are in the system default run-time # search path. case " $sys_lib_dlsearch_path " in *" $absdir "*) ;; *) case "$compile_rpath " in *" $absdir "*) ;; *) compile_rpath="$compile_rpath $absdir" esac ;; esac case " $sys_lib_dlsearch_path " in *" $libdir "*) ;; *) case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" esac ;; esac fi if test -n "$old_archive_from_expsyms_cmds"; then # figure out the soname set dummy $library_names realname="$2" shift; shift libname=`eval \\$echo \"$libname_spec\"` # use dlname if we got it. it's perfectly good, no? if test -n "$dlname"; then soname="$dlname" elif test -n "$soname_spec"; then # bleh windows case $host in *cygwin* | mingw*) major=`expr $current - $age` versuffix="-$major" ;; esac eval soname=\"$soname_spec\" else soname="$realname" fi # Make a new name for the extract_expsyms_cmds to use soroot="$soname" soname=`$echo $soroot | ${SED} -e 's/^.*\///'` newlib="libimp-`$echo $soname | ${SED} 's/^lib//;s/\.dll$//'`.a" # If the library has no export list, then create one now if test -f "$output_objdir/$soname-def"; then : else $show "extracting exported symbol list from \`$soname'" save_ifs="$IFS"; IFS='~' cmds=$extract_expsyms_cmds for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi # Create $newlib if test -f "$output_objdir/$newlib"; then :; else $show "generating import library for \`$soname'" save_ifs="$IFS"; IFS='~' cmds=$old_archive_from_expsyms_cmds for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi # make sure the library variables are pointing to the new library dir=$output_objdir linklib=$newlib fi # test -n "$old_archive_from_expsyms_cmds" if test "$linkmode" = prog || test "$mode" != relink; then add_shlibpath= add_dir= add= lib_linked=yes case $hardcode_action in immediate | unsupported) if test "$hardcode_direct" = no; then add="$dir/$linklib" case $host in *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;; *-*-sysv4*uw2*) add_dir="-L$dir" ;; *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \ *-*-unixware7*) add_dir="-L$dir" ;; *-*-darwin* ) # if the lib is a module then we can not link against # it, someone is ignoring the new warnings I added if /usr/bin/file -L $add 2> /dev/null | $EGREP ": [^:]* bundle" >/dev/null ; then $echo "** Warning, lib $linklib is a module, not a shared library" if test -z "$old_library" ; then $echo $echo "** And there doesn't seem to be a static archive available" $echo "** The link will probably fail, sorry" else add="$dir/$old_library" fi fi esac elif test "$hardcode_minus_L" = no; then case $host in *-*-sunos*) add_shlibpath="$dir" ;; esac add_dir="-L$dir" add="-l$name" elif test "$hardcode_shlibpath_var" = no; then add_shlibpath="$dir" add="-l$name" else lib_linked=no fi ;; relink) if test "$hardcode_direct" = yes; then add="$dir/$linklib" elif test "$hardcode_minus_L" = yes; then add_dir="-L$dir" # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) add_dir="$add_dir -L$inst_prefix_dir$libdir" ;; esac fi add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then add_shlibpath="$dir" add="-l$name" else lib_linked=no fi ;; *) lib_linked=no ;; esac if test "$lib_linked" != yes; then $echo "$modename: configuration error: unsupported hardcode properties" exit $EXIT_FAILURE fi if test -n "$add_shlibpath"; then case :$compile_shlibpath: in *":$add_shlibpath:"*) ;; *) compile_shlibpath="$compile_shlibpath$add_shlibpath:" ;; esac fi if test "$linkmode" = prog; then test -n "$add_dir" && compile_deplibs="$add_dir $compile_deplibs" test -n "$add" && compile_deplibs="$add $compile_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" if test "$hardcode_direct" != yes && \ test "$hardcode_minus_L" != yes && \ test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; esac fi fi fi if test "$linkmode" = prog || test "$mode" = relink; then add_shlibpath= add_dir= add= # Finalize command for both is simple: just hardcode it. if test "$hardcode_direct" = yes; then add="$libdir/$linklib" elif test "$hardcode_minus_L" = yes; then add_dir="-L$libdir" add="-l$name" elif test "$hardcode_shlibpath_var" = yes; then case :$finalize_shlibpath: in *":$libdir:"*) ;; *) finalize_shlibpath="$finalize_shlibpath$libdir:" ;; esac add="-l$name" elif test "$hardcode_automatic" = yes; then if test -n "$inst_prefix_dir" && test -f "$inst_prefix_dir$libdir/$linklib" ; then add="$inst_prefix_dir$libdir/$linklib" else add="$libdir/$linklib" fi else # We cannot seem to hardcode it, guess we'll fake it. add_dir="-L$libdir" # Try looking first in the location we're being installed to. if test -n "$inst_prefix_dir"; then case $libdir in [\\/]*) add_dir="$add_dir -L$inst_prefix_dir$libdir" ;; esac fi add="-l$name" fi if test "$linkmode" = prog; then test -n "$add_dir" && finalize_deplibs="$add_dir $finalize_deplibs" test -n "$add" && finalize_deplibs="$add $finalize_deplibs" else test -n "$add_dir" && deplibs="$add_dir $deplibs" test -n "$add" && deplibs="$add $deplibs" fi fi elif test "$linkmode" = prog; then # Here we assume that one of hardcode_direct or hardcode_minus_L # is not unsupported. This is valid on all known static and # shared platforms. if test "$hardcode_direct" != unsupported; then test -n "$old_library" && linklib="$old_library" compile_deplibs="$dir/$linklib $compile_deplibs" finalize_deplibs="$dir/$linklib $finalize_deplibs" else compile_deplibs="-l$name -L$dir $compile_deplibs" finalize_deplibs="-l$name -L$dir $finalize_deplibs" fi elif test "$build_libtool_libs" = yes; then # Not a shared library if test "$deplibs_check_method" != pass_all; then # We're trying link a shared library against a static one # but the system doesn't support it. # Just print a warning and add the library to dependency_libs so # that the program can be linked against the static library. $echo $echo "*** Warning: This system can not link to static lib archive $lib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have." if test "$module" = yes; then $echo "*** But as you try to build a module library, libtool will still create " $echo "*** a static module, that should work as long as the dlopening application" $echo "*** is linked with the -dlopen flag to resolve symbols at runtime." if test -z "$global_symbol_pipe"; then $echo $echo "*** However, this would only work if libtool was able to extract symbol" $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" $echo "*** not find such a program. So, this module is probably useless." $echo "*** \`nm' from GNU binutils and a full rebuild may help." fi if test "$build_old_libs" = no; then build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi else deplibs="$dir/$old_library $deplibs" link_static=yes fi fi # link shared/static library? if test "$linkmode" = lib; then if test -n "$dependency_libs" && { test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes || test "$link_static" = yes; }; then # Extract -R from dependency_libs temp_deplibs= for libdir in $dependency_libs; do case $libdir in -R*) temp_xrpath=`$echo "X$libdir" | $Xsed -e 's/^-R//'` case " $xrpath " in *" $temp_xrpath "*) ;; *) xrpath="$xrpath $temp_xrpath";; esac;; *) temp_deplibs="$temp_deplibs $libdir";; esac done dependency_libs="$temp_deplibs" fi newlib_search_path="$newlib_search_path $absdir" # Link against this library test "$link_static" = no && newdependency_libs="$abs_ladir/$laname $newdependency_libs" # ... and its dependency_libs tmp_libs= for deplib in $dependency_libs; do newdependency_libs="$deplib $newdependency_libs" if test "X$duplicate_deps" = "Xyes" ; then case "$tmp_libs " in *" $deplib "*) specialdeplibs="$specialdeplibs $deplib" ;; esac fi tmp_libs="$tmp_libs $deplib" done if test "$link_all_deplibs" != no; then # Add the search paths of all dependency libraries for deplib in $dependency_libs; do case $deplib in -L*) path="$deplib" ;; *.la) dir=`$echo "X$deplib" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$deplib" && dir="." # We need an absolute path. case $dir in [\\/]* | [A-Za-z]:[\\/]*) absdir="$dir" ;; *) absdir=`cd "$dir" && pwd` if test -z "$absdir"; then $echo "$modename: warning: cannot determine absolute directory name of \`$dir'" 1>&2 absdir="$dir" fi ;; esac if grep "^installed=no" $deplib > /dev/null; then path="$absdir/$objdir" else eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -z "$libdir"; then $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi if test "$absdir" != "$libdir"; then $echo "$modename: warning: \`$deplib' seems to be moved" 1>&2 fi path="$absdir" fi depdepl= case $host in *-*-darwin*) # we do not want to link against static libs, # but need to link against shared eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib` eval deplibdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -n "$deplibrary_names" ; then for tmp in $deplibrary_names ; do depdepl=$tmp done if test -f "$deplibdir/$depdepl" ; then depdepl="$deplibdir/$depdepl" elif test -f "$path/$depdepl" ; then depdepl="$path/$depdepl" else # Can't find it, oh well... depdepl= fi # do not add paths which are already there case " $newlib_search_path " in *" $path "*) ;; *) newlib_search_path="$newlib_search_path $path";; esac fi path="" ;; *) path="-L$path" ;; esac ;; -l*) case $host in *-*-darwin*) # Again, we only want to link against shared libraries eval tmp_libs=`$echo "X$deplib" | $Xsed -e "s,^\-l,,"` for tmp in $newlib_search_path ; do if test -f "$tmp/lib$tmp_libs.dylib" ; then eval depdepl="$tmp/lib$tmp_libs.dylib" break fi done path="" ;; *) continue ;; esac ;; *) continue ;; esac case " $deplibs " in *" $path "*) ;; *) deplibs="$path $deplibs" ;; esac case " $deplibs " in *" $depdepl "*) ;; *) deplibs="$depdepl $deplibs" ;; esac done fi # link_all_deplibs != no fi # linkmode = lib done # for deplib in $libs dependency_libs="$newdependency_libs" if test "$pass" = dlpreopen; then # Link the dlpreopened libraries before other libraries for deplib in $save_deplibs; do deplibs="$deplib $deplibs" done fi if test "$pass" != dlopen; then if test "$pass" != conv; then # Make sure lib_search_path contains only unique directories. lib_search_path= for dir in $newlib_search_path; do case "$lib_search_path " in *" $dir "*) ;; *) lib_search_path="$lib_search_path $dir" ;; esac done newlib_search_path= fi if test "$linkmode,$pass" != "prog,link"; then vars="deplibs" else vars="compile_deplibs finalize_deplibs" fi for var in $vars dependency_libs; do # Add libraries to $var in reverse order eval tmp_libs=\"\$$var\" new_libs= for deplib in $tmp_libs; do # FIXME: Pedantically, this is the right thing to do, so # that some nasty dependency loop isn't accidentally # broken: #new_libs="$deplib $new_libs" # Pragmatically, this seems to cause very few problems in # practice: case $deplib in -L*) new_libs="$deplib $new_libs" ;; -R*) ;; *) # And here is the reason: when a library appears more # than once as an explicit dependence of a library, or # is implicitly linked in more than once by the # compiler, it is considered special, and multiple # occurrences thereof are not removed. Compare this # with having the same library being listed as a # dependency of multiple other libraries: in this case, # we know (pedantically, we assume) the library does not # need to be listed more than once, so we keep only the # last copy. This is not always right, but it is rare # enough that we require users that really mean to play # such unportable linking tricks to link the library # using -Wl,-lname, so that libtool does not consider it # for duplicate removal. case " $specialdeplibs " in *" $deplib "*) new_libs="$deplib $new_libs" ;; *) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$deplib $new_libs" ;; esac ;; esac ;; esac done tmp_libs= for deplib in $new_libs; do case $deplib in -L*) case " $tmp_libs " in *" $deplib "*) ;; *) tmp_libs="$tmp_libs $deplib" ;; esac ;; *) tmp_libs="$tmp_libs $deplib" ;; esac done eval $var=\"$tmp_libs\" done # for var fi # Last step: remove runtime libs from dependency_libs # (they stay in deplibs) tmp_libs= for i in $dependency_libs ; do case " $predeps $postdeps $compiler_lib_search_path " in *" $i "*) i="" ;; esac if test -n "$i" ; then tmp_libs="$tmp_libs $i" fi done dependency_libs=$tmp_libs done # for pass if test "$linkmode" = prog; then dlfiles="$newdlfiles" dlprefiles="$newdlprefiles" fi case $linkmode in oldlib) case " $deplibs" in *\ -l* | *\ -L*) $echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2 ;; esac if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for archives" 1>&2 fi if test -n "$rpath"; then $echo "$modename: warning: \`-rpath' is ignored for archives" 1>&2 fi if test -n "$xrpath"; then $echo "$modename: warning: \`-R' is ignored for archives" 1>&2 fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for archives" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for archives" 1>&2 fi if test -n "$export_symbols" || test -n "$export_symbols_regex"; then $echo "$modename: warning: \`-export-symbols' is ignored for archives" 1>&2 fi # Now set the variables for building old libraries. build_libtool_libs=no oldlibs="$output" objs="$objs$old_deplibs" ;; lib) # Make sure we only generate libraries of the form `libNAME.la'. case $outputname in lib*) name=`$echo "X$outputname" | $Xsed -e 's/\.la$//' -e 's/^lib//'` eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" ;; *) if test "$module" = no; then $echo "$modename: libtool library \`$output' must begin with \`lib'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test "$need_lib_prefix" != no; then # Add the "lib" prefix for modules if required name=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` eval shared_ext=\"$shrext_cmds\" eval libname=\"$libname_spec\" else libname=`$echo "X$outputname" | $Xsed -e 's/\.la$//'` fi ;; esac if test -n "$objs"; then if test "$deplibs_check_method" != pass_all; then $echo "$modename: cannot build libtool library \`$output' from non-libtool objects on this host:$objs" 2>&1 exit $EXIT_FAILURE else $echo $echo "*** Warning: Linking the shared library $output against the non-libtool" $echo "*** objects $objs is not portable!" libobjs="$libobjs $objs" fi fi if test "$dlself" != no; then $echo "$modename: warning: \`-dlopen self' is ignored for libtool libraries" 1>&2 fi set dummy $rpath if test "$#" -gt 2; then $echo "$modename: warning: ignoring multiple \`-rpath's for a libtool library" 1>&2 fi install_libdir="$2" oldlibs= if test -z "$rpath"; then if test "$build_libtool_libs" = yes; then # Building a libtool convenience library. # Some compilers have problems with a `.al' extension so # convenience libraries should have the same extension an # archive normally would. oldlibs="$output_objdir/$libname.$libext $oldlibs" build_libtool_libs=convenience build_old_libs=yes fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info/-version-number' is ignored for convenience libraries" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for convenience libraries" 1>&2 fi else # Parse the version information argument. save_ifs="$IFS"; IFS=':' set dummy $vinfo 0 0 0 IFS="$save_ifs" if test -n "$8"; then $echo "$modename: too many parameters to \`-version-info'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # convert absolute version numbers to libtool ages # this retains compatibility with .la files and attempts # to make the code below a bit more comprehensible case $vinfo_number in yes) number_major="$2" number_minor="$3" number_revision="$4" # # There are really only two kinds -- those that # use the current revision as the major version # and those that subtract age and use age as # a minor version. But, then there is irix # which has an extra 1 added just for fun # case $version_type in darwin|linux|osf|windows|none) current=`expr $number_major + $number_minor` age="$number_minor" revision="$number_revision" ;; freebsd-aout|freebsd-elf|sunos) current="$number_major" revision="$number_minor" age="0" ;; irix|nonstopux) current=`expr $number_major + $number_minor` age="$number_minor" revision="$number_minor" lt_irix_increment=no ;; esac ;; no) current="$2" revision="$3" age="$4" ;; esac # Check that each of the things are valid numbers. case $current in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: CURRENT \`$current' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac case $revision in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: REVISION \`$revision' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac case $age in 0|[1-9]|[1-9][0-9]|[1-9][0-9][0-9]|[1-9][0-9][0-9][0-9]|[1-9][0-9][0-9][0-9][0-9]) ;; *) $echo "$modename: AGE \`$age' must be a nonnegative integer" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE ;; esac if test "$age" -gt "$current"; then $echo "$modename: AGE \`$age' is greater than the current interface number \`$current'" 1>&2 $echo "$modename: \`$vinfo' is not valid version information" 1>&2 exit $EXIT_FAILURE fi # Calculate the version variables. major= versuffix= verstring= case $version_type in none) ;; darwin) # Like Linux, but with the current version available in # verstring for coding it into the library header major=.`expr $current - $age` versuffix="$major.$age.$revision" # Darwin ld doesn't like 0 for these options... minor_current=`expr $current + 1` xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision" verstring="-compatibility_version $minor_current -current_version $minor_current.$revision" ;; freebsd-aout) major=".$current" versuffix=".$current.$revision"; ;; freebsd-elf) major=".$current" versuffix=".$current"; ;; irix | nonstopux) if test "X$lt_irix_increment" = "Xno"; then major=`expr $current - $age` else major=`expr $current - $age + 1` fi case $version_type in nonstopux) verstring_prefix=nonstopux ;; *) verstring_prefix=sgi ;; esac verstring="$verstring_prefix$major.$revision" # Add in all the interfaces that we are compatible with. loop=$revision while test "$loop" -ne 0; do iface=`expr $revision - $loop` loop=`expr $loop - 1` verstring="$verstring_prefix$major.$iface:$verstring" done # Before this point, $major must not contain `.'. major=.$major versuffix="$major.$revision" ;; linux) major=.`expr $current - $age` versuffix="$major.$age.$revision" ;; osf) major=.`expr $current - $age` versuffix=".$current.$age.$revision" verstring="$current.$age.$revision" # Add in all the interfaces that we are compatible with. loop=$age while test "$loop" -ne 0; do iface=`expr $current - $loop` loop=`expr $loop - 1` verstring="$verstring:${iface}.0" done # Make executables depend on our current version. verstring="$verstring:${current}.0" ;; sunos) major=".$current" versuffix=".$current.$revision" ;; windows) # Use '-' rather than '.', since we only want one # extension on DOS 8.3 filesystems. major=`expr $current - $age` versuffix="-$major" ;; *) $echo "$modename: unknown library version type \`$version_type'" 1>&2 $echo "Fatal configuration error. See the $PACKAGE docs for more information." 1>&2 exit $EXIT_FAILURE ;; esac # Clear the version info if we defaulted, and they specified a release. if test -z "$vinfo" && test -n "$release"; then major= case $version_type in darwin) # we can't check for "0.0" in archive_cmds due to quoting # problems, so we reset it completely verstring= ;; *) verstring="0.0" ;; esac if test "$need_version" = no; then versuffix= else versuffix=".0.0" fi fi # Remove version info from name if versioning should be avoided if test "$avoid_version" = yes && test "$need_version" = no; then major= versuffix= verstring="" fi # Check to see if the archive will have undefined symbols. if test "$allow_undefined" = yes; then if test "$allow_undefined_flag" = unsupported; then $echo "$modename: warning: undefined symbols not allowed in $host shared libraries" 1>&2 build_libtool_libs=no build_old_libs=yes fi else # Don't allow undefined symbols. allow_undefined_flag="$no_undefined_flag" fi fi if test "$mode" != relink; then # Remove our outputs, but don't remove object files since they # may have been created when compiling PIC objects. removelist= tempremovelist=`$echo "$output_objdir/*"` for p in $tempremovelist; do case $p in *.$objext) ;; $output_objdir/$outputname | $output_objdir/$libname.* | $output_objdir/${libname}${release}.*) if test "X$precious_files_regex" != "X"; then if echo $p | $EGREP -e "$precious_files_regex" >/dev/null 2>&1 then continue fi fi removelist="$removelist $p" ;; *) ;; esac done if test -n "$removelist"; then $show "${rm}r $removelist" $run ${rm}r $removelist fi fi # Now set the variables for building old libraries. if test "$build_old_libs" = yes && test "$build_libtool_libs" != convenience ; then oldlibs="$oldlibs $output_objdir/$libname.$libext" # Transform .lo files to .o files. oldobjs="$objs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}'$/d' -e "$lo2o" | $NL2SP` fi # Eliminate all temporary directories. #for path in $notinst_path; do # lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"` # deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"` # dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"` #done if test -n "$xrpath"; then # If the user specified any rpath flags, then add them. temp_xrpath= for libdir in $xrpath; do temp_xrpath="$temp_xrpath -R$libdir" case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" ;; esac done if test "$hardcode_into_libs" != yes || test "$build_old_libs" = yes; then dependency_libs="$temp_xrpath $dependency_libs" fi fi # Make sure dlfiles contains only unique files that won't be dlpreopened old_dlfiles="$dlfiles" dlfiles= for lib in $old_dlfiles; do case " $dlprefiles $dlfiles " in *" $lib "*) ;; *) dlfiles="$dlfiles $lib" ;; esac done # Make sure dlprefiles contains only unique files old_dlprefiles="$dlprefiles" dlprefiles= for lib in $old_dlprefiles; do case "$dlprefiles " in *" $lib "*) ;; *) dlprefiles="$dlprefiles $lib" ;; esac done if test "$build_libtool_libs" = yes; then if test -n "$rpath"; then case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-beos*) # these systems don't actually have a c library (as such)! ;; *-*-rhapsody* | *-*-darwin1.[012]) # Rhapsody C library is in the System framework deplibs="$deplibs -framework System" ;; *-*-netbsd*) # Don't link with libc until the a.out ld.so is fixed. ;; *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*) # Do not include libc due to us having libc/libc_r. ;; *-*-sco3.2v5* | *-*-sco5v6*) # Causes problems with __ctype ;; *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*) # Compiler inserts libc in the correct place for threads to work ;; *) # Add libc to deplibs on all other systems if necessary. if test "$build_libtool_need_lc" = "yes"; then deplibs="$deplibs -lc" fi ;; esac fi # Transform deplibs into only deplibs that can be linked in shared. name_save=$name libname_save=$libname release_save=$release versuffix_save=$versuffix major_save=$major # I'm not sure if I'm treating the release correctly. I think # release should show up in the -l (ie -lgmp5) so we don't want to # add it in twice. Is that correct? release="" versuffix="" major="" newdeplibs= droppeddeps=no case $deplibs_check_method in pass_all) # Don't check for shared/static. Everything works. # This might be a little naive. We might want to check # whether the library exists or not. But this is on # osf3 & osf4 and I'm not really sure... Just # implementing what was already the behavior. newdeplibs=$deplibs ;; test_compile) # This code stresses the "libraries are programs" paradigm to its # limits. Maybe even breaks it. We compile a program, linking it # against the deplibs as a proxy for the library. Then we can check # whether they linked in statically or dynamically with ldd. $rm conftest.c cat > conftest.c </dev/null` for potent_lib in $potential_libs; do # Follow soft links. if ls -lLd "$potent_lib" 2>/dev/null \ | grep " -> " >/dev/null; then continue fi # The statement above tries to avoid entering an # endless loop below, in case of cyclic links. # We might still enter an endless loop, since a link # loop can be closed while we follow links, # but so what? potlib="$potent_lib" while test -h "$potlib" 2>/dev/null; do potliblink=`ls -ld $potlib | ${SED} 's/.* -> //'` case $potliblink in [\\/]* | [A-Za-z]:[\\/]*) potlib="$potliblink";; *) potlib=`$echo "X$potlib" | $Xsed -e 's,[^/]*$,,'`"$potliblink";; esac done if eval $file_magic_cmd \"\$potlib\" 2>/dev/null \ | ${SED} 10q \ | $EGREP "$file_magic_regex" > /dev/null; then newdeplibs="$newdeplibs $a_deplib" a_deplib="" break 2 fi done done fi if test -n "$a_deplib" ; then droppeddeps=yes $echo $echo "*** Warning: linker path does not have real file for library $a_deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib" ; then $echo "*** with $libname but no candidates were found. (...for file magic test)" else $echo "*** with $libname and none of the candidates passed a file format test" $echo "*** using a file magic. Last file checked: $potlib" fi fi else # Add a -L argument. newdeplibs="$newdeplibs $a_deplib" fi done # Gone through all deplibs. ;; match_pattern*) set dummy $deplibs_check_method match_pattern_regex=`expr "$deplibs_check_method" : "$2 \(.*\)"` for a_deplib in $deplibs; do name=`expr $a_deplib : '-l\(.*\)'` # If $name is empty we are operating on a -L argument. if test -n "$name" && test "$name" != "0"; then if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then case " $predeps $postdeps " in *" $a_deplib "*) newdeplibs="$newdeplibs $a_deplib" a_deplib="" ;; esac fi if test -n "$a_deplib" ; then libname=`eval \\$echo \"$libname_spec\"` for i in $lib_search_path $sys_lib_search_path $shlib_search_path; do potential_libs=`ls $i/$libname[.-]* 2>/dev/null` for potent_lib in $potential_libs; do potlib="$potent_lib" # see symlink-check above in file_magic test if eval $echo \"$potent_lib\" 2>/dev/null \ | ${SED} 10q \ | $EGREP "$match_pattern_regex" > /dev/null; then newdeplibs="$newdeplibs $a_deplib" a_deplib="" break 2 fi done done fi if test -n "$a_deplib" ; then droppeddeps=yes $echo $echo "*** Warning: linker path does not have real file for library $a_deplib." $echo "*** I have the capability to make that library automatically link in when" $echo "*** you link to this library. But I can only do this if you have a" $echo "*** shared version of the library, which you do not appear to have" $echo "*** because I did check the linker path looking for a file starting" if test -z "$potlib" ; then $echo "*** with $libname but no candidates were found. (...for regex pattern test)" else $echo "*** with $libname and none of the candidates passed a file format test" $echo "*** using a regex pattern. Last file checked: $potlib" fi fi else # Add a -L argument. newdeplibs="$newdeplibs $a_deplib" fi done # Gone through all deplibs. ;; none | unknown | *) newdeplibs="" tmp_deplibs=`$echo "X $deplibs" | $Xsed -e 's/ -lc$//' \ -e 's/ -[LR][^ ]*//g'` if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then for i in $predeps $postdeps ; do # can't use Xsed below, because $i might contain '/' tmp_deplibs=`$echo "X $tmp_deplibs" | ${SED} -e "1s,^X,," -e "s,$i,,"` done fi if $echo "X $tmp_deplibs" | $Xsed -e 's/[ ]//g' \ | grep . >/dev/null; then $echo if test "X$deplibs_check_method" = "Xnone"; then $echo "*** Warning: inter-library dependencies are not supported in this platform." else $echo "*** Warning: inter-library dependencies are not known to be supported." fi $echo "*** All declared inter-library dependencies are being dropped." droppeddeps=yes fi ;; esac versuffix=$versuffix_save major=$major_save release=$release_save libname=$libname_save name=$name_save case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework newdeplibs=`$echo "X $newdeplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; esac if test "$droppeddeps" = yes; then if test "$module" = yes; then $echo $echo "*** Warning: libtool could not satisfy all declared inter-library" $echo "*** dependencies of module $libname. Therefore, libtool will create" $echo "*** a static module, that should work as long as the dlopening" $echo "*** application is linked with the -dlopen flag." if test -z "$global_symbol_pipe"; then $echo $echo "*** However, this would only work if libtool was able to extract symbol" $echo "*** lists from a program, using \`nm' or equivalent, but libtool could" $echo "*** not find such a program. So, this module is probably useless." $echo "*** \`nm' from GNU binutils and a full rebuild may help." fi if test "$build_old_libs" = no; then oldlibs="$output_objdir/$libname.$libext" build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi else $echo "*** The inter-library dependencies that have been dropped here will be" $echo "*** automatically added whenever a program is linked with this library" $echo "*** or is declared to -dlopen it." if test "$allow_undefined" = no; then $echo $echo "*** Since this library must not contain undefined symbols," $echo "*** because either the platform does not support them or" $echo "*** it was explicitly requested with -no-undefined," $echo "*** libtool will only create a static version of it." if test "$build_old_libs" = no; then oldlibs="$output_objdir/$libname.$libext" build_libtool_libs=module build_old_libs=yes else build_libtool_libs=no fi fi fi fi # Done checking deplibs! deplibs=$newdeplibs fi # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $deplibs " in *" -L$path/$objdir "*) new_libs="$new_libs -L$path/$objdir" ;; esac ;; esac done for deplib in $deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$new_libs $deplib" ;; esac ;; *) new_libs="$new_libs $deplib" ;; esac done deplibs="$new_libs" # All the library-specific variables (install_libdir is set above). library_names= old_library= dlname= # Test again, we may have decided not to build it any more if test "$build_libtool_libs" = yes; then if test "$hardcode_into_libs" = yes; then # Hardcode the library paths hardcode_libdirs= dep_rpath= rpath="$finalize_rpath" test "$mode" != relink && rpath="$compile_rpath$rpath" for libdir in $rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" dep_rpath="$dep_rpath $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) perm_rpath="$perm_rpath $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" if test -n "$hardcode_libdir_flag_spec_ld"; then case $archive_cmds in *\$LD*) eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" ;; *) eval dep_rpath=\"$hardcode_libdir_flag_spec\" ;; esac else eval dep_rpath=\"$hardcode_libdir_flag_spec\" fi fi if test -n "$runpath_var" && test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do rpath="$rpath$dir:" done eval "$runpath_var='$rpath\$$runpath_var'; export $runpath_var" fi test -n "$dep_rpath" && deplibs="$dep_rpath $deplibs" fi shlibpath="$finalize_shlibpath" test "$mode" != relink && shlibpath="$compile_shlibpath$shlibpath" if test -n "$shlibpath"; then eval "$shlibpath_var='$shlibpath\$$shlibpath_var'; export $shlibpath_var" fi # Get the real and link names of the library. eval shared_ext=\"$shrext_cmds\" eval library_names=\"$library_names_spec\" set dummy $library_names realname="$2" shift; shift if test -n "$soname_spec"; then eval soname=\"$soname_spec\" else soname="$realname" fi if test -z "$dlname"; then dlname=$soname fi lib="$output_objdir/$realname" linknames= for link do linknames="$linknames $link" done # Use standard objects if they are pic test -z "$pic_flag" && libobjs=`$echo "X$libobjs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` # Prepare the list of exported symbols if test -z "$export_symbols"; then if test "$always_export_symbols" = yes || test -n "$export_symbols_regex"; then $show "generating symbol list for \`$libname.la'" export_symbols="$output_objdir/$libname.exp" $run $rm $export_symbols cmds=$export_symbols_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" if len=`expr "X$cmd" : ".*"` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then $show "$cmd" $run eval "$cmd" || exit $? skipped_export=false else # The command line is too long to execute in one step. $show "using reloadable object file for export list..." skipped_export=: # Break out early, otherwise skipped_export may be # set to false by a later but shorter cmd. break fi done IFS="$save_ifs" if test -n "$export_symbols_regex"; then $show "$EGREP -e \"$export_symbols_regex\" \"$export_symbols\" > \"${export_symbols}T\"" $run eval '$EGREP -e "$export_symbols_regex" "$export_symbols" > "${export_symbols}T"' $show "$mv \"${export_symbols}T\" \"$export_symbols\"" $run eval '$mv "${export_symbols}T" "$export_symbols"' fi fi fi if test -n "$export_symbols" && test -n "$include_expsyms"; then $run eval '$echo "X$include_expsyms" | $SP2NL >> "$export_symbols"' fi tmp_deplibs= for test_deplib in $deplibs; do case " $convenience " in *" $test_deplib "*) ;; *) tmp_deplibs="$tmp_deplibs $test_deplib" ;; esac done deplibs="$tmp_deplibs" if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then save_libobjs=$libobjs eval libobjs=\"\$libobjs $whole_archive_flag_spec\" else gentop="$output_objdir/${outputname}x" generated="$generated $gentop" func_extract_archives $gentop $convenience libobjs="$libobjs $func_extract_archives_result" fi fi if test "$thread_safe" = yes && test -n "$thread_safe_flag_spec"; then eval flag=\"$thread_safe_flag_spec\" linker_flags="$linker_flags $flag" fi # Make a backup of the uninstalled library when relinking if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}U && $mv $realname ${realname}U)' || exit $? fi # Do each of the archive commands. if test "$module" = yes && test -n "$module_cmds" ; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then eval test_cmds=\"$module_expsym_cmds\" cmds=$module_expsym_cmds else eval test_cmds=\"$module_cmds\" cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then eval test_cmds=\"$archive_expsym_cmds\" cmds=$archive_expsym_cmds else eval test_cmds=\"$archive_cmds\" cmds=$archive_cmds fi fi if test "X$skipped_export" != "X:" && len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then : else # The command line is too long to link in one step, link piecewise. $echo "creating reloadable object files..." # Save the value of $output and $libobjs because we want to # use them later. If we have whole_archive_flag_spec, we # want to use save_libobjs as it was before # whole_archive_flag_spec was expanded, because we can't # assume the linker understands whole_archive_flag_spec. # This may have to be revisited, in case too many # convenience libraries get linked in and end up exceeding # the spec. if test -z "$convenience" || test -z "$whole_archive_flag_spec"; then save_libobjs=$libobjs fi save_output=$output output_la=`$echo "X$output" | $Xsed -e "$basename"` # Clear the reloadable object creation command queue and # initialize k to one. test_cmds= concat_cmds= objlist= delfiles= last_robj= k=1 output=$output_objdir/$output_la-${k}.$objext # Loop over the list of objects to be linked. for obj in $save_libobjs do eval test_cmds=\"$reload_cmds $objlist $last_robj\" if test "X$objlist" = X || { len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len"; }; then objlist="$objlist $obj" else # The command $test_cmds is almost too long, add a # command to the queue. if test "$k" -eq 1 ; then # The first file doesn't have a previous command to add. eval concat_cmds=\"$reload_cmds $objlist $last_robj\" else # All subsequent reloadable object files will link in # the last one created. eval concat_cmds=\"\$concat_cmds~$reload_cmds $objlist $last_robj\" fi last_robj=$output_objdir/$output_la-${k}.$objext k=`expr $k + 1` output=$output_objdir/$output_la-${k}.$objext objlist=$obj len=1 fi done # Handle the remaining objects by creating one last # reloadable object file. All subsequent reloadable object # files will link in the last one created. test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\${concat_cmds}$reload_cmds $objlist $last_robj\" if ${skipped_export-false}; then $show "generating symbol list for \`$libname.la'" export_symbols="$output_objdir/$libname.exp" $run $rm $export_symbols libobjs=$output # Append the command to create the export file. eval concat_cmds=\"\$concat_cmds~$export_symbols_cmds\" fi # Set up a command to remove the reloadable object files # after they are used. i=0 while test "$i" -lt "$k" do i=`expr $i + 1` delfiles="$delfiles $output_objdir/$output_la-${i}.$objext" done $echo "creating a temporary reloadable object file: $output" # Loop through the commands generated above and execute them. save_ifs="$IFS"; IFS='~' for cmd in $concat_cmds; do IFS="$save_ifs" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" libobjs=$output # Restore the value of output. output=$save_output if test -n "$convenience" && test -n "$whole_archive_flag_spec"; then eval libobjs=\"\$libobjs $whole_archive_flag_spec\" fi # Expand the library linking commands again to reset the # value of $libobjs for piecewise linking. # Do each of the archive commands. if test "$module" = yes && test -n "$module_cmds" ; then if test -n "$export_symbols" && test -n "$module_expsym_cmds"; then cmds=$module_expsym_cmds else cmds=$module_cmds fi else if test -n "$export_symbols" && test -n "$archive_expsym_cmds"; then cmds=$archive_expsym_cmds else cmds=$archive_cmds fi fi # Append the command to remove the reloadable object files # to the just-reset $cmds. eval cmds=\"\$cmds~\$rm $delfiles\" fi save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' fi exit $lt_exit } done IFS="$save_ifs" # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv $realname ${realname}T && $mv "$realname"U $realname)' || exit $? if test -n "$convenience"; then if test -z "$whole_archive_flag_spec"; then $show "${rm}r $gentop" $run ${rm}r "$gentop" fi fi exit $EXIT_SUCCESS fi # Create links to the real library. for linkname in $linknames; do if test "$realname" != "$linkname"; then $show "(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)" $run eval '(cd $output_objdir && $rm $linkname && $LN_S $realname $linkname)' || exit $? fi done # If -module or -export-dynamic was specified, set the dlname. if test "$module" = yes || test "$export_dynamic" = yes; then # On all known operating systems, these are identical. dlname="$soname" fi fi ;; obj) case " $deplibs" in *\ -l* | *\ -L*) $echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2 ;; esac if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then $echo "$modename: warning: \`-dlopen' is ignored for objects" 1>&2 fi if test -n "$rpath"; then $echo "$modename: warning: \`-rpath' is ignored for objects" 1>&2 fi if test -n "$xrpath"; then $echo "$modename: warning: \`-R' is ignored for objects" 1>&2 fi if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info' is ignored for objects" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for objects" 1>&2 fi case $output in *.lo) if test -n "$objs$old_deplibs"; then $echo "$modename: cannot build library object \`$output' from non-libtool objects" 1>&2 exit $EXIT_FAILURE fi libobj="$output" obj=`$echo "X$output" | $Xsed -e "$lo2o"` ;; *) libobj= obj="$output" ;; esac # Delete the old objects. $run $rm $obj $libobj # Objects from convenience libraries. This assumes # single-version convenience libraries. Whenever we create # different ones for PIC/non-PIC, this we'll have to duplicate # the extraction. reload_conv_objs= gentop= # reload_cmds runs $LD directly, so let us get rid of # -Wl from whole_archive_flag_spec and hope we can get by with # turning comma into space.. wl= if test -n "$convenience"; then if test -n "$whole_archive_flag_spec"; then eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\" reload_conv_objs=$reload_objs\ `$echo "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'` else gentop="$output_objdir/${obj}x" generated="$generated $gentop" func_extract_archives $gentop $convenience reload_conv_objs="$reload_objs $func_extract_archives_result" fi fi # Create the old-style object. reload_objs="$objs$old_deplibs "`$echo "X$libobjs" | $SP2NL | $Xsed -e '/\.'${libext}$'/d' -e '/\.lib$/d' -e "$lo2o" | $NL2SP`" $reload_conv_objs" ### testsuite: skip nested quoting test output="$obj" cmds=$reload_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" # Exit if we aren't doing a library object file. if test -z "$libobj"; then if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi exit $EXIT_SUCCESS fi if test "$build_libtool_libs" != yes; then if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi # Create an invalid libtool object if no PIC, so that we don't # accidentally link it into a program. # $show "echo timestamp > $libobj" # $run eval "echo timestamp > $libobj" || exit $? exit $EXIT_SUCCESS fi if test -n "$pic_flag" || test "$pic_mode" != default; then # Only do commands if we really have different PIC objects. reload_objs="$libobjs $reload_conv_objs" output="$libobj" cmds=$reload_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" fi if test -n "$gentop"; then $show "${rm}r $gentop" $run ${rm}r $gentop fi exit $EXIT_SUCCESS ;; prog) case $host in *cygwin*) output=`$echo $output | ${SED} -e 's,.exe$,,;s,$,.exe,'` ;; esac if test -n "$vinfo"; then $echo "$modename: warning: \`-version-info' is ignored for programs" 1>&2 fi if test -n "$release"; then $echo "$modename: warning: \`-release' is ignored for programs" 1>&2 fi if test "$preload" = yes; then if test "$dlopen_support" = unknown && test "$dlopen_self" = unknown && test "$dlopen_self_static" = unknown; then $echo "$modename: warning: \`AC_LIBTOOL_DLOPEN' not used. Assuming no dlopen support." fi fi case $host in *-*-rhapsody* | *-*-darwin1.[012]) # On Rhapsody replace the C library is the System framework compile_deplibs=`$echo "X $compile_deplibs" | $Xsed -e 's/ -lc / -framework System /'` finalize_deplibs=`$echo "X $finalize_deplibs" | $Xsed -e 's/ -lc / -framework System /'` ;; esac case $host in *darwin*) # Don't allow lazy linking, it breaks C++ global constructors if test "$tagname" = CXX ; then compile_command="$compile_command ${wl}-bind_at_load" finalize_command="$finalize_command ${wl}-bind_at_load" fi ;; esac # move library search paths that coincide with paths to not yet # installed libraries to the beginning of the library search list new_libs= for path in $notinst_path; do case " $new_libs " in *" -L$path/$objdir "*) ;; *) case " $compile_deplibs " in *" -L$path/$objdir "*) new_libs="$new_libs -L$path/$objdir" ;; esac ;; esac done for deplib in $compile_deplibs; do case $deplib in -L*) case " $new_libs " in *" $deplib "*) ;; *) new_libs="$new_libs $deplib" ;; esac ;; *) new_libs="$new_libs $deplib" ;; esac done compile_deplibs="$new_libs" compile_command="$compile_command $compile_deplibs" finalize_command="$finalize_command $finalize_deplibs" if test -n "$rpath$xrpath"; then # If the user specified any rpath flags, then add them. for libdir in $rpath $xrpath; do # This is the magic to use -rpath. case "$finalize_rpath " in *" $libdir "*) ;; *) finalize_rpath="$finalize_rpath $libdir" ;; esac done fi # Now hardcode the library paths rpath= hardcode_libdirs= for libdir in $compile_rpath $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" rpath="$rpath $flag" fi elif test -n "$runpath_var"; then case "$perm_rpath " in *" $libdir "*) ;; *) perm_rpath="$perm_rpath $libdir" ;; esac fi case $host in *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*) testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'` case :$dllsearchpath: in *":$libdir:"*) ;; *) dllsearchpath="$dllsearchpath:$libdir";; esac case :$dllsearchpath: in *":$testbindir:"*) ;; *) dllsearchpath="$dllsearchpath:$testbindir";; esac ;; esac done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" eval rpath=\" $hardcode_libdir_flag_spec\" fi compile_rpath="$rpath" rpath= hardcode_libdirs= for libdir in $finalize_rpath; do if test -n "$hardcode_libdir_flag_spec"; then if test -n "$hardcode_libdir_separator"; then if test -z "$hardcode_libdirs"; then hardcode_libdirs="$libdir" else # Just accumulate the unique libdirs. case $hardcode_libdir_separator$hardcode_libdirs$hardcode_libdir_separator in *"$hardcode_libdir_separator$libdir$hardcode_libdir_separator"*) ;; *) hardcode_libdirs="$hardcode_libdirs$hardcode_libdir_separator$libdir" ;; esac fi else eval flag=\"$hardcode_libdir_flag_spec\" rpath="$rpath $flag" fi elif test -n "$runpath_var"; then case "$finalize_perm_rpath " in *" $libdir "*) ;; *) finalize_perm_rpath="$finalize_perm_rpath $libdir" ;; esac fi done # Substitute the hardcoded libdirs into the rpath. if test -n "$hardcode_libdir_separator" && test -n "$hardcode_libdirs"; then libdir="$hardcode_libdirs" eval rpath=\" $hardcode_libdir_flag_spec\" fi finalize_rpath="$rpath" if test -n "$libobjs" && test "$build_old_libs" = yes; then # Transform all the library objects into standard objects. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` fi dlsyms= if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then if test -n "$NM" && test -n "$global_symbol_pipe"; then dlsyms="${outputname}S.c" else $echo "$modename: not configured to extract global symbols from dlpreopened files" 1>&2 fi fi if test -n "$dlsyms"; then case $dlsyms in "") ;; *.c) # Discover the nlist of each of the dlfiles. nlist="$output_objdir/${outputname}.nm" $show "$rm $nlist ${nlist}S ${nlist}T" $run $rm "$nlist" "${nlist}S" "${nlist}T" # Parse the name list into a source file. $show "creating $output_objdir/$dlsyms" test -z "$run" && $echo > "$output_objdir/$dlsyms" "\ /* $dlsyms - symbol resolution table for \`$outputname' dlsym emulation. */ /* Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP */ #ifdef __cplusplus extern \"C\" { #endif /* Prevent the only kind of declaration conflicts we can make. */ #define lt_preloaded_symbols some_other_symbol /* External symbol declarations for the compiler. */\ " if test "$dlself" = yes; then $show "generating symbol list for \`$output'" test -z "$run" && $echo ': @PROGRAM@ ' > "$nlist" # Add our own program objects to the symbol list. progfiles=`$echo "X$objs$old_deplibs" | $SP2NL | $Xsed -e "$lo2o" | $NL2SP` for arg in $progfiles; do $show "extracting global C symbols from \`$arg'" $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" done if test -n "$exclude_expsyms"; then $run eval '$EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi if test -n "$export_symbols_regex"; then $run eval '$EGREP -e "$export_symbols_regex" "$nlist" > "$nlist"T' $run eval '$mv "$nlist"T "$nlist"' fi # Prepare the list of exported symbols if test -z "$export_symbols"; then export_symbols="$output_objdir/$outputname.exp" $run $rm $export_symbols $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"' case $host in *cygwin* | *mingw* ) $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' $run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"' ;; esac else $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"' $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T' $run eval 'mv "$nlist"T "$nlist"' case $host in *cygwin* | *mingw* ) $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"' $run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"' ;; esac fi fi for arg in $dlprefiles; do $show "extracting global C symbols from \`$arg'" name=`$echo "$arg" | ${SED} -e 's%^.*/%%'` $run eval '$echo ": $name " >> "$nlist"' $run eval "$NM $arg | $global_symbol_pipe >> '$nlist'" done if test -z "$run"; then # Make sure we have at least an empty file. test -f "$nlist" || : > "$nlist" if test -n "$exclude_expsyms"; then $EGREP -v " ($exclude_expsyms)$" "$nlist" > "$nlist"T $mv "$nlist"T "$nlist" fi # Try sorting and uniquifying the output. if grep -v "^: " < "$nlist" | if sort -k 3 /dev/null 2>&1; then sort -k 3 else sort +2 fi | uniq > "$nlist"S; then : else grep -v "^: " < "$nlist" > "$nlist"S fi if test -f "$nlist"S; then eval "$global_symbol_to_cdecl"' < "$nlist"S >> "$output_objdir/$dlsyms"' else $echo '/* NONE */' >> "$output_objdir/$dlsyms" fi $echo >> "$output_objdir/$dlsyms" "\ #undef lt_preloaded_symbols #if defined (__STDC__) && __STDC__ # define lt_ptr void * #else # define lt_ptr char * # define const #endif /* The mapping between symbol names and symbols. */ " case $host in *cygwin* | *mingw* ) $echo >> "$output_objdir/$dlsyms" "\ /* DATA imports from DLLs on WIN32 can't be const, because runtime relocations are performed -- see ld's documentation on pseudo-relocs */ struct { " ;; * ) $echo >> "$output_objdir/$dlsyms" "\ const struct { " ;; esac $echo >> "$output_objdir/$dlsyms" "\ const char *name; lt_ptr address; } lt_preloaded_symbols[] = {\ " eval "$global_symbol_to_c_name_address" < "$nlist" >> "$output_objdir/$dlsyms" $echo >> "$output_objdir/$dlsyms" "\ {0, (lt_ptr) 0} }; /* This works around a problem in FreeBSD linker */ #ifdef FREEBSD_WORKAROUND static const void *lt_preloaded_setup() { return lt_preloaded_symbols; } #endif #ifdef __cplusplus } #endif\ " fi pic_flag_for_symtable= case $host in # compiling the symbol table file with pic_flag works around # a FreeBSD bug that causes programs to crash when -lm is # linked before any other PIC object. But we must not use # pic_flag when linking with -static. The problem exists in # FreeBSD 2.2.6 and is fixed in FreeBSD 3.1. *-*-freebsd2*|*-*-freebsd3.0*|*-*-freebsdelf3.0*) case "$compile_command " in *" -static "*) ;; *) pic_flag_for_symtable=" $pic_flag -DFREEBSD_WORKAROUND";; esac;; *-*-hpux*) case "$compile_command " in *" -static "*) ;; *) pic_flag_for_symtable=" $pic_flag";; esac esac # Now compile the dynamic symbol file. $show "(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")" $run eval '(cd $output_objdir && $LTCC $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $? # Clean up the generated files. $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T" $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T" # Transform the symbol file into the correct name. case $host in *cygwin* | *mingw* ) if test -f "$output_objdir/${outputname}.def" ; then compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP` else compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` fi ;; * ) compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP` ;; esac ;; *) $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2 exit $EXIT_FAILURE ;; esac else # We keep going just in case the user didn't refer to # lt_preloaded_symbols. The linker will fail if global_symbol_pipe # really was required. # Nullify the symbol file. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP` fi if test "$need_relink" = no || test "$build_libtool_libs" != yes; then # Replace the output file specification. compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$output"'%g' | $NL2SP` link_command="$compile_command$compile_rpath" # We have no uninstalled library dependencies, so finalize right now. $show "$link_command" $run eval "$link_command" exit_status=$? # Delete the generated files. if test -n "$dlsyms"; then $show "$rm $output_objdir/${outputname}S.${objext}" $run $rm "$output_objdir/${outputname}S.${objext}" fi exit $exit_status fi if test -n "$shlibpath_var"; then # We should set the shlibpath_var rpath= for dir in $temp_rpath; do case $dir in [\\/]* | [A-Za-z]:[\\/]*) # Absolute path. rpath="$rpath$dir:" ;; *) # Relative path: add a thisdir entry. rpath="$rpath\$thisdir/$dir:" ;; esac done temp_rpath="$rpath" fi if test -n "$compile_shlibpath$finalize_shlibpath"; then compile_command="$shlibpath_var=\"$compile_shlibpath$finalize_shlibpath\$$shlibpath_var\" $compile_command" fi if test -n "$finalize_shlibpath"; then finalize_command="$shlibpath_var=\"$finalize_shlibpath\$$shlibpath_var\" $finalize_command" fi compile_var= finalize_var= if test -n "$runpath_var"; then if test -n "$perm_rpath"; then # We should set the runpath_var. rpath= for dir in $perm_rpath; do rpath="$rpath$dir:" done compile_var="$runpath_var=\"$rpath\$$runpath_var\" " fi if test -n "$finalize_perm_rpath"; then # We should set the runpath_var. rpath= for dir in $finalize_perm_rpath; do rpath="$rpath$dir:" done finalize_var="$runpath_var=\"$rpath\$$runpath_var\" " fi fi if test "$no_install" = yes; then # We don't need to create a wrapper script. link_command="$compile_var$compile_command$compile_rpath" # Replace the output file specification. link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'` # Delete the old output file. $run $rm $output # Link the executable and exit $show "$link_command" $run eval "$link_command" || exit $? exit $EXIT_SUCCESS fi if test "$hardcode_action" = relink; then # Fast installation is not supported link_command="$compile_var$compile_command$compile_rpath" relink_command="$finalize_var$finalize_command$finalize_rpath" $echo "$modename: warning: this platform does not like uninstalled shared libraries" 1>&2 $echo "$modename: \`$output' will be relinked during installation" 1>&2 else if test "$fast_install" != no; then link_command="$finalize_var$compile_command$finalize_rpath" if test "$fast_install" = yes; then relink_command=`$echo "X$compile_var$compile_command$compile_rpath" | $SP2NL | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g' | $NL2SP` else # fast_install is set to needless relink_command= fi else link_command="$compile_var$compile_command$compile_rpath" relink_command="$finalize_var$finalize_command$finalize_rpath" fi fi # Replace the output file specification. link_command=`$echo "X$link_command" | $Xsed -e 's%@OUTPUT@%'"$output_objdir/$outputname"'%g'` # Delete the old output files. $run $rm $output $output_objdir/$outputname $output_objdir/lt-$outputname $show "$link_command" $run eval "$link_command" || exit $? # Now create the wrapper script. $show "creating $output" # Quote the relink command for shipping. if test -n "$relink_command"; then # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` relink_command="$var=\"$var_value\"; export $var; $relink_command" fi done relink_command="(cd `pwd`; $relink_command)" relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` fi # Quote $echo for shipping. if test "X$echo" = "X$SHELL $progpath --fallback-echo"; then case $progpath in [\\/]* | [A-Za-z]:[\\/]*) qecho="$SHELL $progpath --fallback-echo";; *) qecho="$SHELL `pwd`/$progpath --fallback-echo";; esac qecho=`$echo "X$qecho" | $Xsed -e "$sed_quote_subst"` else qecho=`$echo "X$echo" | $Xsed -e "$sed_quote_subst"` fi # Only actually do things if our run command is non-null. if test -z "$run"; then # win32 will think the script is a binary if it has # a .exe suffix, so we strip it off here. case $output in *.exe) output=`$echo $output|${SED} 's,.exe$,,'` ;; esac # test for cygwin because mv fails w/o .exe extensions case $host in *cygwin*) exeext=.exe outputname=`$echo $outputname|${SED} 's,.exe$,,'` ;; *) exeext= ;; esac case $host in *cygwin* | *mingw* ) output_name=`basename $output` output_path=`dirname $output` cwrappersource="$output_path/$objdir/lt-$output_name.c" cwrapper="$output_path/$output_name.exe" $rm $cwrappersource $cwrapper trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15 cat > $cwrappersource <> $cwrappersource<<"EOF" #include #include #include #include #include #include #include #include #include #if defined(PATH_MAX) # define LT_PATHMAX PATH_MAX #elif defined(MAXPATHLEN) # define LT_PATHMAX MAXPATHLEN #else # define LT_PATHMAX 1024 #endif #ifndef DIR_SEPARATOR # define DIR_SEPARATOR '/' # define PATH_SEPARATOR ':' #endif #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \ defined (__OS2__) # define HAVE_DOS_BASED_FILE_SYSTEM # ifndef DIR_SEPARATOR_2 # define DIR_SEPARATOR_2 '\\' # endif # ifndef PATH_SEPARATOR_2 # define PATH_SEPARATOR_2 ';' # endif #endif #ifndef DIR_SEPARATOR_2 # define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR) #else /* DIR_SEPARATOR_2 */ # define IS_DIR_SEPARATOR(ch) \ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2)) #endif /* DIR_SEPARATOR_2 */ #ifndef PATH_SEPARATOR_2 # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR) #else /* PATH_SEPARATOR_2 */ # define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2) #endif /* PATH_SEPARATOR_2 */ #define XMALLOC(type, num) ((type *) xmalloc ((num) * sizeof(type))) #define XFREE(stale) do { \ if (stale) { free ((void *) stale); stale = 0; } \ } while (0) /* -DDEBUG is fairly common in CFLAGS. */ #undef DEBUG #if defined DEBUGWRAPPER # define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__) #else # define DEBUG(format, ...) #endif const char *program_name = NULL; void * xmalloc (size_t num); char * xstrdup (const char *string); const char * base_name (const char *name); char * find_executable(const char *wrapper); int check_executable(const char *path); char * strendzap(char *str, const char *pat); void lt_fatal (const char *message, ...); int main (int argc, char *argv[]) { char **newargz; int i; program_name = (char *) xstrdup (base_name (argv[0])); DEBUG("(main) argv[0] : %s\n",argv[0]); DEBUG("(main) program_name : %s\n",program_name); newargz = XMALLOC(char *, argc+2); EOF cat >> $cwrappersource <> $cwrappersource <<"EOF" newargz[1] = find_executable(argv[0]); if (newargz[1] == NULL) lt_fatal("Couldn't find %s", argv[0]); DEBUG("(main) found exe at : %s\n",newargz[1]); /* we know the script has the same name, without the .exe */ /* so make sure newargz[1] doesn't end in .exe */ strendzap(newargz[1],".exe"); for (i = 1; i < argc; i++) newargz[i+1] = xstrdup(argv[i]); newargz[argc+1] = NULL; for (i=0; i> $cwrappersource <> $cwrappersource <> $cwrappersource <<"EOF" return 127; } void * xmalloc (size_t num) { void * p = (void *) malloc (num); if (!p) lt_fatal ("Memory exhausted"); return p; } char * xstrdup (const char *string) { return string ? strcpy ((char *) xmalloc (strlen (string) + 1), string) : NULL ; } const char * base_name (const char *name) { const char *base; #if defined (HAVE_DOS_BASED_FILE_SYSTEM) /* Skip over the disk name in MSDOS pathnames. */ if (isalpha ((unsigned char)name[0]) && name[1] == ':') name += 2; #endif for (base = name; *name; name++) if (IS_DIR_SEPARATOR (*name)) base = name + 1; return base; } int check_executable(const char * path) { struct stat st; DEBUG("(check_executable) : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!"); if ((!path) || (!*path)) return 0; if ((stat (path, &st) >= 0) && ( /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */ #if defined (S_IXOTH) ((st.st_mode & S_IXOTH) == S_IXOTH) || #endif #if defined (S_IXGRP) ((st.st_mode & S_IXGRP) == S_IXGRP) || #endif ((st.st_mode & S_IXUSR) == S_IXUSR)) ) return 1; else return 0; } /* Searches for the full path of the wrapper. Returns newly allocated full path name if found, NULL otherwise */ char * find_executable (const char* wrapper) { int has_slash = 0; const char* p; const char* p_next; /* static buffer for getcwd */ char tmp[LT_PATHMAX + 1]; int tmp_len; char* concat_name; DEBUG("(find_executable) : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!"); if ((wrapper == NULL) || (*wrapper == '\0')) return NULL; /* Absolute path? */ #if defined (HAVE_DOS_BASED_FILE_SYSTEM) if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':') { concat_name = xstrdup (wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } else { #endif if (IS_DIR_SEPARATOR (wrapper[0])) { concat_name = xstrdup (wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } #if defined (HAVE_DOS_BASED_FILE_SYSTEM) } #endif for (p = wrapper; *p; p++) if (*p == '/') { has_slash = 1; break; } if (!has_slash) { /* no slashes; search PATH */ const char* path = getenv ("PATH"); if (path != NULL) { for (p = path; *p; p = p_next) { const char* q; size_t p_len; for (q = p; *q; q++) if (IS_PATH_SEPARATOR(*q)) break; p_len = q - p; p_next = (*q == '\0' ? q : q + 1); if (p_len == 0) { /* empty path: current directory */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); tmp_len = strlen(tmp); concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); } else { concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, p, p_len); concat_name[p_len] = '/'; strcpy (concat_name + p_len + 1, wrapper); } if (check_executable(concat_name)) return concat_name; XFREE(concat_name); } } /* not found in PATH; assume curdir */ } /* Relative path | not found in path: prepend cwd */ if (getcwd (tmp, LT_PATHMAX) == NULL) lt_fatal ("getcwd failed"); tmp_len = strlen(tmp); concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1); memcpy (concat_name, tmp, tmp_len); concat_name[tmp_len] = '/'; strcpy (concat_name + tmp_len + 1, wrapper); if (check_executable(concat_name)) return concat_name; XFREE(concat_name); return NULL; } char * strendzap(char *str, const char *pat) { size_t len, patlen; assert(str != NULL); assert(pat != NULL); len = strlen(str); patlen = strlen(pat); if (patlen <= len) { str += len - patlen; if (strcmp(str, pat) == 0) *str = '\0'; } return str; } static void lt_error_core (int exit_status, const char * mode, const char * message, va_list ap) { fprintf (stderr, "%s: %s: ", program_name, mode); vfprintf (stderr, message, ap); fprintf (stderr, ".\n"); if (exit_status >= 0) exit (exit_status); } void lt_fatal (const char *message, ...) { va_list ap; va_start (ap, message); lt_error_core (EXIT_FAILURE, "FATAL", message, ap); va_end (ap); } EOF # we should really use a build-platform specific compiler # here, but OTOH, the wrappers (shell script and this C one) # are only useful if you want to execute the "real" binary. # Since the "real" binary is built for $host, then this # wrapper might as well be built for $host, too. $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource ;; esac $rm $output trap "$rm $output; exit $EXIT_FAILURE" 1 2 15 $echo > $output "\ #! $SHELL # $output - temporary wrapper script for $objdir/$outputname # Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP # # The $output program cannot be directly executed until all the libtool # libraries that it depends on are installed. # # This wrapper script should never be moved out of the build directory. # If it is, it will not operate correctly. # Sed substitution that helps us do robust quoting. It backslashifies # metacharacters that are still active within double-quoted strings. Xsed='${SED} -e 1s/^X//' sed_quote_subst='$sed_quote_subst' # Be Bourne compatible (taken from Autoconf:_AS_BOURNE_COMPATIBLE). if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then emulate sh NULLCMD=: # Zsh 3.x and 4.x performs word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in *posix*) set -o posix;; esac fi BIN_SH=xpg4; export BIN_SH # for Tru64 DUALCASE=1; export DUALCASE # for MKS sh # The HP-UX ksh and POSIX shell print the target directory to stdout # if CDPATH is set. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH relink_command=\"$relink_command\" # This environment variable determines our operation mode. if test \"\$libtool_install_magic\" = \"$magic\"; then # install mode needs the following variable: notinst_deplibs='$notinst_deplibs' else # When we are sourced in execute mode, \$file and \$echo are already set. if test \"\$libtool_execute_magic\" != \"$magic\"; then echo=\"$qecho\" file=\"\$0\" # Make sure echo works. if test \"X\$1\" = X--no-reexec; then # Discard the --no-reexec flag, and continue. shift elif test \"X\`(\$echo '\t') 2>/dev/null\`\" = 'X\t'; then # Yippee, \$echo works! : else # Restart under the correct shell, and then maybe \$echo will work. exec $SHELL \"\$0\" --no-reexec \${1+\"\$@\"} fi fi\ " $echo >> $output "\ # Find the directory that this script lives in. thisdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*$%%'\` test \"x\$thisdir\" = \"x\$file\" && thisdir=. # Follow symbolic links until we get to the real thisdir. file=\`ls -ld \"\$file\" | ${SED} -n 's/.*-> //p'\` while test -n \"\$file\"; do destdir=\`\$echo \"X\$file\" | \$Xsed -e 's%/[^/]*\$%%'\` # If there was a directory component, then change thisdir. if test \"x\$destdir\" != \"x\$file\"; then case \"\$destdir\" in [\\\\/]* | [A-Za-z]:[\\\\/]*) thisdir=\"\$destdir\" ;; *) thisdir=\"\$thisdir/\$destdir\" ;; esac fi file=\`\$echo \"X\$file\" | \$Xsed -e 's%^.*/%%'\` file=\`ls -ld \"\$thisdir/\$file\" | ${SED} -n 's/.*-> //p'\` done # Try to get the absolute directory name. absdir=\`cd \"\$thisdir\" && pwd\` test -n \"\$absdir\" && thisdir=\"\$absdir\" " if test "$fast_install" = yes; then $echo >> $output "\ program=lt-'$outputname'$exeext progdir=\"\$thisdir/$objdir\" if test ! -f \"\$progdir/\$program\" || \\ { file=\`ls -1dt \"\$progdir/\$program\" \"\$progdir/../\$program\" 2>/dev/null | ${SED} 1q\`; \\ test \"X\$file\" != \"X\$progdir/\$program\"; }; then file=\"\$\$-\$program\" if test ! -d \"\$progdir\"; then $mkdir \"\$progdir\" else $rm \"\$progdir/\$file\" fi" $echo >> $output "\ # relink executable if necessary if test -n \"\$relink_command\"; then if relink_command_output=\`eval \$relink_command 2>&1\`; then : else $echo \"\$relink_command_output\" >&2 $rm \"\$progdir/\$file\" exit $EXIT_FAILURE fi fi $mv \"\$progdir/\$file\" \"\$progdir/\$program\" 2>/dev/null || { $rm \"\$progdir/\$program\"; $mv \"\$progdir/\$file\" \"\$progdir/\$program\"; } $rm \"\$progdir/\$file\" fi" else $echo >> $output "\ program='$outputname' progdir=\"\$thisdir/$objdir\" " fi $echo >> $output "\ if test -f \"\$progdir/\$program\"; then" # Export our shlibpath_var if we have one. if test "$shlibpath_overrides_runpath" = yes && test -n "$shlibpath_var" && test -n "$temp_rpath"; then $echo >> $output "\ # Add our own library path to $shlibpath_var $shlibpath_var=\"$temp_rpath\$$shlibpath_var\" # Some systems cannot cope with colon-terminated $shlibpath_var # The second colon is a workaround for a bug in BeOS R4 sed $shlibpath_var=\`\$echo \"X\$$shlibpath_var\" | \$Xsed -e 's/::*\$//'\` export $shlibpath_var " fi # fixup the dll searchpath if we need to. if test -n "$dllsearchpath"; then $echo >> $output "\ # Add the dll search path components to the executable PATH PATH=$dllsearchpath:\$PATH " fi $echo >> $output "\ if test \"\$libtool_execute_magic\" != \"$magic\"; then # Run the actual program with our arguments. " case $host in # Backslashes separate directories on plain windows *-*-mingw | *-*-os2*) $echo >> $output "\ exec \"\$progdir\\\\\$program\" \${1+\"\$@\"} " ;; *) $echo >> $output "\ exec \"\$progdir/\$program\" \${1+\"\$@\"} " ;; esac $echo >> $output "\ \$echo \"\$0: cannot exec \$program \$*\" exit $EXIT_FAILURE fi else # The program doesn't exist. \$echo \"\$0: error: \\\`\$progdir/\$program' does not exist\" 1>&2 \$echo \"This script is just a wrapper for \$program.\" 1>&2 $echo \"See the $PACKAGE documentation for more information.\" 1>&2 exit $EXIT_FAILURE fi fi\ " chmod +x $output fi exit $EXIT_SUCCESS ;; esac # See if we need to build an old-fashioned archive. for oldlib in $oldlibs; do if test "$build_libtool_libs" = convenience; then oldobjs="$libobjs_save" addlibs="$convenience" build_libtool_libs=no else if test "$build_libtool_libs" = module; then oldobjs="$libobjs_save" build_libtool_libs=no else oldobjs="$old_deplibs $non_pic_objects" fi addlibs="$old_convenience" fi if test -n "$addlibs"; then gentop="$output_objdir/${outputname}x" generated="$generated $gentop" func_extract_archives $gentop $addlibs oldobjs="$oldobjs $func_extract_archives_result" fi # Do each command in the archive commands. if test -n "$old_archive_from_new_cmds" && test "$build_libtool_libs" = yes; then cmds=$old_archive_from_new_cmds else # POSIX demands no paths to be encoded in archives. We have # to avoid creating archives with duplicate basenames if we # might have to extract them afterwards, e.g., when creating a # static archive out of a convenience library, or when linking # the entirety of a libtool archive into another (currently # not supported by libtool). if (for obj in $oldobjs do $echo "X$obj" | $Xsed -e 's%^.*/%%' done | sort | sort -uc >/dev/null 2>&1); then : else $echo "copying selected object files to avoid basename conflicts..." if test -z "$gentop"; then gentop="$output_objdir/${outputname}x" generated="$generated $gentop" $show "${rm}r $gentop" $run ${rm}r "$gentop" $show "$mkdir $gentop" $run $mkdir "$gentop" exit_status=$? if test "$exit_status" -ne 0 && test ! -d "$gentop"; then exit $exit_status fi fi save_oldobjs=$oldobjs oldobjs= counter=1 for obj in $save_oldobjs do objbase=`$echo "X$obj" | $Xsed -e 's%^.*/%%'` case " $oldobjs " in " ") oldobjs=$obj ;; *[\ /]"$objbase "*) while :; do # Make sure we don't pick an alternate name that also # overlaps. newobj=lt$counter-$objbase counter=`expr $counter + 1` case " $oldobjs " in *[\ /]"$newobj "*) ;; *) if test ! -f "$gentop/$newobj"; then break; fi ;; esac done $show "ln $obj $gentop/$newobj || cp $obj $gentop/$newobj" $run ln "$obj" "$gentop/$newobj" || $run cp "$obj" "$gentop/$newobj" oldobjs="$oldobjs $gentop/$newobj" ;; *) oldobjs="$oldobjs $obj" ;; esac done fi eval cmds=\"$old_archive_cmds\" if len=`expr "X$cmds" : ".*"` && test "$len" -le "$max_cmd_len" || test "$max_cmd_len" -le -1; then cmds=$old_archive_cmds else # the command line is too long to link in one step, link in parts $echo "using piecewise archive linking..." save_RANLIB=$RANLIB RANLIB=: objlist= concat_cmds= save_oldobjs=$oldobjs # Is there a better way of finding the last object in the list? for obj in $save_oldobjs do last_oldobj=$obj done for obj in $save_oldobjs do oldobjs="$objlist $obj" objlist="$objlist $obj" eval test_cmds=\"$old_archive_cmds\" if len=`expr "X$test_cmds" : ".*" 2>/dev/null` && test "$len" -le "$max_cmd_len"; then : else # the above command should be used before it gets too long oldobjs=$objlist if test "$obj" = "$last_oldobj" ; then RANLIB=$save_RANLIB fi test -z "$concat_cmds" || concat_cmds=$concat_cmds~ eval concat_cmds=\"\${concat_cmds}$old_archive_cmds\" objlist= fi done RANLIB=$save_RANLIB oldobjs=$objlist if test "X$oldobjs" = "X" ; then eval cmds=\"\$concat_cmds\" else eval cmds=\"\$concat_cmds~\$old_archive_cmds\" fi fi fi save_ifs="$IFS"; IFS='~' for cmd in $cmds; do eval cmd=\"$cmd\" IFS="$save_ifs" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" done if test -n "$generated"; then $show "${rm}r$generated" $run ${rm}r$generated fi # Now create the libtool archive. case $output in *.la) old_library= test "$build_old_libs" = yes && old_library="$libname.$libext" $show "creating $output" # Preserve any variables that may affect compiler behavior for var in $variables_saved_for_relink; do if eval test -z \"\${$var+set}\"; then relink_command="{ test -z \"\${$var+set}\" || unset $var || { $var=; export $var; }; }; $relink_command" elif eval var_value=\$$var; test -z "$var_value"; then relink_command="$var=; export $var; $relink_command" else var_value=`$echo "X$var_value" | $Xsed -e "$sed_quote_subst"` relink_command="$var=\"$var_value\"; export $var; $relink_command" fi done # Quote the link command for shipping. relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)" relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP` if test "$hardcode_automatic" = yes ; then relink_command= fi # Only create the output if not a dry run. if test -z "$run"; then for installed in no yes; do if test "$installed" = yes; then if test -z "$install_libdir"; then break fi output="$output_objdir/$outputname"i # Replace all uninstalled libtool libraries with the installed ones newdependency_libs= for deplib in $dependency_libs; do case $deplib in *.la) name=`$echo "X$deplib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib` if test -z "$libdir"; then $echo "$modename: \`$deplib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdependency_libs="$newdependency_libs $libdir/$name" ;; *) newdependency_libs="$newdependency_libs $deplib" ;; esac done dependency_libs="$newdependency_libs" newdlfiles= for lib in $dlfiles; do name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` if test -z "$libdir"; then $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdlfiles="$newdlfiles $libdir/$name" done dlfiles="$newdlfiles" newdlprefiles= for lib in $dlprefiles; do name=`$echo "X$lib" | $Xsed -e 's%^.*/%%'` eval libdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $lib` if test -z "$libdir"; then $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 exit $EXIT_FAILURE fi newdlprefiles="$newdlprefiles $libdir/$name" done dlprefiles="$newdlprefiles" else newdlfiles= for lib in $dlfiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac newdlfiles="$newdlfiles $abs" done dlfiles="$newdlfiles" newdlprefiles= for lib in $dlprefiles; do case $lib in [\\/]* | [A-Za-z]:[\\/]*) abs="$lib" ;; *) abs=`pwd`"/$lib" ;; esac newdlprefiles="$newdlprefiles $abs" done dlprefiles="$newdlprefiles" fi $rm $output # place dlname in correct position for cygwin tdlname=$dlname case $host,$output,$installed,$module,$dlname in *cygwin*,*lai,yes,no,*.dll | *mingw*,*lai,yes,no,*.dll) tdlname=../bin/$dlname ;; esac $echo > $output "\ # $outputname - a libtool library file # Generated by $PROGRAM - GNU $PACKAGE $VERSION$TIMESTAMP # # Please DO NOT delete this file! # It is necessary for linking the library. # The name that we can dlopen(3). dlname='$tdlname' # Names of this library. library_names='$library_names' # The name of the static archive. old_library='$old_library' # Libraries that this one depends upon. dependency_libs='$dependency_libs' # Version information for $libname. current=$current age=$age revision=$revision # Is this an already installed library? installed=$installed # Should we warn about portability when linking against -modules? shouldnotlink=$module # Files to dlopen/dlpreopen dlopen='$dlfiles' dlpreopen='$dlprefiles' # Directory that this library needs to be installed in: libdir='$install_libdir'" if test "$installed" = no && test "$need_relink" = yes; then $echo >> $output "\ relink_command=\"$relink_command\"" fi done fi # Do a symbolic link so that the libtool archive can be found in # LD_LIBRARY_PATH before the program is installed. $show "(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)" $run eval '(cd $output_objdir && $rm $outputname && $LN_S ../$outputname $outputname)' || exit $? ;; esac exit $EXIT_SUCCESS ;; # libtool install mode install) modename="$modename: install" # There may be an optional sh(1) argument at the beginning of # install_prog (especially on Windows NT). if test "$nonopt" = "$SHELL" || test "$nonopt" = /bin/sh || # Allow the use of GNU shtool's install command. $echo "X$nonopt" | grep shtool > /dev/null; then # Aesthetically quote it. arg=`$echo "X$nonopt" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$arg " arg="$1" shift else install_prog= arg=$nonopt fi # The real first argument should be the name of the installation program. # Aesthetically quote it. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$install_prog$arg" # We need to accept at least all the BSD install flags. dest= files= opts= prev= install_type= isdir=no stripme= for arg do if test -n "$dest"; then files="$files $dest" dest=$arg continue fi case $arg in -d) isdir=yes ;; -f) case " $install_prog " in *[\\\ /]cp\ *) ;; *) prev=$arg ;; esac ;; -g | -m | -o) prev=$arg ;; -s) stripme=" -s" continue ;; -*) ;; *) # If the previous option needed an argument, then skip it. if test -n "$prev"; then prev= else dest=$arg continue fi ;; esac # Aesthetically quote the argument. arg=`$echo "X$arg" | $Xsed -e "$sed_quote_subst"` case $arg in *[\[\~\#\^\&\*\(\)\{\}\|\;\<\>\?\'\ \ ]*|*]*|"") arg="\"$arg\"" ;; esac install_prog="$install_prog $arg" done if test -z "$install_prog"; then $echo "$modename: you must specify an install program" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test -n "$prev"; then $echo "$modename: the \`$prev' option requires an argument" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi if test -z "$files"; then if test -z "$dest"; then $echo "$modename: no file or destination specified" 1>&2 else $echo "$modename: you must specify a destination" 1>&2 fi $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Strip any trailing slash from the destination. dest=`$echo "X$dest" | $Xsed -e 's%/$%%'` # Check to see that the destination is a directory. test -d "$dest" && isdir=yes if test "$isdir" = yes; then destdir="$dest" destname= else destdir=`$echo "X$dest" | $Xsed -e 's%/[^/]*$%%'` test "X$destdir" = "X$dest" && destdir=. destname=`$echo "X$dest" | $Xsed -e 's%^.*/%%'` # Not a directory, so check to see that there is only one file specified. set dummy $files if test "$#" -gt 2; then $echo "$modename: \`$dest' is not a directory" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi fi case $destdir in [\\/]* | [A-Za-z]:[\\/]*) ;; *) for file in $files; do case $file in *.lo) ;; *) $echo "$modename: \`$destdir' must be an absolute directory name" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac done ;; esac # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" staticlibs= future_libdirs= current_libdirs= for file in $files; do # Do each installation. case $file in *.$libext) # Do the static libraries later. staticlibs="$staticlibs $file" ;; *.la) # Check to see that this really is a libtool archive. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$file' is not a valid libtool archive" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi library_names= old_library= relink_command= # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Add the libdir to current_libdirs if it is the destination. if test "X$destdir" = "X$libdir"; then case "$current_libdirs " in *" $libdir "*) ;; *) current_libdirs="$current_libdirs $libdir" ;; esac else # Note the libdir as a future libdir. case "$future_libdirs " in *" $libdir "*) ;; *) future_libdirs="$future_libdirs $libdir" ;; esac fi dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'`/ test "X$dir" = "X$file/" && dir= dir="$dir$objdir" if test -n "$relink_command"; then # Determine the prefix the user has applied to our future dir. inst_prefix_dir=`$echo "$destdir" | $SED "s%$libdir\$%%"` # Don't allow the user to place us outside of our expected # location b/c this prevents finding dependent libraries that # are installed to the same prefix. # At present, this check doesn't affect windows .dll's that # are installed into $libdir/../bin (currently, that works fine) # but it's something to keep an eye on. if test "$inst_prefix_dir" = "$destdir"; then $echo "$modename: error: cannot install \`$file' to a directory not ending in $libdir" 1>&2 exit $EXIT_FAILURE fi if test -n "$inst_prefix_dir"; then # Stick the inst_prefix_dir data into the link command. relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%" | $NL2SP` else relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%%" | $NL2SP` fi $echo "$modename: warning: relinking \`$file'" 1>&2 $show "$relink_command" if $run eval "$relink_command"; then : else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 exit $EXIT_FAILURE fi fi # See the names of the shared library. set dummy $library_names if test -n "$2"; then realname="$2" shift shift srcname="$realname" test -n "$relink_command" && srcname="$realname"T # Install the shared library and build the symlinks. $show "$install_prog $dir/$srcname $destdir/$realname" $run eval "$install_prog $dir/$srcname $destdir/$realname" || exit $? if test -n "$stripme" && test -n "$striplib"; then $show "$striplib $destdir/$realname" $run eval "$striplib $destdir/$realname" || exit $? fi if test "$#" -gt 0; then # Delete the old symlinks, and create new ones. # Try `ln -sf' first, because the `ln' binary might depend on # the symlink we replace! Solaris /bin/ln does not understand -f, # so we also need to try rm && ln -s. for linkname do if test "$linkname" != "$realname"; then $show "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" $run eval "(cd $destdir && { $LN_S -f $realname $linkname || { $rm $linkname && $LN_S $realname $linkname; }; })" fi done fi # Do each command in the postinstall commands. lib="$destdir/$realname" cmds=$postinstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || { lt_exit=$? # Restore the uninstalled library and exit if test "$mode" = relink; then $run eval '(cd $output_objdir && $rm ${realname}T && $mv ${realname}U $realname)' fi exit $lt_exit } done IFS="$save_ifs" fi # Install the pseudo-library for information purposes. name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` instname="$dir/$name"i $show "$install_prog $instname $destdir/$name" $run eval "$install_prog $instname $destdir/$name" || exit $? # Maybe install the static library, too. test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" ;; *.lo) # Install (i.e. copy) a libtool object. # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile="$destdir/$destname" else destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` destfile="$destdir/$destfile" fi # Deduce the name of the destination old-style object file. case $destfile in *.lo) staticdest=`$echo "X$destfile" | $Xsed -e "$lo2o"` ;; *.$objext) staticdest="$destfile" destfile= ;; *) $echo "$modename: cannot copy a libtool object to \`$destfile'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac # Install the libtool object if requested. if test -n "$destfile"; then $show "$install_prog $file $destfile" $run eval "$install_prog $file $destfile" || exit $? fi # Install the old object if enabled. if test "$build_old_libs" = yes; then # Deduce the name of the old-style object file. staticobj=`$echo "X$file" | $Xsed -e "$lo2o"` $show "$install_prog $staticobj $staticdest" $run eval "$install_prog \$staticobj \$staticdest" || exit $? fi exit $EXIT_SUCCESS ;; *) # Figure out destination file name, if it wasn't already specified. if test -n "$destname"; then destfile="$destdir/$destname" else destfile=`$echo "X$file" | $Xsed -e 's%^.*/%%'` destfile="$destdir/$destfile" fi # If the file is missing, and there is a .exe on the end, strip it # because it is most likely a libtool script we actually want to # install stripped_ext="" case $file in *.exe) if test ! -f "$file"; then file=`$echo $file|${SED} 's,.exe$,,'` stripped_ext=".exe" fi ;; esac # Do a test to see if this is really a libtool program. case $host in *cygwin*|*mingw*) wrapper=`$echo $file | ${SED} -e 's,.exe$,,'` ;; *) wrapper=$file ;; esac if (${SED} -e '4q' $wrapper | grep "^# Generated by .*$PACKAGE")>/dev/null 2>&1; then notinst_deplibs= relink_command= # Note that it is not necessary on cygwin/mingw to append a dot to # foo even if both foo and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # `FILE.' does not work on cygwin managed mounts. # # If there is no directory component, then add one. case $wrapper in */* | *\\*) . ${wrapper} ;; *) . ./${wrapper} ;; esac # Check the variables that should have been set. if test -z "$notinst_deplibs"; then $echo "$modename: invalid libtool wrapper script \`$wrapper'" 1>&2 exit $EXIT_FAILURE fi finalize=yes for lib in $notinst_deplibs; do # Check to see that each library is installed. libdir= if test -f "$lib"; then # If there is no directory component, then add one. case $lib in */* | *\\*) . $lib ;; *) . ./$lib ;; esac fi libfile="$libdir/"`$echo "X$lib" | $Xsed -e 's%^.*/%%g'` ### testsuite: skip nested quoting test if test -n "$libdir" && test ! -f "$libfile"; then $echo "$modename: warning: \`$lib' has not been installed in \`$libdir'" 1>&2 finalize=no fi done relink_command= # Note that it is not necessary on cygwin/mingw to append a dot to # foo even if both foo and FILE.exe exist: automatic-append-.exe # behavior happens only for exec(3), not for open(2)! Also, sourcing # `FILE.' does not work on cygwin managed mounts. # # If there is no directory component, then add one. case $wrapper in */* | *\\*) . ${wrapper} ;; *) . ./${wrapper} ;; esac outputname= if test "$fast_install" = no && test -n "$relink_command"; then if test "$finalize" = yes && test -z "$run"; then tmpdir=`func_mktempdir` file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'` outputname="$tmpdir/$file" # Replace the output file specification. relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g' | $NL2SP` $show "$relink_command" if $run eval "$relink_command"; then : else $echo "$modename: error: relink \`$file' with the above command before installing it" 1>&2 ${rm}r "$tmpdir" continue fi file="$outputname" else $echo "$modename: warning: cannot relink \`$file'" 1>&2 fi else # Install the binary that we compiled earlier. file=`$echo "X$file$stripped_ext" | $Xsed -e "s%\([^/]*\)$%$objdir/\1%"` fi fi # remove .exe since cygwin /usr/bin/install will append another # one anyway case $install_prog,$host in */usr/bin/install*,*cygwin*) case $file:$destfile in *.exe:*.exe) # this is ok ;; *.exe:*) destfile=$destfile.exe ;; *:*.exe) destfile=`$echo $destfile | ${SED} -e 's,.exe$,,'` ;; esac ;; esac $show "$install_prog$stripme $file $destfile" $run eval "$install_prog\$stripme \$file \$destfile" || exit $? test -n "$outputname" && ${rm}r "$tmpdir" ;; esac done for file in $staticlibs; do name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` # Set up the ranlib parameters. oldlib="$destdir/$name" $show "$install_prog $file $oldlib" $run eval "$install_prog \$file \$oldlib" || exit $? if test -n "$stripme" && test -n "$old_striplib"; then $show "$old_striplib $oldlib" $run eval "$old_striplib $oldlib" || exit $? fi # Do each command in the postinstall commands. cmds=$old_postinstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || exit $? done IFS="$save_ifs" done if test -n "$future_libdirs"; then $echo "$modename: warning: remember to run \`$progname --finish$future_libdirs'" 1>&2 fi if test -n "$current_libdirs"; then # Maybe just do a dry run. test -n "$run" && current_libdirs=" -n$current_libdirs" exec_cmd='$SHELL $progpath $preserve_args --finish$current_libdirs' else exit $EXIT_SUCCESS fi ;; # libtool finish mode finish) modename="$modename: finish" libdirs="$nonopt" admincmds= if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then for dir do libdirs="$libdirs $dir" done for libdir in $libdirs; do if test -n "$finish_cmds"; then # Do each command in the finish commands. cmds=$finish_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" || admincmds="$admincmds $cmd" done IFS="$save_ifs" fi if test -n "$finish_eval"; then # Do the single finish_eval. eval cmds=\"$finish_eval\" $run eval "$cmds" || admincmds="$admincmds $cmds" fi done fi # Exit here if they wanted silent mode. test "$show" = : && exit $EXIT_SUCCESS $echo "X----------------------------------------------------------------------" | $Xsed $echo "Libraries have been installed in:" for libdir in $libdirs; do $echo " $libdir" done $echo $echo "If you ever happen to want to link against installed libraries" $echo "in a given directory, LIBDIR, you must either use libtool, and" $echo "specify the full pathname of the library, or use the \`-LLIBDIR'" $echo "flag during linking and do at least one of the following:" if test -n "$shlibpath_var"; then $echo " - add LIBDIR to the \`$shlibpath_var' environment variable" $echo " during execution" fi if test -n "$runpath_var"; then $echo " - add LIBDIR to the \`$runpath_var' environment variable" $echo " during linking" fi if test -n "$hardcode_libdir_flag_spec"; then libdir=LIBDIR eval flag=\"$hardcode_libdir_flag_spec\" $echo " - use the \`$flag' linker flag" fi if test -n "$admincmds"; then $echo " - have your system administrator run these commands:$admincmds" fi if test -f /etc/ld.so.conf; then $echo " - have your system administrator add LIBDIR to \`/etc/ld.so.conf'" fi $echo $echo "See any operating system documentation about shared libraries for" $echo "more information, such as the ld(1) and ld.so(8) manual pages." $echo "X----------------------------------------------------------------------" | $Xsed exit $EXIT_SUCCESS ;; # libtool execute mode execute) modename="$modename: execute" # The first argument is the command name. cmd="$nonopt" if test -z "$cmd"; then $echo "$modename: you must specify a COMMAND" 1>&2 $echo "$help" exit $EXIT_FAILURE fi # Handle -dlopen flags immediately. for file in $execute_dlfiles; do if test ! -f "$file"; then $echo "$modename: \`$file' is not a file" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi dir= case $file in *.la) # Check to see that this really is a libtool archive. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then : else $echo "$modename: \`$lib' is not a valid libtool archive" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi # Read the libtool library. dlname= library_names= # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Skip this library if it cannot be dlopened. if test -z "$dlname"; then # Warn if it was a shared library. test -n "$library_names" && $echo "$modename: warning: \`$file' was not linked with \`-export-dynamic'" continue fi dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. if test -f "$dir/$objdir/$dlname"; then dir="$dir/$objdir" else if test ! -f "$dir/$dlname"; then $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2 exit $EXIT_FAILURE fi fi ;; *.lo) # Just add the directory containing the .lo file. dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` test "X$dir" = "X$file" && dir=. ;; *) $echo "$modename: warning \`-dlopen' is ignored for non-libtool libraries and objects" 1>&2 continue ;; esac # Get the absolute pathname. absdir=`cd "$dir" && pwd` test -n "$absdir" && dir="$absdir" # Now add the directory to shlibpath_var. if eval "test -z \"\$$shlibpath_var\""; then eval "$shlibpath_var=\"\$dir\"" else eval "$shlibpath_var=\"\$dir:\$$shlibpath_var\"" fi done # This variable tells wrapper scripts just to set shlibpath_var # rather than running their programs. libtool_execute_magic="$magic" # Check if any of the arguments is a wrapper script. args= for file do case $file in -*) ;; *) # Do a test to see if this is really a libtool program. if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # If there is no directory component, then add one. case $file in */* | *\\*) . $file ;; *) . ./$file ;; esac # Transform arg to wrapped name. file="$progdir/$program" fi ;; esac # Quote arguments (to preserve shell metacharacters). file=`$echo "X$file" | $Xsed -e "$sed_quote_subst"` args="$args \"$file\"" done if test -z "$run"; then if test -n "$shlibpath_var"; then # Export the shlibpath_var. eval "export $shlibpath_var" fi # Restore saved environment variables for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES do eval "if test \"\${save_$lt_var+set}\" = set; then $lt_var=\$save_$lt_var; export $lt_var fi" done # Now prepare to actually exec the command. exec_cmd="\$cmd$args" else # Display what would be done. if test -n "$shlibpath_var"; then eval "\$echo \"\$shlibpath_var=\$$shlibpath_var\"" $echo "export $shlibpath_var" fi $echo "$cmd$args" exit $EXIT_SUCCESS fi ;; # libtool clean and uninstall mode clean | uninstall) modename="$modename: $mode" rm="$nonopt" files= rmforce= exit_status=0 # This variable tells wrapper scripts just to set variables rather # than running their programs. libtool_install_magic="$magic" for arg do case $arg in -f) rm="$rm $arg"; rmforce=yes ;; -*) rm="$rm $arg" ;; *) files="$files $arg" ;; esac done if test -z "$rm"; then $echo "$modename: you must specify an RM program" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE fi rmdirs= origobjdir="$objdir" for file in $files; do dir=`$echo "X$file" | $Xsed -e 's%/[^/]*$%%'` if test "X$dir" = "X$file"; then dir=. objdir="$origobjdir" else objdir="$dir/$origobjdir" fi name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` test "$mode" = uninstall && objdir="$dir" # Remember objdir for removal later, being careful to avoid duplicates if test "$mode" = clean; then case " $rmdirs " in *" $objdir "*) ;; *) rmdirs="$rmdirs $objdir" ;; esac fi # Don't error if the file doesn't exist and rm -f was used. if (test -L "$file") >/dev/null 2>&1 \ || (test -h "$file") >/dev/null 2>&1 \ || test -f "$file"; then : elif test -d "$file"; then exit_status=1 continue elif test "$rmforce" = yes; then continue fi rmfiles="$file" case $name in *.la) # Possibly a libtool archive, so verify it. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then . $dir/$name # Delete the libtool libraries and symlinks. for n in $library_names; do rmfiles="$rmfiles $objdir/$n" done test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library" case "$mode" in clean) case " $library_names " in # " " in the beginning catches empty $dlname *" $dlname "*) ;; *) rmfiles="$rmfiles $objdir/$dlname" ;; esac test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i" ;; uninstall) if test -n "$library_names"; then # Do each command in the postuninstall commands. cmds=$postuninstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" if test "$?" -ne 0 && test "$rmforce" != yes; then exit_status=1 fi done IFS="$save_ifs" fi if test -n "$old_library"; then # Do each command in the old_postuninstall commands. cmds=$old_postuninstall_cmds save_ifs="$IFS"; IFS='~' for cmd in $cmds; do IFS="$save_ifs" eval cmd=\"$cmd\" $show "$cmd" $run eval "$cmd" if test "$?" -ne 0 && test "$rmforce" != yes; then exit_status=1 fi done IFS="$save_ifs" fi # FIXME: should reinstall the best remaining shared library. ;; esac fi ;; *.lo) # Possibly a libtool object, so verify it. if (${SED} -e '2q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then # Read the .lo file . $dir/$name # Add PIC object to the list of files to remove. if test -n "$pic_object" \ && test "$pic_object" != none; then rmfiles="$rmfiles $dir/$pic_object" fi # Add non-PIC object to the list of files to remove. if test -n "$non_pic_object" \ && test "$non_pic_object" != none; then rmfiles="$rmfiles $dir/$non_pic_object" fi fi ;; *) if test "$mode" = clean ; then noexename=$name case $file in *.exe) file=`$echo $file|${SED} 's,.exe$,,'` noexename=`$echo $name|${SED} 's,.exe$,,'` # $file with .exe has already been added to rmfiles, # add $file without .exe rmfiles="$rmfiles $file" ;; esac # Do a test to see if this is a libtool program. if (${SED} -e '4q' $file | grep "^# Generated by .*$PACKAGE") >/dev/null 2>&1; then relink_command= . $dir/$noexename # note $name still contains .exe if it was in $file originally # as does the version of $file that was added into $rmfiles rmfiles="$rmfiles $objdir/$name $objdir/${name}S.${objext}" if test "$fast_install" = yes && test -n "$relink_command"; then rmfiles="$rmfiles $objdir/lt-$name" fi if test "X$noexename" != "X$name" ; then rmfiles="$rmfiles $objdir/lt-${noexename}.c" fi fi fi ;; esac $show "$rm $rmfiles" $run $rm $rmfiles || exit_status=1 done objdir="$origobjdir" # Try to remove the ${objdir}s in the directories where we deleted files for dir in $rmdirs; do if test -d "$dir"; then $show "rmdir $dir" $run rmdir $dir >/dev/null 2>&1 fi done exit $exit_status ;; "") $echo "$modename: you must specify a MODE" 1>&2 $echo "$generic_help" 1>&2 exit $EXIT_FAILURE ;; esac if test -z "$exec_cmd"; then $echo "$modename: invalid operation mode \`$mode'" 1>&2 $echo "$generic_help" 1>&2 exit $EXIT_FAILURE fi fi # test -z "$show_help" if test -n "$exec_cmd"; then eval exec $exec_cmd exit $EXIT_FAILURE fi # We need to display help for each of the modes. case $mode in "") $echo \ "Usage: $modename [OPTION]... [MODE-ARG]... Provide generalized library-building support services. --config show all configuration variables --debug enable verbose shell tracing -n, --dry-run display commands without modifying any files --features display basic configuration information and exit --finish same as \`--mode=finish' --help display this help message and exit --mode=MODE use operation mode MODE [default=inferred from MODE-ARGS] --quiet same as \`--silent' --silent don't print informational messages --tag=TAG use configuration variables from tag TAG --version print version information MODE must be one of the following: clean remove files from the build directory compile compile a source file into a libtool object execute automatically set library path, then run a program finish complete the installation of libtool libraries install install libraries or executables link create a library or an executable uninstall remove libraries from an installed directory MODE-ARGS vary depending on the MODE. Try \`$modename --help --mode=MODE' for a more detailed description of MODE. Report bugs to ." exit $EXIT_SUCCESS ;; clean) $echo \ "Usage: $modename [OPTION]... --mode=clean RM [RM-OPTION]... FILE... Remove files from the build directory. RM is the name of the program to use to delete files associated with each FILE (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed to RM. If FILE is a libtool library, object or program, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; compile) $echo \ "Usage: $modename [OPTION]... --mode=compile COMPILE-COMMAND... SOURCEFILE Compile a source file into a libtool library object. This mode accepts the following additional options: -o OUTPUT-FILE set the output file name to OUTPUT-FILE -prefer-pic try to building PIC objects only -prefer-non-pic try to building non-PIC objects only -static always build a \`.o' file suitable for static linking COMPILE-COMMAND is a command to be used in creating a \`standard' object file from the given SOURCEFILE. The output file name is determined by removing the directory component from SOURCEFILE, then substituting the C source code suffix \`.c' with the library object suffix, \`.lo'." ;; execute) $echo \ "Usage: $modename [OPTION]... --mode=execute COMMAND [ARGS]... Automatically set library path, then run a program. This mode accepts the following additional options: -dlopen FILE add the directory containing FILE to the library path This mode sets the library path environment variable according to \`-dlopen' flags. If any of the ARGS are libtool executable wrappers, then they are translated into their corresponding uninstalled binary, and any of their required library directories are added to the library path. Then, COMMAND is executed, with ARGS as arguments." ;; finish) $echo \ "Usage: $modename [OPTION]... --mode=finish [LIBDIR]... Complete the installation of libtool libraries. Each LIBDIR is a directory that contains libtool libraries. The commands that this mode executes may require superuser privileges. Use the \`--dry-run' option if you just want to see what would be executed." ;; install) $echo \ "Usage: $modename [OPTION]... --mode=install INSTALL-COMMAND... Install executables or libraries. INSTALL-COMMAND is the installation command. The first component should be either the \`install' or \`cp' program. The rest of the components are interpreted as arguments to that command (only BSD-compatible install options are recognized)." ;; link) $echo \ "Usage: $modename [OPTION]... --mode=link LINK-COMMAND... Link object files or libraries together to form another library, or to create an executable program. LINK-COMMAND is a command using the C compiler that you would use to create a program from several object files. The following components of LINK-COMMAND are treated specially: -all-static do not do any dynamic linking at all -avoid-version do not add a version suffix if possible -dlopen FILE \`-dlpreopen' FILE if it cannot be dlopened at runtime -dlpreopen FILE link in FILE and add its symbols to lt_preloaded_symbols -export-dynamic allow symbols from OUTPUT-FILE to be resolved with dlsym(3) -export-symbols SYMFILE try to export only the symbols listed in SYMFILE -export-symbols-regex REGEX try to export only the symbols matching REGEX -LLIBDIR search LIBDIR for required installed libraries -lNAME OUTPUT-FILE requires the installed library libNAME -module build a library that can dlopened -no-fast-install disable the fast-install mode -no-install link a not-installable executable -no-undefined declare that a library does not refer to external symbols -o OUTPUT-FILE create OUTPUT-FILE from the specified objects -objectlist FILE Use a list of object files found in FILE to specify objects -precious-files-regex REGEX don't remove output files matching REGEX -release RELEASE specify package release information -rpath LIBDIR the created library will eventually be installed in LIBDIR -R[ ]LIBDIR add LIBDIR to the runtime path of programs and libraries -static do not do any dynamic linking of uninstalled libtool libraries -static-libtool-libs do not do any dynamic linking of libtool libraries -version-info CURRENT[:REVISION[:AGE]] specify library version info [each variable defaults to 0] All other options (arguments beginning with \`-') are ignored. Every other argument is treated as a filename. Files ending in \`.la' are treated as uninstalled libtool libraries, other files are standard or library object files. If the OUTPUT-FILE ends in \`.la', then a libtool library is created, only library objects (\`.lo' files) may be specified, and \`-rpath' is required, except when creating a convenience library. If OUTPUT-FILE ends in \`.a' or \`.lib', then a standard library is created using \`ar' and \`ranlib', or on Windows using \`lib'. If OUTPUT-FILE ends in \`.lo' or \`.${objext}', then a reloadable object file is created, otherwise an executable program is created." ;; uninstall) $echo \ "Usage: $modename [OPTION]... --mode=uninstall RM [RM-OPTION]... FILE... Remove libraries from an installation directory. RM is the name of the program to use to delete files associated with each FILE (typically \`/bin/rm'). RM-OPTIONS are options (such as \`-f') to be passed to RM. If FILE is a libtool library, all the files associated with it are deleted. Otherwise, only FILE itself is deleted using RM." ;; *) $echo "$modename: invalid operation mode \`$mode'" 1>&2 $echo "$help" 1>&2 exit $EXIT_FAILURE ;; esac $echo $echo "Try \`$modename --help' for more information about other modes." exit $? # The TAGs below are defined such that we never get into a situation # in which we disable both kinds of libraries. Given conflicting # choices, we go for a static library, that is the most portable, # since we can't tell whether shared libraries were disabled because # the user asked for that or because the platform doesn't support # them. This is particularly important on AIX, because we don't # support having both static and shared libraries enabled at the same # time on that platform, so we default to a shared-only configuration. # If a disable-shared tag is given, we'll fallback to a static-only # configuration. But we'll never go from static-only to shared-only. # ### BEGIN LIBTOOL TAG CONFIG: disable-shared disable_libs=shared # ### END LIBTOOL TAG CONFIG: disable-shared # ### BEGIN LIBTOOL TAG CONFIG: disable-static disable_libs=static # ### END LIBTOOL TAG CONFIG: disable-static # Local Variables: # mode:shell-script # sh-indentation:2 # End: brp-pacu/configure.ac0000644000175000017500000000211712153127664013527 0ustar miramiraAC_INIT ########## Macintosh implementation ######### if [[ `uname` = 'Darwin' ]] then if [[ -n "PKG_CONFIG_PATH" ]] # Assume that PGK is installed with jhbuild in the home directory then PKG_CONFIG_PATH='/usr/lib/pkgconfig/:/usr/local/lib/pkgconfig/:'$HOME'/gtk/inst/lib/pkgconfig' export PKG_CONFIG_PATH fi fi AM_CONDITIONAL([APPLE], [ test `uname` = 'Darwin']) AC_SUBST(PKG_CONFIG_PATH) ############################################# AC_CONFIG_HEADER(config.h) AM_INIT_AUTOMAKE(BRP_PACU,2.1.1) AC_PROG_CC AC_PROG_INSTALL AC_CONFIG_FILES([Makefile]) AC_OUTPUT AC_CHECK_LIB(m,cos,,AC_MSG_ERROR([could not link to mathlib.])) AC_CHECK_LIB(fftw,fftw_create_plan,,AC_MSG_ERROR([could not link to fftw please install the fftw package.])) PKG_CHECK_MODULES(GTK, gtk+-2.0,,exit) PKG_CHECK_MODULES(PANGO, pango,,exit) PKG_CHECK_MODULES(CAIRO, cairo,,exit) #PKG_CHECK_MODULES(GDK-2.0, gdk-2.0,,exit) PKG_CHECK_MODULES(GTKDATABOX, gtkdatabox,,AC_MSG_ERROR([please install gtkdatabox development version.])) PKG_CHECK_MODULES(JACK, jack,,AC_MSG_ERROR([please install the jack development version.])) brp-pacu/NEWS0000644000175000017500000001220412153127664011736 0ustar miramiraVersion 2.1.1 1/20/2010 Open a window with error message when Jack does not initialize (instead of quitting silently) and automatically open JackPilot The Binary Macintosh distribution is bundled together with the GTK library, so it is not necessary to downloaded GTK separately. The graphical user interface is fetched from file BRP_PACU.iu via GTKBuilder (instead of libglade, which is deprecated) Version 2.1.0 04/17/2009 Changed libraries for thread mutexes for compilation on windows Smaller screen sizes now supported Octave based (log2) frequency grids instead of log10 Auto-resize (ctrl-r) works much more predictably and smoothly Delay size has been increased to 1000millisecs Averaging (graph response time) and smoothing now adjustable via GUI Other minor glitches fixed Version 2.0.8(unreleased) 04/06/2009 Added Pink Noise Menu Item and CTRL-P accel Changed N to N_FFT to avoid symbol collisions Major Performance improvement, more than halved needed CPU cycles in gui *Changed smoothing algorithm in gui.c to not calculate millions of points redundantly Version 2.0.7 04/01/2009 Buffer Management *Added capability to automatically save the capture buffers and load them from $HOME/.BRP_PACU/buff_store at startup if it exists *Added Open, Save, and Save-As dialogs, functionality to store buffers for later usage/reference *Added functionality for opening data files by double-clicking or dragging into the application icon (Mac only) HCI *Put more user friendly name onto Transfer Function Button (formerly H(z) *Changed Buffer names to not start at 0, but 1, updated accelerators accordingly *Removed menu pictures because they hid the accelerator shortcut help in the menus for some reason Keyboard Accelerators *Thanks to Andreas for fixing the Mac key accelerators and suggesting the use of Control keys instead of Alt keys Minor Memory Leaks *Destroy widgets on exit only if left open Premature Memory Deallocation errors * Made colors global variables in gui.c * Made several widgets global variables Fix Jack callback stability by improving threadlock handling *Removed threadlocking around gui_idle_func (Gui Idle function) which keeps jack audio thread from updating buffers *This improves jack performance (XRuns) by preventing Jack audio buffer callback from being locked out for long periods during a gui callback *This is done by only copying critical memory areas during the thread lockout, rather than trying to update the whole gui and not make a copy, which was easier to do but not clean Version 2.0.6 02/01/2009 Thanks to Andreas Schwab for fix to Makefile.am to detect gtk and noticing that the Jack callback Fill_buffer had no return value Version 2.0.6 01/10/2009 *Apply patch created by J Walton, aka tehgooroo so that it will compile using Macports under Mac OS-X. Thanks J! *Fix minor problem in the impulse response algorithm caused by delay fix. 01/05/2009 Fix bug in delay introduced by another bug fix. 01/04/2009 Fix minor install error with gui.glade Starts jack transport automatically 12/31/2008 Fix Jack call back to avoid mutex collisions Version 2.0.0 12/31/2008 Pink Noise and Jack Support Added Pink Noise Output *Mute/Unmute and adjust levels Add Jack Audio Connection Kit support and removed alsa *Automatically connects Reference and Measured to Channel 2 and Channel 1 *Automatically connects Pink Noise Output to Reference Input Removed header install as part of installation (This was an accidental feature in previous versions, sorry) 12/20/2008 Major GUI and UI update! *Delay function now resets delay before each capture, resulting in a much more intuitive delay finding procedure. *Rewrote buffer capture interface so that it makes more sense and works consistently. *Rewrote keyboard shortcuts so they don't interfere with the Avg gain. *Added default zoom button to return to original zoom settings. *Added inserted delay size status on the status bar. *Added "about" and "general help" windows *TODO: add pink noise generator and ability to save buffers to a file. This will allow soundcards with only one input channel to do the transfer function. 11/26/2008 Fixed compilation erors with latest version of gtkkdatabox library. Certain API calls were removed or changed. This update allows compatibility with the latest version. 02/22/2008 Fixed delay dialog units. Fixed delay algorithm bug. Fixed Broken automake links in tarball (Thanks to Dan for pointing them out). 02/04/2008 Added "LED" signal indicators for audio inputs. Changed soundcard buffer handling to prevent oops messages. Fixed various minor UI issues such as delay dialog problems. 01/28/2008 Changed the thread sound read and the fft function to fix likely buffer over/underflows. 01/28/2008 Changed Smoothing function to work properly. This feature was broken in an unreleased version by an upgrade to gtkdatabox-0.8.2.2 brp-pacu/main.h0000644000175000017500000000314712153127664012342 0ustar miramira/* * main.h : defines FFT_Frame struct, PI * * * * Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. */ #include #include #include #include #include #include #include #include #define pi 3.141592653 #ifndef MAIN_H #define MAIN_H struct FFT_Frame { fftw_plan plan; // FFT Plan fftw_plan reverse_plan; // FFT Plan short * prewin_buffer_data_1; // Data from channel short * prewin_buffer_data_2; short * buffer_data_1; // data from channel after window function short * buffer_data_2; // data from channel after window function double * fft_returned_1; double * fft_returned_2; double * rfft_returned_1; float volume_pink; char pink_muted; ////////////////// short * delay; int delay_size; char find_delay; char find_impulse; }; #endif brp-pacu/testfft.h0000644000175000017500000000273312153127664013075 0ustar miramira/* * testfft.h : defines Audio_Sesssion struct, various FFT Parameters * such as window size. * * * * Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. */ #include #include #include "main.h" #define DELAY_BUFFER_SIZE 44100 #define N_FFT 8192 #define RATIO 2 #define MAX_AVG_NUM 32 #define BUFF_NUM 32 #define FSAMP 44100 #define SCALEF 32765 #define NYQUIST FSAMP/2 #define PLOT_PTS (N_FFT)/RATIO #define FBIN (float) ((float) NYQUIST)/( ((float)PLOT_PTS)/1.0) #define BUFSIZE 256 #define B_N N_FFT/BUFSIZE #ifndef TESTFFT_H #define TESTFFT_H struct AUDIO_SESSION { fftw_plan plan; short * buffer_data; double * fft_returned; }; int fft_capture(struct FFT_Frame * session); int impulse_capture(struct FFT_Frame * session); #endif brp-pacu/sinc.xcf0000644000175000017500000045043012153127664012704 0ustar miramiragimp xcf fileBB"Jgamma0.45454999804496765gimp-image-grid(style intersections) (fgcolor (color-rgba 0.000000 0.000000 0.000000 1.000000)) (bgcolor (color-rgba 1.000000 1.000000 1.000000 1.000000)) (xspacing 32.000000) (yspacing 32.000000) (spacing-unit inches) (xoffset 0.000000) (yoffset 0.000000) (offset-unit inches) F8 Background     3p`8]iu88r 8  $ 4 D#''',-|11159f9v9>>CCDGKLMuRRXYIZ^LbdvhmamrPv{x}~oB|@>================;;============================================@>================;;============================================@>================;;============================================?==9?==9?==9? ==2? ==2? ==2?==,?==,?==,?<7 4 2 1 0.,+*(''&%$"#""  !!# %%% "'$$))$)&&+(-(**-**/, , 1 . . 3 3 ?<7 4 2 1 0.,+*(''&%$"#""  !!# %%% "'$$))$)&&+(-(**-**/, , 1 . . 3 3 ?<7 4 2 1 0.,+*(''&%$"#""  !!# %%% "'$$))$)&&+(-(**-**/, , 1 . . 3 3 ?== ?== ?== ?#==?#==?#==?)==?)==?)==7/..5555555555555523655555555555555555555555555555555555555555557/..5555555555555523655555555555555555555555555555555555555555557/..555555555555552365555555555555555555555555555555555555555555==================;;==============================================================;;==============================================================;;==============================================<==><==<;;;;:::::;::::9999888988887777666766665555 4445 4 333==<==><==<;;;;:::::;::::9999888988887777666766665555 4445 4 333==<==><==<;;;;:::::;::::9999888988887777666766665555 4445 4 333. . 3 / 1 4 3334 335 44464576667666867797889888:899;9::;:::<:::<;;;<=<;;. . 3 / 1 4 3334 335 44464576667666867797889888:899;9::;:::<:::<;;;<=<;;. . 3 / 1 4 3334 335 44464576667666867797889888:899;9::;:::<:::<;;;<=<;;655555555555555555236555555555555555555555555555555555555555555565555555555555555523655555555555555555555555555555555555555555556555555555555555552365555555555555555555555555555555555555555555==================;;==============================================================;;==============================================================;;============================================4 3333 22 2 3 2 1 1 1 2 1 1 1 1 0 0 0 1 0/ / / /. . . //. . . .- --.-,,,-,,,-,+++,+***+***+*4 3333 22 2 3 2 1 1 1 2 1 1 1 1 0 0 0 1 0/ / / /. . . //. . . .- --.-,,,-,,,-,+++,+***+***+*4 3333 22 2 3 2 1 1 1 2 1 1 1 1 0 0 0 1 0/ / / /. . . //. . . .- --.-,,,-,,,-,+++,+***+***+*>;>=}>= ?>;>=}>= ?>;>=}>= ?@==}>==<>==<?;;;=<:::<:::<;999:888:977797779866687555755576@==}>==<>==<?;;;=<:::<:::<;999:888:977797779866687555755576@==}>==<>==<?;;;=<:::<:::<;999:888:977797779866687555755576655555555555555555236555555555555555555555555555555555555555555565555555555555555523655555555555555555555555555555555555555555556555555555555555552365555555555555555555555555555555555555555555==================;;==============================================================;;==============================================================;;============================================))))((()('''((''''&&&'&%%%&%%%&%$$$$###$$####"""#"!!!!   !!    ))))((()('''((''''&&&'&%%%&%%%&%$$$$###$$####"""#"!!!!   !!    ))))((()('''((''''&&&'&%%%&%%%&%$$$$###$$####"""#"!!!!   !!    444 5333 5 42 2 2 4 4 2 2 2 3 1 1 1 3 2 0 0 0 2 0 0 0 2 1 / / /0 . . .00 . . ./ ---/.,,,-+++--+++,*444 5333 5 42 2 2 4 4 2 2 2 3 1 1 1 3 2 0 0 0 2 0 0 0 2 1 / / /0 . . .00 . . ./ ---/.,,,-+++--+++,*444 5333 5 42 2 2 4 4 2 2 2 3 1 1 1 3 2 0 0 0 2 0 0 0 2 1 / / /0 . . .00 . . ./ ---/.,,,-+++--+++,*655555555555555555236555555555555555555555555555555555555555555565555555555555555523655555555555555555555555555555555555555555556555555555555555552365555555555555555555555555555555555555555555==================;;==============================================================;;==============================================================;;============================================  2.+(&$" !"#%&'(()*++,---.  2.+(&$" !"#%&'(()*++,---.  2.+(&$" !"#%&'(()*++,---. ===<<;;:99987 ===<<;;:99987 ===<<;;:99987 !!!"  # !!#!!!$!""%"##&#$$&$$$'$%%(%&))&&) !!!"  # !!#!!!$!""%"##&#$$&$$$'$%%(%&))&&) !!!"  # !!#!!!$!""%"##&#$$&$$$'$%%(%&))&&)**+)))++)))*((()'''))'''(&&&'%%%&$$$&$$$%###$"""$"""#!!!"  !!  !**+)))++)))*((()'''))'''(&&&'%%%&$$$&$$$%###$"""$"""#!!!"  !!  !**+)))++)))*((()'''))'''(&&&'%%%&$$$&$$$%###$"""$"""#!!!"  !!  ! ;;:98765 4 4 3 2 1 1 0 0//.---,+ ;;:98765 4 4 3 2 1 1 0 0//.---,+ ;;:98765 4 4 3 2 1 1 0 0//.---,+  3 1/.,+*)(''&%$#""!   !!!"  3 1/.,+*)(''&%$#""!   !!!"  3 1/.,+*)(''&%$#""!   !!!"655555555555555555236555555555555555555555555555555555555555555565555555555555555523655555555555555555555555555555555555555555556555555555555555552365555555555555555555555555555555555555555555=================;;@>==<<;;:9887654 3 1 / / -)(&$"     =============================<;===<;:99876 5 4 1 / / -)(&$"     =============================;;@>==<<;;:9887654 3 1 / / -)(&$"     ============//0 1 2 2 3 4 4 4 56678999:? 5667889:;;<==//0 1 2 2 3 4 4 4 566789995667889:;;<==//0 1 2 2 3 4 4 4 56678999:? 5667889:;;<==7664 5 43 4 3 3 2 1 2 1 /0 .//? 0 3 2 / 2 . 10-0,/+..--),,+(+*&)&)%(''&#&%!$!$ #"7664 5 43 4 3 3 2 1 2 1 /0 .//? 0 3 2 / 2 . 10-0,/+..--),,+(+*&)&)%(''&#&%!$!$ #"7664 5 43 4 3 3 2 1 2 1 /0 .//? 0 3 2 / 2 . 10-0,/+..--),,+(+*&)&)%(''&#&%!$!$ #"&''*'(++((+(),***-*?))((*))+**,***,++-,,...--/ . .00 /0 / 1 0 0 2 1 3 3 2 32 4&''*'(++((+(),***-))((*))+**,***,++-,,...--/ . .00 /0 / 1 0 0 2 1 3 3 2 32 4&''*'(++((+(),***-*?))((*))+**,***,++-,,...--/ . .00 /0 / 1 0 0 2 1 3 3 2 32 4?  ?   !?!!     !!!!!"""###$$$$$%%%&&&&&''(  !?!!     !!!!!"""###$$$$$%%%&&&&&''(  !?!!     !!!!!"""###$$$$$%%%&&&&&''(+**))(((''&&&%$$###?%'&$&#%$"$!# ""!!   ! ! "#"#"$%$&%&%'('+**))(((''&&&%$$###'&$&#%$"$!# ""!!   ! ! "#"#"$%$&%&%'('+**))(((''&&&%$$###?%'&$&#%$"$!# ""!!   ! ! "#"#"$%$&%&%'('##$%&&'((()**+,---.?)**+,,-.//01 1 2 3 3 4 5 67889:;<=@##$%&&'((()**+,---.?)**+,,-.//01 1 2 3 3 4 5 67889:;<=@##$%&&'((()**+,---.?)**+,,-.//01 1 2 3 3 4 5 67889:;<=@65555555555555555/.942100/.-,+ + & ) ( ' &%$$#!  "55555555555565555555555555555/.o432210/.- - ( + * ) ('&&%#"!  "55555555555565555555555555555/.942100/.-,+ + & ) ( ' &%$$#!  "555555555555==================;;==========?==================;;==========?==================;;==========?==8?==8?==8?"!!    !!!"##$$%&&'(()*+-   " ?"!!    !!!"##$$%&&'(()*+-   " ?"!!    !!!"##$$%&&'(()*+-   " ?3 54 54657676899:::;<<<====+?3 54 54657676899:::;<<<====+?3 54 54657676899:::;<<<====+?==%?==%?==%?())))**++++,--.../0001 2 2 3 4 5 ?())))**++++,--.../0001 2 2 3 4 5 F())))**++++,--.../0001 2 2 3 4 5 ?()(*+*+,,---./000 1 2 2 3 4 4 5678 ?()(*+*+,,---./000 1 2 2 3 4 4 5678 ?()(*+*+,,---./000 1 2 2 3 4 4 5678 ?==?==?==?655555555555555555236555555...8655555555555555555236555555...8655555555555555555236555555...8gG3#V Drop Shadow     $q5VYFfFrF~FV}zFvB'7GC G)G)W)g)w))))3Iiiiiijjj't#''7GWgwʗ %&'X($()*+T3=- + Uff('Ufmqjvmw&wUmxy&Uwz{%Ux{|$$Umz{|}|~~~~#~x{~#Umw#ꀪ~~~%􎀀"m"Ux}#Uf"Ufv|"Uq"񀪙qy%󀪙{}~~$"󀪀~$󀪀w}"w$w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"- + Uff('Ufmqjvmw&wUmxy&Uwz{%Ux{|$$Umz{|}|~~~~#~x{~#Umw#ꀪ~~~%􎀀"m"Ux}#Uf"Ufv|"Uq"񀪙qy%󀪙{}~~$"󀪀~$󀪀w}"w$w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"- + Uff('Ufmqjvmw&wUmxy&Uwz{%Ux{|$$Umz{|}|~~~~#~x{~#Umw#ꀪ~~~%􎀀"m"Ux}#Uf"Ufv|"Uq"񀪙qy%󀪙{}~~$"󀪀~$󀪀w}"w$w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"0 - +)(  ' &  %  "$'()*++,$,  %)-14689::;$; #*06;@CFIJKLLM#M $,4www <=< ,:,+*);:;:98M9MLKJI`9`_^\Zu9utrqn9888888888888888888888888888888888888888888888888A fU򟀒mvjqmfUxmUzwU|{xU~|}|{zmU{x큂wmU~~~쀁m}xU|fU򁀀|vUqyq~}{~w}ww~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~wA fU򟀒mvjqmfUxmUzwU|{xU~|}|{zmU{x큂wmU~~~쀁m}xU|fU򁀀|vUqyq~}{~w}ww~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~wA fU򟀒mvjqmfUxmUzwU|{xU~|}|{zmU{x큂wmU~~~쀁m}xU|fU򁀀|vUqyq~}{~w}ww~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w+     ('$" 641-)%  FC@;60*# XTOJC<4,$ kfaZRI?6,# ~yrjaVK?4)  zocVI<0% }o`RC5) zjZJ;-" raP?1% øyfTC4' ~kXF6( ǸnZH8* ̽q]J9+ οr^K:+ °t_L:, ±t_L;,  òt`L;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"9888888888888888888888888888888888888888888888888888888888888888988888888888888888888888888888888888888888888888888888888888888898888888888888888888888888888888888888888888888888888888888888889888888888888888888888888888888888888888888888888888888888888888~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~wIJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"9888888888888888888888888888888888888888888888888888888888888888988888888888888888888888888888888888888888888888888888888888888898888888888888888888888888888888888888888888888888888888888888889888888888888888888888888888888888888888888888888888888888888888~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~wIJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"9888888888888888888888888888888888888888888888888888888888888888988888888888888888888888888888888888888888888888888888888888888898888888888888888888888888888888888888888888888888888888888888889888888888888888888888888888888888888888888888888888888888888888~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~wIJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"9888888888888888888888888888888888888888888888888888888888888888988888888888888888888888888888888888888888888888888888888888888898888888888888888888888888888888888888888888888888888888888888889888888888888888888888888888888888888888888888888888888888888888~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~wIJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"9888888888888888888888888888888888888888888888888888888888888888988888888888888888888888888888888888888888888888888888888888888898888888888888888888888888888888888888888888888888888888888888889888888888888888888888888888888888888888888888888888888888888888~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~wIJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w$󀪀w}"󀪀~$"󀪙{}~~$񀪙qy%Uq"Ufv|"Uf"Ux}#m"􎀀"ꀪ~~~%Umw#x{~#Umz{|}|~~~~#~$Ux{|$Uwz{%Umxy&Ufmqjvmw&w' Uff( +-w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w$󀪀w}"󀪀~$"󀪙{}~~$񀪙qy%Uq"Ufv|"Uf"Ux}#m"􎀀"ꀪ~~~%Umw#x{~#Umz{|}|~~~~#~$Ux{|$Uwz{%Umxy&Ufmqjvmw&w' Uff( +-w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w~"w$󀪀w}"󀪀~$"󀪙{}~~$񀪙qy%Uq"Ufv|"Uf"Ux}#m"􎀀"ꀪ~~~%Umw#x{~#Umz{|}|~~~~#~$Ux{|$Uwz{%Umxy&Ufmqjvmw&w' Uff( +-  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;M`u"  ,;L`t" ,;L_t" ,:L_s" +:K^r" *9J]q" )8HZn" (6FXk~" '4CTfy" $1?Oar" "-;JZjz" )5CR`o}" %0>??988888888888888888888888888888888<8:9?;998;88@99~:~~~:;;{=yw>??988888888888888888888888888888888<8:9?;998;88@99~:~~~:;;{=yw>??9888888888888888888888888888888888888888888889u9utrqn`9`_^\ZM9MLKJI;:;:98,:,+*) ; <=> >???~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~ww}w~w~}{yqq򁀀|vU|fU}xU쀁m~~~큂wmU{x~|}|{zmU|{xUzwUxmUmvjqmfU򟀒fU P~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~ww}w~w~}{yqq򁀀|vU|fU}xU쀁m~~~큂wmU{x~|}|{zmU|{xUzwUxmUmvjqmfU򟀒fU P~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~w~ww}w~w~}{yqq򁀀|vU|fU}xU쀁m~~~큂wmU{x~|}|{zmU|{xUzwUxmUmvjqmfU򟀒fU PIJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  IJu`M;,  òt`L;,  ±t_L;,  °t_L:, οr^K:+ ̽q]J9+ ǸnZH8* ~kXF6( øyfTC4' raP?1% zjZJ;-" }o`RC5) zocVI<0% ~yrjaVK?4)  kfaZRI?6,# XTOJC<4,$ FC@;60*# 641-)%  ('$"      :+oJ7% New Layer     GDGhPPQQ IXIhIxIIIIIIIIJJJ(J8JHJXJhJxJJJJJJJJKKK(K8KHKXKhKxKKKKKKKKLLL(L8LHLXLhLxLLLLLLLLMMM(M8MHMXMhMxMMMMMMMMNNN(N8NHNXNhNxNNNNNNNNOOO(O8OHOXOhOxOOOOOOOOPPP(P8PHPXPhPxPPPPPPOOSS))brp-pacu/TODO0000644000175000017500000000207112153127664011730 0ustar miramira#Maybe a menu item with an accelerator for Pink Noise The program should not quit when Jack does not start but stay on hold until jack is fixed and/or started manually. Also, it should not crash when Jack is stopped manually. Change delay buffer to not be dependent on N-FFT so that the maximum system delay is not dependednt on N_FFT and Sample Rates #Achieve Compilation on mingw There should be a warning, and not buff_store.brp ceated. "Resize" lets the line go out of the window Sample Rate should be displayed somewhere Window size, smoothing, and avg_num should be changeable in the UI Make guiY less points, so drawing requires less CPU. #Change const N to another name like N_FFT because it may cause symbol collisions #Change gui to not use N datapoints because this drastically increases processor usage to draw points that aren't visible or useful #Messages written with printf and fprintf to the console will not be read by the average user. These messages are only useful for debugging. Messages that are meant for the user should appear in alert windows. brp-pacu/ige-mac-image-utils.h0000644000175000017500000000174412153127664015137 0ustar miramira/* * Copyright (C) 2007 Imendio AB * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; version 2.1 * of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ #ifndef __IGE_MAC_IMAGE_UTILS_H__ #define __IGE_MAC_IMAGE_UTILS_H__ #include #include G_BEGIN_DECLS CGImageRef ige_mac_image_from_pixbuf (GdkPixbuf *pixbuf); G_END_DECLS #endif /* __IGE_MAC_IMAGE_UTILS_H__ */ brp-pacu/splint.splintrc0000644000175000017500000000245112153127664014333 0ustar miramira-IHeaders -DDEBUGPRINT -systemdirs /usr/include:/usr/local/lib/:/usr/lib +allmacros # check all macros +checks # checks mode (moderately strict checking) ### Display Flags -locindentspaces 0 +showdeephistory +showscan +showsummary +stats +timedist +charindex -allglobals -export +voidabstract +forwarddecl +relaxquals +allmacros ### Assume all while and for loops execute at least once +loopexec ### Naming Convention +czech -czechconstants -enumprefix ~~* -uncheckedmacroprefix ~* ### global variables should start with g_ -globalprefix g_ +globalprefixexclude ### parameters in declarations should start with p_ -protoparamprefix p_ +protoparamprefixexclude ### these flags slow down checking a lot, ### only use on special occasions. ### +distinctinternalnames -internalnamecaseinsensitive +internalnamelookalike # -externalnamelen 24 +sizeoftype +repeatunrecog +topuse +deepbreak +needspec +evalorderuncon -mustmod +iso99limits +allempty +whileblock +forblock +elseifcomplete ### Limit maximimum include nesting -includenest 5 +posixlib ### this should be builtin to pp? -D__i386__ -D_M_IX86 -booltype bool -booltrue TRUE -boolfalse FALSE +numliteral +numabstractindex +numabstractlit -numabstractprint -indentspaces 3 #drl add 11-15-2001 +slashslashcomment brp-pacu/ChangeLog0000644000175000017500000000206212153127664013012 0ustar miramira2010-01-20 Andreas Schwab * gui.glade replaced by BRP_PACU.ui to be processed by GTKBuilder * gui.c (impulse_hide, delay_hide, close_preferences_cb): replaced by gtk_widget_hide_on_delete 2009-12-27 Andreas Schwab * gui.c: correct various casting errors removed various unused variables removed varoius unused return values * BRP_PACU.c removed various unused variables removed varoius unused return values (on_quit): not used, removed (MyGTKFunction): made g_boolean (gtk_timeout_).. replaced by (g_...) (jack_init): return error status (main): use error status, pop message window on unsuccessful jack init * main.h: removed dat, MyGTKFunction * gui.glade: removed unused : set page size to (10 times) * Makefile.am: renamed README-Mac.txt to README when copied to Macintosh distribution removed unused -framework Carbon -lobjc from AM_CFLAGS * README-Mac.txt: added dependencies brp-pacu/INSTALL0000644000175000017500000002243212153127664012274 0ustar miramiraInstallation Instructions ************************* Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005 Free Software Foundation, Inc. This file is free documentation; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. Basic Installation ================== These are generic installation instructions. The `configure' shell script attempts to guess correct values for various system-dependent variables used during compilation. It uses those values to create a `Makefile' in each directory of the package. It may also create one or more `.h' files containing system-dependent definitions. Finally, it creates a shell script `config.status' that you can run in the future to recreate the current configuration, and a file `config.log' containing compiler output (useful mainly for debugging `configure'). It can also use an optional file (typically called `config.cache' and enabled with `--cache-file=config.cache' or simply `-C') that saves the results of its tests to speed up reconfiguring. (Caching is disabled by default to prevent problems with accidental use of stale cache files.) If you need to do unusual things to compile the package, please try to figure out how `configure' could check whether to do them, and mail diffs or instructions to the address given in the `README' so they can be considered for the next release. If you are using the cache, and at some point `config.cache' contains results you don't want to keep, you may remove or edit it. The file `configure.ac' (or `configure.in') is used to create `configure' by a program called `autoconf'. You only need `configure.ac' if you want to change it or regenerate `configure' using a newer version of `autoconf'. The simplest way to compile this package is: 1. `cd' to the directory containing the package's source code and type `./configure' to configure the package for your system. If you're using `csh' on an old version of System V, you might need to type `sh ./configure' instead to prevent `csh' from trying to execute `configure' itself. Running `configure' takes awhile. While running, it prints some messages telling which features it is checking for. 2. Type `make' to compile the package. 3. Optionally, type `make check' to run any self-tests that come with the package. 4. Type `make install' to install the programs and any data files and documentation. 5. You can remove the program binaries and object files from the source code directory by typing `make clean'. To also remove the files that `configure' created (so you can compile the package for a different kind of computer), type `make distclean'. There is also a `make maintainer-clean' target, but that is intended mainly for the package's developers. If you use it, you may have to get all sorts of other programs in order to regenerate files that came with the distribution. Compilers and Options ===================== Some systems require unusual options for compilation or linking that the `configure' script does not know about. Run `./configure --help' for details on some of the pertinent environment variables. You can give `configure' initial values for configuration parameters by setting variables in the command line or in the environment. Here is an example: ./configure CC=c89 CFLAGS=-O2 LIBS=-lposix *Note Defining Variables::, for more details. Compiling For Multiple Architectures ==================================== You can compile the package for more than one kind of computer at the same time, by placing the object files for each architecture in their own directory. To do this, you must use a version of `make' that supports the `VPATH' variable, such as GNU `make'. `cd' to the directory where you want the object files and executables to go and run the `configure' script. `configure' automatically checks for the source code in the directory that `configure' is in and in `..'. If you have to use a `make' that does not support the `VPATH' variable, you have to compile the package for one architecture at a time in the source code directory. After you have installed the package for one architecture, use `make distclean' before reconfiguring for another architecture. Installation Names ================== By default, `make install' installs the package's commands under `/usr/local/bin', include files under `/usr/local/include', etc. You can specify an installation prefix other than `/usr/local' by giving `configure' the option `--prefix=PREFIX'. You can specify separate installation prefixes for architecture-specific files and architecture-independent files. If you pass the option `--exec-prefix=PREFIX' to `configure', the package uses PREFIX as the prefix for installing programs and libraries. Documentation and other data files still use the regular prefix. In addition, if you use an unusual directory layout you can give options like `--bindir=DIR' to specify different values for particular kinds of files. Run `configure --help' for a list of the directories you can set and what kinds of files go in them. If the package supports it, you can cause programs to be installed with an extra prefix or suffix on their names by giving `configure' the option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. Optional Features ================= Some packages pay attention to `--enable-FEATURE' options to `configure', where FEATURE indicates an optional part of the package. They may also pay attention to `--with-PACKAGE' options, where PACKAGE is something like `gnu-as' or `x' (for the X Window System). The `README' should mention any `--enable-' and `--with-' options that the package recognizes. For packages that use the X Window System, `configure' can usually find the X include and library files automatically, but if it doesn't, you can use the `configure' options `--x-includes=DIR' and `--x-libraries=DIR' to specify their locations. Specifying the System Type ========================== There may be some features `configure' cannot figure out automatically, but needs to determine by the type of machine the package will run on. Usually, assuming the package is built to be run on the _same_ architectures, `configure' can figure that out, but if it prints a message saying it cannot guess the machine type, give it the `--build=TYPE' option. TYPE can either be a short name for the system type, such as `sun4', or a canonical name which has the form: CPU-COMPANY-SYSTEM where SYSTEM can have one of these forms: OS KERNEL-OS See the file `config.sub' for the possible values of each field. If `config.sub' isn't included in this package, then this package doesn't need to know the machine type. If you are _building_ compiler tools for cross-compiling, you should use the option `--target=TYPE' to select the type of system they will produce code for. If you want to _use_ a cross compiler, that generates code for a platform different from the build platform, you should specify the "host" platform (i.e., that on which the generated programs will eventually be run) with `--host=TYPE'. Sharing Defaults ================ If you want to set default values for `configure' scripts to share, you can create a site shell script called `config.site' that gives default values for variables like `CC', `cache_file', and `prefix'. `configure' looks for `PREFIX/share/config.site' if it exists, then `PREFIX/etc/config.site' if it exists. Or, you can set the `CONFIG_SITE' environment variable to the location of the site script. A warning: not all `configure' scripts look for a site script. Defining Variables ================== Variables not defined in a site shell script can be set in the environment passed to `configure'. However, some packages may run configure again during the build, and the customized values of these variables may be lost. In order to avoid this problem, you should set them in the `configure' command line, using `VAR=value'. For example: ./configure CC=/usr/local2/bin/gcc causes the specified `gcc' to be used as the C compiler (unless it is overridden in the site shell script). Here is a another example: /bin/bash ./configure CONFIG_SHELL=/bin/bash Here the `CONFIG_SHELL=/bin/bash' operand causes subsequent configuration-related scripts to be executed by `/bin/bash'. `configure' Invocation ====================== `configure' recognizes the following options to control how it operates. `--help' `-h' Print a summary of the options to `configure', and exit. `--version' `-V' Print the version of Autoconf used to generate the `configure' script, and exit. `--cache-file=FILE' Enable the cache: use and save the results of the tests in FILE, traditionally `config.cache'. FILE defaults to `/dev/null' to disable caching. `--config-cache' `-C' Alias for `--cache-file=config.cache'. `--quiet' `--silent' `-q' Do not print messages saying which checks are being made. To suppress all normal output, redirect it to `/dev/null' (any error messages will still be shown). `--srcdir=DIR' Look for the package's source code in directory DIR. Usually `configure' can determine that directory automatically. `configure' also accepts some other, not widely useful, options. Run `configure --help' for more details. brp-pacu/README-Mac.txt0000644000175000017500000000565112153127664013443 0ustar miramiraBRP-PACU for Mac OS X (Intel architecture only) Web site _______________________________________ http://sourceforge.net/projects/brp-pacu Dependencies _______________________________________ You should first download and install: Jack-OS X from http://www.jackosx.com/ Instructions _______________________________________ To install BRP-PACU, drag the BRP-PACU icon into the Application folder. The double-click on BRP-PACU to start. If Jack-OS X is not present or not running, a warning will appear, and Jack Pilot will open. CLick on "Start" on the JackPilot window, then on "Continue"" on the warning box. If Jack Pilot does not open, this means that Jack-OS X is not installed correctly. Never before asked questions ------------------------------------------- What is BRP-PACU? - It is an analysis tool to configure any sound system with an equalizer. It compares the output of the system to the input of the system and allows you to use this data to perform final equalization by matching the results with actual DSP/EQ. How do you do this? - There are many tutorials on doing this, but it takes practice, experience, and a good ear. You could try: http://www.sounddevices.com/notes/usbpre/usbpre-with-sia-smaart-software/ its a brief introduction to the concept, although the USBPre is not supported by linux as of writing this, so you couldn't use it with this software. Try the M-Audio usb preamp, its what I use. You also need a decent omnidirectional calibrated mic (reasonably flat 20Hz-20kHz). Isn't this software basically like what XYZ company sells for $1100? - Yes Why are you giving it away for free? - There currently is no Linux port for any of these programs and I needed one. Also I believe anyone who knows how to perform the transfer function properly on an audio system should be able to without selling your soul with some ridiculous EULA and forking over $1100. The barrier to entry in any market should be knowledge and skill, not overpriced tools. There are many markets already headed in this direction. What if I try it and it doesn't work? - Email me and I can probably figure it out. My email is lm317t@gmail.com. Also try the mailing list, it should be working. Why is there no documentation? - Channel 1 is the output of the system we are observing (measured), channel 2 is the input (reference). You also need a decent calibrated omnidrectional microphone (reasonably flat 20Hz-20kHz) and either a USB-Preamp like the 2-channel M-Audio, or a mixer with a 30dB pad or so going into the laptop mic input. No Pad is neccessary if you are lucky enough to have a laptop or PC with a line input. The headphone out will have the pink noise. How do you handle a delay between measured and referenced signals? - There is an automatic delay finding button. You can also insert a custom delay if you want. Is there a way to find the impulse response? - It is in the menu under action brp-pacu/configure0000755000175000017500000045604012153127664013160 0ustar miramira#! /bin/sh # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.65. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, # Inc. # # # This configure script is free software; the Free Software Foundation # gives unlimited permission to copy, distribute and modify it. ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH if test "x$CONFIG_SHELL" = x; then as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which # is contrary to our usage. Disable this feature. alias -g '\${1+\"\$@\"}'='\"\$@\"' setopt NO_GLOB_SUBST else case \`(set -o) 2>/dev/null\` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi " as_required="as_fn_return () { (exit \$1); } as_fn_success () { as_fn_return 0; } as_fn_failure () { as_fn_return 1; } as_fn_ret_success () { return 0; } as_fn_ret_failure () { return 1; } exitcode=0 as_fn_success || { exitcode=1; echo as_fn_success failed.; } as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : else exitcode=1; echo positional parameters were not saved. fi test x\$exitcode = x0 || exit 1" as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1" if (eval "$as_required") 2>/dev/null; then : as_have_required=yes else as_have_required=no fi if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR as_found=false for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. as_found=: case $as_dir in #( /*) for as_base in sh bash ksh sh5; do # Try only shells that exist, to save several forks. as_shell=$as_dir/$as_base if { test -f "$as_shell" || test -f "$as_shell.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : CONFIG_SHELL=$as_shell as_have_required=yes if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : break 2 fi fi done;; esac as_found=false done $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : CONFIG_SHELL=$SHELL as_have_required=yes fi; } IFS=$as_save_IFS if test "x$CONFIG_SHELL" != x; then : # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV export CONFIG_SHELL exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} fi if test x$as_have_required = xno; then : $as_echo "$0: This script requires a shell more modern than all" $as_echo "$0: the shells that I found on your system." if test x${ZSH_VERSION+set} = xset ; then $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" $as_echo "$0: be upgraded to zsh 4.3.4 or later." else $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, $0: including any error possibly output before this $0: message. Then install a modern shell, or manually run $0: the script under such a shell if you do have one." fi exit 1 fi fi fi SHELL=${CONFIG_SHELL-/bin/sh} export SHELL # Unset more variables known to interfere with behavior of common tools. CLICOLOR_FORCE= GREP_OPTIONS= unset CLICOLOR_FORCE GREP_OPTIONS ## --------------------- ## ## M4sh Shell Functions. ## ## --------------------- ## # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" } # as_fn_mkdir_p # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith # as_fn_error ERROR [LINENO LOG_FD] # --------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with status $?, using 1 if that was 0. as_fn_error () { as_status=$?; test $as_status -eq 0 && as_status=1 if test "$3"; then as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 fi $as_echo "$as_me: error: $1" >&2 as_fn_exit $as_status } # as_fn_error if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits as_lineno_1=$LINENO as_lineno_1a=$LINENO as_lineno_2=$LINENO as_lineno_2a=$LINENO eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) sed -n ' p /[$]LINENO/= ' <$as_myself | sed ' s/[$]LINENO.*/&-/ t lineno b :lineno N :loop s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ t loop s/-\n.*// ' >$as_me.lineno && chmod +x "$as_me.lineno" || { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } # Don't try to exec as it changes $[0], causing all sort of problems # (the dirname of $[0] is not the place where we might find the # original and so on. Autoconf is especially sensitive to this). . "./$as_me.lineno" # Exit status is that of the last command. exit } ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in #( -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" test -n "$DJDIR" || exec 7<&0 &1 # Name of the host. # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, # so uname gets run too. ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` # # Initializations. # ac_default_prefix=/usr/local ac_clean_files= ac_config_libobj_dir=. LIBOBJS= cross_compiling=no subdirs= MFLAGS= MAKEFLAGS= # Identity of this package. PACKAGE_NAME= PACKAGE_TARNAME= PACKAGE_VERSION= PACKAGE_STRING= PACKAGE_BUGREPORT= PACKAGE_URL= ac_subst_vars='JACK_LIBS JACK_CFLAGS GTKDATABOX_LIBS GTKDATABOX_CFLAGS CAIRO_LIBS CAIRO_CFLAGS PANGO_LIBS PANGO_CFLAGS GTK_LIBS GTK_CFLAGS PKG_CONFIG LTLIBOBJS LIBOBJS am__fastdepCC_FALSE am__fastdepCC_TRUE CCDEPMODE AMDEPBACKSLASH AMDEP_FALSE AMDEP_TRUE am__quote am__include DEPDIR OBJEXT EXEEXT ac_ct_CC CPPFLAGS LDFLAGS CFLAGS CC am__untar am__tar AMTAR am__leading_dot SET_MAKE AWK mkdir_p INSTALL_STRIP_PROGRAM STRIP install_sh MAKEINFO AUTOHEADER AUTOMAKE AUTOCONF ACLOCAL VERSION PACKAGE CYGPATH_W INSTALL_DATA INSTALL_SCRIPT INSTALL_PROGRAM PKG_CONFIG_PATH APPLE_FALSE APPLE_TRUE target_alias host_alias build_alias LIBS ECHO_T ECHO_N ECHO_C DEFS mandir localedir libdir psdir pdfdir dvidir htmldir infodir docdir oldincludedir includedir localstatedir sharedstatedir sysconfdir datadir datarootdir libexecdir sbindir bindir program_transform_name prefix exec_prefix PACKAGE_URL PACKAGE_BUGREPORT PACKAGE_STRING PACKAGE_VERSION PACKAGE_TARNAME PACKAGE_NAME PATH_SEPARATOR SHELL' ac_subst_files='' ac_user_opts=' enable_option_checking enable_dependency_tracking ' ac_precious_vars='build_alias host_alias target_alias CC CFLAGS LDFLAGS LIBS CPPFLAGS PKG_CONFIG GTK_CFLAGS GTK_LIBS PANGO_CFLAGS PANGO_LIBS CAIRO_CFLAGS CAIRO_LIBS GTKDATABOX_CFLAGS GTKDATABOX_LIBS JACK_CFLAGS JACK_LIBS' # Initialize some variables set by options. ac_init_help= ac_init_version=false ac_unrecognized_opts= ac_unrecognized_sep= # The variables have the same names as the options, with # dashes changed to underlines. cache_file=/dev/null exec_prefix=NONE no_create= no_recursion= prefix=NONE program_prefix=NONE program_suffix=NONE program_transform_name=s,x,x, silent= site= srcdir= verbose= x_includes=NONE x_libraries=NONE # Installation directory options. # These are left unexpanded so users can "make install exec_prefix=/foo" # and all the variables that are supposed to be based on exec_prefix # by default will actually change. # Use braces instead of parens because sh, perl, etc. also accept them. # (The list follows the same order as the GNU Coding Standards.) bindir='${exec_prefix}/bin' sbindir='${exec_prefix}/sbin' libexecdir='${exec_prefix}/libexec' datarootdir='${prefix}/share' datadir='${datarootdir}' sysconfdir='${prefix}/etc' sharedstatedir='${prefix}/com' localstatedir='${prefix}/var' includedir='${prefix}/include' oldincludedir='/usr/include' docdir='${datarootdir}/doc/${PACKAGE}' infodir='${datarootdir}/info' htmldir='${docdir}' dvidir='${docdir}' pdfdir='${docdir}' psdir='${docdir}' libdir='${exec_prefix}/lib' localedir='${datarootdir}/locale' mandir='${datarootdir}/man' ac_prev= ac_dashdash= for ac_option do # If the previous option needs an argument, assign it. if test -n "$ac_prev"; then eval $ac_prev=\$ac_option ac_prev= continue fi case $ac_option in *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; *) ac_optarg=yes ;; esac # Accept the important Cygnus configure options, so we can diagnose typos. case $ac_dashdash$ac_option in --) ac_dashdash=yes ;; -bindir | --bindir | --bindi | --bind | --bin | --bi) ac_prev=bindir ;; -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) bindir=$ac_optarg ;; -build | --build | --buil | --bui | --bu) ac_prev=build_alias ;; -build=* | --build=* | --buil=* | --bui=* | --bu=*) build_alias=$ac_optarg ;; -cache-file | --cache-file | --cache-fil | --cache-fi \ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) ac_prev=cache_file ;; -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) cache_file=$ac_optarg ;; --config-cache | -C) cache_file=config.cache ;; -datadir | --datadir | --datadi | --datad) ac_prev=datadir ;; -datadir=* | --datadir=* | --datadi=* | --datad=*) datadir=$ac_optarg ;; -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | --dataroo | --dataro | --datar) ac_prev=datarootdir ;; -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) datarootdir=$ac_optarg ;; -disable-* | --disable-*) ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=no ;; -docdir | --docdir | --docdi | --doc | --do) ac_prev=docdir ;; -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) docdir=$ac_optarg ;; -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) ac_prev=dvidir ;; -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) dvidir=$ac_optarg ;; -enable-* | --enable-*) ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error "invalid feature name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "enable_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval enable_$ac_useropt=\$ac_optarg ;; -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | --exec | --exe | --ex) ac_prev=exec_prefix ;; -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | --exec=* | --exe=* | --ex=*) exec_prefix=$ac_optarg ;; -gas | --gas | --ga | --g) # Obsolete; use --with-gas. with_gas=yes ;; -help | --help | --hel | --he | -h) ac_init_help=long ;; -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) ac_init_help=recursive ;; -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) ac_init_help=short ;; -host | --host | --hos | --ho) ac_prev=host_alias ;; -host=* | --host=* | --hos=* | --ho=*) host_alias=$ac_optarg ;; -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) ac_prev=htmldir ;; -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | --ht=*) htmldir=$ac_optarg ;; -includedir | --includedir | --includedi | --included | --include \ | --includ | --inclu | --incl | --inc) ac_prev=includedir ;; -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | --includ=* | --inclu=* | --incl=* | --inc=*) includedir=$ac_optarg ;; -infodir | --infodir | --infodi | --infod | --info | --inf) ac_prev=infodir ;; -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) infodir=$ac_optarg ;; -libdir | --libdir | --libdi | --libd) ac_prev=libdir ;; -libdir=* | --libdir=* | --libdi=* | --libd=*) libdir=$ac_optarg ;; -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | --libexe | --libex | --libe) ac_prev=libexecdir ;; -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | --libexe=* | --libex=* | --libe=*) libexecdir=$ac_optarg ;; -localedir | --localedir | --localedi | --localed | --locale) ac_prev=localedir ;; -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) localedir=$ac_optarg ;; -localstatedir | --localstatedir | --localstatedi | --localstated \ | --localstate | --localstat | --localsta | --localst | --locals) ac_prev=localstatedir ;; -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) localstatedir=$ac_optarg ;; -mandir | --mandir | --mandi | --mand | --man | --ma | --m) ac_prev=mandir ;; -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) mandir=$ac_optarg ;; -nfp | --nfp | --nf) # Obsolete; use --without-fp. with_fp=no ;; -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | --no-cr | --no-c | -n) no_create=yes ;; -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) no_recursion=yes ;; -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | --oldin | --oldi | --old | --ol | --o) ac_prev=oldincludedir ;; -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) oldincludedir=$ac_optarg ;; -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) ac_prev=prefix ;; -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) prefix=$ac_optarg ;; -program-prefix | --program-prefix | --program-prefi | --program-pref \ | --program-pre | --program-pr | --program-p) ac_prev=program_prefix ;; -program-prefix=* | --program-prefix=* | --program-prefi=* \ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) program_prefix=$ac_optarg ;; -program-suffix | --program-suffix | --program-suffi | --program-suff \ | --program-suf | --program-su | --program-s) ac_prev=program_suffix ;; -program-suffix=* | --program-suffix=* | --program-suffi=* \ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) program_suffix=$ac_optarg ;; -program-transform-name | --program-transform-name \ | --program-transform-nam | --program-transform-na \ | --program-transform-n | --program-transform- \ | --program-transform | --program-transfor \ | --program-transfo | --program-transf \ | --program-trans | --program-tran \ | --progr-tra | --program-tr | --program-t) ac_prev=program_transform_name ;; -program-transform-name=* | --program-transform-name=* \ | --program-transform-nam=* | --program-transform-na=* \ | --program-transform-n=* | --program-transform-=* \ | --program-transform=* | --program-transfor=* \ | --program-transfo=* | --program-transf=* \ | --program-trans=* | --program-tran=* \ | --progr-tra=* | --program-tr=* | --program-t=*) program_transform_name=$ac_optarg ;; -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) ac_prev=pdfdir ;; -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) pdfdir=$ac_optarg ;; -psdir | --psdir | --psdi | --psd | --ps) ac_prev=psdir ;; -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) psdir=$ac_optarg ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) silent=yes ;; -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) ac_prev=sbindir ;; -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | --sbi=* | --sb=*) sbindir=$ac_optarg ;; -sharedstatedir | --sharedstatedir | --sharedstatedi \ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | --sharedst | --shareds | --shared | --share | --shar \ | --sha | --sh) ac_prev=sharedstatedir ;; -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | --sha=* | --sh=*) sharedstatedir=$ac_optarg ;; -site | --site | --sit) ac_prev=site ;; -site=* | --site=* | --sit=*) site=$ac_optarg ;; -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) ac_prev=srcdir ;; -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) srcdir=$ac_optarg ;; -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | --syscon | --sysco | --sysc | --sys | --sy) ac_prev=sysconfdir ;; -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) sysconfdir=$ac_optarg ;; -target | --target | --targe | --targ | --tar | --ta | --t) ac_prev=target_alias ;; -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) target_alias=$ac_optarg ;; -v | -verbose | --verbose | --verbos | --verbo | --verb) verbose=yes ;; -version | --version | --versio | --versi | --vers | -V) ac_init_version=: ;; -with-* | --with-*) ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=\$ac_optarg ;; -without-* | --without-*) ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` # Reject names that are not valid shell variable names. expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && as_fn_error "invalid package name: $ac_useropt" ac_useropt_orig=$ac_useropt ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` case $ac_user_opts in *" "with_$ac_useropt" "*) ;; *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" ac_unrecognized_sep=', ';; esac eval with_$ac_useropt=no ;; --x) # Obsolete; use --with-x. with_x=yes ;; -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | --x-incl | --x-inc | --x-in | --x-i) ac_prev=x_includes ;; -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) x_includes=$ac_optarg ;; -x-libraries | --x-libraries | --x-librarie | --x-librari \ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) ac_prev=x_libraries ;; -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) x_libraries=$ac_optarg ;; -*) as_fn_error "unrecognized option: \`$ac_option' Try \`$0 --help' for more information." ;; *=*) ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` # Reject names that are not valid shell variable names. case $ac_envvar in #( '' | [0-9]* | *[!_$as_cr_alnum]* ) as_fn_error "invalid variable name: \`$ac_envvar'" ;; esac eval $ac_envvar=\$ac_optarg export $ac_envvar ;; *) # FIXME: should be removed in autoconf 3.0. $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} ;; esac done if test -n "$ac_prev"; then ac_option=--`echo $ac_prev | sed 's/_/-/g'` as_fn_error "missing argument to $ac_option" fi if test -n "$ac_unrecognized_opts"; then case $enable_option_checking in no) ;; fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; esac fi # Check all directory arguments for consistency. for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ datadir sysconfdir sharedstatedir localstatedir includedir \ oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ libdir localedir mandir do eval ac_val=\$$ac_var # Remove trailing slashes. case $ac_val in */ ) ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` eval $ac_var=\$ac_val;; esac # Be sure to have absolute directory names. case $ac_val in [\\/$]* | ?:[\\/]* ) continue;; NONE | '' ) case $ac_var in *prefix ) continue;; esac;; esac as_fn_error "expected an absolute directory name for --$ac_var: $ac_val" done # There might be people who depend on the old broken behavior: `$host' # used to hold the argument of --host etc. # FIXME: To remove some day. build=$build_alias host=$host_alias target=$target_alias # FIXME: To remove some day. if test "x$host_alias" != x; then if test "x$build_alias" = x; then cross_compiling=maybe $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used." >&2 elif test "x$build_alias" != "x$host_alias"; then cross_compiling=yes fi fi ac_tool_prefix= test -n "$host_alias" && ac_tool_prefix=$host_alias- test "$silent" = yes && exec 6>/dev/null ac_pwd=`pwd` && test -n "$ac_pwd" && ac_ls_di=`ls -di .` && ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || as_fn_error "working directory cannot be determined" test "X$ac_ls_di" = "X$ac_pwd_ls_di" || as_fn_error "pwd does not report name of working directory" # Find the source files, if location was not specified. if test -z "$srcdir"; then ac_srcdir_defaulted=yes # Try the directory containing this script, then the parent directory. ac_confdir=`$as_dirname -- "$as_myself" || $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_myself" : 'X\(//\)[^/]' \| \ X"$as_myself" : 'X\(//\)$' \| \ X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_myself" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` srcdir=$ac_confdir if test ! -r "$srcdir/$ac_unique_file"; then srcdir=.. fi else ac_srcdir_defaulted=no fi if test ! -r "$srcdir/$ac_unique_file"; then test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" fi ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" ac_abs_confdir=`( cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg" pwd)` # When building in place, set srcdir=. if test "$ac_abs_confdir" = "$ac_pwd"; then srcdir=. fi # Remove unnecessary trailing slashes from srcdir. # Double slashes in file names in object file debugging info # mess up M-x gdb in Emacs. case $srcdir in */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; esac for ac_var in $ac_precious_vars; do eval ac_env_${ac_var}_set=\${${ac_var}+set} eval ac_env_${ac_var}_value=\$${ac_var} eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} eval ac_cv_env_${ac_var}_value=\$${ac_var} done # # Report the --help message. # if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF \`configure' configures this package to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... To assign environment variables (e.g., CC, CFLAGS...), specify them as VAR=VALUE. See below for descriptions of some of the useful variables. Defaults for the options are specified in brackets. Configuration: -h, --help display this help and exit --help=short display options specific to this package --help=recursive display the short help of all the included packages -V, --version display version information and exit -q, --quiet, --silent do not print \`checking...' messages --cache-file=FILE cache test results in FILE [disabled] -C, --config-cache alias for \`--cache-file=config.cache' -n, --no-create do not create output files --srcdir=DIR find the sources in DIR [configure dir or \`..'] Installation directories: --prefix=PREFIX install architecture-independent files in PREFIX [$ac_default_prefix] --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX [PREFIX] By default, \`make install' will install all the files in \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify an installation prefix other than \`$ac_default_prefix' using \`--prefix', for instance \`--prefix=\$HOME'. For better control, use the options below. Fine tuning of the installation directories: --bindir=DIR user executables [EPREFIX/bin] --sbindir=DIR system admin executables [EPREFIX/sbin] --libexecdir=DIR program executables [EPREFIX/libexec] --sysconfdir=DIR read-only single-machine data [PREFIX/etc] --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] --localstatedir=DIR modifiable single-machine data [PREFIX/var] --libdir=DIR object code libraries [EPREFIX/lib] --includedir=DIR C header files [PREFIX/include] --oldincludedir=DIR C header files for non-gcc [/usr/include] --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] --datadir=DIR read-only architecture-independent data [DATAROOTDIR] --infodir=DIR info documentation [DATAROOTDIR/info] --localedir=DIR locale-dependent data [DATAROOTDIR/locale] --mandir=DIR man documentation [DATAROOTDIR/man] --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] --htmldir=DIR html documentation [DOCDIR] --dvidir=DIR dvi documentation [DOCDIR] --pdfdir=DIR pdf documentation [DOCDIR] --psdir=DIR ps documentation [DOCDIR] _ACEOF cat <<\_ACEOF Program names: --program-prefix=PREFIX prepend PREFIX to installed program names --program-suffix=SUFFIX append SUFFIX to installed program names --program-transform-name=PROGRAM run sed PROGRAM on installed program names _ACEOF fi if test -n "$ac_init_help"; then cat <<\_ACEOF Optional Features: --disable-option-checking ignore unrecognized --enable/--with options --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) --enable-FEATURE[=ARG] include FEATURE [ARG=yes] --disable-dependency-tracking speeds up one-time build --enable-dependency-tracking do not reject slow dependency extractors Some influential environment variables: CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -L if you have libraries in a nonstandard directory LIBS libraries to pass to the linker, e.g. -l CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if you have headers in a nonstandard directory PKG_CONFIG path to pkg-config utility GTK_CFLAGS C compiler flags for GTK, overriding pkg-config GTK_LIBS linker flags for GTK, overriding pkg-config PANGO_CFLAGS C compiler flags for PANGO, overriding pkg-config PANGO_LIBS linker flags for PANGO, overriding pkg-config CAIRO_CFLAGS C compiler flags for CAIRO, overriding pkg-config CAIRO_LIBS linker flags for CAIRO, overriding pkg-config GTKDATABOX_CFLAGS C compiler flags for GTKDATABOX, overriding pkg-config GTKDATABOX_LIBS linker flags for GTKDATABOX, overriding pkg-config JACK_CFLAGS C compiler flags for JACK, overriding pkg-config JACK_LIBS linker flags for JACK, overriding pkg-config Use these variables to override the choices made by `configure' or to help it to find libraries and programs with nonstandard names/locations. Report bugs to the package provider. _ACEOF ac_status=$? fi if test "$ac_init_help" = "recursive"; then # If there are subdirs, report their specific --help. for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue test -d "$ac_dir" || { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || continue ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix cd "$ac_dir" || { ac_status=$?; continue; } # Check for guested configure. if test -f "$ac_srcdir/configure.gnu"; then echo && $SHELL "$ac_srcdir/configure.gnu" --help=recursive elif test -f "$ac_srcdir/configure"; then echo && $SHELL "$ac_srcdir/configure" --help=recursive else $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 fi || ac_status=$? cd "$ac_pwd" || { ac_status=$?; break; } done fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF configure generated by GNU Autoconf 2.65 Copyright (C) 2009 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it. _ACEOF exit fi ## ------------------------ ## ## Autoconf initialization. ## ## ------------------------ ## # ac_fn_c_try_compile LINENO # -------------------------- # Try to compile conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_compile () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest.$ac_objext; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} as_fn_set_status $ac_retval } # ac_fn_c_try_compile # ac_fn_c_try_link LINENO # ----------------------- # Try to link conftest.$ac_ext, and return whether this succeeded. ac_fn_c_try_link () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack rm -f conftest.$ac_objext conftest$ac_exeext if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>conftest.err ac_status=$? if test -s conftest.err; then grep -v '^ *+' conftest.err >conftest.er1 cat conftest.er1 >&5 mv -f conftest.er1 conftest.err fi $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } && { test -z "$ac_c_werror_flag" || test ! -s conftest.err } && test -s conftest$ac_exeext && { test "$cross_compiling" = yes || $as_test_x conftest$ac_exeext }; then : ac_retval=0 else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} as_fn_set_status $ac_retval } # ac_fn_c_try_link cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. It was created by $as_me, which was generated by GNU Autoconf 2.65. Invocation command line was $ $0 $@ _ACEOF exec 5>>config.log { cat <<_ASUNAME ## --------- ## ## Platform. ## ## --------- ## hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` uname -m = `(uname -m) 2>/dev/null || echo unknown` uname -r = `(uname -r) 2>/dev/null || echo unknown` uname -s = `(uname -s) 2>/dev/null || echo unknown` uname -v = `(uname -v) 2>/dev/null || echo unknown` /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` _ASUNAME as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. $as_echo "PATH: $as_dir" done IFS=$as_save_IFS } >&5 cat >&5 <<_ACEOF ## ----------- ## ## Core tests. ## ## ----------- ## _ACEOF # Keep a trace of the command line. # Strip out --no-create and --no-recursion so they do not pile up. # Strip out --silent because we don't want to record it for future runs. # Also quote any args containing shell meta-characters. # Make two passes to allow for proper duplicate-argument suppression. ac_configure_args= ac_configure_args0= ac_configure_args1= ac_must_keep_next=false for ac_pass in 1 2 do for ac_arg do case $ac_arg in -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil) continue ;; *\'*) ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; esac case $ac_pass in 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 2) as_fn_append ac_configure_args1 " '$ac_arg'" if test $ac_must_keep_next = true; then ac_must_keep_next=false # Got value, back to normal. else case $ac_arg in *=* | --config-cache | -C | -disable-* | --disable-* \ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | -with-* | --with-* | -without-* | --without-* | --x) case "$ac_configure_args0 " in "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; esac ;; -* ) ac_must_keep_next=true ;; esac fi as_fn_append ac_configure_args " '$ac_arg'" ;; esac done done { ac_configure_args0=; unset ac_configure_args0;} { ac_configure_args1=; unset ac_configure_args1;} # When interrupted or exit'd, cleanup temporary files, and complete # config.log. We remove comments because anyway the quotes in there # would cause problems or look ugly. # WARNING: Use '\'' to represent an apostrophe within the trap. # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. trap 'exit_status=$? # Save into config.log some information that might help in debugging. { echo cat <<\_ASBOX ## ---------------- ## ## Cache variables. ## ## ---------------- ## _ASBOX echo # The following way of writing the cache mishandles newlines in values, ( for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( *${as_nl}ac_space=\ *) sed -n \ "s/'\''/'\''\\\\'\'''\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" ;; #( *) sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) echo cat <<\_ASBOX ## ----------------- ## ## Output variables. ## ## ----------------- ## _ASBOX echo for ac_var in $ac_subst_vars do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo if test -n "$ac_subst_files"; then cat <<\_ASBOX ## ------------------- ## ## File substitutions. ## ## ------------------- ## _ASBOX echo for ac_var in $ac_subst_files do eval ac_val=\$$ac_var case $ac_val in *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; esac $as_echo "$ac_var='\''$ac_val'\''" done | sort echo fi if test -s confdefs.h; then cat <<\_ASBOX ## ----------- ## ## confdefs.h. ## ## ----------- ## _ASBOX echo cat confdefs.h echo fi test "$ac_signal" != 0 && $as_echo "$as_me: caught signal $ac_signal" $as_echo "$as_me: exit $exit_status" } >&5 rm -f core *.core core.conftest.* && rm -f -r conftest* confdefs* conf$$* $ac_clean_files && exit $exit_status ' 0 for ac_signal in 1 2 13 15; do trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal done ac_signal=0 # confdefs.h avoids OS command line length limits that DEFS can exceed. rm -f -r conftest* confdefs.h $as_echo "/* confdefs.h */" > confdefs.h # Predefined preprocessor variables. cat >>confdefs.h <<_ACEOF #define PACKAGE_NAME "$PACKAGE_NAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_TARNAME "$PACKAGE_TARNAME" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_VERSION "$PACKAGE_VERSION" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_STRING "$PACKAGE_STRING" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" _ACEOF cat >>confdefs.h <<_ACEOF #define PACKAGE_URL "$PACKAGE_URL" _ACEOF # Let the site file select an alternate cache file if it wants to. # Prefer an explicitly selected file to automatically selected ones. ac_site_file1=NONE ac_site_file2=NONE if test -n "$CONFIG_SITE"; then ac_site_file1=$CONFIG_SITE elif test "x$prefix" != xNONE; then ac_site_file1=$prefix/share/config.site ac_site_file2=$prefix/etc/config.site else ac_site_file1=$ac_default_prefix/share/config.site ac_site_file2=$ac_default_prefix/etc/config.site fi for ac_site_file in "$ac_site_file1" "$ac_site_file2" do test "x$ac_site_file" = xNONE && continue if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 $as_echo "$as_me: loading site script $ac_site_file" >&6;} sed 's/^/| /' "$ac_site_file" >&5 . "$ac_site_file" fi done if test -r "$cache_file"; then # Some versions of bash will fail to source /dev/null (special files # actually), so we avoid doing that. DJGPP emulates it as a regular file. if test /dev/null != "$cache_file" && test -f "$cache_file"; then { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 $as_echo "$as_me: loading cache $cache_file" >&6;} case $cache_file in [\\/]* | ?:[\\/]* ) . "$cache_file";; *) . "./$cache_file";; esac fi else { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 $as_echo "$as_me: creating cache $cache_file" >&6;} >$cache_file fi # Check that the precious variables saved in the cache have kept the same # value. ac_cache_corrupted=false for ac_var in $ac_precious_vars; do eval ac_old_set=\$ac_cv_env_${ac_var}_set eval ac_new_set=\$ac_env_${ac_var}_set eval ac_old_val=\$ac_cv_env_${ac_var}_value eval ac_new_val=\$ac_env_${ac_var}_value case $ac_old_set,$ac_new_set in set,) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} ac_cache_corrupted=: ;; ,set) { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} ac_cache_corrupted=: ;; ,);; *) if test "x$ac_old_val" != "x$ac_new_val"; then # differences in whitespace do not lead to failure. ac_old_val_w=`echo x $ac_old_val` ac_new_val_w=`echo x $ac_new_val` if test "$ac_old_val_w" != "$ac_new_val_w"; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} ac_cache_corrupted=: else { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} eval $ac_var=\$ac_old_val fi { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} fi;; esac # Pass precious variables to config.status. if test "$ac_new_set" = set; then case $ac_new_val in *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; *) ac_arg=$ac_var=$ac_new_val ;; esac case " $ac_configure_args " in *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. *) as_fn_append ac_configure_args " '$ac_arg'" ;; esac fi done if $ac_cache_corrupted; then { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 fi ## -------------------- ## ## Main body of script. ## ## -------------------- ## ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu ########## Macintosh implementation ######### if [ `uname` = 'Darwin' ] then if [ -n "PKG_CONFIG_PATH" ] # Assume that PGK is installed with jhbuild in the home directory then PKG_CONFIG_PATH='/usr/lib/pkgconfig/:/usr/local/lib/pkgconfig/:'$HOME'/gtk/inst/lib/pkgconfig' export PKG_CONFIG_PATH fi fi if test `uname` = 'Darwin'; then APPLE_TRUE= APPLE_FALSE='#' else APPLE_TRUE='#' APPLE_FALSE= fi ############################################# ac_config_headers="$ac_config_headers config.h" am__api_version="1.9" ac_aux_dir= for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do for ac_t in install-sh install.sh shtool; do if test -f "$ac_dir/$ac_t"; then ac_aux_dir=$ac_dir ac_install_sh="$ac_aux_dir/$ac_t -c" break 2 fi done done if test -z "$ac_aux_dir"; then as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 fi # These three variables are undocumented and unsupported, # and are intended to be withdrawn in a future Autoconf release. # They can cause serious problems if a builder's source tree is in a directory # whose full name contains unusual characters. ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. # Find a good install program. We prefer a C program (faster), # so one script is as good as another. But avoid the broken or # incompatible versions: # SysV /etc/install, /usr/sbin/install # SunOS /usr/etc/install # IRIX /sbin/install # AIX /bin/install # AmigaOS /C/install, which installs bootblocks on floppy discs # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag # AFS /usr/afsws/bin/install, which mishandles nonexistent args # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" # OS/2's system install, which has a completely different semantic # ./install, which can be erroneously created by make from ./install.sh. # Reject install programs that cannot install multiple files. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then if test "${ac_cv_path_install+set}" = set; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. # Account for people who put trailing slashes in PATH elements. case $as_dir/ in #(( ./ | .// | /[cC]/* | \ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ /usr/ucb/* ) ;; *) # OSF1 and SCO ODT 3.0 have their own names for install. # Don't use installbsd from OSF since it installs stuff as root # by default. for ac_prog in ginstall scoinst install; do for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then if test $ac_prog = install && grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # AIX install. It has an incompatible calling convention. : elif test $ac_prog = install && grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then # program-specific install script used by HP pwplus--don't use. : else rm -rf conftest.one conftest.two conftest.dir echo one > conftest.one echo two > conftest.two mkdir conftest.dir if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && test -s conftest.one && test -s conftest.two && test -s conftest.dir/conftest.one && test -s conftest.dir/conftest.two then ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" break 3 fi fi fi done done ;; esac done IFS=$as_save_IFS rm -rf conftest.one conftest.two conftest.dir fi if test "${ac_cv_path_install+set}" = set; then INSTALL=$ac_cv_path_install else # As a last resort, use the slow shell script. Don't cache a # value for INSTALL within a source directory, because that will # break other packages using the cache if that directory is # removed, or if the value is a relative name. INSTALL=$ac_install_sh fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 $as_echo "$INSTALL" >&6; } # Use test -z because SunOS4 sh mishandles braces in ${var-val}. # It thinks the first close brace ends the variable substitution. test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 $as_echo_n "checking whether build environment is sane... " >&6; } # Just in case sleep 1 echo timestamp > conftest.file # Do `set' in a subshell so we don't clobber the current shell's # arguments. Must try -L first in case configure is actually a # symlink; some systems play weird games with the mod time of symlinks # (eg FreeBSD returns the mod time of the symlink's containing # directory). if ( set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null` if test "$*" = "X"; then # -L didn't work. set X `ls -t $srcdir/configure conftest.file` fi rm -f conftest.file if test "$*" != "X $srcdir/configure conftest.file" \ && test "$*" != "X conftest.file $srcdir/configure"; then # If neither matched, then we have a broken ls. This can happen # if, for instance, CONFIG_SHELL is bash and it inherits a # broken ls alias from the environment. This has actually # happened. Such a system could not be considered "sane". as_fn_error "ls -t appears to fail. Make sure there is not a broken alias in your environment" "$LINENO" 5 fi test "$2" = conftest.file ) then # Ok. : else as_fn_error "newly created file is older than distributed files! Check your system clock" "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } test "$program_prefix" != NONE && program_transform_name="s&^&$program_prefix&;$program_transform_name" # Use a double $ so make ignores it. test "$program_suffix" != NONE && program_transform_name="s&\$&$program_suffix&;$program_transform_name" # Double any \ or $. # By default was `s,x,x', remove it if useless. ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` # expand $ac_aux_dir to an absolute path am_aux_dir=`cd $ac_aux_dir && pwd` test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing" # Use eval to expand $SHELL if eval "$MISSING --run true"; then am_missing_run="$MISSING --run " else am_missing_run= { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} fi if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then # We used to keeping the `.' as first argument, in order to # allow $(mkdir_p) to be used without argument. As in # $(mkdir_p) $(somedir) # where $(somedir) is conditionally defined. However this is wrong # for two reasons: # 1. if the package is installed by a user who cannot write `.' # make install will fail, # 2. the above comment should most certainly read # $(mkdir_p) $(DESTDIR)$(somedir) # so it does not work when $(somedir) is undefined and # $(DESTDIR) is not. # To support the latter case, we have to write # test -z "$(somedir)" || $(mkdir_p) $(DESTDIR)$(somedir), # so the `.' trick is pointless. mkdir_p='mkdir -p --' else # On NextStep and OpenStep, the `mkdir' command does not # recognize any option. It will interpret all options as # directories to create, and then abort because `.' already # exists. for d in ./-p ./--version; do test -d $d && rmdir $d done # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists. if test -f "$ac_aux_dir/mkinstalldirs"; then mkdir_p='$(mkinstalldirs)' else mkdir_p='$(install_sh) -d' fi fi for ac_prog in gawk mawk nawk awk do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_AWK+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$AWK"; then ac_cv_prog_AWK="$AWK" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_AWK="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi AWK=$ac_cv_prog_AWK if test -n "$AWK"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 $as_echo "$AWK" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$AWK" && break done { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } set x ${MAKE-make} ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : $as_echo_n "(cached) " >&6 else cat >conftest.make <<\_ACEOF SHELL = /bin/sh all: @echo '@@@%%%=$(MAKE)=@@@%%%' _ACEOF # GNU make sometimes prints "make[1]: Entering...", which would confuse us. case `${MAKE-make} -f conftest.make 2>/dev/null` in *@@@%%%=?*=@@@%%%*) eval ac_cv_prog_make_${ac_make}_set=yes;; *) eval ac_cv_prog_make_${ac_make}_set=no;; esac rm -f conftest.make fi if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } SET_MAKE= else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } SET_MAKE="MAKE=${MAKE-make}" fi rm -rf .tst 2>/dev/null mkdir .tst 2>/dev/null if test -d .tst; then am__leading_dot=. else am__leading_dot=_ fi rmdir .tst 2>/dev/null # test to see if srcdir already configured if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 fi # test whether we have cygpath if test -z "$CYGPATH_W"; then if (cygpath --version) >/dev/null 2>/dev/null; then CYGPATH_W='cygpath -w' else CYGPATH_W=echo fi fi # Define the identity of the package. PACKAGE=BRP_PACU VERSION=2.1.1 cat >>confdefs.h <<_ACEOF #define PACKAGE "$PACKAGE" _ACEOF cat >>confdefs.h <<_ACEOF #define VERSION "$VERSION" _ACEOF # Some tools Automake needs. ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} install_sh=${install_sh-"$am_aux_dir/install-sh"} # Installed binaries are usually stripped using `strip' when the user # run `make install-strip'. However `strip' might not be the right # tool to use in cross-compilation environments, therefore Automake # will honor the `STRIP' environment variable to overrule this program. if test "$cross_compiling" != no; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. set dummy ${ac_tool_prefix}strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_STRIP+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$STRIP"; then ac_cv_prog_STRIP="$STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_STRIP="${ac_tool_prefix}strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi STRIP=$ac_cv_prog_STRIP if test -n "$STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 $as_echo "$STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_STRIP"; then ac_ct_STRIP=$STRIP # Extract the first word of "strip", so it can be a program name with args. set dummy strip; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_STRIP"; then ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_STRIP="strip" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP if test -n "$ac_ct_STRIP"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 $as_echo "$ac_ct_STRIP" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_STRIP" = x; then STRIP=":" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac STRIP=$ac_ct_STRIP fi else STRIP="$ac_cv_prog_STRIP" fi fi INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s" # We need awk for the "check" target. The system "awk" is bad on # some platforms. # Always define AMTAR for backward compatibility. AMTAR=${AMTAR-"${am_missing_run}tar"} am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_prog_CC"; then ac_ct_CC=$CC # Extract the first word of "gcc", so it can be a program name with args. set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="gcc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi else CC="$ac_cv_prog_CC" fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="${ac_tool_prefix}cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi fi if test -z "$CC"; then # Extract the first word of "cc", so it can be a program name with args. set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else ac_prog_rejected=no as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then ac_prog_rejected=yes continue fi ac_cv_prog_CC="cc" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS if test $ac_prog_rejected = yes; then # We found a bogon in the path, so make sure we never use it. set dummy $ac_cv_prog_CC shift if test $# != 0; then # We chose a different compiler from the bogus one. # However, it has the same basename, so the bogon will be chosen # first if we set CC to just the basename; use the full file name. shift ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" fi fi fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$CC"; then if test -n "$ac_tool_prefix"; then for ac_prog in cl.exe do # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then ac_cv_prog_CC="$CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_CC="$ac_tool_prefix$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi CC=$ac_cv_prog_CC if test -n "$CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 $as_echo "$CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$CC" && break done fi if test -z "$CC"; then ac_ct_CC=$CC for ac_prog in cl.exe do # Extract the first word of "$ac_prog", so it can be a program name with args. set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_prog_ac_ct_CC="$ac_prog" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS fi fi ac_ct_CC=$ac_cv_prog_ac_ct_CC if test -n "$ac_ct_CC"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 $as_echo "$ac_ct_CC" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi test -n "$ac_ct_CC" && break done if test "x$ac_ct_CC" = x; then CC="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac CC=$ac_ct_CC fi fi fi test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "no acceptable C compiler found in \$PATH See \`config.log' for more details." "$LINENO" 5; } # Provide some information about the compiler. $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 set X $ac_compile ac_compiler=$2 for ac_option in --version -v -V -qversion; do { { ac_try="$ac_compiler $ac_option >&5" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compiler $ac_option >&5") 2>conftest.err ac_status=$? if test -s conftest.err; then sed '10a\ ... rest of stderr output deleted ... 10q' conftest.err >conftest.er1 cat conftest.er1 >&5 fi rm -f conftest.er1 conftest.err $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } done cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" # Try to create an executable without -o first, disregard a.out. # It will help us diagnose broken compilers, and finding out an intuition # of exeext. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 $as_echo_n "checking whether the C compiler works... " >&6; } ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` # The possible output files: ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" ac_rmfiles= for ac_file in $ac_files do case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; * ) ac_rmfiles="$ac_rmfiles $ac_file";; esac done rm -f $ac_rmfiles if { { ac_try="$ac_link_default" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link_default") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' # in a Makefile. We should not override ac_cv_exeext if it was cached, # so that the user can short-circuit this test for compilers unknown to # Autoconf. for ac_file in $ac_files '' do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; [ab].out ) # We found the default executable, but exeext='' is most # certainly right. break;; *.* ) if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; then :; else ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` fi # We set ac_cv_exeext here because the later test for it is not # safe: cross compilers may not add the suffix if given an `-o' # argument, so we may need to know it at that point already. # Even if this section looks crufty: it has the advantage of # actually working. break;; * ) break;; esac done test "$ac_cv_exeext" = no && ac_cv_exeext= else ac_file='' fi if test -z "$ac_file"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} { as_fn_set_status 77 as_fn_error "C compiler cannot create executables See \`config.log' for more details." "$LINENO" 5; }; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 $as_echo_n "checking for C compiler default output file name... " >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 $as_echo "$ac_file" >&6; } ac_exeext=$ac_cv_exeext rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 $as_echo_n "checking for suffix of executables... " >&6; } if { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : # If both `conftest.exe' and `conftest' are `present' (well, observable) # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will # work properly (i.e., refer to `conftest.exe'), while it won't with # `rm'. for ac_file in conftest.exe conftest conftest.*; do test -f "$ac_file" || continue case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` break;; * ) break;; esac done else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot compute suffix of executables: cannot compile and link See \`config.log' for more details." "$LINENO" 5; } fi rm -f conftest conftest$ac_cv_exeext { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 $as_echo "$ac_cv_exeext" >&6; } rm -f conftest.$ac_ext EXEEXT=$ac_cv_exeext ac_exeext=$EXEEXT cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include int main () { FILE *f = fopen ("conftest.out", "w"); return ferror (f) || fclose (f) != 0; ; return 0; } _ACEOF ac_clean_files="$ac_clean_files conftest.out" # Check that the compiler produces executables we can run. If not, either # the compiler is broken, or we cross compile. { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 $as_echo_n "checking whether we are cross compiling... " >&6; } if test "$cross_compiling" != yes; then { { ac_try="$ac_link" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_link") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; } if { ac_try='./conftest$ac_cv_exeext' { { case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_try") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; }; then cross_compiling=no else if test "$cross_compiling" = maybe; then cross_compiling=yes else { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot run C compiled programs. If you meant to cross compile, use \`--host'. See \`config.log' for more details." "$LINENO" 5; } fi fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 $as_echo "$cross_compiling" >&6; } rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } if test "${ac_cv_objext+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF rm -f conftest.o conftest.obj if { { ac_try="$ac_compile" case "(($ac_try" in *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; *) ac_try_echo=$ac_try;; esac eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" $as_echo "$ac_try_echo"; } >&5 (eval "$ac_compile") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then : for ac_file in conftest.o conftest.obj conftest.*; do test -f "$ac_file" || continue; case $ac_file in *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` break;; esac done else $as_echo "$as_me: failed program was:" >&5 sed 's/^/| /' conftest.$ac_ext >&5 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} as_fn_error "cannot compute suffix of object files: cannot compile See \`config.log' for more details." "$LINENO" 5; } fi rm -f conftest.$ac_cv_objext conftest.$ac_ext fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 $as_echo "$ac_cv_objext" >&6; } OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } if test "${ac_cv_c_compiler_gnu+set}" = set; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { #ifndef __GNUC__ choke me #endif ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_compiler_gnu=yes else ac_compiler_gnu=no fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_cv_c_compiler_gnu=$ac_compiler_gnu fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 $as_echo "$ac_cv_c_compiler_gnu" >&6; } if test $ac_compiler_gnu = yes; then GCC=yes else GCC= fi ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } if test "${ac_cv_prog_cc_g+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag ac_c_werror_flag=yes ac_cv_prog_cc_g=no CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes else CFLAGS="" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : else ac_c_werror_flag=$ac_save_c_werror_flag CFLAGS="-g" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ int main () { ; return 0; } _ACEOF if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_g=yes fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext fi rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext ac_c_werror_flag=$ac_save_c_werror_flag fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 $as_echo "$ac_cv_prog_cc_g" >&6; } if test "$ac_test_CFLAGS" = set; then CFLAGS=$ac_save_CFLAGS elif test $ac_cv_prog_cc_g = yes; then if test "$GCC" = yes; then CFLAGS="-g -O2" else CFLAGS="-g" fi else if test "$GCC" = yes; then CFLAGS="-O2" else CFLAGS= fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } if test "${ac_cv_prog_cc_c89+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no ac_save_CC=$CC cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ #include #include #include #include /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ struct buf { int x; }; FILE * (*rcsopen) (struct buf *, struct stat *, int); static char *e (p, i) char **p; int i; { return p[i]; } static char *f (char * (*g) (char **, int), char **p, ...) { char *s; va_list v; va_start (v,p); s = g (p, va_arg (v,int)); va_end (v); return s; } /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has function prototypes and stuff, but not '\xHH' hex character constants. These don't provoke an error unfortunately, instead are silently treated as 'x'. The following induces an error, until -std is added to get proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an array size at least. It's necessary to write '\x00'==0 to get something that's true only with -std. */ int osf4_cc_array ['\x00' == 0 ? 1 : -1]; /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters inside strings and character constants. */ #define FOO(x) 'x' int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; int test (int i, double x); struct s1 {int (*f) (int a);}; struct s2 {int (*f) (double a);}; int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); int argc; char **argv; int main () { return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; ; return 0; } _ACEOF for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" do CC="$ac_save_CC $ac_arg" if ac_fn_c_try_compile "$LINENO"; then : ac_cv_prog_cc_c89=$ac_arg fi rm -f core conftest.err conftest.$ac_objext test "x$ac_cv_prog_cc_c89" != "xno" && break done rm -f conftest.$ac_ext CC=$ac_save_CC fi # AC_CACHE_VAL case "x$ac_cv_prog_cc_c89" in x) { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 $as_echo "none needed" >&6; } ;; xno) { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 $as_echo "unsupported" >&6; } ;; *) CC="$CC $ac_cv_prog_cc_c89" { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; esac if test "x$ac_cv_prog_cc_c89" != xno; then : fi ac_ext=c ac_cpp='$CPP $CPPFLAGS' ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' ac_compiler_gnu=$ac_cv_c_compiler_gnu DEPDIR="${am__leading_dot}deps" ac_config_commands="$ac_config_commands depfiles" am_make=${MAKE-make} cat > confinc << 'END' am__doit: @echo done .PHONY: am__doit END # If we don't find an include directive, just comment out the code. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 $as_echo_n "checking for style of include used by $am_make... " >&6; } am__include="#" am__quote= _am_result=none # First try GNU make style include. echo "include confinc" > confmf # We grep out `Entering directory' and `Leaving directory' # messages which can occur if `w' ends up in MAKEFLAGS. # In particular we don't look at `^make:' because GNU make might # be invoked under some other name (usually "gmake"), in which # case it prints its new name instead of `make'. if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then am__include=include am__quote= _am_result=GNU fi # Now try BSD make style include. if test "$am__include" = "#"; then echo '.include "confinc"' > confmf if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then am__include=.include am__quote="\"" _am_result=BSD fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 $as_echo "$_am_result" >&6; } rm -f confinc confmf # Check whether --enable-dependency-tracking was given. if test "${enable_dependency_tracking+set}" = set; then : enableval=$enable_dependency_tracking; fi if test "x$enable_dependency_tracking" != xno; then am_depcomp="$ac_aux_dir/depcomp" AMDEPBACKSLASH='\' fi if test "x$enable_dependency_tracking" != xno; then AMDEP_TRUE= AMDEP_FALSE='#' else AMDEP_TRUE='#' AMDEP_FALSE= fi depcc="$CC" am_compiler_list= { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 $as_echo_n "checking dependency style of $depcc... " >&6; } if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then : $as_echo_n "(cached) " >&6 else if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then # We make a subdir and do the tests there. Otherwise we can end up # making bogus files that we don't know about and never remove. For # instance it was reported that on HP-UX the gcc test will end up # making a dummy file named `D' -- because `-MD' means `put the output # in D'. mkdir conftest.dir # Copy depcomp to subdir because otherwise we won't find it if we're # using a relative directory. cp "$am_depcomp" conftest.dir cd conftest.dir # We will build objects and dependencies in a subdirectory because # it helps to detect inapplicable dependency modes. For instance # both Tru64's cc and ICC support -MD to output dependencies as a # side effect of compilation, but ICC will put the dependencies in # the current directory while Tru64 will put them in the object # directory. mkdir sub am_cv_CC_dependencies_compiler_type=none if test "$am_compiler_list" = ""; then am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` fi for depmode in $am_compiler_list; do # Setup a source with many dependencies, because some compilers # like to wrap large dependency lists on column 80 (with \), and # we should not choose a depcomp mode which is confused by this. # # We need to recreate these files for each test, as the compiler may # overwrite some of them when testing with obscure command lines. # This happens at least with the AIX C compiler. : > sub/conftest.c for i in 1 2 3 4 5 6; do echo '#include "conftst'$i'.h"' >> sub/conftest.c # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with # Solaris 8's {/usr,}/bin/sh. touch sub/conftst$i.h done echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf case $depmode in nosideeffect) # after this tag, mechanisms are not by side-effect, so they'll # only be used when explicitly requested if test "x$enable_dependency_tracking" = xyes; then continue else break fi ;; none) break ;; esac # We check with `-c' and `-o' for the sake of the "dashmstdout" # mode. It turns out that the SunPro C++ compiler does not properly # handle `-M -o', and we need to detect this. if depmode=$depmode \ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \ >/dev/null 2>conftest.err && grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 && ${MAKE-make} -s -f confmf > /dev/null 2>&1; then # icc doesn't choke on unknown options, it will just issue warnings # or remarks (even with -Werror). So we grep stderr for any message # that says an option was ignored or not supported. # When given -MP, icc 7.0 and 7.1 complain thusly: # icc: Command line warning: ignoring option '-M'; no argument required # The diagnosis changed in icc 8.0: # icc: Command line remark: option '-MP' not supported if (grep 'ignoring option' conftest.err || grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else am_cv_CC_dependencies_compiler_type=$depmode break fi fi done cd .. rm -rf conftest.dir else am_cv_CC_dependencies_compiler_type=none fi fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type if test "x$enable_dependency_tracking" != xno \ && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then am__fastdepCC_TRUE= am__fastdepCC_FALSE='#' else am__fastdepCC_TRUE='#' am__fastdepCC_FALSE= fi ac_config_files="$ac_config_files Makefile" cat >confcache <<\_ACEOF # This file is a shell script that caches the results of configure # tests run on this system so they can be shared between configure # scripts and configure runs, see configure's option --config-cache. # It is not useful on other systems. If it contains results you don't # want to keep, you may remove or edit it. # # config.status only pays attention to the cache file if you give it # the --recheck option to rerun configure. # # `ac_cv_env_foo' variables (set or unset) will be overridden when # loading this file, other *unset* `ac_cv_foo' will be assigned the # following values. _ACEOF # The following way of writing the cache mishandles newlines in values, # but we know of no workaround that is simple, portable, and efficient. # So, we kill variables containing newlines. # Ultrix sh set writes to stderr and can't be redirected directly, # and sets the high bit in the cache file unless we assign to the vars. ( for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do eval ac_val=\$$ac_var case $ac_val in #( *${as_nl}*) case $ac_var in #( *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; esac case $ac_var in #( _ | IFS | as_nl) ;; #( BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( *) { eval $ac_var=; unset $ac_var;} ;; esac ;; esac done (set) 2>&1 | case $as_nl`(ac_space=' '; set) 2>&1` in #( *${as_nl}ac_space=\ *) # `set' does not quote correctly, so add quotes: double-quote # substitution turns \\\\ into \\, and sed turns \\ into \. sed -n \ "s/'/'\\\\''/g; s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" ;; #( *) # `set' quotes correctly as required by POSIX, so do not add quotes. sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" ;; esac | sort ) | sed ' /^ac_cv_env_/b end t clear :clear s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ t end s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ :end' >>confcache if diff "$cache_file" confcache >/dev/null 2>&1; then :; else if test -w "$cache_file"; then test "x$cache_file" != "x/dev/null" && { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 $as_echo "$as_me: updating cache $cache_file" >&6;} cat confcache >$cache_file else { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} fi fi rm -f confcache test "x$prefix" = xNONE && prefix=$ac_default_prefix # Let make expand exec_prefix. test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' DEFS=-DHAVE_CONFIG_H ac_libobjs= ac_ltlibobjs= for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue # 1. Remove the extension, and $U if already installed. ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' ac_i=`$as_echo "$ac_i" | sed "$ac_script"` # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR # will be set to the directory where LIBOBJS objects are built. as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' done LIBOBJS=$ac_libobjs LTLIBOBJS=$ac_ltlibobjs if test -z "${APPLE_TRUE}" && test -z "${APPLE_FALSE}"; then as_fn_error "conditional \"APPLE\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then as_fn_error "conditional \"AMDEP\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then as_fn_error "conditional \"am__fastdepCC\" was never defined. Usually this means the macro was only invoked conditionally." "$LINENO" 5 fi : ${CONFIG_STATUS=./config.status} ac_write_fail=0 ac_clean_files_save=$ac_clean_files ac_clean_files="$ac_clean_files $CONFIG_STATUS" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} as_write_fail=0 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 #! $SHELL # Generated by $as_me. # Run this file to recreate the current configuration. # Compiler output produced by configure, useful for debugging # configure, is in config.log if it exists. debug=false ac_cs_recheck=false ac_cs_silent=false SHELL=\${CONFIG_SHELL-$SHELL} export SHELL _ASEOF cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 ## -------------------- ## ## M4sh Initialization. ## ## -------------------- ## # Be more Bourne compatible DUALCASE=1; export DUALCASE # for MKS sh if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : emulate sh NULLCMD=: # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which # is contrary to our usage. Disable this feature. alias -g '${1+"$@"}'='"$@"' setopt NO_GLOB_SUBST else case `(set -o) 2>/dev/null` in #( *posix*) : set -o posix ;; #( *) : ;; esac fi as_nl=' ' export as_nl # Printing a long string crashes Solaris 7 /usr/bin/printf. as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo # Prefer a ksh shell builtin over an external printf program on Solaris, # but without wasting forks for bash or zsh. if test -z "$BASH_VERSION$ZSH_VERSION" \ && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='print -r --' as_echo_n='print -rn --' elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then as_echo='printf %s\n' as_echo_n='printf %s' else if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' as_echo_n='/usr/ucb/echo -n' else as_echo_body='eval expr "X$1" : "X\\(.*\\)"' as_echo_n_body='eval arg=$1; case $arg in #( *"$as_nl"*) expr "X$arg" : "X\\(.*\\)$as_nl"; arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; esac; expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" ' export as_echo_n_body as_echo_n='sh -c $as_echo_n_body as_echo' fi export as_echo_body as_echo='sh -c $as_echo_body as_echo' fi # The user is always right. if test "${PATH_SEPARATOR+set}" != set; then PATH_SEPARATOR=: (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || PATH_SEPARATOR=';' } fi # IFS # We need space, tab and new line, in precisely that order. Quoting is # there to prevent editors from complaining about space-tab. # (If _AS_PATH_WALK were called with IFS unset, it would disable word # splitting by setting IFS to empty value.) IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break done IFS=$as_save_IFS ;; esac # We did not find ourselves, most probably we were run as `sh COMMAND' # in which case we are not to be found in the path. if test "x$as_myself" = x; then as_myself=$0 fi if test ! -f "$as_myself"; then $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 exit 1 fi # Unset variables that we do not need and which cause bugs (e.g. in # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" # suppresses any "Segmentation fault" message there. '((' could # trigger a bug in pdksh 5.2.14. for as_var in BASH_ENV ENV MAIL MAILPATH do eval test x\${$as_var+set} = xset \ && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : done PS1='$ ' PS2='> ' PS4='+ ' # NLS nuisances. LC_ALL=C export LC_ALL LANGUAGE=C export LANGUAGE # CDPATH. (unset CDPATH) >/dev/null 2>&1 && unset CDPATH # as_fn_error ERROR [LINENO LOG_FD] # --------------------------------- # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are # provided, also output the error to LOG_FD, referencing LINENO. Then exit the # script with status $?, using 1 if that was 0. as_fn_error () { as_status=$?; test $as_status -eq 0 && as_status=1 if test "$3"; then as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 fi $as_echo "$as_me: error: $1" >&2 as_fn_exit $as_status } # as_fn_error # as_fn_set_status STATUS # ----------------------- # Set $? to STATUS, without forking. as_fn_set_status () { return $1 } # as_fn_set_status # as_fn_exit STATUS # ----------------- # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. as_fn_exit () { set +e as_fn_set_status $1 exit $1 } # as_fn_exit # as_fn_unset VAR # --------------- # Portably unset VAR. as_fn_unset () { { eval $1=; unset $1;} } as_unset=as_fn_unset # as_fn_append VAR VALUE # ---------------------- # Append the text in VALUE to the end of the definition contained in VAR. Take # advantage of any shell optimizations that allow amortized linear growth over # repeated appends, instead of the typical quadratic growth present in naive # implementations. if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : eval 'as_fn_append () { eval $1+=\$2 }' else as_fn_append () { eval $1=\$$1\$2 } fi # as_fn_append # as_fn_arith ARG... # ------------------ # Perform arithmetic evaluation on the ARGs, and store the result in the # global $as_val. Take advantage of shells that can avoid forks. The arguments # must be portable across $(()) and expr. if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : eval 'as_fn_arith () { as_val=$(( $* )) }' else as_fn_arith () { as_val=`expr "$@" || test $? -eq 1` } fi # as_fn_arith if expr a : '\(a\)' >/dev/null 2>&1 && test "X`expr 00001 : '.*\(...\)'`" = X001; then as_expr=expr else as_expr=false fi if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then as_basename=basename else as_basename=false fi if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then as_dirname=dirname else as_dirname=false fi as_me=`$as_basename -- "$0" || $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ X"$0" : 'X\(//\)$' \| \ X"$0" : 'X\(/\)' \| . 2>/dev/null || $as_echo X/"$0" | sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/ q } /^X\/\(\/\/\)$/{ s//\1/ q } /^X\/\(\/\).*/{ s//\1/ q } s/.*/./; q'` # Avoid depending upon Character Ranges. as_cr_letters='abcdefghijklmnopqrstuvwxyz' as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' as_cr_Letters=$as_cr_letters$as_cr_LETTERS as_cr_digits='0123456789' as_cr_alnum=$as_cr_Letters$as_cr_digits ECHO_C= ECHO_N= ECHO_T= case `echo -n x` in #((((( -n*) case `echo 'xy\c'` in *c*) ECHO_T=' ';; # ECHO_T is single tab character. xy) ECHO_C='\c';; *) echo `echo ksh88 bug on AIX 6.1` > /dev/null ECHO_T=' ';; esac;; *) ECHO_N='-n';; esac rm -f conf$$ conf$$.exe conf$$.file if test -d conf$$.dir; then rm -f conf$$.dir/conf$$.file else rm -f conf$$.dir mkdir conf$$.dir 2>/dev/null fi if (echo >conf$$.file) 2>/dev/null; then if ln -s conf$$.file conf$$ 2>/dev/null; then as_ln_s='ln -s' # ... but there are two gotchas: # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. # In both cases, we have to default to `cp -p'. ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || as_ln_s='cp -p' elif ln conf$$.file conf$$ 2>/dev/null; then as_ln_s=ln else as_ln_s='cp -p' fi else as_ln_s='cp -p' fi rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file rmdir conf$$.dir 2>/dev/null # as_fn_mkdir_p # ------------- # Create "$as_dir" as a directory, including parents if necessary. as_fn_mkdir_p () { case $as_dir in #( -*) as_dir=./$as_dir;; esac test -d "$as_dir" || eval $as_mkdir_p || { as_dirs= while :; do case $as_dir in #( *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( *) as_qdir=$as_dir;; esac as_dirs="'$as_qdir' $as_dirs" as_dir=`$as_dirname -- "$as_dir" || $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$as_dir" : 'X\(//\)[^/]' \| \ X"$as_dir" : 'X\(//\)$' \| \ X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$as_dir" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` test -d "$as_dir" && break done test -z "$as_dirs" || eval "mkdir $as_dirs" } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" } # as_fn_mkdir_p if mkdir -p . 2>/dev/null; then as_mkdir_p='mkdir -p "$as_dir"' else test -d ./-p && rmdir ./-p as_mkdir_p=false fi if test -x / >/dev/null 2>&1; then as_test_x='test -x' else if ls -dL / >/dev/null 2>&1; then as_ls_L_option=L else as_ls_L_option= fi as_test_x=' eval sh -c '\'' if test -d "$1"; then test -d "$1/."; else case $1 in #( -*)set "./$1";; esac; case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( ???[sx]*):;;*)false;;esac;fi '\'' sh ' fi as_executable_p=$as_test_x # Sed expression to map a string onto a valid CPP name. as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" # Sed expression to map a string onto a valid variable name. as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" exec 6>&1 ## ----------------------------------- ## ## Main body of $CONFIG_STATUS script. ## ## ----------------------------------- ## _ASEOF test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Save the log message, to keep $0 and so on meaningful, and to # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" This file was extended by $as_me, which was generated by GNU Autoconf 2.65. Invocation command line was CONFIG_FILES = $CONFIG_FILES CONFIG_HEADERS = $CONFIG_HEADERS CONFIG_LINKS = $CONFIG_LINKS CONFIG_COMMANDS = $CONFIG_COMMANDS $ $0 $@ on `(hostname || uname -n) 2>/dev/null | sed 1q` " _ACEOF case $ac_config_files in *" "*) set x $ac_config_files; shift; ac_config_files=$*;; esac case $ac_config_headers in *" "*) set x $ac_config_headers; shift; ac_config_headers=$*;; esac cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # Files that config.status was made for. config_files="$ac_config_files" config_headers="$ac_config_headers" config_commands="$ac_config_commands" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 ac_cs_usage="\ \`$as_me' instantiates files and other configuration actions from templates according to the current configuration. Unless the files and actions are specified as TAGs, all are instantiated by default. Usage: $0 [OPTION]... [TAG]... -h, --help print this help, then exit -V, --version print version number and configuration settings, then exit --config print configuration, then exit -q, --quiet, --silent do not print progress messages -d, --debug don't remove temporary files --recheck update $as_me by reconfiguring in the same conditions --file=FILE[:TEMPLATE] instantiate the configuration file FILE --header=FILE[:TEMPLATE] instantiate the configuration header FILE Configuration files: $config_files Configuration headers: $config_headers Configuration commands: $config_commands Report bugs to the package provider." _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ config.status configured by $0, generated by GNU Autoconf 2.65, with options \\"\$ac_cs_config\\" Copyright (C) 2009 Free Software Foundation, Inc. This config.status script is free software; the Free Software Foundation gives unlimited permission to copy, distribute and modify it." ac_pwd='$ac_pwd' srcdir='$srcdir' INSTALL='$INSTALL' AWK='$AWK' test -n "\$AWK" || AWK=awk _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # The default lists apply if the user does not specify any file. ac_need_defaults=: while test $# != 0 do case $1 in --*=*) ac_option=`expr "X$1" : 'X\([^=]*\)='` ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` ac_shift=: ;; *) ac_option=$1 ac_optarg=$2 ac_shift=shift ;; esac case $ac_option in # Handling of the options. -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) ac_cs_recheck=: ;; --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) $as_echo "$ac_cs_version"; exit ;; --config | --confi | --conf | --con | --co | --c ) $as_echo "$ac_cs_config"; exit ;; --debug | --debu | --deb | --de | --d | -d ) debug=: ;; --file | --fil | --fi | --f ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_FILES " '$ac_optarg'" ac_need_defaults=false;; --header | --heade | --head | --hea ) $ac_shift case $ac_optarg in *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; esac as_fn_append CONFIG_HEADERS " '$ac_optarg'" ac_need_defaults=false;; --he | --h) # Conflict between --help and --header as_fn_error "ambiguous option: \`$1' Try \`$0 --help' for more information.";; --help | --hel | -h ) $as_echo "$ac_cs_usage"; exit ;; -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | -silent | --silent | --silen | --sile | --sil | --si | --s) ac_cs_silent=: ;; # This is an error. -*) as_fn_error "unrecognized option: \`$1' Try \`$0 --help' for more information." ;; *) as_fn_append ac_config_targets " $1" ac_need_defaults=false ;; esac shift done ac_configure_extra_args= if $ac_cs_silent; then exec 6>/dev/null ac_configure_extra_args="$ac_configure_extra_args --silent" fi _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 if \$ac_cs_recheck; then set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion shift \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 CONFIG_SHELL='$SHELL' export CONFIG_SHELL exec "\$@" fi _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 exec 5>>config.log { echo sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX ## Running $as_me. ## _ASBOX $as_echo "$ac_log" } >&5 _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 # # INIT-COMMANDS # AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # Handling of arguments. for ac_config_target in $ac_config_targets do case $ac_config_target in "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac done # If the user did not use the arguments to specify the items to instantiate, # then the envvar interface is used. Set only those that are not. # We use the long form for the default assignment because of an extremely # bizarre bug on SunOS 4.1.3. if $ac_need_defaults; then test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands fi # Have a temporary directory for convenience. Make it in the build tree # simply because there is no reason against having it here, and in addition, # creating and moving files from /tmp can sometimes cause problems. # Hook for its removal unless debugging. # Note that there is a small window in which the directory will not be cleaned: # after its creation but before its name has been assigned to `$tmp'. $debug || { tmp= trap 'exit_status=$? { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status ' 0 trap 'as_fn_exit 1' 1 2 13 15 } # Create a (secure) tmp directory for tmp files. { tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" } || { tmp=./conf$$-$RANDOM (umask 077 && mkdir "$tmp") } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 # Set up the scripts for CONFIG_FILES section. # No need to generate them if there are no CONFIG_FILES. # This happens for instance with `./config.status config.h'. if test -n "$CONFIG_FILES"; then ac_cr=`echo X | tr X '\015'` # On cygwin, bash can eat \r inside `` if the user requested igncr. # But we know of no other shell where ac_cr would be empty at this # point, so we can use a bashism as a fallback. if test "x$ac_cr" = x; then eval ac_cr=\$\'\\r\' fi ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' /dev/null` if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then ac_cs_awk_cr='\r' else ac_cs_awk_cr=$ac_cr fi echo 'BEGIN {' >"$tmp/subs1.awk" && _ACEOF { echo "cat >conf$$subs.awk <<_ACEOF" && echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && echo "_ACEOF" } >conf$$subs.sh || as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` ac_delim='%!_!# ' for ac_last_try in false false false false false :; do . ./conf$$subs.sh || as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` if test $ac_delim_n = $ac_delim_num; then break elif $ac_last_try; then as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done rm -f conf$$subs.sh cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 cat >>"\$tmp/subs1.awk" <<\\_ACAWK && _ACEOF sed -n ' h s/^/S["/; s/!.*/"]=/ p g s/^[^!]*!// :repl t repl s/'"$ac_delim"'$// t delim :nl h s/\(.\{148\}\)..*/\1/ t more1 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ p n b repl :more1 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t nl :delim h s/\(.\{148\}\)..*/\1/ t more2 s/["\\]/\\&/g; s/^/"/; s/$/"/ p b :more2 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ p g s/.\{148\}// t delim ' >$CONFIG_STATUS || ac_write_fail=1 rm -f conf$$subs.awk cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 _ACAWK cat >>"\$tmp/subs1.awk" <<_ACAWK && for (key in S) S_is_set[key] = 1 FS = "" } { line = $ 0 nfields = split(line, field, "@") substed = 0 len = length(field[1]) for (i = 2; i < nfields; i++) { key = field[i] keylen = length(key) if (S_is_set[key]) { value = S[key] line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) len += length(value) + length(field[++i]) substed = 1 } else len += 1 + keylen } print line } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" else cat fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ || as_fn_error "could not setup config files machinery" "$LINENO" 5 _ACEOF # VPATH may cause trouble with some makes, so we remove $(srcdir), # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and # trailing colons and then remove the whole line if VPATH becomes empty # (actually we leave an empty line to preserve line numbers). if test "x$srcdir" = x.; then ac_vpsub='/^[ ]*VPATH[ ]*=/{ s/:*\$(srcdir):*/:/ s/:*\${srcdir}:*/:/ s/:*@srcdir@:*/:/ s/^\([^=]*=[ ]*\):*/\1/ s/:*$// s/^[^=]*=[ ]*$// }' fi cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 fi # test -n "$CONFIG_FILES" # Set up the scripts for CONFIG_HEADERS section. # No need to generate them if there are no CONFIG_HEADERS. # This happens for instance with `./config.status Makefile'. if test -n "$CONFIG_HEADERS"; then cat >"$tmp/defines.awk" <<\_ACAWK || BEGIN { _ACEOF # Transform confdefs.h into an awk script `defines.awk', embedded as # here-document in config.status, that substitutes the proper values into # config.h.in to produce config.h. # Create a delimiter string that does not exist in confdefs.h, to ease # handling of long lines. ac_delim='%!_!# ' for ac_last_try in false false :; do ac_t=`sed -n "/$ac_delim/p" confdefs.h` if test -z "$ac_t"; then break elif $ac_last_try; then as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5 else ac_delim="$ac_delim!$ac_delim _$ac_delim!! " fi done # For the awk script, D is an array of macro values keyed by name, # likewise P contains macro parameters if any. Preserve backslash # newline sequences. ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* sed -n ' s/.\{148\}/&'"$ac_delim"'/g t rset :rset s/^[ ]*#[ ]*define[ ][ ]*/ / t def d :def s/\\$// t bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3"/p s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p d :bsnl s/["\\]/\\&/g s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ D["\1"]=" \3\\\\\\n"\\/p t cont s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p t cont d :cont n s/.\{148\}/&'"$ac_delim"'/g t clear :clear s/\\$// t bsnlc s/["\\]/\\&/g; s/^/"/; s/$/"/p d :bsnlc s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p b cont ' >$CONFIG_STATUS || ac_write_fail=1 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 for (key in D) D_is_set[key] = 1 FS = "" } /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { line = \$ 0 split(line, arg, " ") if (arg[1] == "#") { defundef = arg[2] mac1 = arg[3] } else { defundef = substr(arg[1], 2) mac1 = arg[2] } split(mac1, mac2, "(") #) macro = mac2[1] prefix = substr(line, 1, index(line, defundef) - 1) if (D_is_set[macro]) { # Preserve the white space surrounding the "#". print prefix "define", macro P[macro] D[macro] next } else { # Replace #undef with comments. This is necessary, for example, # in the case of _POSIX_SOURCE, which is predefined and required # on some systems where configure will not decide to define it. if (defundef == "undef") { print "/*", prefix defundef, macro, "*/" next } } } { print } _ACAWK _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 as_fn_error "could not setup config headers machinery" "$LINENO" 5 fi # test -n "$CONFIG_HEADERS" eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" shift for ac_tag do case $ac_tag in :[FHLC]) ac_mode=$ac_tag; continue;; esac case $ac_mode$ac_tag in :[FHL]*:*);; :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;; :[FH]-) ac_tag=-:-;; :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; esac ac_save_IFS=$IFS IFS=: set x $ac_tag IFS=$ac_save_IFS shift ac_file=$1 shift case $ac_mode in :L) ac_source=$1;; :[FH]) ac_file_inputs= for ac_f do case $ac_f in -) ac_f="$tmp/stdin";; *) # Look for the file first in the build tree, then in the source tree # (if the path is not absolute). The absolute path cannot be DOS-style, # because $ac_f cannot contain `:'. test -f "$ac_f" || case $ac_f in [\\/$]*) false;; *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; esac || as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; esac case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac as_fn_append ac_file_inputs " '$ac_f'" done # Let's still pretend it is `configure' which instantiates (i.e., don't # use $as_me), people would be surprised to read: # /* config.h. Generated by config.status. */ configure_input='Generated from '` $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' `' by configure.' if test x"$ac_file" != x-; then configure_input="$ac_file. $configure_input" { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 $as_echo "$as_me: creating $ac_file" >&6;} fi # Neutralize special characters interpreted by sed in replacement strings. case $configure_input in #( *\&* | *\|* | *\\* ) ac_sed_conf_input=`$as_echo "$configure_input" | sed 's/[\\\\&|]/\\\\&/g'`;; #( *) ac_sed_conf_input=$configure_input;; esac case $ac_tag in *:-:* | *:-) cat >"$tmp/stdin" \ || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; esac ;; esac ac_dir=`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir="$ac_dir"; as_fn_mkdir_p ac_builddir=. case "$ac_dir" in .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` # A ".." for each directory in $ac_dir_suffix. ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` case $ac_top_builddir_sub in "") ac_top_builddir_sub=. ac_top_build_prefix= ;; *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; esac ;; esac ac_abs_top_builddir=$ac_pwd ac_abs_builddir=$ac_pwd$ac_dir_suffix # for backward compatibility: ac_top_builddir=$ac_top_build_prefix case $srcdir in .) # We are building in place. ac_srcdir=. ac_top_srcdir=$ac_top_builddir_sub ac_abs_top_srcdir=$ac_pwd ;; [\\/]* | ?:[\\/]* ) # Absolute name. ac_srcdir=$srcdir$ac_dir_suffix; ac_top_srcdir=$srcdir ac_abs_top_srcdir=$srcdir ;; *) # Relative name. ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix ac_top_srcdir=$ac_top_build_prefix$srcdir ac_abs_top_srcdir=$ac_pwd/$srcdir ;; esac ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix case $ac_mode in :F) # # CONFIG_FILE # case $INSTALL in [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; esac _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # If the template does not know about datarootdir, expand it. # FIXME: This hack should be removed a few years after 2.60. ac_datarootdir_hack=; ac_datarootdir_seen= ac_sed_dataroot=' /datarootdir/ { p q } /@datadir@/p /@docdir@/p /@infodir@/p /@localedir@/p /@mandir@/p' case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in *datarootdir*) ac_datarootdir_seen=yes;; *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_datarootdir_hack=' s&@datadir@&$datadir&g s&@docdir@&$docdir&g s&@infodir@&$infodir&g s&@localedir@&$localedir&g s&@mandir@&$mandir&g s&\\\${datarootdir}&$datarootdir&g' ;; esac _ACEOF # Neutralize VPATH when `$srcdir' = `.'. # Shell code in configure.ac might set extrasub. # FIXME: do we really want to maintain this feature? cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_sed_extra="$ac_vpsub $extrasub _ACEOF cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 :t /@[a-zA-Z_][a-zA-Z_0-9]*@/!b s|@configure_input@|$ac_sed_conf_input|;t t s&@top_builddir@&$ac_top_builddir_sub&;t t s&@top_build_prefix@&$ac_top_build_prefix&;t t s&@srcdir@&$ac_srcdir&;t t s&@abs_srcdir@&$ac_abs_srcdir&;t t s&@top_srcdir@&$ac_top_srcdir&;t t s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t s&@builddir@&$ac_builddir&;t t s&@abs_builddir@&$ac_abs_builddir&;t t s&@abs_top_builddir@&$ac_abs_top_builddir&;t t s&@INSTALL@&$ac_INSTALL&;t t $ac_datarootdir_hack " eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \ || as_fn_error "could not create $ac_file" "$LINENO" 5 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&5 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' which seems to be undefined. Please make sure it is defined." >&2;} rm -f "$tmp/stdin" case $ac_file in -) cat "$tmp/out" && rm -f "$tmp/out";; *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; esac \ || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; :H) # # CONFIG_HEADER # if test x"$ac_file" != x-; then { $as_echo "/* $configure_input */" \ && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" } >"$tmp/config.h" \ || as_fn_error "could not create $ac_file" "$LINENO" 5 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 $as_echo "$as_me: $ac_file is unchanged" >&6;} else rm -f "$ac_file" mv "$tmp/config.h" "$ac_file" \ || as_fn_error "could not create $ac_file" "$LINENO" 5 fi else $as_echo "/* $configure_input */" \ && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ || as_fn_error "could not create -" "$LINENO" 5 fi # Compute "$ac_file"'s index in $config_headers. _am_stamp_count=1 for _am_header in $config_headers :; do case $_am_header in "$ac_file" | "$ac_file":* ) break ;; * ) _am_stamp_count=`expr $_am_stamp_count + 1` ;; esac done echo "timestamp for "$ac_file"" >`$as_dirname -- "$ac_file" || $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$ac_file" : 'X\(//\)[^/]' \| \ X"$ac_file" : 'X\(//\)$' \| \ X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$ac_file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'`/stamp-h$_am_stamp_count ;; :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 $as_echo "$as_me: executing $ac_file commands" >&6;} ;; esac case $ac_file$ac_mode in "depfiles":C) test x"$AMDEP_TRUE" != x"" || for mf in $CONFIG_FILES; do # Strip MF so we end up with the name of the file. mf=`echo "$mf" | sed -e 's/:.*$//'` # Check whether this is an Automake generated Makefile or not. # We used to match only the files named `Makefile.in', but # some people rename them; so instead we look at the file content. # Grep'ing the first line is not enough: some people post-process # each Makefile.in and add a new line on top of each file to say so. # So let's grep whole file. if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then dirpart=`$as_dirname -- "$mf" || $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$mf" : 'X\(//\)[^/]' \| \ X"$mf" : 'X\(//\)$' \| \ X"$mf" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$mf" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` else continue fi # Extract the definition of DEPDIR, am__include, and am__quote # from the Makefile without running `make'. DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` test -z "$DEPDIR" && continue am__include=`sed -n 's/^am__include = //p' < "$mf"` test -z "am__include" && continue am__quote=`sed -n 's/^am__quote = //p' < "$mf"` # When using ansi2knr, U may be empty or an underscore; expand it U=`sed -n 's/^U = //p' < "$mf"` # Find all dependency output files, they are included files with # $(DEPDIR) in their names. We invoke sed twice because it is the # simplest approach to changing $(DEPDIR) to its actual value in the # expansion. for file in `sed -n " s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do # Make sure the directory exists. test -f "$dirpart/$file" && continue fdir=`$as_dirname -- "$file" || $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ X"$file" : 'X\(//\)[^/]' \| \ X"$file" : 'X\(//\)$' \| \ X"$file" : 'X\(/\)' \| . 2>/dev/null || $as_echo X"$file" | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/ q } /^X\(\/\/\)[^/].*/{ s//\1/ q } /^X\(\/\/\)$/{ s//\1/ q } /^X\(\/\).*/{ s//\1/ q } s/.*/./; q'` as_dir=$dirpart/$fdir; as_fn_mkdir_p # echo "creating $dirpart/$file" echo '# dummy' > "$dirpart/$file" done done ;; esac done # for ac_tag as_fn_exit 0 _ACEOF ac_clean_files=$ac_clean_files_save test $ac_write_fail = 0 || as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 # configure is writing to config.log, and then calls config.status. # config.status does its own redirection, appending to config.log. # Unfortunately, on DOS this fails, as config.log is still kept open # by configure, so config.status won't be able to write to it; its # output is simply discarded. So we exec the FD to /dev/null, # effectively closing config.log, so it can be properly (re)opened and # appended to by config.status. When coming back to configure, we # need to make the FD available again. if test "$no_create" != yes; then ac_cs_success=: ac_config_status_args= test "$silent" = yes && ac_config_status_args="$ac_config_status_args --quiet" exec 5>/dev/null $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false exec 5>>config.log # Use ||, not &&, to avoid exiting from the if with $? = 1, which # would make configure fail if this is the last instruction. $ac_cs_success || as_fn_exit $? fi if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 $as_echo_n "checking for cos in -lm... " >&6; } if test "${ac_cv_lib_m_cos+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lm $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char cos (); int main () { return cos (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_m_cos=yes else ac_cv_lib_m_cos=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 $as_echo "$ac_cv_lib_m_cos" >&6; } if test "x$ac_cv_lib_m_cos" = x""yes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBM 1 _ACEOF LIBS="-lm $LIBS" else as_fn_error "could not link to mathlib." "$LINENO" 5 fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fftw_create_plan in -lfftw" >&5 $as_echo_n "checking for fftw_create_plan in -lfftw... " >&6; } if test "${ac_cv_lib_fftw_fftw_create_plan+set}" = set; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS LIBS="-lfftw $LIBS" cat confdefs.h - <<_ACEOF >conftest.$ac_ext /* end confdefs.h. */ /* Override any GCC internal prototype to avoid an error. Use char because int might match the return type of a GCC builtin and then its argument prototype would still apply. */ #ifdef __cplusplus extern "C" #endif char fftw_create_plan (); int main () { return fftw_create_plan (); ; return 0; } _ACEOF if ac_fn_c_try_link "$LINENO"; then : ac_cv_lib_fftw_fftw_create_plan=yes else ac_cv_lib_fftw_fftw_create_plan=no fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext conftest.$ac_ext LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_fftw_fftw_create_plan" >&5 $as_echo "$ac_cv_lib_fftw_fftw_create_plan" >&6; } if test "x$ac_cv_lib_fftw_fftw_create_plan" = x""yes; then : cat >>confdefs.h <<_ACEOF #define HAVE_LIBFFTW 1 _ACEOF LIBS="-lfftw $LIBS" else as_fn_error "could not link to fftw please install the fftw package." "$LINENO" 5 fi if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then if test -n "$ac_tool_prefix"; then # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_path_PKG_CONFIG+set}" = set; then : $as_echo_n "(cached) " >&6 else case $PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi PKG_CONFIG=$ac_cv_path_PKG_CONFIG if test -n "$PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 $as_echo "$PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi fi if test -z "$ac_cv_path_PKG_CONFIG"; then ac_pt_PKG_CONFIG=$PKG_CONFIG # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } if test "${ac_cv_path_ac_pt_PKG_CONFIG+set}" = set; then : $as_echo_n "(cached) " >&6 else case $ac_pt_PKG_CONFIG in [\\/]* | ?:[\\/]*) ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR for as_dir in $PATH do IFS=$as_save_IFS test -z "$as_dir" && as_dir=. for ac_exec_ext in '' $ac_executable_extensions; do if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 break 2 fi done done IFS=$as_save_IFS ;; esac fi ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG if test -n "$ac_pt_PKG_CONFIG"; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 $as_echo "$ac_pt_PKG_CONFIG" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } fi if test "x$ac_pt_PKG_CONFIG" = x; then PKG_CONFIG="" else case $cross_compiling:$ac_tool_warned in yes:) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} ac_tool_warned=yes ;; esac PKG_CONFIG=$ac_pt_PKG_CONFIG fi else PKG_CONFIG="$ac_cv_path_PKG_CONFIG" fi fi if test -n "$PKG_CONFIG"; then _pkg_min_version=0.9.0 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } PKG_CONFIG="" fi fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTK" >&5 $as_echo_n "checking for GTK... " >&6; } if test -n "$PKG_CONFIG"; then if test -n "$GTK_CFLAGS"; then pkg_cv_GTK_CFLAGS="$GTK_CFLAGS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk+-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK_CFLAGS=`$PKG_CONFIG --cflags "gtk+-2.0" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test -n "$PKG_CONFIG"; then if test -n "$GTK_LIBS"; then pkg_cv_GTK_LIBS="$GTK_LIBS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtk+-2.0\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtk+-2.0") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTK_LIBS=`$PKG_CONFIG --libs "gtk+-2.0" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test $pkg_failed = yes; then if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GTK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "gtk+-2.0"` else GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gtk+-2.0"` fi # Put the nasty error message in config.log where it belongs echo "$GTK_PKG_ERRORS" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } exit elif test $pkg_failed = untried; then exit else GTK_CFLAGS=$pkg_cv_GTK_CFLAGS GTK_LIBS=$pkg_cv_GTK_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } : fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANGO" >&5 $as_echo_n "checking for PANGO... " >&6; } if test -n "$PKG_CONFIG"; then if test -n "$PANGO_CFLAGS"; then pkg_cv_PANGO_CFLAGS="$PANGO_CFLAGS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"pango\""; } >&5 ($PKG_CONFIG --exists --print-errors "pango") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_PANGO_CFLAGS=`$PKG_CONFIG --cflags "pango" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test -n "$PKG_CONFIG"; then if test -n "$PANGO_LIBS"; then pkg_cv_PANGO_LIBS="$PANGO_LIBS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"pango\""; } >&5 ($PKG_CONFIG --exists --print-errors "pango") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_PANGO_LIBS=`$PKG_CONFIG --libs "pango" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test $pkg_failed = yes; then if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then PANGO_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "pango"` else PANGO_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "pango"` fi # Put the nasty error message in config.log where it belongs echo "$PANGO_PKG_ERRORS" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } exit elif test $pkg_failed = untried; then exit else PANGO_CFLAGS=$pkg_cv_PANGO_CFLAGS PANGO_LIBS=$pkg_cv_PANGO_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } : fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAIRO" >&5 $as_echo_n "checking for CAIRO... " >&6; } if test -n "$PKG_CONFIG"; then if test -n "$CAIRO_CFLAGS"; then pkg_cv_CAIRO_CFLAGS="$CAIRO_CFLAGS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"cairo\""; } >&5 ($PKG_CONFIG --exists --print-errors "cairo") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CAIRO_CFLAGS=`$PKG_CONFIG --cflags "cairo" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test -n "$PKG_CONFIG"; then if test -n "$CAIRO_LIBS"; then pkg_cv_CAIRO_LIBS="$CAIRO_LIBS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"cairo\""; } >&5 ($PKG_CONFIG --exists --print-errors "cairo") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_CAIRO_LIBS=`$PKG_CONFIG --libs "cairo" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test $pkg_failed = yes; then if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then CAIRO_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "cairo"` else CAIRO_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "cairo"` fi # Put the nasty error message in config.log where it belongs echo "$CAIRO_PKG_ERRORS" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } exit elif test $pkg_failed = untried; then exit else CAIRO_CFLAGS=$pkg_cv_CAIRO_CFLAGS CAIRO_LIBS=$pkg_cv_CAIRO_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } : fi #PKG_CHECK_MODULES(GDK-2.0, gdk-2.0,,exit) pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GTKDATABOX" >&5 $as_echo_n "checking for GTKDATABOX... " >&6; } if test -n "$PKG_CONFIG"; then if test -n "$GTKDATABOX_CFLAGS"; then pkg_cv_GTKDATABOX_CFLAGS="$GTKDATABOX_CFLAGS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtkdatabox\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtkdatabox") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTKDATABOX_CFLAGS=`$PKG_CONFIG --cflags "gtkdatabox" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test -n "$PKG_CONFIG"; then if test -n "$GTKDATABOX_LIBS"; then pkg_cv_GTKDATABOX_LIBS="$GTKDATABOX_LIBS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"gtkdatabox\""; } >&5 ($PKG_CONFIG --exists --print-errors "gtkdatabox") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_GTKDATABOX_LIBS=`$PKG_CONFIG --libs "gtkdatabox" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test $pkg_failed = yes; then if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then GTKDATABOX_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "gtkdatabox"` else GTKDATABOX_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gtkdatabox"` fi # Put the nasty error message in config.log where it belongs echo "$GTKDATABOX_PKG_ERRORS" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } as_fn_error "please install gtkdatabox development version." "$LINENO" 5 elif test $pkg_failed = untried; then as_fn_error "please install gtkdatabox development version." "$LINENO" 5 else GTKDATABOX_CFLAGS=$pkg_cv_GTKDATABOX_CFLAGS GTKDATABOX_LIBS=$pkg_cv_GTKDATABOX_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } : fi pkg_failed=no { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JACK" >&5 $as_echo_n "checking for JACK... " >&6; } if test -n "$PKG_CONFIG"; then if test -n "$JACK_CFLAGS"; then pkg_cv_JACK_CFLAGS="$JACK_CFLAGS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"jack\""; } >&5 ($PKG_CONFIG --exists --print-errors "jack") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_JACK_CFLAGS=`$PKG_CONFIG --cflags "jack" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test -n "$PKG_CONFIG"; then if test -n "$JACK_LIBS"; then pkg_cv_JACK_LIBS="$JACK_LIBS" else if test -n "$PKG_CONFIG" && \ { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"jack\""; } >&5 ($PKG_CONFIG --exists --print-errors "jack") 2>&5 ac_status=$? $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 test $ac_status = 0; }; then pkg_cv_JACK_LIBS=`$PKG_CONFIG --libs "jack" 2>/dev/null` else pkg_failed=yes fi fi else pkg_failed=untried fi if test $pkg_failed = yes; then if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then _pkg_short_errors_supported=yes else _pkg_short_errors_supported=no fi if test $_pkg_short_errors_supported = yes; then JACK_PKG_ERRORS=`$PKG_CONFIG --short-errors --errors-to-stdout --print-errors "jack"` else JACK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "jack"` fi # Put the nasty error message in config.log where it belongs echo "$JACK_PKG_ERRORS" >&5 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 $as_echo "no" >&6; } as_fn_error "please install the jack development version." "$LINENO" 5 elif test $pkg_failed = untried; then as_fn_error "please install the jack development version." "$LINENO" 5 else JACK_CFLAGS=$pkg_cv_JACK_CFLAGS JACK_LIBS=$pkg_cv_JACK_LIBS { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 $as_echo "yes" >&6; } : fi brp-pacu/ige-mac-dock.h0000644000175000017500000000644412153127664013641 0ustar miramira/* GTK+ Integration for the Mac OS X Dock. * * Copyright (C) 2007, 2008 Imendio AB * * For further information, see: * http://developer.imendio.com/projects/gtk-macosx/integration * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; version 2.1 * of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ #ifndef __IGE_MAC_DOCK_H__ #define __IGE_MAC_DOCK_H__ #include #include G_BEGIN_DECLS #define IGE_TYPE_MAC_DOCK (ige_mac_dock_get_type ()) #define IGE_MAC_DOCK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), IGE_TYPE_MAC_DOCK, IgeMacDock)) #define IGE_MAC_DOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), IGE_TYPE_MAC_DOCK, IgeMacDockClass)) #define IGE_IS_MAC_DOCK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), IGE_TYPE_MAC_DOCK)) #define IGE_IS_MAC_DOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), IGE_TYPE_MAC_DOCK)) #define IGE_MAC_DOCK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), IGE_TYPE_MAC_DOCK, IgeMacDockClass)) typedef struct _IgeMacDock IgeMacDock; typedef struct _IgeMacDockClass IgeMacDockClass; typedef struct _IgeMacAttentionRequest IgeMacAttentionRequest; struct _IgeMacDock { GObject parent_instance; }; struct _IgeMacDockClass { GObjectClass parent_class; }; typedef enum { IGE_MAC_ATTENTION_CRITICAL, IGE_MAC_ATTENTION_INFO } IgeMacAttentionType; GType ige_mac_dock_get_type (void); IgeMacDock * ige_mac_dock_new (void); IgeMacDock * ige_mac_dock_get_default (void); void ige_mac_dock_set_icon_from_pixbuf (IgeMacDock *dock, GdkPixbuf *pixbuf); void ige_mac_dock_set_icon_from_resource (IgeMacDock *dock, IgeMacBundle *bundle, const gchar *name, const gchar *type, const gchar *subdir); void ige_mac_dock_set_overlay_from_pixbuf (IgeMacDock *dock, GdkPixbuf *pixbuf); void ige_mac_dock_set_overlay_from_resource (IgeMacDock *dock, IgeMacBundle *bundle, const gchar *name, const gchar *type, const gchar *subdir); IgeMacAttentionRequest *ige_mac_dock_attention_request (IgeMacDock *dock, IgeMacAttentionType type); void ige_mac_dock_attention_cancel (IgeMacDock *dock, IgeMacAttentionRequest *request); #define IGE_TYPE_MAC_ATTENTION_TYPE (ige_mac_attention_type_get_type()) GType ige_mac_attention_type_get_type (void); G_END_DECLS #endif /* __IGE_MAC_DOCK_H__ */ brp-pacu/movelibraries.sh0000755000175000017500000000471312153127664014447 0ustar miramira#!/bin/sh # Copyright (C) 2010 Andreas Schwab andreas.schwab@mcgill.ca # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU Library General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. ###################################################### # Find dynamic shared libraries to be incorporated # into an OS-X application bundle # and change installnames to be relative to # the executable in the application # # usage: # movelibraries.sh APPLICATION SOURCE_LIB # where APPLICATION is the path to the application # and SOURCE_LIB is the absolute path of the directory # that contains the dynamic shared libraries # to be copied to the application. # ###################################################### ########################### APPL_CONTENTS=`cd "$1"/Contents; pwd` SOURCE_LIB="$2" #### Define temporary files #### TMP1=`mktemp /tmp/BRPXXXXXX` TMP2=`mktemp /tmp/BRPXXXXXX` cd "$APPL_CONTENTS"/Frameworks #### Make a list of dylibs liked by the executable or any dylibs already in the application #### otool -L $APPL_CONTENTS/MacOS/* `ls` \ | sed -n 's:'"$SOURCE_LIB"'.*/\(.*\) (.*:\1:p' \ | sort -u -o $TMP1 #### Test if any more dylibs have been added to the list cd "$SOURCE_LIB" until cmp -s $TMP1 $TMP2 #### save old list do cp $TMP1 $TMP2 #### Add any dylibs linked by existing dylibs to the list #### otool -L `cat $TMP1` | \ sed -n 's:'"$SOURCE_LIB"'.*/\(.*\) (.*:\1:p' \ | sort -u \ | sort -mu - $TMP1 -o $TMP1 done #### Copy the dylibs to the destination directory cp -p `cat $TMP1` $APPL_CONTENTS/Frameworks #### Change install names to be relative to the executable in the application for i in "$APPL_CONTENTS"/Frameworks/* "$APPL_CONTENTS"/MacOS/* do install_name_tool `otool -L $i \ | sed -n '\:'"$SOURCE_LIB"': s/\(.*\/\)\(.*\) (.*/-change \1\2 @executable_path\/..\/Frameworks\/\2 /p'` \ $i done #### clean up #### rm $TMP1 $TMP2 brp-pacu/Makefile.am0000644000175000017500000000705012153127664013276 0ustar miramira# Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) # Macintosh implementation Copyright (C) 2009 Andreas Schwab # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU Library General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. bin_PROGRAMS = BRP_PACU pkgconfigdir = $(libdir)/pkgconfig BRP_PACU_SOURCES = testfft.c gui.c BRP_PACU.c include_HEADERS = testfft.h gui.h main.h EXTRA_DIST = BRP_PACU.ui sinc.png info.plist \ sinc.icns sinc.xcf brpData.icns README-Mac.txt INSTALL-Mac.txt movelibraries.sh AM_CFLAGS = -O2 -Wall -g `pkg-config --cflags gtk+-2.0` `pkg-config --cflags gdk-2.0` `pkg-config --cflags glib-2.0` `pkg-config --cflags gtkdatabox` -DDATADIR=\"$(pkgdatadir)\" -lgthread-2.0 LIBS = -lm -lfftw `pkg-config --libs gtk+-2.0` `pkg-config --libs gdk-2.0` `pkg-config --libs glib-2.0` `pkg-config --libs gthread-2.0` `pkg-config --libs gtkdatabox` `pkg-config --libs jack` pkgdata_DATA = BRP_PACU.ui sinc.png ######### Macintosh implementation ######### if APPLE PKG_CONFIG_PATH+=@PKG_CONFIG_PATH@ export PKG_CONFIG_PATH MACAPPLICATION=macdistdir/BRP-PACU.app MACCONTENTS=$(MACAPPLICATION)/Contents MACRESOURCES=$(MACCONTENTS)/Resources MACFRAMEWORKS=$(MACCONTENTS)/Frameworks MACEXECUTABLE=$(MACCONTENTS)/MacOS/BRP_PACU MACDISK=BRP-PACU-mac-$(VERSION) AM_LDFLAGS=-framework Carbon AM_CFLAGS += `pkg-config --cflags gdk-quartz-2.0` `pkg-config --cflags ige-mac-integration` LIBS += `pkg-config --libs gdk-quartz-2.0` `pkg-config --libs ige-mac-integration` $(MACCONTENTS): BRP_PACU.ui AUTHORS COPYING COPYING.LESSER NEWS ChangeLog README-Mac.txt sinc.icns brpData.icns info.plist mkdir -p $(MACRESOURCES)/en.lproj $(MACCONTENTS)/MacOS $(MACFRAMEWORKS) cp -fp BRP_PACU.ui sinc.icns brpData.icns sinc.png $(MACRESOURCES) cp -fp AUTHORS COPYING COPYING.LESSER NEWS ChangeLog README-Mac.txt $(MACRESOURCES)/en.lproj sed -e 's/VERSION/$(VERSION)/' < info.plist > $(MACCONTENTS)/info.plist echo APPLBRPP > $(MACCONTENTS)/PkgInfo cp -fRP `pkg-config --variable=libdir gtkdatabox`/libgtkdatabox*.dylib $(MACFRAMEWORKS) macapplication: $(MACAPPLICATION) $(MACAPPLICATION): $(bin_PROGRAMS) $(MACCONTENTS) cp $(bin_PROGRAMS) $(MACEXECUTABLE) # Change install names to be relative to the executable in the application movelibraries.sh $(MACAPPLICATION) `pkg-config --variable=libdir gtk+-2.0` install_name_tool \ `otool -L $(MACEXECUTABLE) | sed -n '\:/libgtkdatabox: s/\(.*\/\)\(.*\) (.*/-change \1\2 @executable_path\/..\/Frameworks\/\2 /p'` \ $(MACEXECUTABLE) touch $(MACAPPLICATION) # create distribution disk image macdist: $(MACDISK).dmg $(MACDISK).dmg: $(MACAPPLICATION) AUTHORS COPYING COPYING.LESSER NEWS ChangeLog macdistdir README-Mac.txt test -z $(MACDISK).dmg || rm -f $(MACDISK).dmg cp -fp AUTHORS COPYING COPYING.LESSER NEWS ChangeLog macdistdir cp -fp README-Mac.txt macdistdir/README hdiutil create -srcfolder macdistdir -fs HFS+J -volname $(MACDISK) $(MACDISK).dmg clean-local: -rm -rf macdistdir ############################################# endif brp-pacu/COPYING.LESSER0000644000175000017500000001672712153127664013304 0ustar miramira GNU LESSER GENERAL PUBLIC LICENSE Version 3, 29 June 2007 Copyright (C) 2007 Free Software Foundation, Inc. Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. This version of the GNU Lesser General Public License incorporates the terms and conditions of version 3 of the GNU General Public License, supplemented by the additional permissions listed below. 0. Additional Definitions. As used herein, "this License" refers to version 3 of the GNU Lesser General Public License, and the "GNU GPL" refers to version 3 of the GNU General Public License. "The Library" refers to a covered work governed by this License, other than an Application or a Combined Work as defined below. An "Application" is any work that makes use of an interface provided by the Library, but which is not otherwise based on the Library. Defining a subclass of a class defined by the Library is deemed a mode of using an interface provided by the Library. A "Combined Work" is a work produced by combining or linking an Application with the Library. The particular version of the Library with which the Combined Work was made is also called the "Linked Version". The "Minimal Corresponding Source" for a Combined Work means the Corresponding Source for the Combined Work, excluding any source code for portions of the Combined Work that, considered in isolation, are based on the Application, and not on the Linked Version. The "Corresponding Application Code" for a Combined Work means the object code and/or source code for the Application, including any data and utility programs needed for reproducing the Combined Work from the Application, but excluding the System Libraries of the Combined Work. 1. Exception to Section 3 of the GNU GPL. You may convey a covered work under sections 3 and 4 of this License without being bound by section 3 of the GNU GPL. 2. Conveying Modified Versions. If you modify a copy of the Library, and, in your modifications, a facility refers to a function or data to be supplied by an Application that uses the facility (other than as an argument passed when the facility is invoked), then you may convey a copy of the modified version: a) under this License, provided that you make a good faith effort to ensure that, in the event an Application does not supply the function or data, the facility still operates, and performs whatever part of its purpose remains meaningful, or b) under the GNU GPL, with none of the additional permissions of this License applicable to that copy. 3. Object Code Incorporating Material from Library Header Files. The object code form of an Application may incorporate material from a header file that is part of the Library. You may convey such object code under terms of your choice, provided that, if the incorporated material is not limited to numerical parameters, data structure layouts and accessors, or small macros, inline functions and templates (ten or fewer lines in length), you do both of the following: a) Give prominent notice with each copy of the object code that the Library is used in it and that the Library and its use are covered by this License. b) Accompany the object code with a copy of the GNU GPL and this license document. 4. Combined Works. You may convey a Combined Work under terms of your choice that, taken together, effectively do not restrict modification of the portions of the Library contained in the Combined Work and reverse engineering for debugging such modifications, if you also do each of the following: a) Give prominent notice with each copy of the Combined Work that the Library is used in it and that the Library and its use are covered by this License. b) Accompany the Combined Work with a copy of the GNU GPL and this license document. c) For a Combined Work that displays copyright notices during execution, include the copyright notice for the Library among these notices, as well as a reference directing the user to the copies of the GNU GPL and this license document. d) Do one of the following: 0) Convey the Minimal Corresponding Source under the terms of this License, and the Corresponding Application Code in a form suitable for, and under terms that permit, the user to recombine or relink the Application with a modified version of the Linked Version to produce a modified Combined Work, in the manner specified by section 6 of the GNU GPL for conveying Corresponding Source. 1) Use a suitable shared library mechanism for linking with the Library. A suitable mechanism is one that (a) uses at run time a copy of the Library already present on the user's computer system, and (b) will operate properly with a modified version of the Library that is interface-compatible with the Linked Version. e) Provide Installation Information, but only if you would otherwise be required to provide such information under section 6 of the GNU GPL, and only to the extent that such information is necessary to install and execute a modified version of the Combined Work produced by recombining or relinking the Application with a modified version of the Linked Version. (If you use option 4d0, the Installation Information must accompany the Minimal Corresponding Source and Corresponding Application Code. If you use option 4d1, you must provide the Installation Information in the manner specified by section 6 of the GNU GPL for conveying Corresponding Source.) 5. Combined Libraries. You may place library facilities that are a work based on the Library side by side in a single library together with other library facilities that are not Applications and are not covered by this License, and convey such a combined library under terms of your choice, if you do both of the following: a) Accompany the combined library with a copy of the same work based on the Library, uncombined with any other library facilities, conveyed under the terms of this License. b) Give prominent notice with the combined library that part of it is a work based on the Library, and explaining where to find the accompanying uncombined form of the same work. 6. Revised Versions of the GNU Lesser General Public License. The Free Software Foundation may publish revised and/or new versions of the GNU Lesser General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. Each version is given a distinguishing version number. If the Library as you received it specifies that a certain numbered version of the GNU Lesser General Public License "or any later version" applies to it, you have the option of following the terms and conditions either of that published version or of any later version published by the Free Software Foundation. If the Library as you received it does not specify a version number of the GNU Lesser General Public License, you may choose any version of the GNU Lesser General Public License ever published by the Free Software Foundation. If the Library as you received it specifies that a proxy can decide whether future versions of the GNU Lesser General Public License shall apply, that proxy's public statement of acceptance of any version is permanent authorization for you to choose that version for the Library. brp-pacu/gui.c0000644000175000017500000015061212153127664012175 0ustar miramira/* * gui.c : Creates the gui, updates the gui, and handles or triggers * all gui events. * * * Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) * Macintosh code Copyright (C) 2009 Andreas Schwab * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. */ #include #ifdef __APPLE__ #include #include #include "ige-mac-menu.h" #include "ige-mac-dock.h" #endif #include #include #include #include #include //#include #include #include #include #include #include #include "gui.h" #include "testfft.h" #include "config.h" #define COLOR_T {0,90,90,90} ///////////////////////////////////////////// // LED Pixmap stuff static GdkPixmap *measured_pixmap = NULL; static GdkPixmap *reference_pixmap = NULL; static GtkWidget *measured_draw; static GtkWidget *reference_draw; ///////////////////////////////////////////// static GtkDataboxGraph **graph; static GtkDataboxGraph *graph_impulse; static GtkWidget *window = NULL; static GtkWidget *box; static GtkWidget *impulse_box; static GtkWidget *about_me_window = NULL; static GtkWidget *about_ok = NULL; static GtkWidget *delay_window = NULL; static GtkWidget *impulse_window = NULL; static GtkWidget *volume_pink_gui = NULL; static GtkWidget *pinknoise_button = NULL; static GtkToggleAction *pinknoise_menu_item = NULL; static GtkWidget *transfer_function_toggle = NULL; static GtkToggleAction *transfer_function_menu = NULL; static GtkWidget *buffer_button[N_BUFF] = { NULL, NULL, NULL, NULL, NULL }; static GtkToggleAction *buffer_menu[N_BUFF] = { NULL, NULL, NULL, NULL, NULL }; static GtkWidget *preferences_dialog = NULL; static GtkWidget *smoothing_spin_button=NULL; static GtkWidget *averaging_spin_button=NULL; static gfloat volume_pink_value = 0; static gfloat *guiX = NULL; static gfloat *guiY = NULL; static gfloat *gui_impulse_Y = NULL; static gfloat *gui_impulse_X = NULL; static gfloat guiYBuf[N_BUFF][PLOT_PTS]; static gfloat guiYBufAvgHold[PLOT_PTS]; static GString *file_name_str = NULL; static GString *save_name_str = NULL; static char * home_string, *file_path1, *file_path2; static char pinknoise_muted = 0; static char update_delay = 0; static char buffer[N_BUFF] = {2, 2, 2, 2, 2}; static gfloat grid_x[] = {32.0, 64.0, 128.0, 256.0, 512.0, 1024.0, 2048.0, 4096.0, 8192.0, 16384.0}; static guint avg_num; static gfloat avg_gain = 0; static int buffer_last_clicked; static GtkWidget *bkg_dialog; // static GtkWidget *cb; static GtkAction *save_now; static GtkAction *save_as; static GtkAction *open_menuitem; static gint avg_index = 0; static gchar tf = 1; static gfloat avgY[PLOT_PTS][MAX_AVG_NUM]; static gint gui_idle = 0; static gfloat gui_frequency = 3. * G_PI / 2.; static GtkWidget *gui_label = NULL; static GtkWidget *gui_db_label = NULL; static GtkWidget *gui_status_delay_label = NULL; static GtkWidget *gui_sb_label = NULL; static GtkWidget *gui_sb = NULL; static GtkWidget *open_dialog = NULL; static GtkWidget *save_as_dialog = NULL; static guint gui_counter = 0; static guint smooth_factor; static guint smooth_constant; static GdkColor background_color; static GdkColor grid_color; static GdkColor trace_transfer_color; static GdkColor trace_impulse_color; static GdkColor line_color[N_BUFF] = { //unused, red, green, blue {0, 16384 , 16384 , 65535 }, {0, 0 , 62000 , 0 }, {0, 65535 , 0 , 0 }, {0, 65535 , 16384 , 65535 }, {0, 65535 , 65535 , 65535 } }; static GdkColor myColor1 = { 0, 0x3333, 0x3333, 0x3333 }; static GdkColor myColor2 = { 0, 0x3333, 0x3333, 0x3333 }; void message(char * format, char* text, gboolean error) { fprintf(stderr, format, text); fprintf(stderr, "\n"); GtkWidget* dialog = gtk_message_dialog_new (GTK_WINDOW(window), GTK_DIALOG_DESTROY_WITH_PARENT, error ? GTK_MESSAGE_ERROR : GTK_MESSAGE_WARNING, GTK_BUTTONS_CLOSE, format, text); gtk_window_set_position(GTK_WINDOW(dialog), GTK_WIN_POS_CENTER); gtk_window_set_decorated (GTK_WINDOW(dialog), FALSE); gtk_window_present (GTK_WINDOW(dialog)); gtk_dialog_run (GTK_DIALOG (dialog)); gtk_widget_destroy (dialog); } gboolean gui_idle_func (struct FFT_Frame *data) { gfloat tmp[PLOT_PTS]; gint smoothing; gint index; gint i; gint j, k; gint max; gfloat temp, max_x, min_x, max_y, min_y, tmp_spin; gchar * label = NULL; GdkGC *gc1 = NULL; GdkGC *gc2 = NULL; if (!GTK_IS_DATABOX (box)) { fprintf(stderr, "Box not a gtk_databox\n"); return FALSE; } gc1 = gdk_gc_new(measured_draw->window); gc2 = gdk_gc_new(reference_draw->window); ///// label = g_new0(gchar*, 10); data->pink_muted = pinknoise_muted; data->volume_pink = volume_pink_value; avg_index++; if (avg_index >= avg_num) avg_index = 0; min_y = 0.0; max_y = 0.0; if (data->find_impulse == 2) { for (i = 0; i < N_FFT; i++) { index = i; temp = (gfloat)data->rfft_returned_1[index] ; gui_impulse_Y[i] = temp; //printf(" %g %g ", temp, gui_impulse_Y[i]); if (temp > max_y) max_y = temp; if (temp < min_y) min_y = temp; } } else { for (i = 0; i < PLOT_PTS; i++) { if (tf) avgY[i][avg_index] = (0.0 + 20.0 * log10((gfloat)data->fft_returned_1[i] / \ (gfloat)data->fft_returned_2[i])); else avgY[i][avg_index] = (0.0 + 20.0 * log10((gfloat)data->fft_returned_1[i])); // avgY[i][avg_index] = (20*log10((gfloat)data->fft_returned_1[index]+1)); tmp[i] = 0; for (k = 0; k < avg_num; k++) { tmp[i] += avgY[i][k]; } tmp[i] /= avg_num; //guiY[i] = avgY[i][0]; } } smoothing=1; for (i = 0; i < PLOT_PTS; i += smoothing) { guiY[i] = tmp[i]; for (j = 1; j <= smoothing; j++) { guiY[i] += tmp[(i-j)>=0?(i-j):0]; guiY[i] += tmp[(i+j)=0?(i-j):0] = guiY[i] * (smoothing - j) / smoothing + guiY[(i-smoothing)>=0?(i-smoothing):0] * (j) / smoothing; guiY[(i+j)find_impulse == 2) { min_x = 0.0; max_x = ((gfloat) N_FFT) / NYQUIST; gtk_databox_set_total_limits (GTK_DATABOX (impulse_box), min_x, max_x, max_y, \ min_y); gtk_widget_queue_draw(GTK_WIDGET (impulse_box)); data->find_impulse = 0; } if (data->find_delay == 1) { label = g_strdup_printf ( "Finding Delay....." ); //data->delay_size); gtk_label_set_markup (GTK_LABEL (gui_sb_label), label); g_free((gpointer)label); } if (data->find_delay == 2) { label = g_strdup_printf ( " Found: %g secs ", (float) data->delay_size * (1.0 / (float)FSAMP) ); //data->delay_size); gtk_label_set_markup (GTK_LABEL (gui_sb_label), label); g_free((gpointer)label); data->find_delay = 0; } if (update_delay) { tmp_spin = gtk_spin_button_get_value_as_float(GTK_SPIN_BUTTON (gui_sb)); data->delay_size = (int) (((gfloat)tmp_spin) * (gfloat) FSAMP); update_delay = 0; gtk_widget_hide_all (delay_window); } label = g_strdup_printf ( "Delay %3.2f msecs", (float) data->delay_size * (1.0 / (float)FSAMP) * 1000.0 ); gtk_label_set_text (GTK_LABEL (gui_status_delay_label), label); g_free((gpointer)label); /////////////////////////////////////////////////////////////////////////////////////////////////// //LED Color Choosing & rendering max = 0; for (k = N_FFT - 2000; k < N_FFT; k++) { if (max < data->buffer_data_1[k]) max = data->buffer_data_1[k]; } if (max > 20000) { myColor1.red = 0xFFFF; myColor1.green = 0x3333; myColor1.blue = 0x3333; } else if (max > 5000) { myColor1.red = 0xCCCC; myColor1.green = 0xFFFF; myColor1.blue = 0x3333; } else if (max > 1000) { myColor1.red = 0x3333; myColor1.green = 0xDDDD; myColor1.blue = 0x3333; } else if (max > 40) { myColor1.red = 0x3333; myColor1.green = 0x8888; myColor1.blue = 0x3333; } else { myColor1.red = 0x0000; myColor1.green = 0x0000; myColor1.blue = 0x0000; } gdk_gc_set_rgb_fg_color (gc1, &myColor1); gdk_draw_rectangle (measured_pixmap, gc1, TRUE, 7, 7, 16, 16); gdk_draw_drawable (measured_draw->window, measured_draw->style->fg_gc[GTK_WIDGET_STATE (measured_draw)], measured_pixmap, 5, 5, 5, 5, 20, 20); max = 0; for (k = N_FFT - 2000; k < N_FFT; k++) { if (max < data->buffer_data_2[k]) max = data->buffer_data_2[k]; } if (max > 20000) { myColor2.red = 0xFFFF; myColor2.green = 0x3333; myColor2.blue = 0x3333; } else if (max > 5000) { myColor2.red = 0xCCCC; myColor2.green = 0xFFFF; myColor2.blue = 0x3333; } else if (max > 1000) { myColor2.red = 0x3333; myColor2.green = 0xDDDD; myColor2.blue = 0x3333; } else if (max > 40) { myColor2.red = 0x3333; myColor2.green = 0x8888; myColor2.blue = 0x3333; } else { myColor2.red = 0x0000; myColor2.green = 0x0000; myColor2.blue = 0x0000; } gdk_gc_set_rgb_fg_color (gc2, &myColor2); //gdk_gc_set_rgb_fg_color (gc2, &myColor); gdk_draw_rectangle (reference_pixmap, gc2, TRUE, 7, 7, 16, 16); gdk_draw_drawable (reference_draw->window, reference_draw->style->fg_gc[GTK_WIDGET_STATE (reference_draw)], reference_pixmap, 5, 5, 5, 5, 20, 20); ///////////////////////////////////////////////////////////////////////////////////////////////////// gtk_widget_queue_draw(GTK_WIDGET (box)); g_object_unref(gc1); g_object_unref(gc2); return TRUE; } static void delay_custom_cb(GtkWidget *widget)// , gtkwidget *widget) { update_delay = 1; } static void pinknoise_mute(GtkWidget *widget, char * data)// , gtkwidget *widget) { if (strcmp(data, "menu") == 0) // what button was pressed { if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (pinknoise_button)) != gtk_toggle_action_get_active(pinknoise_menu_item) ) // is this the first call { gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (pinknoise_button), !gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (pinknoise_button)) ); pinknoise_muted ^= 1; } } else { if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (pinknoise_button)) != gtk_toggle_action_get_active(pinknoise_menu_item) ) // is this the first call { gtk_toggle_action_set_active(pinknoise_menu_item, !gtk_toggle_action_get_active(pinknoise_menu_item)); pinknoise_muted ^= 1; } } } static void volume_gui(GtkWidget *widget)// , gtkwidget *widget) { volume_pink_value = gtk_spin_button_get_value_as_float(GTK_SPIN_BUTTON (volume_pink_gui)); } static void delay_keep_cb(GtkWidget *widget)// , gtkwidget *widget) { gtk_widget_hide_all (delay_window); } static gboolean about_ok_cb(GtkWidget *widget)// , gtkwidget *widget) { gtk_widget_hide_all (about_me_window); return TRUE; } static void about_me_cb(GtkWidget *widget)// , gtkwidget *widget) { gtk_widget_show_all (about_me_window); gtk_window_present (GTK_WINDOW(about_me_window)); } // Trigger the gui to do the transfer function static void transfer_function_toggled_cb(GtkWidget *widget) { if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (transfer_function_toggle))) { if (tf == 0) //Don't do anything if initiated by transfer_fxn_cb() { tf = 1; gtk_toggle_action_set_active(GTK_TOGGLE_ACTION(transfer_function_menu), TRUE); } } else { if (tf != 0) //Don't do anything if initiated by transfer_fxn_cb() { tf = 0; gtk_toggle_action_set_active(GTK_TOGGLE_ACTION(transfer_function_menu), FALSE); } } } static void transfer_fxn_cb(GtkWidget *widget) { if (gtk_toggle_action_get_active (GTK_TOGGLE_ACTION(transfer_function_menu))) { if (tf != 1) //Don't do anything if initiated by transfer_function_toggled_cb() { tf = 1; gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(transfer_function_toggle), TRUE); } } else { if (tf == 1) //Don't do anything if initiated by transfer_function_toggled_cb() { tf = 0; gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(transfer_function_toggle), FALSE); } } } // capture call back static void capture_cb(GtkWidget *widget, GtkWidget *box)// , gtkwidget *widget) { int i, k, write_output; float avg_avg = 0; FILE *file_handle; gint tmp_array[1]; if (buffer[buffer_last_clicked] == 1) // Is it on the screen? { if (buffer_last_clicked == N_BUFF - 1) // Is it the average buffer? { for (k = 0; k < PLOT_PTS; k++) { guiYBuf[N_BUFF-1][k] = 0.0; for (i = 0; i < N_BUFF - 1; i++) guiYBuf[N_BUFF-1][k] += guiYBuf[i][k]; guiYBuf[N_BUFF-1][k] /= 4.0; avg_avg += guiYBuf[N_BUFF-1][k] * (1.0 / ((float) PLOT_PTS)); // avg_avg gives us the //location of the preflipped avg on the dB scale } // printf("\n"); for (k = 0; k < PLOT_PTS; k++) { guiYBufAvgHold[k] = 0.0 - guiYBuf[N_BUFF-1][k] + (avg_avg * 2); guiYBuf[N_BUFF-1][k] = avg_gain + guiYBufAvgHold[k]; //printf(" %g ",guiYBuf[N_BUFF-1][k]); } // printf("\n"); } else // it is a regular buffer for (k = 0; k < PLOT_PTS; k++) guiYBuf[buffer_last_clicked][k] = guiY[k]; write_output = mkdir(file_path1, 0770); if ( ((write_output == -1) && (errno == EEXIST)) || (write_output == 0) ) write_output = 1; if ( write_output == 1) // The directory exists or was created { file_handle = fopen(file_path2, "wb"); if (file_handle == NULL) { write_output = 0; message("Could not open file %s, permissions issue?", file_path2, TRUE); } } if (write_output == 1) { tmp_array[0] = PLOT_PTS; printf("Writing %d elements per buffer to %s\n", tmp_array[0], file_path2); fwrite (tmp_array, sizeof(gint), 1, file_handle ); for (i = 0; i < N_BUFF; i++) fwrite (guiYBuf[i], sizeof(gfloat), PLOT_PTS, file_handle ); fclose(file_handle); } } } // Increase/Decrease the gain of Averaging buffer static void gain_cb( GtkWidget *widget, GtkSpinButton *spin ) { int k; avg_gain = gtk_spin_button_get_value_as_float (spin); for (k = 0; k < PLOT_PTS; k++) guiYBuf[N_BUFF - 1][k] = avg_gain + guiYBufAvgHold[k]; } // Handle addition/removal of the individual buffers static void buffer_button_cb(GtkWidget *widget, gpointer p) { gint i; i = GPOINTER_TO_INT(p); if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (buffer_button[i]))) { if (buffer[i] != 1) //Don't do anything if initiated by buffer_button_cb() { gtk_databox_graph_add (GTK_DATABOX(box), graph[i+1]); buffer[i] = 1; // Its not on the screen gtk_toggle_action_set_active( buffer_menu[i], TRUE); } } else { if (buffer[i] == 1) //Don't do anything if initiated by buffer_button_cb() { gtk_databox_graph_remove (GTK_DATABOX(box), graph[i+1]); buffer[i] = 0; // Its on the screen gtk_toggle_action_set_active( buffer_menu[i], FALSE); } } buffer_last_clicked = i; } static void buffer_menu_cb(GtkWidget *widget, gpointer p) { gint i; i = GPOINTER_TO_INT(p); if (gtk_toggle_action_get_active ( buffer_menu[i])) { if (buffer[i] != 1) //Don't do anything if initiated by buffer_button_cb() { gtk_databox_graph_add (GTK_DATABOX(box), graph[i+1]); buffer[i] = 1; // Its not on the screen gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (buffer_button[i]), TRUE); } } else { if (buffer[i] == 1) //Don't do anything if initiated by buffer_button_cb() { gtk_databox_graph_remove (GTK_DATABOX(box), graph[i+1]); buffer[i] = 0; // Its on the screen gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (buffer_button[i]), FALSE); } } buffer_last_clicked = i; } // cleanup and quit static void cleanup_gui(GtkWidget *widget, struct FFT_Frame * data) { if (open_dialog) gtk_widget_destroy (GTK_WIDGET(open_dialog)); if (save_as_dialog) gtk_widget_destroy (GTK_WIDGET(save_as_dialog)); gtk_main_quit(); printf("GUI is done with cleanup\n"); } void open_file(char *fn) { int k; FILE *file_handle; gint read_plot_pts[1]; printf("%s is being opened\n", fn ); file_handle = fopen( fn, "rb"); if (file_handle != NULL) { fread (read_plot_pts, sizeof(gint), 1, file_handle ); if (read_plot_pts[0] == PLOT_PTS) { for (k = 0; k < N_BUFF; k++) fread (guiYBuf[k], sizeof(gfloat), PLOT_PTS, file_handle ); if (save_name_str) g_string_assign(save_name_str, fn); else save_name_str = g_string_new(fn); } else { message("Wrong file format", NULL, TRUE); fprintf (stderr, "PLOT_PTS is different from PLOT_PTS last captured size."); fprintf (stderr, "N_FFT has been changed from N_FFT=%d * 2 since your last capture.\n", (int) read_plot_pts ); } } else message("Couldn't open file %s for reading\n", fn, TRUE); fclose(file_handle); } static void save_file(char* fn) { int k; gint tmp_array[1]; FILE *file_handle; printf("%s is being saved\n", fn); /* for (k = 0; k < PLOT_PTS; k++) { printf("%g*",guiYBufAvg[k]); } */ file_handle = fopen(fn, "wb"); if (file_handle != NULL) { tmp_array[0] = PLOT_PTS; fwrite (tmp_array, sizeof(gint), 1, file_handle ); for (k = 0; k < N_BUFF; k++) fwrite (guiYBuf[k], sizeof(gfloat), PLOT_PTS, file_handle ); if (save_name_str) g_string_assign(save_name_str, fn); else save_name_str = g_string_new(fn); fclose(file_handle); } else message("Couldn't open file %s for writing. Usually this is a permissions issue.", fn, TRUE); } #ifdef __APPLE__ static char strBuffer[PATH_MAX]; // To open a file, pass docList containing one record with the file to open // and set basename to NULL. // To save a flle, pass basename with the file name // and docList containing one record with the encloseing folder // doclist must contain exactly one entry. static OSStatus DoOpenSave(AEDescList docList, CFStringRef basename) { FSRef theFSRef; long index = 1; long count = 0; OSErr osError; char bn[256]; osError = AECountItems(&docList, &count); if (osError == noErr) { if (count == 1) { if (osError == noErr) osError = AEGetNthPtr(&docList, index, typeFSRef, NULL, NULL, &theFSRef, sizeof(FSRef), NULL); if (osError == noErr) osError = FSRefMakePath(&theFSRef, (UInt8 *) strBuffer, PATH_MAX); if (osError == noErr) { if (basename) { if (CFStringGetCString(basename, bn, 256, kCFStringEncodingUTF8)) { strcat(strBuffer, "/"); strcat(strBuffer, bn); } save_file(strBuffer); } else open_file(strBuffer); return(0); } } else message("Cannot open more than one file at a time.", NULL, TRUE); return(0); } fprintf(stderr, "OS X error %d\n", (int)osError); return(0); } // Handler function for opening files from the OS X finder // such as double-click on a data file OSErr openAndPrintDocsEventHandler(AppleEvent *theAppleEvent, AppleEvent *reply, SInt32 handlerRefcon) { AEDescList docList; OSErr osError; osError = AEGetParamDesc(theAppleEvent, keyDirectObject, typeAEList, &docList); if (osError == noErr) osError = DoOpenSave(docList, NULL); fprintf(stderr, "OS X error %d\n", (int)osError); return(0); } static void open_cb(GtkWidget *widget, char *data) { OSStatus status; NavDialogCreationOptions navOptions; CFStringRef uti; CFMutableArrayRef identifiers; NavDialogRef theDialog = NULL; status = NavGetDefaultDialogCreationOptions(&navOptions); require_noerr(status, NavGetDefaultDialogCreationOptions); navOptions.preferenceKey = 1; navOptions.optionFlags &= ~kNavAllowMultipleFiles; gtk_action_set_sensitive(open_menuitem, 0); gtk_action_set_sensitive(save_as, 0); gtk_action_set_sensitive(save_now, 0); status = NavCreateGetFileDialog(&navOptions, NULL, NULL, NULL, NULL, NULL, &theDialog); require_noerr(status, NavCreateChooseFileDialog); // BRP-PACU can open files with the ".brp" extension identifiers = CFArrayCreateMutable( kCFAllocatorDefault, 0, &kCFTypeArrayCallBacks ); require_action( identifiers != NULL, CantCreateChooseFileFilterIdentifiers, status = coreFoundationUnknownErr ); // create the image browser UTI conforming to "public.data" because it's a data file rather than a bundle uti = UTTypeCreatePreferredIdentifierForTag( kUTTagClassFilenameExtension, CFSTR("brp"), kUTTypeData ); require_action( uti != NULL, CantCreateImageBrowserUTI, status = coreFoundationUnknownErr ); CFArrayAppendValue( identifiers, uti ); // filter by image browser UTI status = NavDialogSetFilterTypeIdentifiers( theDialog, identifiers ); require_noerr( status, CantSetChooseFileFilterIdentifiers ); status = NavDialogRun(theDialog); require_noerr(status, NavDialogRun); NavReplyRecord aNavReplyRecord; status = NavDialogGetReply(theDialog, &aNavReplyRecord); require((status == noErr) || (status == userCanceledErr), NavDialogGetReply); if (aNavReplyRecord.validRecord) status = DoOpenSave(aNavReplyRecord.selection, NULL); else status = userCanceledErr; NavDialogGetReply: NavDisposeReply(&aNavReplyRecord); CantCreateChooseFileFilterIdentifiers: CantCreateImageBrowserUTI: // coreFoundationUnknownErr: CantSetChooseFileFilterIdentifiers: NavDialogRun: NavCreateChooseFileDialog: NavGetDefaultDialogCreationOptions: if (status && status != userCanceledErr) fprintf(stderr, "OS X error %d\n", (int) status); if (theDialog != NULL) NavDialogDispose(theDialog); gtk_action_set_sensitive(save_as, 1); gtk_action_set_sensitive(save_now, 1); gtk_action_set_sensitive(open_menuitem, 1); return; } // static OSStatus Do_SaveAs(WindowRef inWindow) static void save_as_cb(GtkWidget *widget, char *data) { OSStatus status = noErr; CFStringRef theFileName; NavDialogCreationOptions navOptions; status = NavGetDefaultDialogCreationOptions(&navOptions); require_noerr(status, NavGetDefaultDialogCreationOptions); theFileName = CFStringCreateWithCString (NULL, save_name_str ? strrchr(save_name_str->str, '/') + 1 : "Untitled.brp", kCFStringEncodingUTF8); CFMutableStringRef newFileName = CFStringCreateMutableCopy(NULL, 0, theFileName); CFRelease(theFileName); CFIndex len = CFStringGetLength(newFileName); if (len > 255) len = 255; UniChar buffer[255]; CFStringGetCharacters(newFileName, CFRangeMake(0, len), buffer); UniCharCount extIndex; status = LSGetExtensionInfo(len, buffer, &extIndex); require_noerr(status, LSGetExtensionInfo); if (extIndex != kLSInvalidExtensionIndex) CFStringReplace(newFileName, CFRangeMake(extIndex, len - extIndex), CFSTR("brp")); else CFStringAppend(newFileName, CFSTR(".brp")); navOptions.preferenceKey = 2; navOptions.optionFlags |= kNavPreserveSaveFileExtension; navOptions.saveFileName = newFileName; NavDialogRef theDialog = NULL; gtk_action_set_sensitive(open_menuitem, 0); gtk_action_set_sensitive(save_as, 0); gtk_action_set_sensitive(save_now, 0); status = NavCreatePutFileDialog(&navOptions, (OSType) NULL, (OSType) "BRPP", NULL, NULL, &theDialog); CFRelease(newFileName); require_noerr(status, NavCreatePutFileDialog); status = NavDialogRun(theDialog); require_noerr(status, NavDialogRun); NavReplyRecord aNavReplyRecord; status = NavDialogGetReply(theDialog, &aNavReplyRecord); require((status == noErr) || (status == userCanceledErr), NavDialogGetReply); if (aNavReplyRecord.validRecord) status = DoOpenSave(aNavReplyRecord.selection, aNavReplyRecord.saveFileName); else status = userCanceledErr; NavDialogRun: NavCreatePutFileDialog: LSGetExtensionInfo: NavGetDefaultDialogCreationOptions: NavDialogGetReply: if (status && status != userCanceledErr) fprintf(stderr, "OS X error %d\n", (int) status); if (theDialog != NULL) NavDialogDispose(theDialog); gtk_action_set_sensitive(save_as, 1); gtk_action_set_sensitive(save_now, 1); gtk_action_set_sensitive(open_menuitem, 1); return; } // Do_SaveAs #else static void open_cb(GtkWidget *widget, char *data) { GtkFileFilter *file_filter = NULL; gint result; if (open_dialog != NULL) { gtk_window_present (GTK_FILE_CHOOSER(open_dialog)); return(0); } open_dialog = gtk_file_chooser_dialog_new ("Open Capture Buffers From", GTK_WINDOW(bkg_dialog), GTK_FILE_CHOOSER_ACTION_OPEN, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OPEN, GTK_RESPONSE_ACCEPT, NULL); // if(save_name_str) // gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(open_dialog),save_name_str->str); // else // gtk_file_chooser_set_current_folder(GTK_FILE_CHOOSER(open_dialog),home_string); file_filter = gtk_file_filter_new (); gtk_file_filter_add_pattern (file_filter, "*.brp"); gtk_file_filter_set_name(file_filter, "BRP-PACU files"); gtk_file_chooser_set_filter (GTK_FILE_CHOOSER(open_dialog), GTK_FILE_FILTER(file_filter)); gtk_window_set_transient_for(GTK_WINDOW(open_dialog), GTK_WINDOW(window)); gtk_action_set_sensitive(save_as, 0); gtk_action_set_sensitive(save_now, 0); result = gtk_dialog_run (GTK_DIALOG (open_dialog)); switch (result) { case GTK_RESPONSE_ACCEPT: open_file(gtk_file_chooser_get_filename (GTK_FILE_CHOOSER(open_dialog))); break; default: break; } gtk_widget_destroy (open_dialog); gtk_action_set_sensitive(save_as, 1); gtk_action_set_sensitive(save_now, 1); open_dialog = NULL; return; } static void save_as_cb(GtkWidget *widget, char *data) { gint result; GtkFileFilter *file_filter = NULL; char* file_name, * extension; if (save_as_dialog != NULL) { gtk_window_present (GTK_WINDOW(save_as_dialog)); return; } save_as_dialog = gtk_file_chooser_dialog_new ("Save Capture Buffers As (*.brp recommended)", GTK_WINDOW(bkg_dialog), GTK_FILE_CHOOSER_ACTION_SAVE, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_SAVE_AS, GTK_RESPONSE_ACCEPT, NULL); if (save_name_str) gtk_file_chooser_set_filename(GTK_FILE_CHOOSER(save_as_dialog), save_name_str->str); file_filter = gtk_file_filter_new (); gtk_file_filter_add_pattern (file_filter, "*.brp"); gtk_file_filter_set_name(file_filter, "BRP-PACU files"); gtk_file_chooser_set_filter (GTK_FILE_CHOOSER(save_as_dialog), GTK_FILE_FILTER(file_filter)); gtk_window_set_transient_for(GTK_WINDOW(save_as_dialog), GTK_WINDOW(window)); gtk_file_chooser_set_do_overwrite_confirmation (GTK_FILE_CHOOSER (save_as_dialog), TRUE); gtk_action_set_sensitive(open_menuitem, 0); if (save_name_str) g_string_assign(file_name_str, save_name_str->str); while (TRUE) { file_name = strrchr(file_name_str->str, '/'); file_name = file_name ? file_name + 1 : file_name_str->str; gtk_file_chooser_set_current_name(GTK_FILE_CHOOSER(save_as_dialog), file_name); result = gtk_dialog_run (GTK_DIALOG (save_as_dialog)); file_name = gtk_file_chooser_get_filename (GTK_FILE_CHOOSER(save_as_dialog)); g_string_assign(file_name_str, file_name); file_name = file_name_str->str; extension = strrchr(file_name, '.'); if (extension && !strcmp(extension, ".brp")) break; g_string_append(file_name_str, ".brp"); } switch (result) { case GTK_RESPONSE_ACCEPT: save_file(file_name); break; default: break; } gtk_widget_destroy (save_as_dialog); save_as_dialog = NULL; gtk_action_set_sensitive(open_menuitem, 1); return; } #endif static void save_now_cb(GtkWidget *widget, char *data) { if (save_name_str) save_file(save_name_str->str); else save_as_cb(widget, data); } // Trigger the gtk callback to find the impulse response in BRP_PACU.c static void impulse_cb(GtkWidget *widget, struct FFT_Frame * data)// , gtkwidget *widget) { gtk_widget_show_all(impulse_window); gtk_window_present(GTK_WINDOW(impulse_window)); data->find_impulse = 1; // signal for Fill_Buffer fxn to find delay data->find_delay = 1; // signal for Fill_Buffer fxn to find delay } // Trigger the gtk callback to find the delay in BRP_PACU.c static void delay_cb(GtkWidget *widget, struct FFT_Frame * data)// , gtkwidget *widget) { gtk_window_set_transient_for(GTK_WINDOW(delay_window), GTK_WINDOW(window)); gtk_window_set_decorated (GTK_WINDOW(delay_window), FALSE); gtk_widget_show_all(delay_window); gtk_window_present (GTK_WINDOW(delay_window)); data->find_delay = 1; // signal for Fill_Buffer fxn to find delay } static void resize_default_cb(GtkWidget *widget, GtkWidget *box )// , GtkWidget *widget) { gfloat min_x, min_y, max_x, max_y; min_x = 20.0; max_x = (gfloat) NYQUIST; min_y = -100.0; max_y = 100.0; gtk_databox_set_total_limits (GTK_DATABOX (box), min_x, max_x, max_y, \ min_y); gtk_widget_queue_draw(GTK_WIDGET (box)); } // Auto-resizing function static void resize_cb(GtkWidget *widget, GtkWidget *box )// , GtkWidget *widget) { gint k; gfloat min_x, min_y, max_x, max_y, tempY; min_x = 20.0; max_x = (gfloat) NYQUIST; max_y = -100.0; min_y = 100.0; for (k = (int) (min_x / (gfloat)FBIN); k < PLOT_PTS - 10; k++) { tempY = guiY[k]; max_y = (max_y > tempY) ? max_y : tempY; min_y = (min_y < tempY) ? min_y : tempY; } gtk_databox_set_visible_limits (GTK_DATABOX (box), min_x, max_x, max_y + 5.0, \ min_y - 5.0); gtk_widget_queue_draw(GTK_WIDGET (box)); } // update the frequency and dB level labels static gint show_motion_notify_cb(GtkWidget *widget, GdkEventMotion *event)// , GtkWidget *widget) { gfloat x; gfloat y; GtkDatabox *box_coords = GTK_DATABOX (widget); // GtkDataboxValueRectangle value; x = gtk_databox_pixel_to_value_x (box_coords, event->x); y = gtk_databox_pixel_to_value_y (box_coords, event->y); gchar *label; //y= (gfloat)y; label = g_strdup_printf ( "%5.1f Hz", x); gtk_label_set_text (GTK_LABEL (gui_label), label); g_free((gpointer)label); label = g_strdup_printf ( "%3.2f dB", (y) ); gtk_label_set_text (GTK_LABEL (gui_db_label), label); g_free((gpointer)label); return FALSE; } //////////////////////////////////// /* LED Signal stuff: Create a new backing pixmap of the appropriate size * Part of gui initialization*/ static gboolean configure_event_measured( GtkWidget *widget, GdkEventConfigure *event ) { //GdkColor *myColor; GdkGC *gc = NULL; gc = gdk_gc_new(measured_draw->window); // red grn blu GdkColor myColor = { 0, 0x8888, 0x8888, 0x8888 }; gdk_gc_set_rgb_fg_color (gc, &myColor); if (measured_pixmap) g_object_unref (measured_pixmap); measured_pixmap = gdk_pixmap_new (measured_draw->window, widget->allocation.width, widget->allocation.height, -1); gdk_draw_rectangle (measured_pixmap, gc, TRUE, 0, 0, widget->allocation.width, widget->allocation.height); myColor.red = 0x3333; myColor.green = 0x3333; myColor.blue = 0x3333; gdk_gc_set_rgb_fg_color (gc, &myColor); gdk_draw_rectangle (measured_pixmap, gc, TRUE, 7, 7, 16, 16); g_object_unref(gc); return TRUE; } static gboolean configure_event_reference( GtkWidget *widget, GdkEventConfigure *event ) { //GdkColor *myColor; GdkGC *gc = NULL; gc = gdk_gc_new(reference_draw->window); // red grn blu GdkColor myColor = { 0, 0x8888, 0x8888, 0x8888 }; gdk_gc_set_rgb_fg_color (gc, &myColor); if (reference_pixmap) g_object_unref (reference_pixmap); reference_pixmap = gdk_pixmap_new (reference_draw->window, widget->allocation.width, widget->allocation.height, -1); gdk_draw_rectangle (reference_pixmap, gc, TRUE, 0, 0, widget->allocation.width, widget->allocation.height); myColor.red = 0x3333; myColor.green = 0x3333; myColor.blue = 0x3333; gdk_gc_set_rgb_fg_color (gc, &myColor); gdk_draw_rectangle (reference_pixmap, gc, TRUE, 7, 7, 16, 16); g_object_unref(gc); return TRUE; } static void preferences_dialog_cb(GtkWidget *widget)// , gtkwidget *widget) { gtk_window_set_transient_for(GTK_WINDOW(preferences_dialog), GTK_WINDOW(window)); gtk_window_set_decorated (GTK_WINDOW(preferences_dialog), FALSE); gtk_spin_button_set_value (GTK_SPIN_BUTTON(smoothing_spin_button), (gdouble) smooth_factor); gtk_spin_button_set_value (GTK_SPIN_BUTTON(averaging_spin_button), (gdouble) avg_num); gtk_widget_show_all(preferences_dialog); gtk_window_present (GTK_WINDOW(preferences_dialog)); } static gboolean close_preferences_cb(GtkWidget *widget)// , gtkwidget *widget) { gtk_widget_hide_all (preferences_dialog); return TRUE; } static void apply_preferences_cb( GtkWidget *widget) { smooth_factor = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON(smoothing_spin_button)); smooth_constant=pow(2,smooth_factor)-1; avg_num = gtk_spin_button_get_value_as_int (GTK_SPIN_BUTTON(averaging_spin_button)); } gboolean create_gui (struct FFT_Frame * data, char * datadir) { GtkWidget *box_container; GtkWidget *box_container_impulse; ///// GtkWidget *label; GtkWidget *table; GtkWidget *table_impulse; GtkWidget *separator; //// GtkRuler * hruler; GtkDataboxGraph *my_grid; GtkBuilder* builder = gtk_builder_new (); avg_num=32; smooth_factor=5; smooth_constant=pow(2,smooth_factor)-1; FILE * file_handle; gint read_plot_pts[1]; file_name_str = g_string_new("Untitled.brp"); char tmp_string[] = "BRP-PACU vxx.xx.xx "; char gtkbuilder_path[400]; graph = g_new0 (GtkDataboxGraph *, 10); // allocate memory graph array graph_impulse = g_new0 (GtkDataboxGraph, 1); // allocate memory graph array gint k; gint i; gfloat min_x, max_x, min_y, max_y; /* set the extrema */ min_x = 20.0; max_x = (gfloat) NYQUIST; min_y = -100.0; max_y = 100.0; guint done = 0; GError* error = NULL; #ifdef __APPLE__ // Find GtkBuilder file in application resource directory first CFURLRef xmlUrl = CFBundleCopyResourceURL(CFBundleGetMainBundle(), CFSTR("BRP_PACU"), CFSTR("ui"), NULL); if (xmlUrl != NULL) { char buffer[PATH_MAX]; if (CFURLGetFileSystemRepresentation(xmlUrl, true, (UInt8*) buffer, PATH_MAX)) done = gtk_builder_add_from_file (builder, buffer, &error); else done = 1; } else #endif //done = gtk_builder_add_from_file (builder, "BRP_PACU.ui", &error); sprintf(gtkbuilder_path, "%s/BRP_PACU.ui", datadir); if (done == 0) { if (gtk_builder_add_from_file (builder, gtkbuilder_path, &error) == 0) { //message("Couldn't load builder file:", NULL, TRUE); // gtk_builder_add_from_file throws error about the path fprintf(1,"\n\n-----------Error--------------\n\n\n"); return(FALSE); } } window = GTK_WIDGET (gtk_builder_get_object (builder, "window1")); bkg_dialog = GTK_WIDGET (gtk_builder_get_object (builder, "bkg_dialog")); about_me_window = GTK_WIDGET (gtk_builder_get_object (builder, "about_me_window")); about_ok = GTK_WIDGET (gtk_builder_get_object (builder, "about_ok")); delay_window = GTK_WIDGET (gtk_builder_get_object (builder, "delay1")); impulse_window = GTK_WIDGET (gtk_builder_get_object (builder, "impulse_window")); box_container = GTK_WIDGET (gtk_builder_get_object (builder, "vbox1")); gui_label = GTK_WIDGET (gtk_builder_get_object (builder, "label3")); gui_sb_label = GTK_WIDGET (gtk_builder_get_object (builder, "delay_label")); gui_sb = GTK_WIDGET (gtk_builder_get_object (builder, "spinbutton1")); gui_db_label = GTK_WIDGET (gtk_builder_get_object (builder, "label4")); save_as = GTK_ACTION (gtk_builder_get_object (builder, "save_as")); save_now = GTK_ACTION (gtk_builder_get_object (builder, "save_now")); open_menuitem = GTK_ACTION (gtk_builder_get_object (builder, "open")); box_container_impulse = GTK_WIDGET (gtk_builder_get_object (builder, "vbox_impulse")); measured_draw = GTK_WIDGET (gtk_builder_get_object (builder, "Measured_Draw")); reference_draw = GTK_WIDGET (gtk_builder_get_object (builder, "Reference_Draw")); gui_status_delay_label = GTK_WIDGET (gtk_builder_get_object (builder, "delay_status_label")); volume_pink_gui = GTK_WIDGET (gtk_builder_get_object (builder, "volumebutton1")); pinknoise_button = GTK_WIDGET (gtk_builder_get_object (builder, "pinknoise_button")); pinknoise_menu_item = GTK_TOGGLE_ACTION (gtk_builder_get_object (builder, "pink_noise")); transfer_function_toggle = GTK_WIDGET (gtk_builder_get_object (builder, "TransferFxn")); transfer_function_menu = GTK_TOGGLE_ACTION (gtk_builder_get_object (builder, "transfer_fxn")); preferences_dialog = GTK_WIDGET (gtk_builder_get_object (builder, "preferences_dialog")); smoothing_spin_button = GTK_WIDGET (gtk_builder_get_object (builder, "spinbutton_smoothing")); averaging_spin_button = GTK_WIDGET (gtk_builder_get_object (builder, "spinbutton_averaging")); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "plot_preferences")), "activate", G_CALLBACK (preferences_dialog_cb), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "close_preferences")), "clicked", G_CALLBACK (close_preferences_cb), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "apply_preferences")), "clicked", G_CALLBACK (apply_preferences_cb), NULL); g_signal_connect (GTK_OBJECT (preferences_dialog), "delete_event", G_CALLBACK (gtk_widget_hide_on_delete), NULL); gtk_window_set_decorated (GTK_WINDOW(preferences_dialog), FALSE); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "pinknoise_button")), "clicked", G_CALLBACK (pinknoise_mute), "button"); //g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "volumebutton1")), "popdown", G_CALLBACK (volume_popdown_gui), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "volumebutton1")), "value-changed", G_CALLBACK (volume_gui), NULL); // g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "volumebutton1")), "clicked", G_CALLBACK (volume_popup_gui), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "quit_ap")), "activate", G_CALLBACK (cleanup_gui), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "save_as")), "activate", G_CALLBACK (save_as_cb), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "save_now")), "activate", G_CALLBACK (save_now_cb), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "open")), "activate", G_CALLBACK (open_cb), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "about_me")), "activate", G_CALLBACK (about_me_cb), NULL); g_signal_connect (G_OBJECT (about_me_window), "delete_event", G_CALLBACK (gtk_widget_hide_on_delete), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "about_ok")), "clicked", G_CALLBACK (about_ok_cb), NULL); g_signal_connect (G_OBJECT (transfer_function_menu), "activate", G_CALLBACK (transfer_fxn_cb), NULL); g_signal_connect (G_OBJECT (transfer_function_toggle), "clicked", G_CALLBACK (transfer_function_toggled_cb), NULL); g_signal_connect (GTK_BUTTON (gtk_builder_get_object (builder, "find_delay")), "clicked", G_CALLBACK (delay_cb), data); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "find_delay_m")), "activate", G_CALLBACK (delay_cb), data); g_signal_connect (GTK_OBJECT (window), "destroy", G_CALLBACK (cleanup_gui), NULL); g_signal_connect (GTK_OBJECT (window), "delete_event", G_CALLBACK (cleanup_gui), NULL); g_signal_connect (GTK_OBJECT (delay_window), "delete_event", G_CALLBACK (gtk_widget_hide_on_delete), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "delay_keep_button")), "clicked", G_CALLBACK (delay_keep_cb), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "impulse_response")), "activate", G_CALLBACK (impulse_cb), data); g_signal_connect (GTK_OBJECT (impulse_window), "delete_event", G_CALLBACK (gtk_widget_hide_on_delete), NULL); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "pink_noise")), "activate", G_CALLBACK (pinknoise_mute), "menu"); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "delay_custom_button")), "clicked", G_CALLBACK (delay_custom_cb), NULL); gui_frequency = 0; gtk_widget_set_size_request (GTK_WIDGET(window), WINDOW_W, WINDOW_H); sprintf(tmp_string, "BRP-PACU v%s", VERSION); gtk_window_set_title (GTK_WINDOW (window), tmp_string); gtk_container_set_border_width (GTK_CONTAINER (window), 0); ///// Impulse response Window ///////////////////////// gtk_widget_set_size_request (impulse_window, IMPULSE_WINDOW_W, IMPULSE_WINDOW_H); sprintf(tmp_string, "BRP-PACU Impulse"); gtk_window_set_title (GTK_WINDOW (impulse_window), tmp_string); gtk_container_set_border_width (GTK_CONTAINER (impulse_window), 0); //////////////////////////////////////////////////////// separator = gtk_hseparator_new (); gtk_box_pack_start (GTK_BOX (box_container), separator, FALSE, FALSE, 0); gtk_label_set_text (GTK_LABEL (gui_label), "0"); gui_idle = 0; gui_frequency = 3. * G_PI / 2.; gui_counter = 0; // Create a GtkDatabox widget along with scrollbars and rulers gtk_databox_create_box_with_scrollbars_and_rulers (&box, &table, TRUE, TRUE, TRUE, TRUE); // Create a GtkDatabox widget for impulse response along with scrollbars and rulers gtk_databox_create_box_with_scrollbars_and_rulers (&impulse_box, &table_impulse, TRUE, TRUE, TRUE, TRUE); gtk_databox_set_total_limits (GTK_DATABOX (box), min_x, max_x, max_y, min_y); min_x = 30.0; max_x = (gfloat) NYQUIST; min_y = -100.0; max_y = 100.0; gtk_databox_set_total_limits (GTK_DATABOX (impulse_box), min_x, max_x, max_y, min_y); //hruler = gtk_databox_get_hruler (GTK_DATABOX(box)); //gtk_databox_set_scale_type_x (GTK_DATABOX (box), GTK_DATABOX_SCALE_LOG); gtk_databox_set_scale_type_x (GTK_DATABOX (box), GTK_DATABOX_SCALE_LOG2); gtk_databox_set_scale_type_y (GTK_DATABOX (box), GTK_DATABOX_SCALE_LINEAR); /*for(index=0; index<10; index++) hruler->metric->ruler_scale[index] = lscale[index]; */ //gtk_databox_set_hruler (box,hruler); g_signal_connect (G_OBJECT (box), "motion_notify_event", G_CALLBACK (show_motion_notify_cb), NULL); //g_signal_connect (G_OBJECT (hruler), "state_changed", G_CALLBACK (show_motion_notify_cb),NULL); gtk_box_pack_start (GTK_BOX (box_container), table, TRUE, TRUE, 0); gtk_box_pack_start (GTK_BOX (box_container_impulse), table_impulse, TRUE, TRUE, 0); background_color.red = 2048; background_color.green = 2048; background_color.blue = 2048; gtk_widget_modify_bg (box, GTK_STATE_NORMAL, &background_color); guiX = g_new0 (gfloat, PLOT_PTS); guiY = g_new0 (gfloat, PLOT_PTS); gui_impulse_Y = g_new0 (gfloat, N_FFT); gui_impulse_X = g_new0 (gfloat, N_FFT); for (i = 0; i < N_FFT / 2; i++) { gui_impulse_Y[i] = .01; gui_impulse_X[i] = ((gfloat)i) / ((gfloat)FSAMP); } for (i = 0; i < PLOT_PTS; i++) { guiX[i] = ((gfloat)i) * (gfloat)FBIN; for (k = 0; k < MAX_AVG_NUM; k++) avgY[i][k] = .01; guiY[i] = .01; for (k = 0; k < N_BUFF; k++) guiYBuf[k][i] = 0.0; guiYBufAvgHold[i] = 0.0; //guiY[i] = i * 40.0 / (float) PLOT_PTS - 20; } trace_transfer_color.red = 16384; trace_transfer_color.green = 65535; trace_transfer_color.blue = 45000; graph[0] = gtk_databox_lines_new (PLOT_PTS, guiX, guiY, &trace_transfer_color, 1); gtk_databox_graph_add (GTK_DATABOX (box), graph[0]); for (i = 0; i < N_BUFF; i++) graph[i+1] = gtk_databox_lines_new (PLOT_PTS, guiX, guiYBuf[i], &line_color[i], 1); grid_color.red = 65535; grid_color.green = 65535; grid_color.blue = 32767; my_grid = gtk_databox_grid_array_new (19, 10, NULL, grid_x, &grid_color, 1); //my_grid = gtk_databox_grid_new (19, 21.5, &grid_color, 1); gtk_databox_graph_add (GTK_DATABOX (box), my_grid); trace_impulse_color.red = 16384; trace_impulse_color.green = 16384; trace_impulse_color.blue = 65535; graph_impulse = gtk_databox_lines_new (PLOT_PTS, gui_impulse_X, gui_impulse_Y, &trace_impulse_color, 1); gtk_databox_graph_add (GTK_DATABOX (impulse_box), graph_impulse); buffer_button[0] = GTK_WIDGET (gtk_builder_get_object (builder, "buff1")); buffer_button[1] = GTK_WIDGET (gtk_builder_get_object (builder, "buff2")); buffer_button[2] = GTK_WIDGET (gtk_builder_get_object (builder, "buff3")); buffer_button[3] = GTK_WIDGET (gtk_builder_get_object (builder, "buff4")); buffer_button[4] = GTK_WIDGET (gtk_builder_get_object (builder, "buffAvg")); buffer_menu[0] = GTK_TOGGLE_ACTION (gtk_builder_get_object (builder, "buffer_1")); buffer_menu[1] = GTK_TOGGLE_ACTION (gtk_builder_get_object (builder, "buffer_2")); buffer_menu[2] = GTK_TOGGLE_ACTION (gtk_builder_get_object (builder, "buffer_3")); buffer_menu[3] = GTK_TOGGLE_ACTION (gtk_builder_get_object (builder, "buffer_4")); buffer_menu[4] = GTK_TOGGLE_ACTION (gtk_builder_get_object (builder, "bufferAvg")); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "auto_resize")), "clicked", G_CALLBACK (resize_cb), (gpointer) box); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "resize_default")), "clicked", G_CALLBACK (resize_default_cb), (gpointer) box); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "auto_resize_m")), "activate", G_CALLBACK (resize_cb), (gpointer) box); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "resize_default_m")), "activate", G_CALLBACK (resize_default_cb), (gpointer) box); for (i = 0; i < N_BUFF; i++) { g_signal_connect (G_OBJECT (buffer_button[i]), "clicked", G_CALLBACK (buffer_button_cb), GINT_TO_POINTER((gint) i)); g_signal_connect (G_OBJECT (buffer_menu[i]), "activate", G_CALLBACK (buffer_menu_cb), GINT_TO_POINTER((gint) i)); } g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "capt")), "clicked", G_CALLBACK (capture_cb), (gpointer) box); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "capt_m")), "activate", G_CALLBACK (capture_cb), (gpointer) box); g_signal_connect (G_OBJECT (gtk_builder_get_object (builder, "gain1")), "value-changed", G_CALLBACK (gain_cb), (G_OBJECT (gtk_builder_get_object (builder, "gain1")) )); //////////////////////////////////////////////////////////////////////////////////////////////////// // Pixmap stuff g_signal_connect (G_OBJECT (reference_draw), "configure_event", G_CALLBACK (configure_event_reference), NULL); g_signal_connect (G_OBJECT (measured_draw), "configure_event", G_CALLBACK (configure_event_measured), NULL); //////////////////////////////////////////////////////////////////////////////////////////////////// volume_pink_value = gtk_spin_button_get_value_as_float(GTK_SPIN_BUTTON (volume_pink_gui)); gtk_widget_show_all (window); ///////////////////////////////////////////////////////////////////////////////////////////////////// #ifdef __APPLE__ GtkWidget *menubar1; GtkAction *quit_ap; GtkWidget *about_item; IgeMacMenuGroup *group; IgeMacDock *dock; OSErr osError; menubar1 = GTK_WIDGET (gtk_builder_get_object (builder, "menubar1")); quit_ap = GTK_ACTION (gtk_builder_get_object (builder, "quit_ap")); about_item = GTK_WIDGET (gtk_menu_item_new_with_label ("About BRP-PACU")); gtk_widget_hide (menubar1); // Put menu bar to the top of the screen ige_mac_menu_set_menu_bar (GTK_MENU_SHELL (menubar1)); ige_mac_menu_set_quit_menu_item (GTK_MENU_ITEM (quit_ap)); // move "About BRP-PACU" menu item to application menu g_signal_connect (about_item, "activate", G_CALLBACK (about_me_cb), "about_me"); group = ige_mac_menu_add_app_menu_group (); ige_mac_menu_add_app_menu_item (group, GTK_MENU_ITEM (about_item), NULL); gtk_action_set_visible (GTK_ACTION (gtk_builder_get_object (builder, "about_me")),FALSE); gtk_action_set_visible (GTK_ACTION (gtk_builder_get_object (builder, "quit_ap")),FALSE); // Enable quit from dock dock = ige_mac_dock_new (); g_signal_connect (dock, "quit-activate", G_CALLBACK (cleanup_gui), window); ige_mac_menu_connect_window_key_handler (GTK_WINDOW(window)); // Enable file open from Mac OS osError = AEInstallEventHandler(kCoreEventClass, kAEOpenDocuments, NewAEEventHandlerUPP((AEEventHandlerProcPtr) openAndPrintDocsEventHandler), 0, false); if (osError != noErr) fprintf(stderr, "OS X error %d\n", (int)osError); // RunApplicationEventLoop(); #endif home_string = getenv ("HOME"); file_path1 = malloc(sizeof(home_string) + 30); file_path2 = malloc(sizeof(home_string) + 50); #ifdef __APPLE__ sprintf(file_path1, "%s/Library/Caches/BRP-PACU", home_string); #else sprintf(file_path1, "%s/.BRP_PACU", home_string); #endif sprintf(file_path2, "%s/buff_store.brp", file_path1 ); if ((file_handle = fopen(file_path2, "rb")) <= 0) message("No BRP_PACU initialization file yet\nAre you running BRP_PACU for the 1st time?\nIf so, a file will be created for you on your next capture.", NULL, FALSE); else { fread (read_plot_pts, sizeof(gint), 1, file_handle ); if (read_plot_pts[0] == PLOT_PTS) { for (i = 0; i < N_BUFF; i++) fread (guiYBuf[i], sizeof(gfloat), PLOT_PTS, file_handle ); } else { message("The BRP_PACU initialization file has the wrong format. An initialization file will be created for you on your next capture.", NULL, FALSE); fprintf (stderr, "PLOT_PTS is different from PLOT_PTS saved size, this is because you have changed N_FFT since your last capture. Please change it back to %d * 2. Otherwise making a new capture should overwrite the old file\n", (int) read_plot_pts ); } fclose(file_handle); } g_object_unref (G_OBJECT(builder)); return(TRUE); } brp-pacu/ige-mac-private.h0000644000175000017500000000213112153127664014360 0ustar miramira/* GTK+ Integration for Mac OS X. * * Copyright (C) 2007, 2008 Imendio AB * * For further information, see: * http://developer.imendio.com/projects/gtk-macosx/menubar * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public * License as published by the Free Software Foundation; version 2.1 * of the License. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ #ifndef __IGE_MAC_PRIVATE_H__ #define __IGE_MAC_PRIVATE_H__ G_BEGIN_DECLS gboolean _ige_mac_menu_is_quit_menu_item_handled (void); gboolean _ige_mac_dock_is_quit_menu_item_handled (void); G_END_DECLS #endif /* __IGE_MAC_PRIVATE_H__ */ brp-pacu/gui.glade0000644000175000017500000014274312153127664013035 0ustar miramira About BRP-PACU True True True False GTK_JUSTIFY_FILL Brian's Reasonably Priced Professional Audio Configuration Utility * Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) * Macintosh application Copyright (C) 2009 Andreas Schwab * Macintosh synchronization Copyright (C) 2007 Pioneer Research Center USA, Inc. * Macintosh integration Copyright (C) 2007, 2008 Imendio AB * This program is based on the following libraries * FFTW: Copyright (c) 1997-1999, 2003 Massachusetts Institute of Technology * libglade: Copyright (C) 1998-2002 James Henstridge * gtkdatabox: Copyright (C) 1998 - 2008 Dr. Roland Bock * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * Written by Brian R. Phelps aka Electronjunkie http://electronjunkie.wordpress.com Questions or comments? Interested in contributing? Please email me at lm317t@gmail.com I need someone to help me package it for Debian/Ubuntu! Also a Redhat/Fedora rpm or any other packaging help would be much appreciated. True True True True OK 0 1 1 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 5 Delay GTK_WIN_POS_CENTER_ON_PARENT True GDK_WINDOW_TYPE_HINT_NORMAL True GDK_GRAVITY_CENTER window1 False True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Insert custom delay or found delay? True False 9 1 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK <b> Found: 0.000 secs</b> True 3 2 True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 0 0 100 1 10 0 3 3 1 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GTK_BUTTONBOX_END True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Custom 0 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Found 0 1 False GTK_PACK_END My Window sinc.png True True True _File True True True gtk-open True True True gtk-save True True True gtk-save-as True True True True gtk-quit True True True _Buffers True True True Buffer _1 True True Buffer _2 True True Buffer _3 True True Buffer _4 True True Buffer _Avg True True _View True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Resize Window True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Resize Default True True Change how quickly the plot responds to input Plot Preferences True True Ac_tions True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Record Impulse Response h(n) True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Find Delay True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Capture Trace True True Pink Noise True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Calculate Transfer Function H(z) True True True _Help True True True gtk-about True True False 28 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 94 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Hz GTK_JUSTIFY_CENTER False False 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK False 2 1 82 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK dB GTK_JUSTIFY_CENTER False False 2 2 True False 2 3 True Delay 0.0ms True False False 3 4 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK _Capture Trace True 0 False False 10 5 True Avg Gain False False 2 6 60 True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Gain for Averaging Buffer 0.25 -100 100 0.25 10 0 2 False False 1 7 True False 4 8 True True True Pink Noise 0 False False 9 74 True True GDK_POINTER_MOTION_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK | GDK_STRUCTURE_MASK GDK_EXTENSION_EVENTS_ALL 5.0499999999999998 -10 15 0.050000000000000003 4 0 2 False False 1 10 True False 11 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Measured False False 5 12 26 True True GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK False False 3 13 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Reference False False 3 14 26 True True GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK False False 3 15 False False 1 28 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _1 True 0 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _2 True 0 1 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _3 True 0 2 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Buffer _4 True 0 3 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK _Avg True 0 4 False GTK_PACK_END 4 33 True True True Transfer Function 0 True True False True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 0 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK _Resize True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK gtk-refresh 1 1 True True True 0 True True Resi_ze Default True True gtk-fullscreen 1 2 True True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK Find _Delay True 0 3 False GTK_PACK_END 3 GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 5 Graph Preferences GTK_WIN_POS_CENTER_ON_PARENT True GDK_WINDOW_TYPE_HINT_NORMAL True GDK_GRAVITY_CENTER window1 False True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Averaging Value: True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Increasing this value slows down the response of the graph.. 32 1 32 1 2 0 3 True False 7 4 True Smoothing Value 5 1 True True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK True Increasing this value smooths the graph more. 5 1 10 1 2 0 2 True GDK_POINTER_MOTION_MASK | GDK_POINTER_MOTION_HINT_MASK | GDK_BUTTON_PRESS_MASK | GDK_BUTTON_RELEASE_MASK GTK_BUTTONBOX_END True True True gtk-apply True 0 True True True gtk-close True 0 1 False GTK_PACK_END brp-pacu/sinc.png0000644000175000017500000001036512153127664012707 0ustar miramiraPNG  IHDR8R=sRGBbKGD pHYsttfxtIME 823uIDATxKs6PMx '\f.Zrl9Ɲ6%:ZkH\J)/W1SQQuQuQ62ӿ`mƟG]q 8/[:Ze/`p'!m*@p&*S7_q^8 \lgjժ p+8@ q<n\qXJ@Rʾ[FVq5d4q* ' 8>*8&\I8&" 8&Ap&8,"oOX/X]@pD:`|1 hgp4@w MRme pWH RŸp٢ Uia'p2bpCCKxmSpw*ش#e`hm;qp~z`* 邂OR }iu @> -cM87 >fm p-ʇ@ ,gp@rpT{-*Mq 7pa 'lS 8@XYrnqpp%TlS 8@HplOtl|g|8PJ)RJ^.!m) 7HTkVm`Z@q#Ц>Yd{ / [  '_'_Qq Qa $+p@::p ޷h|'8 ^@@Mʻp@8 5H5~9pAG Ȗ[ . KؒQ pTw]8 jDeBM@RM|9pA5@"w @R 8@A@pl|M}@:  DzBF&ms8 Ȗc| 5H5Q;`A : e40Q  8-[-jTk?x 46I_ߘs[7gm8HtP3_Rm28YslOAN$QC@T/|/tP;@ *+68@I48 ƀ8@DL18 W@|l˖ 8N.j8j}y8A@怀&Yo8A5@"Er,/h=H5:`|,A6 := 4@>g +i 8tֈ{- 8 `I>8x=efs@+Ԃ.i~ۖOt&89+A'~g cpL7N`pH潷c38CkM }۪耞q)Ag)t>O^ 8:19cEt>,NgpvfkkMilC0!bGu>,Y66ڀCS ZۮށC)ޅVAS[փ pxj~o o8hꉶ@zj:mc- 6 8x06!pK&u!h&|D8N&P;s N}mDY۾ڇΰ5s1&NN6 m'Nc6"hpt6Oh#spOFh#j;տn'>"ν}Gō9 LF LMmEmDAoXNgIҗ>w's! `Qxр&o7Q B]fԅʟfШt.o/>>.9jpmYq*8RJ9Z2K)凣8w=iI?$eup)S)>B 9'wQ7[nfOIENDB`brp-pacu/info.plist0000644000175000017500000000327612153127664013260 0ustar miramira CFBundleDevelopmentRegion English CFBundleDocumentTypes CFBundleTypeIconFile brpData CFBundleTypeRole Editor LSItemContentTypes net.sourceforge.brp-pacu.buffers CFBundleExecutable BRP_PACU CFBundleGetInfoString VERSION © 2009 Brian Phelps CFBundleIconFile sinc.icns CFBundleInfoDictionaryVersion 6.0 CFBundleName BRP-PACU CFBundlePackageType APPL CFBundleShortVersionString VERSION CFBundleVersion VERSION LSMinimumSystemVersion 10.5.0 UTExportedTypeDeclarations UTTypeConformsTo public.data UTTypeDescription BRP-PACU buffers UTTypeIconFile brpData.icns UTTypeIdentifier net.sourceforge.brp-pacu.buffers UTTypeReferenceURL http://sourceforge.net/projects/brp-pacu/ UTTypeTagSpecification public.filename-extension brp brp-pacu/install-sh0000755000175000017500000002202112153127664013241 0ustar miramira#!/bin/sh # install - install a program, script, or datafile scriptversion=2005-05-14.22 # This originates from X11R5 (mit/util/scripts/install.sh), which was # later released in X11R6 (xc/config/util/install.sh) with the # following copyright and license. # # Copyright (C) 1994 X Consortium # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to # deal in the Software without restriction, including without limitation the # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or # sell copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. # # Except as contained in this notice, the name of the X Consortium shall not # be used in advertising or otherwise to promote the sale, use or other deal- # ings in this Software without prior written authorization from the X Consor- # tium. # # # FSF changes to this file are in the public domain. # # Calling this script install-sh is preferred over install.sh, to prevent # `make' implicit rules from creating a file called install from it # when there is no Makefile. # # This script is compatible with the BSD install script, but was written # from scratch. It can only install one file at a time, a restriction # shared with many OS's install programs. # set DOITPROG to echo to test this script # Don't use :- since 4.3BSD and earlier shells don't like it. doit="${DOITPROG-}" # put in absolute paths if you don't have them in your path; or use env. vars. mvprog="${MVPROG-mv}" cpprog="${CPPROG-cp}" chmodprog="${CHMODPROG-chmod}" chownprog="${CHOWNPROG-chown}" chgrpprog="${CHGRPPROG-chgrp}" stripprog="${STRIPPROG-strip}" rmprog="${RMPROG-rm}" mkdirprog="${MKDIRPROG-mkdir}" chmodcmd="$chmodprog 0755" chowncmd= chgrpcmd= stripcmd= rmcmd="$rmprog -f" mvcmd="$mvprog" src= dst= dir_arg= dstarg= no_target_directory= usage="Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE or: $0 [OPTION]... SRCFILES... DIRECTORY or: $0 [OPTION]... -t DIRECTORY SRCFILES... or: $0 [OPTION]... -d DIRECTORIES... In the 1st form, copy SRCFILE to DSTFILE. In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. In the 4th, create DIRECTORIES. Options: -c (ignored) -d create directories instead of installing files. -g GROUP $chgrpprog installed files to GROUP. -m MODE $chmodprog installed files to MODE. -o USER $chownprog installed files to USER. -s $stripprog installed files. -t DIRECTORY install into DIRECTORY. -T report an error if DSTFILE is a directory. --help display this help and exit. --version display version info and exit. Environment variables override the default commands: CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG " while test -n "$1"; do case $1 in -c) shift continue;; -d) dir_arg=true shift continue;; -g) chgrpcmd="$chgrpprog $2" shift shift continue;; --help) echo "$usage"; exit $?;; -m) chmodcmd="$chmodprog $2" shift shift continue;; -o) chowncmd="$chownprog $2" shift shift continue;; -s) stripcmd=$stripprog shift continue;; -t) dstarg=$2 shift shift continue;; -T) no_target_directory=true shift continue;; --version) echo "$0 $scriptversion"; exit $?;; *) # When -d is used, all remaining arguments are directories to create. # When -t is used, the destination is already specified. test -n "$dir_arg$dstarg" && break # Otherwise, the last argument is the destination. Remove it from $@. for arg do if test -n "$dstarg"; then # $@ is not empty: it contains at least $arg. set fnord "$@" "$dstarg" shift # fnord fi shift # arg dstarg=$arg done break;; esac done if test -z "$1"; then if test -z "$dir_arg"; then echo "$0: no input file specified." >&2 exit 1 fi # It's OK to call `install-sh -d' without argument. # This can happen when creating conditional directories. exit 0 fi for src do # Protect names starting with `-'. case $src in -*) src=./$src ;; esac if test -n "$dir_arg"; then dst=$src src= if test -d "$dst"; then mkdircmd=: chmodcmd= else mkdircmd=$mkdirprog fi else # Waiting for this to be detected by the "$cpprog $src $dsttmp" command # might cause directories to be created, which would be especially bad # if $src (and thus $dsttmp) contains '*'. if test ! -f "$src" && test ! -d "$src"; then echo "$0: $src does not exist." >&2 exit 1 fi if test -z "$dstarg"; then echo "$0: no destination specified." >&2 exit 1 fi dst=$dstarg # Protect names starting with `-'. case $dst in -*) dst=./$dst ;; esac # If destination is a directory, append the input filename; won't work # if double slashes aren't ignored. if test -d "$dst"; then if test -n "$no_target_directory"; then echo "$0: $dstarg: Is a directory" >&2 exit 1 fi dst=$dst/`basename "$src"` fi fi # This sed command emulates the dirname command. dstdir=`echo "$dst" | sed -e 's,/*$,,;s,[^/]*$,,;s,/*$,,;s,^$,.,'` # Make sure that the destination directory exists. # Skip lots of stat calls in the usual case. if test ! -d "$dstdir"; then defaultIFS=' ' IFS="${IFS-$defaultIFS}" oIFS=$IFS # Some sh's can't handle IFS=/ for some reason. IFS='%' set x `echo "$dstdir" | sed -e 's@/@%@g' -e 's@^%@/@'` shift IFS=$oIFS pathcomp= while test $# -ne 0 ; do pathcomp=$pathcomp$1 shift if test ! -d "$pathcomp"; then $mkdirprog "$pathcomp" # mkdir can fail with a `File exist' error in case several # install-sh are creating the directory concurrently. This # is OK. test -d "$pathcomp" || exit fi pathcomp=$pathcomp/ done fi if test -n "$dir_arg"; then $doit $mkdircmd "$dst" \ && { test -z "$chowncmd" || $doit $chowncmd "$dst"; } \ && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } \ && { test -z "$stripcmd" || $doit $stripcmd "$dst"; } \ && { test -z "$chmodcmd" || $doit $chmodcmd "$dst"; } else dstfile=`basename "$dst"` # Make a couple of temp file names in the proper directory. dsttmp=$dstdir/_inst.$$_ rmtmp=$dstdir/_rm.$$_ # Trap to clean up those temp files at exit. trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 trap '(exit $?); exit' 1 2 13 15 # Copy the file name to the temp name. $doit $cpprog "$src" "$dsttmp" && # and set any options; do chmod last to preserve setuid bits. # # If any of these fail, we abort the whole thing. If we want to # ignore errors from any of these, just make sure not to ignore # errors from the above "$doit $cpprog $src $dsttmp" command. # { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } \ && { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } \ && { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } \ && { test -z "$chmodcmd" || $doit $chmodcmd "$dsttmp"; } && # Now rename the file to the real destination. { $doit $mvcmd -f "$dsttmp" "$dstdir/$dstfile" 2>/dev/null \ || { # The rename failed, perhaps because mv can't rename something else # to itself, or perhaps because mv is so ancient that it does not # support -f. # Now remove or move aside any old file at destination location. # We try this two ways since rm can't unlink itself on some # systems and the destination file might be busy for other # reasons. In this case, the final cleanup might fail but the new # file should still install successfully. { if test -f "$dstdir/$dstfile"; then $doit $rmcmd -f "$dstdir/$dstfile" 2>/dev/null \ || $doit $mvcmd -f "$dstdir/$dstfile" "$rmtmp" 2>/dev/null \ || { echo "$0: cannot unlink or rename $dstdir/$dstfile" >&2 (exit 1); exit 1 } else : fi } && # Now rename the file to the real destination. $doit $mvcmd "$dsttmp" "$dstdir/$dstfile" } } fi || { (exit 1); exit 1; } done # The final little trick to "correctly" pass the exit status to the exit trap. { (exit 0); exit 0 } # Local variables: # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: brp-pacu/depcomp0000755000175000017500000003710012153127664012616 0ustar miramira#! /bin/sh # depcomp - compile a program generating dependencies as side-effects scriptversion=2005-07-09.11 # Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2, or (at your option) # any later version. # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301, USA. # As a special exception to the GNU General Public License, if you # distribute this file as part of a program that contains a # configuration script generated by Autoconf, you may include it under # the same distribution terms that you use for the rest of that program. # Originally written by Alexandre Oliva . case $1 in '') echo "$0: No command. Try \`$0 --help' for more information." 1>&2 exit 1; ;; -h | --h*) cat <<\EOF Usage: depcomp [--help] [--version] PROGRAM [ARGS] Run PROGRAMS ARGS to compile a file, generating dependencies as side-effects. Environment variables: depmode Dependency tracking mode. source Source file read by `PROGRAMS ARGS'. object Object file output by `PROGRAMS ARGS'. DEPDIR directory where to store dependencies. depfile Dependency file to output. tmpdepfile Temporary file to use when outputing dependencies. libtool Whether libtool is used (yes/no). Report bugs to . EOF exit $? ;; -v | --v*) echo "depcomp $scriptversion" exit $? ;; esac if test -z "$depmode" || test -z "$source" || test -z "$object"; then echo "depcomp: Variables source, object and depmode must be set" 1>&2 exit 1 fi # Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. depfile=${depfile-`echo "$object" | sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} rm -f "$tmpdepfile" # Some modes work just like other modes, but use different flags. We # parameterize here, but still list the modes in the big case below, # to make depend.m4 easier to write. Note that we *cannot* use a case # here, because this file can only contain one case statement. if test "$depmode" = hp; then # HP compiler uses -M and no extra arg. gccflag=-M depmode=gcc fi if test "$depmode" = dashXmstdout; then # This is just like dashmstdout with a different argument. dashmflag=-xM depmode=dashmstdout fi case "$depmode" in gcc3) ## gcc 3 implements dependency tracking that does exactly what ## we want. Yay! Note: for some reason libtool 1.4 doesn't like ## it if -MD -MP comes after the -MF stuff. Hmm. "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi mv "$tmpdepfile" "$depfile" ;; gcc) ## There are various ways to get dependency output from gcc. Here's ## why we pick this rather obscure method: ## - Don't want to use -MD because we'd like the dependencies to end ## up in a subdir. Having to rename by hand is ugly. ## (We might end up doing this anyway to support other compilers.) ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like ## -MM, not -M (despite what the docs say). ## - Using -M directly means running the compiler twice (even worse ## than renaming). if test -z "$gccflag"; then gccflag=-MD, fi "$@" -Wp,"$gccflag$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" echo "$object : \\" > "$depfile" alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ## The second -e expression handles DOS-style file names with drive letters. sed -e 's/^[^:]*: / /' \ -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" ## This next piece of magic avoids the `deleted header file' problem. ## The problem is that when a header file which appears in a .P file ## is deleted, the dependency causes make to die (because there is ## typically no way to rebuild the header). We avoid this by adding ## dummy dependencies for each header file. Too bad gcc doesn't do ## this for us directly. tr ' ' ' ' < "$tmpdepfile" | ## Some versions of gcc put a space before the `:'. On the theory ## that the space means something, we add a space to the output as ## well. ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; hp) # This case exists only to let depend.m4 do its work. It works by # looking at the text of this script. This case will never be run, # since it is checked for above. exit 1 ;; sgi) if test "$libtool" = yes; then "$@" "-Wp,-MDupdate,$tmpdepfile" else "$@" -MDupdate "$tmpdepfile" fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files echo "$object : \\" > "$depfile" # Clip off the initial element (the dependent). Don't try to be # clever and replace this with sed code, as IRIX sed won't handle # lines with more than a fixed number of characters (4096 in # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; # the IRIX cc adds comments like `#:fec' to the end of the # dependency line. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ tr ' ' ' ' >> $depfile echo >> $depfile # The second pass generates a dummy entry for each header file. tr ' ' ' ' < "$tmpdepfile" \ | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ >> $depfile else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; aix) # The C for AIX Compiler uses -M and outputs the dependencies # in a .u file. In older versions, this file always lives in the # current directory. Also, the AIX compiler puts `$object:' at the # start of each line; $object doesn't have directory information. # Version 6 uses the directory in both cases. stripped=`echo "$object" | sed 's/\(.*\)\..*$/\1/'` tmpdepfile="$stripped.u" if test "$libtool" = yes; then "$@" -Wc,-M else "$@" -M fi stat=$? if test -f "$tmpdepfile"; then : else stripped=`echo "$stripped" | sed 's,^.*/,,'` tmpdepfile="$stripped.u" fi if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi if test -f "$tmpdepfile"; then outname="$stripped.o" # Each line is of the form `foo.o: dependent.h'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed -e "s,^$outname:,$object :," < "$tmpdepfile" > "$depfile" sed -e "s,^$outname: \(.*\)$,\1:," < "$tmpdepfile" >> "$depfile" else # The sourcefile does not contain any dependencies, so just # store a dummy comment line, to avoid errors with the Makefile # "include basename.Plo" scheme. echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; icc) # Intel's C compiler understands `-MD -MF file'. However on # icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c # ICC 7.0 will fill foo.d with something like # foo.o: sub/foo.c # foo.o: sub/foo.h # which is wrong. We want: # sub/foo.o: sub/foo.c # sub/foo.o: sub/foo.h # sub/foo.c: # sub/foo.h: # ICC 7.1 will output # foo.o: sub/foo.c sub/foo.h # and will wrap long lines using \ : # foo.o: sub/foo.c ... \ # sub/foo.h ... \ # ... "$@" -MD -MF "$tmpdepfile" stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile" exit $stat fi rm -f "$depfile" # Each line is of the form `foo.o: dependent.h', # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. # Do two passes, one to just change these to # `$object: dependent.h' and one to simply `dependent.h:'. sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" # Some versions of the HPUX 10.20 sed can't process this invocation # correctly. Breaking it into two sed invocations is a workaround. sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; tru64) # The Tru64 compiler uses -MD to generate dependencies as a side # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put # dependencies in `foo.d' instead, so we check for that too. # Subdirectories are respected. dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` test "x$dir" = "x$object" && dir= base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` if test "$libtool" = yes; then # With Tru64 cc, shared objects can also be used to make a # static library. This mecanism is used in libtool 1.4 series to # handle both shared and static libraries in a single compilation. # With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d. # # With libtool 1.5 this exception was removed, and libtool now # generates 2 separate objects for the 2 libraries. These two # compilations output dependencies in in $dir.libs/$base.o.d and # in $dir$base.o.d. We have to check for both files, because # one of the two compilations can be disabled. We should prefer # $dir$base.o.d over $dir.libs/$base.o.d because the latter is # automatically cleaned when .libs/ is deleted, while ignoring # the former would cause a distcleancheck panic. tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4 tmpdepfile2=$dir$base.o.d # libtool 1.5 tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5 tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504 "$@" -Wc,-MD else tmpdepfile1=$dir$base.o.d tmpdepfile2=$dir$base.d tmpdepfile3=$dir$base.d tmpdepfile4=$dir$base.d "$@" -MD fi stat=$? if test $stat -eq 0; then : else rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" exit $stat fi for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" do test -f "$tmpdepfile" && break done if test -f "$tmpdepfile"; then sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" # That's a tab and a space in the []. sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" else echo "#dummy" > "$depfile" fi rm -f "$tmpdepfile" ;; #nosideeffect) # This comment above is used by automake to tell side-effect # dependency tracking mechanisms from slower ones. dashmstdout) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done test -z "$dashmflag" && dashmflag=-M # Require at least two characters before searching for `:' # in the target name. This is to cope with DOS-style filenames: # a dependency such as `c:/foo/bar' could be seen as target `c' otherwise. "$@" $dashmflag | sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" tr ' ' ' ' < "$tmpdepfile" | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; dashXmstdout) # This case only exists to satisfy depend.m4. It is never actually # run, as this mode is specially recognized in the preamble. exit 1 ;; makedepend) "$@" || exit $? # Remove any Libtool call if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # X makedepend shift cleared=no for arg in "$@"; do case $cleared in no) set ""; shift cleared=yes ;; esac case "$arg" in -D*|-I*) set fnord "$@" "$arg"; shift ;; # Strip any option that makedepend may not understand. Remove # the object too, otherwise makedepend will parse it as a source file. -*|$object) ;; *) set fnord "$@" "$arg"; shift ;; esac done obj_suffix="`echo $object | sed 's/^.*\././'`" touch "$tmpdepfile" ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" rm -f "$depfile" cat < "$tmpdepfile" > "$depfile" sed '1,2d' "$tmpdepfile" | tr ' ' ' ' | \ ## Some versions of the HPUX 10.20 sed can't process this invocation ## correctly. Breaking it into two sed invocations is a workaround. sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" rm -f "$tmpdepfile" "$tmpdepfile".bak ;; cpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout. "$@" || exit $? # Remove the call to Libtool. if test "$libtool" = yes; then while test $1 != '--mode=compile'; do shift done shift fi # Remove `-o $object'. IFS=" " for arg do case $arg in -o) shift ;; $object) shift ;; *) set fnord "$@" "$arg" shift # fnord shift # $arg ;; esac done "$@" -E | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | sed '$ s: \\$::' > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" cat < "$tmpdepfile" >> "$depfile" sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" rm -f "$tmpdepfile" ;; msvisualcpp) # Important note: in order to support this mode, a compiler *must* # always write the preprocessed file to stdout, regardless of -o, # because we must use -o when running libtool. "$@" || exit $? IFS=" " for arg do case "$arg" in "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") set fnord "$@" shift shift ;; *) set fnord "$@" "$arg" shift shift ;; esac done "$@" -E | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::echo "`cygpath -u \\"\1\\"`":p' | sort | uniq > "$tmpdepfile" rm -f "$depfile" echo "$object : \\" > "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" echo " " >> "$depfile" . "$tmpdepfile" | sed 's% %\\ %g' | sed -n '/^\(.*\)$/ s::\1\::p' >> "$depfile" rm -f "$tmpdepfile" ;; none) exec "$@" ;; *) echo "Unknown depmode $depmode" 1>&2 exit 1 ;; esac exit 0 # Local Variables: # mode: shell-script # sh-indentation: 2 # eval: (add-hook 'write-file-hooks 'time-stamp) # time-stamp-start: "scriptversion=" # time-stamp-format: "%:y-%02m-%02d.%02H" # time-stamp-end: "$" # End: brp-pacu/gui.h0000644000175000017500000000220212153127664012171 0ustar miramira/* * gui.h : defines window sizes, and functions used * * * * Copyright (C) 2007-2008 Brian Phelps(lm317t@gmail.com) * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Library General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. */ #include #include "main.h" #ifndef GUI_H #define GUI_H #define WINDOW_H 600 #define WINDOW_W 950 #define IMPULSE_WINDOW_H 500 #define IMPULSE_WINDOW_W 900 #define N_BUFF 5 gboolean gui_idle_func (struct FFT_Frame * data); gboolean create_gui (struct FFT_Frame * data, char* datadir); #endif