The scripts are responsible for a backward compatibility.
orb_id is now being passed to forbrun from the scripts.
However, the scripts do not pass the make. Omk accepts .sh
extension instead of no extension scripts.
Minor bugs fixed also.
LOCAL_CONFIG_H = fcb_config.h
+bin_SCRIPTS += fcb
+
# include-pass_HOOKS = fcb_contract_gavl.inc
# fcb_contract_gavl.inc: $(SOURCES_DIR)/fcb_contract_gavl.c
--- /dev/null
+#!/bin/sh
+
+./forbrun -i "org.frescor.fcb" ../lib/libcbroker.so "$@"
forb_executor_t executor;
int ret;
forb_init_attr_t attr = {
- .orb_id = "org.frescor.fcb",
.peer_discovery_callback = peer_discovery_callback,
.peer_dead_callback = peer_dead_callback,
.fixed_tcp_port = FCB_TCP_PORT,
memset(&fcb_data, 0, sizeof(fcb_data));
fosa_clock_get_time(CLOCK_REALTIME, &start_time);
- if (opt_daemon)
- forb_daemon_prepare(opt_pidfile);
+
#if CONFIG_FCB_INET && !CONFIG_FORB_PROTO_INET_DEFAULT
ret = register_inet_port(orb);
include_HEADERS = cluster_tree.h
include_GEN_HEADERS = cluster_tree_idl.h
+bin_SCRIPTS += cluster_tree
+
endif
--- /dev/null
+#!/bin/sh
+
+./forbrun -i "org.frescor.frm.cluster_tree" ../lib/libfrm_cluster_tree.so "$@"
int forb_main(forb_orb orb, int argc, char *argv[])
{
int ret;
- forb_init_attr_t attr = { .orb_id = "org.frescor.frm.cluster_tree" };
-
fres_block_register_cluster_tree();
ret = frm_register_and_run(orb, &frm);
LOADLIBES += -Xlinker -rpath -Xlinker $(AQUOSA_ROOT)/lib
frm_aqcpu_LIBS = frm forb contract fosa rt ulut fcb_client qreslib qsuplib
lib_LOADLIBES+= frsh
+
+bin_SCRIPTS += frm_aqcpu
\ No newline at end of file
--- /dev/null
+#!/bin/sh
+
+./forbrun -i "org.frescor.frm.aqcpu" ../lib/libfrm_aqcpu.so "$@"
int forb_main(forb_orb orb, int argc, char *argv[])
{
int ret;
- forb_init_attr_t attr = { .orb_id = "org.frescor.frm.aqcpu" };
int opt;
bool opt_daemon = false;
char *opt_pidfile = NULL;
frm_cgcpu_SOURCES = frm_cgcpu.c
frm_cgcpu_LIBS = frm forb contract fosa rt ulut fcb_client
lib_LOADLIBES+= frsh
+
+bin_SCRIPTS += frm_cgcpu
\ No newline at end of file
--- /dev/null
+#!/bin/sh
+
+./forbrun -i "org.frescor.frm.cgcpu" ../lib/libfrm_cgcpu.so "$@"
FILE* fd;
int ret;
int opt;
- forb_init_attr_t attr = { .orb_id = "org.frescor.frm.cgcpu" };
bool opt_daemon = false;
char *opt_pidfile = NULL;
include_HEADERS = res_dummy.h
include_GEN_HEADERS = res_dummy_idl.h
+
+bin_SCRIPTS += frm_dummy
\ No newline at end of file
--- /dev/null
+#!/bin/sh
+
+./forbrun -i "org.frescor.frm.dummy" ../lib/libfrm_dummy.so "$@"
static struct option long_opts[] = {
{ "loglevel", 1, 0, 'l' },
-// { "id", required_argument, 0, 'i' },
+ { "id", required_argument, 0, 'i' },
{ "accept-all", 0, 0, 'a' },
{ "help", 0, 0, 'h' },
{ 0, 0, 0, 0}
printf("usage: frm_dummy [ options ]\n");
printf(" -a, --accept-all Accepts all contracts\n");
printf(" -d, --daemon [pid-file] go to background after FORB initialization\n");
-/* printf(" -i, --id <resource id> Use a different id that the default (%d)\n", DUMMY_RESOURCE_ID);*/
+ printf(" -i, --id <resource id> Use a different id that the default (%d)\n", DUMMY_RESOURCE_ID);
printf(" -h, --help Display this help\n");
printf(" -l, --loglevel <number>|<domain>=<number>,...\n");
}
int forb_main(forb_orb orb, int argc, char *argv[])
{
int ret;
- forb_init_attr_t attr = { .orb_id = "org.frescor.frm.dummy" };
int opt;
while ((opt = getopt_long(argc, argv, "ai:l:h", &long_opts[0], NULL)) != EOF) {
opt_daemon = true;
opt_pidfile = optarg;
break;
-// case 'i':
-// opt_res_id = atoi(optarg);
-// break;
+ case 'i':
+ opt_res_id = atoi(optarg);
+ break;
case 'l':
ul_log_domain_arg2levels(optarg);
break;
include_HEADERS = res_fpga.h
include_GEN_HEADERS = res_fpga_idl.h
+
+bin_SCRIPTS += fpga
endif
--- /dev/null
+#!/bin/sh
+
+./forbrun -i "org.frescor.frm.fpga" ../lib/libfrm_fpga.so "$@"
int forb_main(forb_orb orb, int argc, char *argv[])
{
int ret;
- forb_init_attr_t attr = { .orb_id = "org.frescor.frm.fpga" };
/* Register fres_block_fpga to contract handling
* functions */
include_HEADERS = item.h
include_GEN_HEADERS = item_idl.h
+bin_SCRIPTS += item
+
SUBDIRS=tests
endif
--- /dev/null
+#!/bin/sh
+
+./forbrun -i "org.frescor.frm.item" ../lib/libfrm_item.so "$@"
char platform[]="telosb";
char *parametrsITEM[] ={NULL,device,platform};
- forb_init_attr_t attr = { .orb_id = "org.frescor.frm.item" };
-
fres_block_register_item();