diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/ChangeLog g-wrap/ChangeLog --- g-wrap.orig/ChangeLog 2002-11-08 05:46:51.000000000 +0100 +++ g-wrap/ChangeLog 2003-08-04 15:32:15.000000000 +0200 @@ -1,3 +1,20 @@ +2003-08-04 Andreas Rottmann + + * g-wrap.scm (gw:param-visibility): New type attribute. + + * test/test-enumeration, test/test-gw-wct, test/test-gtkobj, + test/test-gw-glib, test/test-gw-standard: Fixed for VPATH build. + + * rpm/Makefile.am, test/Makefile.am: Fixed for VPATH build. + +2003-05-19 Andreas Rottmann + + * Makefile.am (guilemoduledir), + * g-wrap/Makefile.am (gwrapmoduledir): Install into + $(datadir)/guile/site instead of fixed configure-time location. + + * g-wrap.scm (gw:call-arg-ccg): New CCG. + 2002-11-07 Rob Browning * release 1.3.4. diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/Makefile.am g-wrap/Makefile.am --- g-wrap.orig/Makefile.am 2002-11-07 18:23:43.000000000 +0100 +++ g-wrap/Makefile.am 2003-05-16 14:50:59.000000000 +0200 @@ -1,6 +1,6 @@ SUBDIRS = doc rpm bin g-wrap example test -guilemoduledir=@GUILEMODDIR@ +guilemoduledir=$(datadir)/guile/site guilemodule_DATA=@GUILEMOD_TARGET@ EXTRA_DIST = g-wrap.m4 g-wrap.scm Only in g-wrap: autom4te.cache diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/bin/Makefile.am g-wrap/bin/Makefile.am --- g-wrap.orig/bin/Makefile.am 2002-11-07 18:23:43.000000000 +0100 +++ g-wrap/bin/Makefile.am 2003-08-04 14:19:12.000000000 +0200 @@ -17,7 +17,7 @@ # Depend on Makefile so that we pick up changes to ../configure g-wrap: g-wrap.in Makefile rm -f $@.tmp - sed < $@.in > $@.tmp \ + sed < $< > $@.tmp \ -e 's:@-GUILE-@:${GUILE}:' \ -e 's:@-VERSION-@:${VERSION}:' \ -e 's:@-GUILE_MODULE_DIR-@:${GUILEMODDIR}:' @@ -31,7 +31,7 @@ g-wrap-config: g-wrap-config.in rm -f $@.tmp - sed < $@.in > $@.tmp \ + sed < $< > $@.tmp \ -e 's:@-GUILE-@:${GUILE}:' \ -e 's:@-VERSION-@:${VERSION}:' \ -e 's:@-libdir-@:${libdir}:' \ Only in g-wrap: build diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/g-wrap/Makefile.am g-wrap/g-wrap/Makefile.am --- g-wrap.orig/g-wrap/Makefile.am 2002-11-07 18:23:43.000000000 +0100 +++ g-wrap/g-wrap/Makefile.am 2003-05-16 14:51:16.000000000 +0200 @@ -1,5 +1,5 @@ -gwrapmoduledir=@GUILEMODDIR@/g-wrap +gwrapmoduledir=$(datadir)/guile/site/g-wrap gwrapincludedir = $(includedir)/g-wrap CLEANFILES = diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/g-wrap/g-wrap-glib.c g-wrap/g-wrap/g-wrap-glib.c --- g-wrap.orig/g-wrap/g-wrap-glib.c 2002-11-07 18:23:43.000000000 +0100 +++ g-wrap/g-wrap/g-wrap-glib.c 2003-05-11 22:38:56.000000000 +0200 @@ -63,7 +63,7 @@ if (bits00to15_mask == SCM_BOOL_F) { bits00to15_mask = gh_ulong2scm(0xFFFF); - scm_protect_object (bits00to15_mask); + scm_gc_protect_object (bits00to15_mask); } /* @@ -115,8 +115,8 @@ tmp <<= 32; minval = gw_glib_gint64_to_scm(tmp); - scm_protect_object(maxval); - scm_protect_object(minval); + scm_gc_protect_object(maxval); + scm_gc_protect_object(minval); initialized = 1; } Only in g-wrap.orig/g-wrap: gw-glib.scm Only in g-wrap.orig/g-wrap: gw-gtk.scm diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/g-wrap/gw-standard-spec.scm g-wrap/g-wrap/gw-standard-spec.scm --- g-wrap.orig/g-wrap/gw-standard-spec.scm 2002-11-07 18:23:43.000000000 +0100 +++ g-wrap/g-wrap/gw-standard-spec.scm 2003-05-14 21:30:07.000000000 +0200 @@ -10,13 +10,13 @@ ;;; ;;; code stolen from plain simple-types. The same, but different :> -(define (wrap-simple-ranged-signed-integer-type wrapset - type-sym - c-type-name - scm-minval-text - scm-maxval-text - scm->c-form - c->scm-form) +(define (wrap-simple-ranged-integer-type wrapset + type-sym + c-type-name + c-minval-text ; for unsigned, #f + c-maxval-text + scm->c-function + c->scm-function) (define (replace-syms tree alist) (cond @@ -39,39 +39,47 @@ (define (global-declarations-ccg type client-wrapset) (if client-wrapset - (list "static SCM " minvar ";\n" + (list (if c-minval-text + (list "static SCM " minvar ";\n") + '()) "static SCM " maxvar ";\n") '())) ;; TODO: maybe use status-var. (define (global-init-ccg type client-wrapset status-var) (if client-wrapset - (list minvar " = " scm-minval-text ";\n" - "scm_protect_object(" minvar ");\n" - maxvar " = " scm-maxval-text ";\n" + (list (if c-minval-text + (list minvar " = " c->scm-function "(" c-minval-text ");\n" + "scm_protect_object(" minvar ");\n") + '()) + maxvar " = " c->scm-function "(" c-maxval-text ");\n" "scm_protect_object(" maxvar ");\n") '())) (define (scm->c-ccg c-var scm-var typespec status-var) - (let ((scm->c-code (replace-syms scm->c-form `((c-var . ,c-var) - (scm-var . ,scm-var))))) - (list "if(SCM_FALSEP(scm_integer_p(" scm-var ")))" - `(gw:error ,status-var type ,scm-var) - "else if(SCM_FALSEP(scm_geq_p(" scm-var ", " minvar "))" - " || SCM_FALSEP(scm_leq_p(" scm-var ", " maxvar ")))" - `(gw:error ,status-var range ,scm-var) - "else {" scm->c-code "}\n" - "\n" - "if(" `(gw:error? ,status-var type) ")" - `(gw:error ,status-var arg-type) - "else if(" `(gw:error? ,status-var range) ")" - `(gw:error ,status-var arg-range)))) + (list "if(SCM_FALSEP(scm_integer_p(" scm-var ")))" + `(gw:error ,status-var type ,scm-var) + (if c-minval-text + (list + "else if(SCM_FALSEP(scm_geq_p(" scm-var ", " minvar "))" + " || SCM_FALSEP(scm_leq_p(" scm-var ", " maxvar ")))") + (list + "else if(SCM_NFALSEP(scm_negative_p(" scm-var "))" + " || SCM_FALSEP(scm_leq_p(" scm-var ", " maxvar ")))")) + `(gw:error ,status-var range ,scm-var) + "else {\n" + ;; here we pass NULL and 0 as the callers because we've already + ;; checked the bounds on the argument + " " c-var " = " scm->c-function "(" scm-var ", 0, NULL);\n" + "}\n" + "\n" + "if(" `(gw:error? ,status-var type) ")" + `(gw:error ,status-var arg-type) + "else if(" `(gw:error? ,status-var range) ")" + `(gw:error ,status-var arg-range))) - (define (c->scm-ccg scm-var c-var typespec status-var) - (replace-syms c->scm-form - `((c-var . ,c-var) - (scm-var . ,scm-var)))) + (list scm-var " = " c->scm-function "(" c-var ");\n")) (define (pre-call-arg-ccg param status-var) (let* ((scm-name (gw:param-get-scm-name param)) @@ -105,92 +113,6 @@ simple-type)) -(define (wrap-simple-ranged-unsigned-integer-type wrapset - type-sym - c-type-name - scm-maxval-text - scm->c-form - c->scm-form) - - (define (replace-syms tree alist) - (cond - ((null? tree) tree) - ((list? tree) (map (lambda (elt) (replace-syms elt alist)) tree)) - ((symbol? tree) - (let ((expansion (assq-ref alist tree))) - (if (string? expansion) - expansion - (error "Expected string for expansion...")))) - (else tree))) - - (let* ((simple-type (gw:wrap-type wrapset type-sym)) - (c-sym-name (gw:any-str->c-sym-str (symbol->string type-sym))) - (maxvar (gw:gen-c-tmp (string-append "range_maxval" c-sym-name)))) - - (define (c-type-name-func typespec) - c-type-name) - - (define (global-declarations-ccg type client-wrapset) - (if client-wrapset - (list "static SCM " maxvar ";\n") - '())) - - ;; TODO: maybe use status-var - (define (global-init-ccg type client-wrapset status-var) - (if client-wrapset - (list maxvar " = " scm-maxval-text ";\n" - "scm_protect_object(" maxvar ");\n") - '())) - - (define (scm->c-ccg c-var scm-var typespec status-var) - (let ((scm->c-code (replace-syms scm->c-form `((c-var . ,c-var) - (scm-var . ,scm-var))))) - - (list - "if(SCM_FALSEP(scm_integer_p(" scm-var ")))" - `(gw:error ,status-var type ,scm-var) - "else if(SCM_NFALSEP(scm_negative_p(" scm-var "))" - " || SCM_FALSEP(scm_leq_p(" scm-var ", " maxvar ")))" - `(gw:error ,status-var range ,scm-var) - "else {" scm->c-code "}\n"))) - - (define (c->scm-ccg scm-var c-var typespec status-var) - (replace-syms c->scm-form - `((c-var . ,c-var) - (scm-var . ,scm-var)))) - - (define (pre-call-arg-ccg param status-var) - (let* ((scm-name (gw:param-get-scm-name param)) - (c-name (gw:param-get-c-name param)) - (typespec (gw:param-get-typespec param))) - (list - (scm->c-ccg c-name scm-name typespec status-var) - "if(" `(gw:error? ,status-var type) ")" - `(gw:error ,status-var arg-type) - "else if(" `(gw:error? ,status-var range) ")" - `(gw:error ,status-var arg-range)))) - - (define (call-ccg result func-call-code status-var) - (list (gw:result-get-c-name result) " = " func-call-code ";\n")) - - (define (post-call-result-ccg result status-var) - (let* ((scm-name (gw:result-get-scm-name result)) - (c-name (gw:result-get-c-name result)) - (typespec (gw:result-get-typespec result))) - (c->scm-ccg scm-name c-name typespec status-var))) - - (gw:type-set-c-type-name-func! simple-type c-type-name-func) - (gw:type-set-global-declarations-ccg! simple-type global-declarations-ccg) - (gw:type-set-global-initializations-ccg! simple-type global-init-ccg) - (gw:type-set-scm->c-ccg! simple-type scm->c-ccg) - (gw:type-set-c->scm-ccg! simple-type c->scm-ccg) - (gw:type-set-pre-call-arg-ccg! simple-type pre-call-arg-ccg) - (gw:type-set-call-ccg! simple-type call-ccg) - (gw:type-set-post-call-result-ccg! simple-type post-call-result-ccg) - - simple-type)) - - (let ((ws (gw:new-wrapset "gw-standard")) (limits-requiring-types '())) @@ -254,13 +176,20 @@ '(scm-var "= (" c-var ") ? SCM_BOOL_T : SCM_BOOL_F;\n")) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; - ;; + ;; -- FIXME: scm chars are 0-255, not [-128,127] like c chars (gw:wrap-simple-type ws ' "char" '("SCM_NFALSEP(scm_char_p(" scm-var "))\n") '(c-var "= SCM_CHAR(" scm-var ");\n") '(scm-var "= SCM_MAKE_CHAR(" c-var ");\n")) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + ;; -- scm chars are bounded to [0,255] + (gw:wrap-simple-type ws ' "unsigned char" + '("SCM_NFALSEP(scm_char_p(" scm-var "))\n") + '(c-var "= SCM_CHAR(" scm-var ");\n") + '(scm-var "= SCM_MAKE_CHAR(" c-var ");\n")) + + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; (gw:wrap-simple-type ws ' "float" '("SCM_NFALSEP(scm_number_p(" scm-var "))\n") @@ -275,53 +204,78 @@ '(scm-var "= gh_double2scm(" c-var ");\n")) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + ;; + (let ((wt (wrap-simple-ranged-integer-type + ws ' "short" + "SHRT_MIN" "SHRT_MAX" + "scm_num2short" "scm_short2num"))) + (set! limits-requiring-types (cons wt limits-requiring-types))) + + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + ;; + (let ((wt (wrap-simple-ranged-integer-type + ws ' "unsigned short" + #f "USHRT_MAX" + "scm_num2ushort" "scm_ushort2num"))) + (set! limits-requiring-types (cons wt limits-requiring-types))) + + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; - (let ((wt (wrap-simple-ranged-signed-integer-type + (let ((wt (wrap-simple-ranged-integer-type ws ' "int" - "scm_long2num(INT_MIN)" - "scm_long2num(INT_MAX)" - '(c-var "= gh_scm2long(" scm-var ");\n") - '(scm-var "= gh_long2scm(" c-var ");\n")))) + "INT_MIN" "INT_MAX" + "scm_num2int" "scm_int2num"))) (set! limits-requiring-types (cons wt limits-requiring-types))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; - (let ((wt (wrap-simple-ranged-unsigned-integer-type + (let ((wt (wrap-simple-ranged-integer-type ws ' "unsigned int" - "scm_ulong2num(UINT_MAX)" - '(c-var "= gh_scm2ulong(" scm-var ");\n") - '(scm-var "= gh_ulong2scm(" c-var ");\n")))) + #f "UINT_MAX" + "scm_num2uint" "scm_uint2num"))) (set! limits-requiring-types (cons wt limits-requiring-types))) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; - (let ((wt (wrap-simple-ranged-signed-integer-type + (let ((wt (wrap-simple-ranged-integer-type ws ' "long" - "scm_long2num(LONG_MIN)" - "scm_long2num(LONG_MAX)" - '(c-var "= gh_scm2long(" scm-var ");\n") - '(scm-var "= gh_long2scm(" c-var ");\n")))) + "LONG_MIN" "LONG_MAX" + "scm_num2long" "scm_long2num"))) (set! limits-requiring-types (cons wt limits-requiring-types))) - + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; - (let ((wt (wrap-simple-ranged-unsigned-integer-type + (let ((wt (wrap-simple-ranged-integer-type ws ' "unsigned long" - "scm_ulong2num(ULONG_MAX)" - '(c-var "= gh_scm2ulong(" scm-var ");\n") - '(scm-var "= gh_ulong2scm(" c-var ");\n")))) + #f "ULONG_MAX" + "scm_num2ulong" "scm_ulong2num"))) (set! limits-requiring-types (cons wt limits-requiring-types))) - - ;; long long support is currently unavailable. To fix that, we're - ;; going to need to do some work to handle broken versions of guile - ;; (or perhaps just refuse to add long long support for those - ;; versions. The issue is that some versions of guile in - ;; libguile/__scm.h just "typedef long long_long" even on platforms - ;; that have long long's that are larger than long. This is a mess, - ;; meaning, among other things, that long_long won't be big enough - ;; to hold LONG_LONG_MAX, etc. yuck. (NOTE: =? (version) "1.6") + (begin + ;; There's a bit of a mess in some older guiles wrt long long + ;; support. I don't know when it was fixed, but I know that the + ;; 1.6 series works properly -- apw + + ;; FIXME: how to handle the no-long-longs case nicely? + ;; Why can't an honest guy seem to get a hold of LLONG_MAX? + + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + ;; + (let ((wt (wrap-simple-ranged-integer-type + ws ' "long long" + "((long long)0x7fffffffffffffff)" "((long long)0x8000000000000000)" + "scm_num2long_long" "scm_long_long2num"))) + (set! limits-requiring-types (cons wt limits-requiring-types))) + + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + ;; + (let ((wt (wrap-simple-ranged-integer-type + ws ' "unsigned long long" + #f "((unsigned long long)0xffffffffffffffff)" + "scm_num2ulong_long" "scm_ulong_long2num"))) + (set! limits-requiring-types (cons wt limits-requiring-types))))) + (let* ((mchars (gw:wrap-type ws '))) (define (c-type-name-func typespec) Only in g-wrap.orig/g-wrap: gw-standard.scm Only in g-wrap.orig/g-wrap: gw-wct.scm Only in g-wrap: g-wrap-1.3.4 Only in g-wrap: g-wrap-1.3.4.tar.gz diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/g-wrap.scm g-wrap/g-wrap.scm --- g-wrap.orig/g-wrap.scm 2002-11-07 18:23:44.000000000 +0100 +++ g-wrap/g-wrap.scm 2003-08-04 13:39:44.000000000 +0200 @@ -24,7 +24,7 @@ ;; FIXME: What does this one do? :use-module (g-wrap g-translate)) -(use-modules (ice-9 slib)) +(use-modules (ice-9 slib) (srfi srfi-1)) (if (not (defined? 'simple-format)) (begin @@ -642,6 +642,9 @@ (define-public (gw:param-get-c-type-name x) (gw:typespec-get-c-type-name (gw:param-get-typespec x))) +(define-public (gw:param-visible? x) + (gw:type-get-param-visibility (gw:param-get-type x))) + (define (param-specs->params param-specs wrapset) (let loop ((remainder param-specs) (n 0)) (if (null? remainder) @@ -726,6 +729,10 @@ ;;; gw:call-ccg (result func-call-code status-var) ;;; Normally must (at least) assign func-call-code (a string) to C result var. ;;; +;;; gw:call-arg-ccg (param) +;;; +;;; Optional. Can transform the param for the call (e.g. call-by-reference) +;;; ;;; gw:post-call-result-ccg (result status-var) ;;; ;;; Normally must at least convert the C result and assign it to the @@ -763,6 +770,11 @@ (define-public (gw:type-get-typespec-options-parser t) (hashq-ref t 'gw:typespec-options-parser)) +(define-public (gw:type-set-param-visibility! t vis) + (hashq-set! t 'gw:param-visibility vis)) +(define-public (gw:type-get-param-visibility t) + (hashq-ref t 'gw:param-visibility #t)) + (define-public (gw:type-set-global-initializations-ccg! t generator) (hashq-set! t 'gw:global-initializations-ccg generator)) (define-public (gw:type-set-global-declarations-ccg! t generator) @@ -789,6 +801,8 @@ (hashq-set! t 'gw:pre-call-result-ccg generator)) (define-public (gw:type-set-pre-call-arg-ccg! t generator) (hashq-set! t 'gw:pre-call-arg-ccg generator)) +(define-public (gw:type-set-call-arg-ccg! t generator) + (hashq-set! t 'gw:call-arg-ccg generator)) (define-public (gw:type-set-call-ccg! t generator) (hashq-set! t 'gw:call-ccg generator)) (define-public (gw:type-set-post-call-arg-ccg! t generator) @@ -1360,16 +1374,21 @@ (else tree))) (gw:expand-helper tree param allowed-errors tree)) -(define (make-c-call-param-list params) +(define (make-c-call-param-list params) (cond ((null? params) '()) - (else - (cons - (list - (gw:param-get-c-name (car params)) - (if (null? (cdr params)) - "" - ", ")) - (make-c-call-param-list (cdr params)))))) + (else + (let* ((param (car params)) + (type (gw:param-get-type param)) + (call-arg-ccg (hashq-ref type 'gw:call-arg-ccg))) + (cons + (list + (if call-arg-ccg + (call-arg-ccg param) + (gw:param-get-c-name param)) + (if (null? (cdr params)) + "" + ", ")) + (make-c-call-param-list (cdr params))))))) (define (make-c-wrapper-param-declarations param-list) (let loop ((params param-list) @@ -1395,12 +1414,12 @@ description wrapper-name wrapper-namestr) - - (let ((param-decl (make-c-wrapper-param-declarations params)) - (fn-c-wrapper wrapper-name) - (fn-c-string wrapper-namestr) - (nargs (length params)) - (status-var "gw__error_status")) + (let* ((scm-params (filter gw:param-visible? params)) + (param-decl (make-c-wrapper-param-declarations scm-params)) + (fn-c-wrapper wrapper-name) + (fn-c-string wrapper-namestr) + (nargs (length scm-params)) + (status-var "gw__error_status")) (list "static char * " fn-c-string " = \"" scheme-sym "\";\n" @@ -1433,21 +1452,24 @@ (let ((pre-call-ccg (hashq-ref (gw:param-get-type param) 'gw:pre-call-arg-ccg #f))) (list - "/* ARG " (gw:param-get-number param) " */\n" - "gw__arg_pos++;\n" - (if (> (gw:param-get-number param) gw:*max-fixed-params*) + (if (gw:param-visible? param) (list - "if (SCM_NULLP (gw__restargs)) " status-var " = GW__ERR_ARGC;\n" - "else {\n" - " " (gw:param-get-scm-name param) " = SCM_CAR(gw__restargs);\n" - " gw__restargs = SCM_CDR (gw__restargs);\n" - "}\n") + "/* ARG " (gw:param-get-number param) " */\n" + "gw__arg_pos++;\n" + (if (> (gw:param-get-number param) gw:*max-fixed-params*) + (list + "if (SCM_NULLP (gw__restargs)) " status-var " = GW__ERR_ARGC;\n" + "else {\n" + " " (gw:param-get-scm-name param) " = SCM_CAR(gw__restargs);\n" + " gw__restargs = SCM_CDR (gw__restargs);\n" + "}\n") + '()) + "if (" status-var " != GW__ERR_NONE)" + " goto " (if (zero? (gw:param-get-number param)) + "gw__wrapper_exit;\n" + (list "gw__post_call_arg_" + (- (gw:param-get-number param) 1) ";\n"))) '()) - "if (" status-var " != GW__ERR_NONE)" - " goto " (if (zero? (gw:param-get-number param)) - "gw__wrapper_exit;\n" - (list "gw__post_call_arg_" - (- (gw:param-get-number param) 1) ";\n")) "\n{\n" (if pre-call-ccg (gw:expand-special-forms @@ -1455,11 +1477,11 @@ param '(memory misc type range arg-type arg-range)) " /* no pre-call arg code requested! */\n")))) - params) - - (let ((pre-call-result-ccg - (hashq-ref (gw:result-get-type result) 'gw:pre-call-result-ccg #f))) - (list + params) + + (let ((pre-call-result-ccg + (hashq-ref (gw:result-get-type result) 'gw:pre-call-result-ccg #f))) + (list "if (" status-var " == GW__ERR_NONE)\n" "{\n" (if pre-call-result-ccg @@ -1578,7 +1600,7 @@ (param-specs->description-head scheme-sym (gw:result-get-type result) param-specs) new-description)) - (nargs (length params))) + (nargs (length (filter gw:param-visible? params)))) (gw:wrapset-add-guile-module-export! wrapset scheme-sym) diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/rpm/Makefile.am g-wrap/rpm/Makefile.am --- g-wrap.orig/rpm/Makefile.am 2002-11-07 18:23:43.000000000 +0100 +++ g-wrap/rpm/Makefile.am 2003-08-04 14:16:03.000000000 +0200 @@ -15,9 +15,9 @@ ## brackets here, instead of the usual @...@. This prevents autoconf ## from substituting the values directly into the left-hand sides of ## the sed substitutions. *sigh* -spec: spec.in Makefile +spec: $(srcdir)/spec.in Makefile rm -f $@.tmp - sed < $@.in > $@.tmp \ + sed < $< > $@.tmp \ -e 's:@-GW_RTLIB_VER-@:${GW_MAJ}.${GW_REV}.${GW_AGE}:' \ -e 's:@-GW_RTLIB_MAJ-@:${GW_MAJ}:' \ -e 's:@-VERSION-@:${VERSION}:' diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/test/Makefile.am g-wrap/test/Makefile.am --- g-wrap.orig/test/Makefile.am 2002-11-07 18:23:42.000000000 +0100 +++ g-wrap/test/Makefile.am 2003-08-04 15:15:55.000000000 +0200 @@ -43,9 +43,10 @@ G_WRAP_MODULE_DIR = ${LOCALPWD}/.. EXTRA_DIST += gw-guile -EXTRA_DIST += test-gw-wct +EXTRA_DIST += test-gw-wct test-enumeration test-gtkobj test-gw-glib +EXTRA_DIST += test-gw-standard guile-test-env EXTRA_DIST += .cvsignore -EXTRA_DIST += $(wildcard *-spec.scm) +EXTRA_DIST += $(wildcard $(srcdir)/*-spec.scm) # =========================================================================== @@ -85,7 +86,7 @@ (read-enable 'positions) \ (set! %load-path (cons \"${G_WRAP_MODULE_DIR}\" %load-path)) \ (use-modules (g-wrap)) \ - (primitive-load \"./gw-test-standard-spec.scm\") \ + (primitive-load \"$(srcdir)/gw-test-standard-spec.scm\") \ (gw:generate-wrapset \"gw-test-standard\")" CLEANFILES += gw-test-standard.scm gw-test-standard.h gw-test-standard.c gw-test-standard.html gw-test-standard-autogen.h @@ -105,7 +106,7 @@ (read-enable 'positions) \ (set! %load-path (cons \"${G_WRAP_MODULE_DIR}\" %load-path)) \ (use-modules (g-wrap)) \ - (primitive-load \"./gw-test-enumeration-spec.scm\") \ + (primitive-load \"$(srcdir)/gw-test-enumeration-spec.scm\") \ (gw:generate-wrapset \"gw-test-enumeration\")" CLEANFILES += gw-test-enumeration.scm gw-test-enumeration.h gw-test-enumeration.c gw-test-enumeration.html gw-test-enumeration-autogen.h @@ -127,7 +128,7 @@ (debug-enable 'debug) \ (set! %load-path (cons \"${G_WRAP_MODULE_DIR}\" %load-path)) \ (use-modules (g-wrap)) \ - (primitive-load \"./gw-test-parent-spec.scm\") \ + (primitive-load \"$(srcdir)/gw-test-parent-spec.scm\") \ (gw:generate-wrapset \"gw-test-parent\")" CLEANFILES += gw-test-parent.scm gw-test-parent.h gw-test-parent.c gw-test-parent.html gw-test-parent-autogen.h @@ -144,8 +145,8 @@ guile -c \ "(set! %load-path (cons \"${G_WRAP_MODULE_DIR}\" %load-path)) \ (use-modules (g-wrap)) \ - (primitive-load \"./gw-test-parent-spec.scm\") \ - (primitive-load \"./gw-test-child-spec.scm\") \ + (primitive-load \"$(srcdir)/gw-test-parent-spec.scm\") \ + (primitive-load \"$(srcdir)/gw-test-child-spec.scm\") \ (gw:generate-wrapset \"gw-test-child\")" CLEANFILES += gw-test-child.scm gw-test-child.h gw-test-child.c gw-test-child.html gw-test-child-autogen.h @@ -167,7 +168,7 @@ (read-enable 'positions) \ (set! %load-path (cons \"${G_WRAP_MODULE_DIR}\" %load-path)) \ (use-modules (g-wrap)) \ - (primitive-load \"./gw-test-glib-spec.scm\") \ + (primitive-load \"$(srcdir)/gw-test-glib-spec.scm\") \ (gw:generate-wrapset \"gw-test-glib\")" CLEANFILES += gw-test-glib.scm gw-test-glib.h gw-test-glib.c gw-test-glib.html gw-test-glib-autogen.h @@ -193,7 +194,4 @@ # # ==================================================================== -${TESTS}: - chmod a+x $@ - .PHONY: ${TESTS} diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/test/test-enumeration g-wrap/test/test-enumeration --- g-wrap.orig/test/test-enumeration 2002-11-07 18:23:42.000000000 +0100 +++ g-wrap/test/test-enumeration 2003-08-04 15:30:22.000000000 +0200 @@ -1,5 +1,5 @@ #!/bin/sh -exec ./guile-test-env guile -s "$0" "$@" +exec ${srcdir:-.}/guile-test-env guile -s "$0" "$@" !# (use-modules (gw-test-enumeration)) diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/test/test-gtkobj g-wrap/test/test-gtkobj --- g-wrap.orig/test/test-gtkobj 2002-11-07 18:23:42.000000000 +0100 +++ g-wrap/test/test-gtkobj 2003-08-04 15:29:50.000000000 +0200 @@ -1,5 +1,5 @@ #!/bin/sh -exec ./guile-test-env guile -s "$0" "$@" +exec ${srcdir:-.}/guile-test-env guile -s "$0" "$@" !# (use-modules (g-wrap gw-gtk-spec)) diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/test/test-gw-glib g-wrap/test/test-gw-glib --- g-wrap.orig/test/test-gw-glib 2002-11-07 18:23:42.000000000 +0100 +++ g-wrap/test/test-gw-glib 2003-08-04 15:29:32.000000000 +0200 @@ -1,5 +1,5 @@ #!/bin/sh -exec ./guile-test-env guile -s "$0" "$@" +exec ${srcdir:-.}/guile-test-env guile -s "$0" "$@" !# (use-modules (gw-test-glib)) diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/test/test-gw-standard g-wrap/test/test-gw-standard --- g-wrap.orig/test/test-gw-standard 2002-11-07 18:23:42.000000000 +0100 +++ g-wrap/test/test-gw-standard 2003-08-04 15:28:54.000000000 +0200 @@ -1,5 +1,5 @@ #!/bin/sh -exec ./guile-test-env guile -s "$0" "$@" +exec ${srcdir:-.}/guile-test-env guile -s "$0" "$@" !# (use-modules (gw-test-standard)) diff -xconfigure -xaclocal.m4 -xMakefile.in --recursive -u g-wrap.orig/test/test-gw-wct g-wrap/test/test-gw-wct --- g-wrap.orig/test/test-gw-wct 2002-11-07 18:23:42.000000000 +0100 +++ g-wrap/test/test-gw-wct 2003-08-04 15:29:20.000000000 +0200 @@ -1,5 +1,5 @@ #!/bin/sh -exec ./guile-test-env guile -s "$0" "$@" +exec ${srcdir:-.}/guile-test-env guile -s "$0" "$@" !# (use-modules (test gw-test-child))