Skip to content

Commit

Permalink
dat2json_cli, yatc_cli: Made them build with bazel again. Documented …
Browse files Browse the repository at this point in the history
…invocation.
  • Loading branch information
ivucica committed Sep 15, 2023
1 parent 46b3552 commit d154a4b
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 4 deletions.
19 changes: 15 additions & 4 deletions cli/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ filegroup(

cc_library(
name = "dat2json_cli_lib",
defines = ["CLI_ONLY=1", "BAZEL_BUILD=1"] + select({
defines = ["CLI_ONLY=1", "HAVE_TOMMATH=1", "BAZEL_BUILD=1"] + select({
"//conditions:default": [],
"//:windows": ["WIN32=1",],
"//:windows_msys": ["WIN32=1",],
Expand All @@ -178,7 +178,8 @@ cc_library(
"creatureui.cpp", "//:creatureui.h",
"thingui.cpp", "//:thingui.h",
"effectui.cpp", "//:effectui.h",
"objects.cpp", "//:objects.h",
#"objects.cpp",
"//:objects.h",
"distanceui.cpp", "//:distanceui.h",
"itemui.cpp", "//:itemui.h",
"notifications.cpp", "//:notifications.h",
Expand Down Expand Up @@ -218,15 +219,23 @@ cc_library(
"//net:protocolgame.h",
"//net:protocollogin.h",
"//net:protocollogin.cpp",
#"//net:rsa.h",
#"//net:rsa.cpp",
"//net:rsa.h",
"//net:rsa.cpp",

"//:util.cpp",
"//:util.h",
"//:product.h",
"//:macutil.h",

"//gamecontent:item.cpp",
"//gamecontent:viplist.cpp",
"//:objects.cpp",
"//:options.cpp", "//:options.h", "//:confighandler.h", "//:confighandler.cpp",
"//:bigint.h",
"//:bigint.cpp",

":protocolgamehdrs",
":protocolgamesrcs", # why?
"dat2json_cli.cpp",
],
deps = [
Expand Down Expand Up @@ -255,6 +264,8 @@ cc_library(
}),
data = [
"@tibia854//:Tibia.dat",
"@tibia854//:Tibia.spr",
"@tibia854//:Tibia.pic",
],
copts = select({
"//conditions:default": ["-isystem external/tommath"],
Expand Down
20 changes: 20 additions & 0 deletions cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,23 @@ not been eliminated.

The client is just for experimentation, and thus no care was taken to make it
autoconf'igurable.

It can be build with either `make` or:

```
bazel build --define LOGIN_ONLY=1 :yatc_cli
```

`LOGIN_ONLY` is required at this time. Gameworld connections are not supported
at this time.

## dat2json

This is also the directory where, at this time, it made the most sense to place
dat2json. It can be built with either `make` or:

```
bazel build --define LOGIN_ONLY=1 //cli:dat2json_cli
```

`LOGIN_ONLY` is required at this time.

0 comments on commit d154a4b

Please sign in to comment.